python-typeshed-client
LOW
maintainer Smoolak
0 votes
scanned 2026-09-21 19:35:51.541891
Why flagged
Uploaded within the last 14 days with 2 or fewer community votes — little peer review so far.
Triggered rules
Low
Few votes, recently uploaded
zero_votes_recent
Uploaded within the last 14 days with 2 or fewer community votes — little peer review so far.
PKGBUILD
1
# Maintainer: Smoolak <smoolak@gmail.com>
2
3
pkgname=python-typeshed-client
4
_name=typeshed_client
5
pkgver=2.12.0
6
pkgrel=2
7
pkgdesc='Library for accessing and resolving type stubs from typeshed'
8
arch=('any')
9
url='https://github.com/JelleZijlstra/typeshed_client'
10
license=('MIT')
11
depends=(
12
'python>=3.9'
13
'python-importlib_resources>=1.4.0'
14
'python-typing_extensions>=4.5.0'
15
)
16
makedepends=(
17
'python-build'
18
'python-installer'
19
'python-setuptools>=42'
20
'python-wheel'
21
)
22
source=(
23
"$pkgname-$pkgver.tar.gz::$url/archive/refs/tags/v$pkgver.tar.gz"
24
'LICENSE'
25
)
26
sha256sums=(
27
'e8ad507a8cb776e45c9a757b2ab3101ef53dfdf8528319e49669ee454d05f671'
28
'febc00dc5a0557ca8afbcdc6d3896731dc42f4cecabd87e6c98326212f8dbf36'
29
)
30
31
build() {
32
cd "$_name-$pkgver"
33
python -m build --wheel --no-isolation
34
}
35
36
check() {
37
local _site
38
_site="$(python -c 'import sysconfig; print(sysconfig.get_path("purelib"))')"
39
40
rm -rf "$srcdir/_check" "$srcdir/_testroot"
41
python -m installer --destdir="$srcdir/_check" "$_name-$pkgver"/dist/*.whl
42
install -d "$srcdir/_testroot"
43
cp -a "$_name-$pkgver/tests" "$srcdir/_testroot/"
44
45
cd "$srcdir/_testroot"
46
PYTHONNOUSERSITE=1 \
47
PYTHONPATH="$srcdir/_check$_site" \
48
python -P tests/test.py
49
50
PYTHONNOUSERSITE=1 \
51
PYTHONPATH="$srcdir/_check$_site" \
52
python -P - <<'PY'
53
from pathlib import Path
54
55
import typeshed_client
56
57
module_path = Path(typeshed_client.__file__).resolve()
58
stub_path = typeshed_client.get_stub_file("pathlib")
59
names = typeshed_client.get_stub_names("argparse")
60
resolved = typeshed_client.Resolver().get_fully_qualified_name(
61
"collections.Counter"
62
)
63
64
assert "_check" in module_path.parts
65
assert stub_path is not None
66
assert stub_path.name == "__init__.pyi" and stub_path.parent.name == "pathlib"
67
assert names is not None and "ArgumentParser" in names
68
assert resolved is not None
69
PY
70
}
71
72
package() {
73
cd "$_name-$pkgver"
74
PYTHONHASHSEED=0 python -m installer \
75
--compile-bytecode 1 \
76
--destdir="$pkgdir" \
77
dist/*.whl
78
install -Dm644 LICENSE \
79
"$pkgdir/usr/share/licenses/$pkgname/LICENSE.upstream"
80
install -Dm644 "$srcdir/LICENSE" \
81
"$pkgdir/usr/share/licenses/$pkgname/LICENSE.packaging"
82
}
83
84
# vim:set ts=2 sw=2 et:
85
Scan history
| Scanned at (UTC) | Severity | Rules |
|---|---|---|
| 2026-09-21 19:35:51 | Low | 1 |