Skip to content

Commit

Permalink
Merge with dev
Browse files Browse the repository at this point in the history
  • Loading branch information
barseghyanartur committed Feb 27, 2023
2 parents 9c1b1bb + 8b04549 commit 1626e84
Show file tree
Hide file tree
Showing 35 changed files with 305 additions and 524 deletions.
2 changes: 0 additions & 2 deletions .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ omit =
src/tld/parsers/*
.tox/*
src_*/*
src_py27/*
src_py35/*

relative_files = True

Expand Down
36 changes: 2 additions & 34 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,38 +28,6 @@ jobs:
- name: Run pre-commit
uses: pre-commit/[email protected]

# *************************************
# ************* Python 3.6 ************
# *************************************
test-python-36:
runs-on: ubuntu-20.04
strategy:
fail-fast: false
max-parallel: 5
matrix:
include:
- python-version: '3.6'
tox_env: py36
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python-version }}
- name: Install Dependencies
run: |
python -m pip install --upgrade pip
pip install pip-tools
pip-compile requirements/testing.in
pip install -r requirements/testing.txt
- name: Run Tests
run: tox -e ${{ matrix.tox_env }}
- name: Coveralls
uses: AndreMiras/coveralls-python-action@develop
with:
parallel: true
flag-name: Run Tests

# *************************************
# ********** Python 3.7-3.11 **********
# *************************************
Expand All @@ -81,9 +49,9 @@ jobs:
- python-version: '3.11'
tox_env: py311
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v1
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install Dependencies
Expand Down
5 changes: 5 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ are used for versioning (schema follows below):
0.3.4 to 0.4).
- All backwards incompatible changes are mentioned in this document.

0.13
----

- Drop Python 2.7, 3.5 and 3.6 support. Minimum required version now is Python 3.7.

0.12.7
------
2023-02-01
Expand Down
61 changes: 2 additions & 59 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,7 @@ Optionally raises exceptions on non-existing TLDs or silently fails (if

Prerequisites
=============
- Python 3.6, 3.7, 3.8, 3.9, 3.10 or 3.11.

`Support for Python 2.7 and 3.5`_ is available as well.
- Python 3.7, 3.8, 3.9, 3.10 or 3.11.

Documentation
=============
Expand Down Expand Up @@ -267,61 +265,6 @@ To free up memory occupied by loading of custom TLD names, use
# Free resources occupied by the custom TLD names list
reset_tld_names("tests/res/effective_tld_names_custom.dat.txt")
Support for Python 2.7 and 3.5
==============================
As you might have noticed, typing (Python 3.6+) is extensively used in the code.
However, Python 3.5 will likely be supported until it's EOL. All modern recent
versions (starting from `tld` 0.11.7) are fully compatible with
Python 2.7 and 3.5 (just works with ``pip install tld``).
**Install from pip**
.. code-block:: sh
pip install tld
Development tips follow:
Python 2.7
----------
**Install locally in development mode**
.. code-block:: sh
python setup.py develop --python-tag py27
**Prepare dist**
.. code-block:: sh
./scripts/prepare_build_py27.sh
**Run tests**
.. code-block:: sh
tox -e py27
Python 3.5
----------
**Install locally in development mode**
.. code-block:: sh
python setup.py develop --python-tag py35
**Prepare dist**
.. code-block:: sh
./scripts/prepare_build_py35.sh
**Run tests**
.. code-block:: sh
tox -e py35
Troubleshooting
===============
If somehow domain names listed `here <https://publicsuffix.org/list/public_suffix_list.dat>`_
Expand All @@ -344,7 +287,7 @@ Simply type:
.. code-block:: sh
./runtests.py
pytest
Or use tox:
Expand Down
7 changes: 3 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

[tool.black]
line-length = 80
target-version = ['py36', 'py37', 'py38', 'py39', 'py310', 'py311']
target-version = ['py37', 'py38', 'py39', 'py310', 'py311']
include = '\.pyi?$'
extend-exclude = '''
/(
Expand Down Expand Up @@ -35,8 +35,8 @@ force_grid_wrap = 0
use_parentheses = true
ensure_newline_before_comments = true
line_length = 80
known_first_party = "faker_file"
known_third_party = ["django", "factory"]
known_first_party = "tld"
known_third_party = ["faker"]
skip = ["wsgi.py",]

[tool.ruff]
Expand Down Expand Up @@ -67,7 +67,6 @@ exclude = [
"dist",
"node_modules",
"venv",
"examples/django_example/project/wsgi.py",
"examples/gae/data.py",
]
per-file-ignores = {}
Expand Down
2 changes: 1 addition & 1 deletion pytest.ini
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ python_files =
test.py
test_*.py
tests.py
python_paths =
pythonpath =
src
examples/gae
addopts=
Expand Down
4 changes: 2 additions & 2 deletions requirements/bench.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ kiwisolver==1.4.4
# via matplotlib
line-profiler==4.0.2
# via -r bench.in
matplotlib==3.6.3
matplotlib==3.7.0
# via -r bench.in
memory-profiler==0.61.0
# via -r bench.in
numpy==1.24.1
numpy==1.24.2
# via
# contourpy
# matplotlib
Expand Down
11 changes: 5 additions & 6 deletions requirements/code_style.in
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
# Style checkers
black
doc8
isort
mypy
pre-commit
#pydocstyle
#pylint
ruff
isort
pre-commit
mypy<=0.256; python_version <= '2.7'
mypy; python_version >= '2.7'
black
doc8
22 changes: 12 additions & 10 deletions requirements/code_style.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#
# pip-compile code_style.in
#
black==22.12.0
black==23.1.0
# via -r code_style.in
cfgv==3.3.1
# via pre-commit
Expand All @@ -20,46 +20,48 @@ docutils==0.19
# restructuredtext-lint
filelock==3.9.0
# via virtualenv
identify==2.5.17
identify==2.5.18
# via pre-commit
isort==5.12.0
# via -r code_style.in
mypy==0.991 ; python_version >= "2.7"
mypy==1.0.1
# via -r code_style.in
mypy-extensions==0.4.3
mypy-extensions==1.0.0
# via
# black
# mypy
nodeenv==1.7.0
# via pre-commit
packaging==23.0
# via black
pathspec==0.11.0
# via black
pbr==5.11.1
# via stevedore
platformdirs==2.6.2
platformdirs==3.0.0
# via
# black
# virtualenv
pre-commit==3.0.2
pre-commit==3.1.0
# via -r code_style.in
pygments==2.14.0
# via doc8
pyyaml==6.0
# via pre-commit
restructuredtext-lint==1.4.0
# via doc8
ruff==0.0.238
ruff==0.0.253
# via -r code_style.in
stevedore==4.1.1
stevedore==5.0.0
# via doc8
tomli==2.0.1
# via
# black
# doc8
# mypy
typing-extensions==4.4.0
typing-extensions==4.5.0
# via mypy
virtualenv==20.17.1
virtualenv==20.19.0
# via pre-commit

# The following packages are considered to be unsafe in a requirements file:
Expand Down
4 changes: 2 additions & 2 deletions requirements/debug.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ executing==1.2.0
# via stack-data
ipdb==0.13.11
# via -r debug.in
ipython==8.9.0
ipython==8.10.0
# via
# -r debug.in
# ipdb
Expand All @@ -30,7 +30,7 @@ pexpect==4.8.0
# via ipython
pickleshare==0.7.5
# via ipython
prompt-toolkit==3.0.36
prompt-toolkit==3.0.37
# via ipython
ptyprocess==0.7.0
# via pexpect
Expand Down
Loading

0 comments on commit 1626e84

Please sign in to comment.