Skip to content

Scrapy, a fast high-level web crawling & scraping framework for Python.

Added constrain on lxml version based on Python version

Renne Rochaa25e09ecdd6b
diff --git a/requirements-py3.txt b/requirements-py3.txt
index 5a5d4c95a..478ed0010 100644
--- a/requirements-py3.txt
+++ b/requirements-py3.txt
@@ -1,5 +1,6 @@
Twisted>=17.9.0
-lxml>=3.2.4
+lxml;python_version!="3.4"
+lxml<=4.3.5;python_version=="3.4"
pyOpenSSL>=0.13.1
cssselect>=0.9
queuelib>=1.1.1
diff --git a/setup.py b/setup.py
index 4dc6d18c1..ee0aaabf0 100644
--- a/setup.py
+++ b/setup.py
@@ -69,7 +69,8 @@ setup(
'Twisted>=13.1.0,<=19.2.0;python_version=="3.4"',
'w3lib>=1.17.0',
'queuelib',
- 'lxml',
+ 'lxml;python_version!="3.4"',
+ 'lxml<=4.3.5;python_version=="3.4"',
'pyOpenSSL',
'cssselect>=0.9',
'six>=1.5.2',
diff --git a/tests/constraints.txt b/tests/constraints.txt
index e59e68b3f..5655ac2d3 100644
--- a/tests/constraints.txt
+++ b/tests/constraints.txt
@@ -1,2 +1 @@
-Twisted!=18.4.0
-lxml!=4.2.2
\ No newline at end of file
+Twisted!=18.4.0
\ No newline at end of file