Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
CaosDB Crawler
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
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 Crawler
Commits
3a1384d7
Commit
3a1384d7
authored
4 months ago
by
Florian Spreckelsen
Browse files
Options
Downloads
Patches
Plain Diff
FIX: Raise NotImplementedError at correct position
parent
f0a56809
No related branches found
No related tags found
2 merge requests
!217
TST: Make NamedTemporaryFiles Windows-compatible
,
!208
ENH: Allow crawler_main to operate on a list of paths
Pipeline
#58678
passed
4 months ago
Stage: info
Stage: setup
Stage: cert
Stage: style
Stage: test
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/caoscrawler/crawl.py
+6
-10
6 additions, 10 deletions
src/caoscrawler/crawl.py
with
6 additions
and
10 deletions
src/caoscrawler/crawl.py
+
6
−
10
View file @
3a1384d7
...
...
@@ -661,6 +661,12 @@ one with the entities that need to be updated and the other with entities to be
"
use for example the Scanner to create this data.
"
))
crawled_data
=
self
.
crawled_data
if
isinstance
(
path_for_authorized_run
,
list
)
and
self
.
securityMode
!=
SecurityMode
.
UPDATE
:
raise
NotImplementedError
(
"
Authorization of inserts and updates is currently implemented only
"
"
for single paths, not for lists of paths.
"
)
to_be_inserted
,
to_be_updated
=
self
.
_split_into_inserts_and_updates
(
SyncGraph
(
crawled_data
,
self
.
identifiableAdapter
))
...
...
@@ -718,21 +724,11 @@ one with the entities that need to be updated and the other with entities to be
update_cache
=
UpdateCache
()
pending_inserts
=
update_cache
.
get_inserts
(
self
.
run_id
)
if
pending_inserts
:
if
isinstance
(
path_for_authorized_run
,
list
):
raise
NotImplementedError
(
"
Authorization of inserts is currently implemented only for single paths,
"
"
not for lists of paths.
"
)
Crawler
.
inform_about_pending_changes
(
pending_inserts
,
self
.
run_id
,
path_for_authorized_run
)
pending_updates
=
update_cache
.
get_updates
(
self
.
run_id
)
if
pending_updates
:
if
isinstance
(
path_for_authorized_run
,
list
):
raise
NotImplementedError
(
"
Authorization of updates is currently implemented only for single paths,
"
"
not for lists of paths.
"
)
Crawler
.
inform_about_pending_changes
(
pending_updates
,
self
.
run_id
,
path_for_authorized_run
)
...
...
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