Skip to content

Commit

Permalink
Stop installing cchardet speedup under >Python 3.9
Browse files Browse the repository at this point in the history
`cchardet` stopped being maintained a while ago so this patch removes
it from the `speedups` extra to keep it helpful. It also makes the
same adjustment in the CI under the most recent CPython versions to
keep the testing going.

Refs:
* aio-libs#6819 (comment)
* PyYoshi/cChardet#77
  • Loading branch information
webknjaz committed Aug 3, 2022
1 parent 0db3362 commit 16e3e5a
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 2 deletions.
2 changes: 2 additions & 0 deletions CHANGES/6857.misc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Excluded :term:`cchardet` from the ``speedups`` extra in the package
metadata under Python 3.10 or higher -- by :user:`webknjaz`.
5 changes: 5 additions & 0 deletions docs/_snippets/cchardet-unmaintained-admonition.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
.. warning::

Note that the :term:`cchardet` project is known not to support
Python 3.10 or higher. See :issue:`6819` and
:gh:`PyYoshi/cChardet/issues/77` for more details.
2 changes: 2 additions & 0 deletions docs/glossary.rst
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,8 @@

https://pypi.python.org/pypi/cchardet/

.. include:: _snippets/cchardet-unmaintained-admonition.rst

gunicorn

Gunicorn 'Green Unicorn' is a Python WSGI HTTP Server for
Expand Down
2 changes: 2 additions & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ replacement for :term:`charset-normalizer`:
$ pip install cchardet
.. include:: _snippets/cchardet-unmaintained-admonition.rst

For speeding up DNS resolving by client API you may install
:term:`aiodns` as well.
This option is highly recommended:
Expand Down
2 changes: 1 addition & 1 deletion requirements/base.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ aiosignal==1.2.0
async-timeout==4.0.2
asynctest==0.13.0; python_version<"3.8"
Brotli==1.0.9
cchardet==2.1.7
cchardet==2.1.7; python_version < "3.10" # Unmaintained: aio-libs/aiohttp#6819
charset-normalizer==2.0.12
frozenlist==1.3.1
gunicorn==20.1.0
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ install_requires =
speedups =
aiodns >= 1.1
Brotli
cchardet
cchardet; python_version < "3.10"

[options.packages.find]
exclude =
Expand Down

0 comments on commit 16e3e5a

Please sign in to comment.