arachne
arachne copied to clipboard
Fix scrapy settings priority over global settings
What does this PR do?
- Fix the settings defined in default_settings.py not being applied. Currently, only settings specified in SCRAPY_SETTINGS, which itself is an empty dict are evaluated and applied.
- Fix settings defined in individual spiders in spider_scrappy_settings not overriding the default settings.
How should this be manually tested?
No separate/new tests required as those available cover the changes.
Background context
I had wanted to use this module for some scrapping work, but item_pipelines were never applied. This should fix that.
Tested and works on Python 2.7 and 3.6.1
This should fix issue: https://github.com/kirankoduru/arachne/issues/17
Coverage decreased (-0.8%) to 94.186% when pulling 2ba4f7e0159a43a4a89a6781ed8eac078645679e on dmkitui:fix-scrapy-settings-priority-over-global-settings into 8185ca2e5cc615ee1acec62e35f051602129f6df on kirankoduru:master.
Coverage decreased (-0.8%) to 94.186% when pulling 2ba4f7e0159a43a4a89a6781ed8eac078645679e on dmkitui:fix-scrapy-settings-priority-over-global-settings into 8185ca2e5cc615ee1acec62e35f051602129f6df on kirankoduru:master.
@kirankoduru Have a look and revert with your thoughts. Meanwhile, I will have a go at the tests and try to make the coverage check comply.