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
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
caosdb
Software
CaosDB Crawler
Commits
3f657d91
Commit
3f657d91
authored
2 years ago
by
Henrik tom Wörden
Browse files
Options
Downloads
Patches
Plain Diff
fixes
parent
da700e99
No related branches found
No related tags found
3 merge requests
!108
Release 0.5.0
,
!106
Suggestion htw
,
!104
Create a new scanner module and move functions from crawl module there
Pipeline
#34935
passed
2 years ago
Stage: info
Stage: setup
Stage: cert
Stage: style
Stage: test
Changes
2
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
integrationtests/basic_example/test_basic.py
+1
-1
1 addition, 1 deletion
integrationtests/basic_example/test_basic.py
src/caoscrawler/crawl.py
+4
-2
4 additions, 2 deletions
src/caoscrawler/crawl.py
with
5 additions
and
3 deletions
integrationtests/basic_example/test_basic.py
+
1
−
1
View file @
3f657d91
...
@@ -292,7 +292,7 @@ def test_file_insertion_dry(clear_database, usemodel, ident):
...
@@ -292,7 +292,7 @@ def test_file_insertion_dry(clear_database, usemodel, ident):
def
test_file_insertion
(
clear_database
,
usemodel
,
ident
,
crawler_extended
):
def
test_file_insertion
(
clear_database
,
usemodel
,
ident
,
crawler_extended
):
ins
,
ups
=
crawler_extended
[
0
].
synchronize
(
ins
,
ups
=
crawler_extended
[
0
].
synchronize
(
crawled_data
=
deepcopy
(
crawler_extended
[
1
]
)
,
commit_changes
=
True
)
crawled_data
=
crawler_extended
[
1
],
commit_changes
=
True
)
file_list_ins
=
[
r
for
r
in
ins
if
r
.
role
==
"
File
"
]
file_list_ins
=
[
r
for
r
in
ins
if
r
.
role
==
"
File
"
]
assert
len
(
file_list_ins
)
==
11
assert
len
(
file_list_ins
)
==
11
...
...
This diff is collapsed.
Click to expand it.
src/caoscrawler/crawl.py
+
4
−
2
View file @
3f657d91
...
@@ -869,12 +869,14 @@ class Crawler(object):
...
@@ -869,12 +869,14 @@ class Crawler(object):
pending_inserts
=
update_cache
.
get_inserts
(
self
.
run_id
)
pending_inserts
=
update_cache
.
get_inserts
(
self
.
run_id
)
if
pending_inserts
:
if
pending_inserts
:
Crawler
.
inform_about_pending_changes
(
Crawler
.
inform_about_pending_changes
(
pending_inserts
,
self
.
run_id
,
self
.
crawled_directory
)
# TODO crawled_directory is no longer available
pending_inserts
,
self
.
run_id
,
"
missing crawled_directory
"
)
pending_updates
=
update_cache
.
get_updates
(
self
.
run_id
)
pending_updates
=
update_cache
.
get_updates
(
self
.
run_id
)
if
pending_updates
:
if
pending_updates
:
Crawler
.
inform_about_pending_changes
(
Crawler
.
inform_about_pending_changes
(
pending_updates
,
self
.
run_id
,
self
.
crawled_directory
)
# TODO crawled_directory is no longer available
pending_updates
,
self
.
run_id
,
"
missing crawled_directory
"
)
return
(
to_be_inserted
,
to_be_updated
)
return
(
to_be_inserted
,
to_be_updated
)
...
...
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