Skip to content
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

UrlLengthMiddleware: don't skip silently #5036

Merged
merged 4 commits into from
Mar 19, 2021

Conversation

dmiwell
Copy link
Contributor

@dmiwell dmiwell commented Mar 12, 2021

I guess it's a good idea to not just send the skipped info to debug, since it could be critical and not so obvious to debug in case of accidental long url generating.

So it's better to log to INFO at least, and add count to crawler stats.

@codecov
Copy link

codecov bot commented Mar 12, 2021

Codecov Report

Merging #5036 (3d2618b) into master (ab037ab) will decrease coverage by 0.18%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master    #5036      +/-   ##
==========================================
- Coverage   88.01%   87.82%   -0.19%     
==========================================
  Files         158      158              
  Lines        9736     9737       +1     
  Branches     1435     1435              
==========================================
- Hits         8569     8552      -17     
- Misses        911      929      +18     
  Partials      256      256              
Impacted Files Coverage Δ
scrapy/spidermiddlewares/urllength.py 90.47% <100.00%> (+0.47%) ⬆️
scrapy/robotstxt.py 75.30% <0.00%> (-22.23%) ⬇️

scrapy/spidermiddlewares/urllength.py Outdated Show resolved Hide resolved
scrapy/spidermiddlewares/urllength.py Outdated Show resolved Hide resolved
@kmike kmike merged commit 0e7ee12 into scrapy:master Mar 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants