Skip to content

Commit

Permalink
maintenance: deprecate Python 3.6 & 3.7 (#105)
Browse files Browse the repository at this point in the history
* maintenance: deprecate Python 3.6 & 3.7

* fix typos
  • Loading branch information
adbar committed Jun 14, 2024
1 parent b38ca2d commit 5378869
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 16 deletions.
4 changes: 0 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,6 @@ jobs:
python-version: [3.8, 3.9, "3.10", "3.11", "3.12", "3.13-dev"]
include:
# other OS version necessary
- os: ubuntu-20.04
python-version: 3.6
- os: ubuntu-20.04
python-version: 3.7
- os: macos-latest
python-version: "3.10"
- os: windows-latest
Expand Down
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,9 @@ $ pip install --upgrade courlan # to make sure you have the latest version
$ pip install git+https://github.com/adbar/courlan.git # latest available code (see build status above)
```

The last version to support Python 3.6 and 3.7 is `courlan==1.2.0`.


## Python

Most filters revolve around the `strict` and `language` arguments.
Expand Down
3 changes: 1 addition & 2 deletions courlan/clean.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,8 +157,7 @@ def decode_punycode(string: str) -> str:
def normalize_part(url_part: str) -> str:
"""Normalize URLs parts (specifically path and fragment) while
accounting for certain characters."""
# "~" for compatibility with Python 3.6
return quote(url_part, safe="/%!=:,-~")
return quote(url_part, safe="/%!=:,-")


def normalize_fragment(fragment: str, language: Optional[str] = None) -> str:
Expand Down
2 changes: 1 addition & 1 deletion courlan/filters.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from typing import Any, Optional, Tuple
from urllib.parse import urlsplit

from babel import Locale, UnknownLocaleError # type: ignore
from babel import Locale, UnknownLocaleError


LOGGER = logging.getLogger(__name__)
Expand Down
13 changes: 4 additions & 9 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,7 @@ def get_long_description():
long_description_content_type="text/markdown",
classifiers=[
# As from http://pypi.python.org/pypi?%3Aaction=list_classifiers
"Development Status :: 4 - Beta",
#'Development Status :: 5 - Production/Stable',
"Development Status :: 5 - Production/Stable",
#'Development Status :: 6 - Mature',
"Environment :: Console",
"Intended Audience :: Developers",
Expand All @@ -72,8 +71,6 @@ def get_long_description():
"Operating System :: POSIX :: Linux",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
Expand Down Expand Up @@ -108,13 +105,11 @@ def get_long_description():
},
# package_data={},
include_package_data=True,
python_requires=">=3.6",
python_requires=">=3.8",
install_requires=[
"babel >= 2.11.0",
"tld == 0.12.6; python_version < '3.7'",
"tld >= 0.13; python_version >= '3.7'",
"urllib3 >= 1.26, < 2; python_version < '3.7'",
"urllib3 >= 1.26, < 3; python_version >= '3.7'",
"tld >= 0.13",
"urllib3 >= 1.26, < 3",
],
# extras_require=extras,
entry_points={
Expand Down

0 comments on commit 5378869

Please sign in to comment.