-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Port Crawler Improvements #258
base: master
Are you sure you want to change the base?
Conversation
Codecov Report
@@ Coverage Diff @@
## master #258 +/- ##
=========================================
- Coverage 15.83% 15.64% -0.2%
=========================================
Files 13 13
Lines 1894 1918 +24
Branches 328 331 +3
=========================================
Hits 300 300
- Misses 1592 1616 +24
Partials 2 2
Continue to review full report at Codecov.
|
collect.py
Outdated
|
||
from autowebcompat import utils | ||
|
||
already_clicked_elems = set() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have several crawler threads, so this can't be a global variable (otherwise the different threads will overwrite each other's variable).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just the concurrency problem to fix as far as I can see.
@sagarvijaygupta do you want to take a look too?
collect.py
Outdated
break | ||
else: | ||
children_to_ignore.extend(elems) | ||
else: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@marco-c This else
is not aligned correctly with its corresponding if
@sagarvijaygupta @marco-c so i made |
What if you put the try before the if-else for xpath? |
It can't be local to do_something, otherwise it gets cleared every time we click on something and thus it becomes ineffective. |
@marco-c where should i declare it instead? because one way i can think of is declaring it in the function which is calling it and pass it as a parameter |
@Shashi456 I think we should declare it in |
Yes, we should declare it in |
Fixes #236