Skip to content

Commit caec8e9

Browse files
committed
Split requirements-optional so chardet works on Python 2 and 3.
As the comment says, I am well aware how evil this is hardcoding the Debian URL, but this allows for testing of all supported optional extras, and given chardet is packaged for Python 3 in varies places, this seems worthwhile to support.
1 parent 2aff0a3 commit caec8e9

File tree

4 files changed

+11
-4
lines changed

4 files changed

+11
-4
lines changed

.travis.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ before_install:
1616
install:
1717
- pip install -r requirements.txt -r requirements-test.txt --use-mirrors
1818
- if [[ $USE_OPTIONAL == "true" ]]; then pip install -r requirements-optional.txt --use-mirrors; fi
19+
- if [[ $TRAVIS_PYTHON_VERSION != 3.* && $USE_OPTIONAL == "true" ]]; then pip install -r requirements-optional-2.txt --use-mirrors; fi
20+
- if [[ $TRAVIS_PYTHON_VERSION == 3.* && $USE_OPTIONAL == "true" ]]; then pip install -r requirements-optional-3.txt --use-mirrors; fi
1921
- if [[ $TRAVIS_PYTHON_VERSION != "pypy" && $USE_OPTIONAL == "true" ]]; then pip install -r requirements-optional-cpython.txt --use-mirrors; fi
2022

2123
script:

requirements-optional-2.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# chardet can be used as a fallback in case we are unable to determine
2+
# the encoding of a document.
3+
chardet

requirements-optional-3.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# chardet can be used as a fallback in case we are unable to determine
2+
# the encoding of a document.
3+
# And yes, I know it's evil hardcoding the Debian URL here. But alas,
4+
# there has never been a formal release supporting Python 3, though
5+
# several distros provide packages for it that support Python 3.
6+
http://ftp.us.debian.org/debian/pool/main/p/python3-chardet/python3-chardet_2.0.1.orig.tar.gz

requirements-optional.txt

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,6 @@
22
# streams.
33
genshi
44

5-
# chardet can be used as a fallback in case we are unable to determine
6-
# the encoding of a document.
7-
chardet
8-
95
# DATrie can be used in place of our Python trie implementation for
106
# slightly better parsing performance.
117
datrie

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy