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

Fix bug #5145 - Removing Selector for Response's that are not Http or Xml #5269

Merged
merged 1 commit into from
Oct 14, 2021
Merged

Fix bug #5145 - Removing Selector for Response's that are not Http or Xml #5269

merged 1 commit into from
Oct 14, 2021

Conversation

Ankur19
Copy link
Contributor

@Ankur19 Ankur19 commented Oct 9, 2021

Fixes #5145

  • set Selector to None when the response is of type base-response Response

Please provide feedback

@Gallaecio
Copy link
Member

It would be great to also get a test to prove the change works.

Fix condition for failing tests

set Selector to None on AttributeError

Add test and remove unused imports

Fix imports
@codecov
Copy link

codecov bot commented Oct 11, 2021

Codecov Report

Merging #5269 (6fbd6f9) into master (d3f1bf7) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##           master    #5269   +/-   ##
=======================================
  Coverage   88.52%   88.52%           
=======================================
  Files         163      163           
  Lines       10605    10608    +3     
  Branches     1557     1557           
=======================================
+ Hits         9388     9391    +3     
  Misses        942      942           
  Partials      275      275           
Impacted Files Coverage Δ
scrapy/loader/__init__.py 100.00% <100.00%> (ø)

Copy link
Member

@Gallaecio Gallaecio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nicely done, thanks!

@wRAR wRAR merged commit 5b13bfd into scrapy:master Oct 14, 2021
@Ankur19 Ankur19 deleted the allow-non-text-response-types-in-ItemLoader branch October 19, 2021 02:23
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.

ItemLoader: support non-TextResponse
3 participants