Skip to content

Commit

Permalink
add compatibility with 2.10
Browse files Browse the repository at this point in the history
  • Loading branch information
pawelmhm committed Sep 20, 2023
1 parent d8b6ff6 commit e76f2b9
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
strategy:
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11"]
scrapy-version: ["2.11"]
scrapy-version: ["2.11", "2.10"]

steps:
- uses: actions/checkout@v2
Expand Down
5 changes: 3 additions & 2 deletions scrapyrt/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,9 @@ def crawl(self, *args, **kwargs):
self.crawling = True
try:
self.spider = self._create_spider(*args, **kwargs)
self._apply_settings()
self._update_root_log_handler()
if hasattr(self, "_apply_settings"):
self._apply_settings()
self._update_root_log_handler()
self.engine = self._create_engine()
if self.start_requests:
start_requests = iter(self.spider.start_requests())
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
"Tracker": "https://github.com/scrapinghub/scrapyrt/issues"
},
install_requires=[
'Scrapy>=2.11'
'Scrapy>=2.10'
],
package_data={
'scrapyrt': [
Expand Down

0 comments on commit e76f2b9

Please sign in to comment.