Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
caosdb-pylib
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
caosdb
Software
caosdb-pylib
Commits
c746e377
Commit
c746e377
authored
5 months ago
by
I. Nüske
Browse files
Options
Downloads
Patches
Plain Diff
MNT: Hide namechange from API
parent
611bd4b1
No related branches found
Branches containing commit
No related tags found
Tags containing commit
2 merge requests
!159
Release 0.16.o
,
!155
Review filter lists and compare_entities
Pipeline
#57145
passed with warnings
5 months ago
Stage: code_style
Stage: linting
Stage: test
Stage: deploy
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/linkahead/apiutils.py
+4
-3
4 additions, 3 deletions
src/linkahead/apiutils.py
with
4 additions
and
3 deletions
src/linkahead/apiutils.py
+
4
−
3
View file @
c746e377
...
...
@@ -179,7 +179,7 @@ def getCommitIn(folder):
return
get_commit_in
(
folder
)
def
compare_entities
(
entity
0
:
Entity
,
entity
1
:
Entity
,
def
compare_entities
(
old_
entity
:
Entity
,
new_
entity
:
Entity
,
compare_referenced_records
:
bool
=
False
,
entity_name_id_equivalency
:
bool
=
False
)
->
tuple
[
dict
[
str
,
Any
],
dict
[
str
,
Any
]]:
...
...
@@ -219,9 +219,9 @@ def compare_entities(entity0: Entity, entity1: Entity,
Params
------
entity
0
: Entity
old_
entity : Entity
First entity to be compared.
entity
1
: Entity
new_
entity : Entity
Second entity to be compared.
compare_referenced_records: bool, default: False
If set to True, values with referenced records
...
...
@@ -252,6 +252,7 @@ def compare_entities(entity0: Entity, entity1: Entity,
# - Make the empty_diff functionality faster by adding a parameter to
# this function so that it returns after the first found difference?
# - Add parameter to restrict diff to some characteristics
entity0
,
entity1
=
old_entity
,
new_entity
diff
=
({
"
properties
"
:
{},
"
parents
"
:
[]},
{
"
properties
"
:
{},
"
parents
"
:
[]})
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment