summaryrefslogtreecommitdiff
path: root/dev-python/cchardet
diff options
context:
space:
mode:
Diffstat (limited to 'dev-python/cchardet')
-rw-r--r--dev-python/cchardet/Manifest3
-rw-r--r--dev-python/cchardet/cchardet-2.1.7-r1.ebuild31
-rw-r--r--dev-python/cchardet/files/cchardet-2.1.7-pytest.patch120
3 files changed, 0 insertions, 154 deletions
diff --git a/dev-python/cchardet/Manifest b/dev-python/cchardet/Manifest
index 1aba4332da3b..dbd35a609939 100644
--- a/dev-python/cchardet/Manifest
+++ b/dev-python/cchardet/Manifest
@@ -1,6 +1,3 @@
-AUX cchardet-2.1.7-pytest.patch 3529 BLAKE2B 2ce0bb1a7ee281477f471dad08b1e7819b9d47b96db2c4321b67185dd860de5f4e94150846e76ab8364bee079f823884af366256c8ad98ef0797987d2cab9a0c SHA512 0e7d126a49c3c1d2c810085aa1dd6fa1b1b38807876d168d3d459ea837bb8e146e0585c93a10599713a5511a76c328696ee0889d4c9a63ef8aee4d97b5df686a
-DIST cchardet-2.1.7.tar.gz 653617 BLAKE2B 0ca9becac01c67da191290c7de0dc52d5c8e6c2715f660811c8e67d9a06e74ac155a081de81af96ade74ccc4065093fc226f232a26f66236fafe9fc1b48a9c9e SHA512 43e663e30ec079b2a954862de5e8136a2e40f69e300d65eb4ce9d7ffa5d8c496dc7c0937b3306b4096cfad12a1d0617628f8f0115534ab6faf9eb39d2b3935a2
DIST faust-cchardet-2.1.19.tar.gz 678871 BLAKE2B e87389ef602bc5e69ae2037aff1000b9caacfd91a44c5eb8fb2084d4ac33772eb8e480b05109ff83ebfcb2b9a57e215b4bc9cc5558f4f7e1a19b58dd1dfca8b5 SHA512 bd75ddf8b2e9891fe6ecdfd687a6903342a24b93f35a3d9a1b20da9abc77684e73840db73da97689636e3412e33da25b68cfafad114186681d0dec98880ffe95
EBUILD cchardet-2.1.19.ebuild 566 BLAKE2B 31d3e2ea19b3e984ba33ccc0b412e2226b11fb28b47d2d4e0d1521b19a9d80c6a756c633ecdf3c735213727907249709b4e5d0896154ed3f742d889dc2724d8d SHA512 78ea53f3714c387495b426e5fc238e141514f5f2c157872657d8b4e669bcbcf128b104562c275012a5ae04ece31a615fd77013ea074b1b8c7a97ddd7d6505952
-EBUILD cchardet-2.1.7-r1.ebuild 601 BLAKE2B 9b32081169bcc78dad9a1b40ca7673acf67c20db089b3e2eb1730c02cc78c8016a27d8dca26ccebeb3c818791a4c28ebb769da9bb4dbe2571a814b0dc4eb8427 SHA512 79c8720f19a41ed1046f24ec74380c8ef0605272250755fab2f1961207dd02d0a95cf08a98f87fe4de2fd3b67a0a3eb2b18fc0dbc784ae810b94879df44456c1
MISC metadata.xml 461 BLAKE2B 465041740ce32a894081ad2f533ca436b111a61b289b6e9047088e54cbda0462f9b44520ee2aab0dbf4922dc823001e3d00343a775d0e411b9af07055e574df9 SHA512 1b65345c4440af61bea35d6fa1e897ae12f1b50d440542f2e45270f58e21069819b4bcfe85f0fb11f329d74da8ec22fea2d660907a48974a85cf886c1fc782c8
diff --git a/dev-python/cchardet/cchardet-2.1.7-r1.ebuild b/dev-python/cchardet/cchardet-2.1.7-r1.ebuild
deleted file mode 100644
index 3cb84bf4e1db..000000000000
--- a/dev-python/cchardet/cchardet-2.1.7-r1.ebuild
+++ /dev/null
@@ -1,31 +0,0 @@
-# Copyright 2021-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-DISTUTILS_EXT=1
-DISTUTILS_USE_PEP517=setuptools
-PYTHON_COMPAT=( python3_{10..12} )
-
-inherit distutils-r1 pypi
-
-DESCRIPTION="High speed universal character encoding detector"
-HOMEPAGE="
- https://github.com/PyYoshi/cChardet
- https://pypi.org/project/cchardet/
-"
-
-LICENSE="MPL-1.1"
-SLOT="0"
-KEYWORDS="amd64 ~arm x86"
-
-BDEPEND="
- dev-python/cython[${PYTHON_USEDEP}]
-"
-
-PATCHES=(
- # https://github.com/PyYoshi/cChardet/pull/78
- "${FILESDIR}/${P}-pytest.patch"
-)
-
-distutils_enable_tests pytest
diff --git a/dev-python/cchardet/files/cchardet-2.1.7-pytest.patch b/dev-python/cchardet/files/cchardet-2.1.7-pytest.patch
deleted file mode 100644
index 11f38579c184..000000000000
--- a/dev-python/cchardet/files/cchardet-2.1.7-pytest.patch
+++ /dev/null
@@ -1,120 +0,0 @@
-https://github.com/PyYoshi/cChardet/pull/78
-
-From: q0w <43147888+q0w@users.noreply.github.com>
-Date: Wed, 17 Nov 2021 14:50:41 +0300
-Subject: [PATCH 02/13] Use pytest
-
---- /dev/null
-+++ b/src/tests/cchardet_test.py
-@@ -0,0 +1,111 @@
-+import glob
-+import os
-+
-+import cchardet
-+
-+SKIP_LIST = [
-+ 'src/tests/testdata/ja/utf-16le.txt',
-+ 'src/tests/testdata/ja/utf-16be.txt',
-+ 'src/tests/testdata/es/iso-8859-15.txt',
-+ 'src/tests/testdata/da/iso-8859-1.txt',
-+ 'src/tests/testdata/he/iso-8859-8.txt'
-+]
-+
-+# Python can't decode encoding
-+SKIP_LIST_02 = [
-+ 'src/tests/testdata/vi/viscii.txt',
-+ 'src/tests/testdata/zh/euc-tw.txt'
-+]
-+SKIP_LIST_02.extend(SKIP_LIST)
-+
-+
-+def test_ascii():
-+ detected_encoding = cchardet.detect(b'abcdefghijklmnopqrstuvwxyz')
-+ assert 'ascii' == detected_encoding['encoding'].lower()
-+
-+
-+def test_detect():
-+ testfiles = glob.glob('src/tests/testdata/*/*.txt')
-+ for testfile in testfiles:
-+ if testfile.replace("\\", "/") in SKIP_LIST:
-+ continue
-+
-+ base = os.path.basename(testfile)
-+ expected_charset = os.path.splitext(base)[0]
-+ with open(testfile, 'rb') as f:
-+ msg = f.read()
-+ detected_encoding = cchardet.detect(msg)
-+ assert expected_charset.lower() == detected_encoding['encoding'].lower()
-+
-+
-+def test_detector():
-+ detector = cchardet.UniversalDetector()
-+ with open("src/tests/samples/wikipediaJa_One_Thousand_and_One_Nights_SJIS.txt", 'rb') as f:
-+ line = f.readline()
-+ while line:
-+ detector.feed(line)
-+ if detector.done:
-+ break
-+ line = f.readline()
-+ detector.close()
-+ detected_encoding = detector.result
-+ assert "shift_jis" == detected_encoding['encoding'].lower()
-+
-+
-+def test_github_issue_20():
-+ """
-+ https://github.com/PyYoshi/cChardet/issues/20
-+ """
-+ msg = b'\x8f'
-+
-+ cchardet.detect(msg)
-+
-+ detector = cchardet.UniversalDetector()
-+ detector.feed(msg)
-+ detector.close()
-+
-+
-+def test_decode():
-+ testfiles = glob.glob('src/tests/testdata/*/*.txt')
-+ for testfile in testfiles:
-+ if testfile.replace("\\", "/") in SKIP_LIST_02:
-+ continue
-+
-+ base = os.path.basename(testfile)
-+ expected_charset = os.path.splitext(base)[0]
-+ with open(testfile, 'rb') as f:
-+ msg = f.read()
-+ detected_encoding = cchardet.detect(msg)
-+ try:
-+ msg.decode(detected_encoding["encoding"])
-+ except LookupError as e:
-+ print("LookupError: { file=%s, encoding=%s }" % (
-+ testfile, detected_encoding["encoding"]))
-+ raise e
-+
-+
-+def test_utf8_with_bom():
-+ sample = b'\xEF\xBB\xBF'
-+ detected_encoding = cchardet.detect(sample)
-+ assert "utf-8-sig" == detected_encoding['encoding'].lower()
-+
-+
-+def test_null_bytes():
-+ sample = b'ABC\x00\x80\x81'
-+ detected_encoding = cchardet.detect(sample)
-+
-+ assert detected_encoding['encoding'] is None
-+
-+# def test_iso8859_2_csv(self):
-+# testfile = 'tests/samples/iso8859-2.csv'
-+# with open(testfile, 'rb') as f:
-+# msg = f.read()
-+# detected_encoding = cchardet.detect(msg)
-+# eq_(
-+# "iso8859-2",
-+# detected_encoding['encoding'].lower(),
-+# 'Expected %s, but got %s' % (
-+# "iso8859-2",
-+# detected_encoding['encoding'].lower()
-+# )
-+# )