14
0

Accepting request 843031 from devel:languages:python

- Update to 3.0.0:
  This release fixes the long standing bug that public and private
  suffixes were generated separately and could not be switched at
  runtime, https://github.com/john-kurkowski/tldextract/issues/66
  * Breaking Changes
    + Rename `cache_file` to `cache_dir` as it is no longer a
      single file but a directory
      (https://github.com/john-kurkowski/tldextract/issues/207)
    + Rename CLI arg also, from `--cache_file` to `--cache_dir`
    + Remove Python 2.7 support
  * Features
    + Can pass `include_psl_private_domains` on call, not only on
      construction
    + Use filelocking to support multi-processing and
      multithreading environments
  * Bugfixes
    + Select public or private suffixes at runtime
      (https://github.com/john-kurkowski/tldextract/issues/66)
  * Removals
    + Do not `debug` log the diff during update
  * Drop tldextract-tests-offline.patch

OBS-URL: https://build.opensuse.org/request/show/843031
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-tldextract?expand=0&rev=8
This commit is contained in:
2020-10-21 12:39:08 +00:00
committed by Git OBS Bridge
5 changed files with 33 additions and 35 deletions

View File

@@ -1,3 +1,29 @@
-------------------------------------------------------------------
Tue Oct 20 22:45:59 UTC 2020 - Mia Herkt <mia@0x0.st>
- Update to 3.0.0:
This release fixes the long standing bug that public and private
suffixes were generated separately and could not be switched at
runtime, https://github.com/john-kurkowski/tldextract/issues/66
* Breaking Changes
+ Rename `cache_file` to `cache_dir` as it is no longer a
single file but a directory
(https://github.com/john-kurkowski/tldextract/issues/207)
+ Rename CLI arg also, from `--cache_file` to `--cache_dir`
+ Remove Python 2.7 support
* Features
+ Can pass `include_psl_private_domains` on call, not only on
construction
+ Use filelocking to support multi-processing and
multithreading environments
* Bugfixes
+ Select public or private suffixes at runtime
(https://github.com/john-kurkowski/tldextract/issues/66)
* Removals
+ Do not `debug` log the diff during update
* Drop tldextract-tests-offline.patch
------------------------------------------------------------------- -------------------------------------------------------------------
Thu Sep 17 11:47:16 UTC 2020 - Dirk Mueller <dmueller@suse.com> Thu Sep 17 11:47:16 UTC 2020 - Dirk Mueller <dmueller@suse.com>

View File

@@ -16,9 +16,10 @@
# #
%define skip_python2 1
%{?!python_module:%define python_module() python-%{**} python3-%{**}} %{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-tldextract Name: python-tldextract
Version: 2.2.3 Version: 3.0.0
Release: 0 Release: 0
Summary: Python module to separate the TLD of a URL Summary: Python module to separate the TLD of a URL
License: BSD-3-Clause License: BSD-3-Clause
@@ -26,9 +27,8 @@ Group: Development/Languages/Python
URL: https://github.com/john-kurkowski/tldextract URL: https://github.com/john-kurkowski/tldextract
Source: https://files.pythonhosted.org/packages/source/t/tldextract/tldextract-%{version}.tar.gz Source: https://files.pythonhosted.org/packages/source/t/tldextract/tldextract-%{version}.tar.gz
Source1: %{name}-rpmlintrc Source1: %{name}-rpmlintrc
# No internet connection on OBS build hosts; skip suffix list snapshot diff
Patch0: tldextract-tests-offline.patch
### BEGIN test requirements ### BEGIN test requirements
BuildRequires: %{python_module filelock} >= 3.0.8
BuildRequires: %{python_module pytest-mock} BuildRequires: %{python_module pytest-mock}
BuildRequires: %{python_module pytest} BuildRequires: %{python_module pytest}
BuildRequires: %{python_module requests-file} >= 1.4 BuildRequires: %{python_module requests-file} >= 1.4
@@ -39,6 +39,7 @@ BuildRequires: %{python_module setuptools_scm}
BuildRequires: %{python_module setuptools} BuildRequires: %{python_module setuptools}
BuildRequires: fdupes BuildRequires: fdupes
BuildRequires: python-rpm-macros BuildRequires: python-rpm-macros
Requires: python-filelock >= 3.0.8
Requires: python-idna >= 2.1.0 Requires: python-idna >= 2.1.0
Requires: python-requests >= 2.1.0 Requires: python-requests >= 2.1.0
Requires: python-requests-file >= 1.4 Requires: python-requests-file >= 1.4
@@ -58,7 +59,6 @@ as well.
%prep %prep
%setup -q -n tldextract-%{version} %setup -q -n tldextract-%{version}
%autopatch -p1
%build %build
sed -i 's:--pylint::' pytest.ini sed -i 's:--pylint::' pytest.ini

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:ab0e38977a129c72729476d5f8c85a8e1f8e49e9202e1db8dca76e95da7be9a8
size 64729

3
tldextract-3.0.0.tar.gz Normal file
View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:fadb427ee522e2a5109e70cf95f3b1ac4cc1b8f4471ffaa83cda692866da7a0e
size 99718

View File

@@ -1,28 +0,0 @@
diff -ru tldextract-2.2.1.orig/tests/integration_test.py tldextract-2.2.1/tests/integration_test.py
--- tldextract-2.2.1.orig/tests/integration_test.py 2016-04-04 04:11:18.000000000 +0200
+++ tldextract-2.2.1/tests/integration_test.py 2019-03-10 21:25:34.201039604 +0100
@@ -8,24 +8,6 @@
import tldextract
-
-def test_log_snapshot_diff(mocker):
- mocker.patch.object(logging.getLogger(), 'level', logging.DEBUG)
- debug_mock = mocker.patch.object(logging.getLogger('tldextract'), 'debug')
-
- extractor = tldextract.TLDExtract()
- try:
- os.remove(extractor.cache_file)
- except (IOError, OSError):
- logging.warning(traceback.format_exc())
-
- extractor('ignore.com')
-
- assert debug_mock.call_count == 1
- log_str = debug_mock.call_args[0][0]
- assert log_str.startswith('computed TLD diff')
-
-
def test_bad_kwargs():
with pytest.raises(ValueError):
tldextract.TLDExtract(