From abfc9d28e52ab3f73d1f7ef87f0162a121031e2b Mon Sep 17 00:00:00 2001 From: "emdee@spm.plastiras.org" Date: Mon, 5 Feb 2024 14:26:19 +0000 Subject: [PATCH] update --- Makefile | 8 +++++--- pyproject.toml | 8 -------- setup.cfg | 6 ++---- stem_examples.txt | 26 +++++++++++++------------- 4 files changed, 20 insertions(+), 28 deletions(-) diff --git a/Makefile b/Makefile index 737b472..e946fbb 100644 --- a/Makefile +++ b/Makefile @@ -13,8 +13,10 @@ check:: lint:: sh .pylint.sh -xinstall:: - ${PIP_EXE_MSYS} install --target ${PREFIX}/lib/python3.11/site-packages/ --upgrade . +install:: + ${PIP_EXE_MSYS} --python ${PYTHON_EXE_MSYS} install \ + --target ${PREFIX}/lib/python${PYTHON_MINOR}/site-packages/ \ + --upgrade . rsync:: bash .rsync.sh @@ -48,7 +50,7 @@ test:: TOR_CONTROLLER_PASSWORD=${PASS} ${PYTHON_EXE_MSYS} src/${MOD}/tor_bootstrap_check.py doctest: - export PYTHONPATH=${PWD} + sudo -u tor env PYTHONPATH=${PWD}/src \ ${DOCTEST} ${MOD}.txt veryclean:: clean diff --git a/pyproject.toml b/pyproject.toml index 724e80b..2028645 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -3,9 +3,6 @@ name = "stem_examples" description = "examples of using stem" authors = [{ name = "emdee", email = "emdee@spm.plastiras.org" } ] requires-python = ">=3.6" -dependencies = [ - 'stem', -] keywords = ["stem", "python3", "tor"] classifiers = [ "License :: OSI Approved", @@ -49,8 +46,3 @@ build-backend = "setuptools.build_meta" version = {attr = "stem_examples.__version__"} readme = {file = ["README.md", "stem_examples.txt"]} -[tool.setuptools] -packages = ["stem_examples"] - -#[tool.setuptools.packages.find] -#where = "src" diff --git a/setup.cfg b/setup.cfg index 460a28f..6cb75d2 100644 --- a/setup.cfg +++ b/setup.cfg @@ -19,11 +19,9 @@ classifiers = [options] zip_safe = false python_requires = ~=3.6 -include_package_data = false +include_package_data = + "*" = ["*.txt"] install_requires = - qasync - cryptography - rsa stem ruamel.yaml package_dir= diff --git a/stem_examples.txt b/stem_examples.txt index b0611c8..dd98ff3 100644 --- a/stem_examples.txt +++ b/stem_examples.txt @@ -137,17 +137,6 @@ provides an easy method for accessing this information. INFO Our platform supports connection resolution via: ... -## interpreter - - >>> print("interpreter", file=sys.stderr) - >>> import interpreter - >>> lArgs = ['GETINFO', 'version'] - >>> interpreter.iMain(lArgs) #doctest: +ELLIPSIS +NORMALIZE_WHITESPACE - 250-version=0.4.8.10 - 250 OK - - 0 - ## tor_bootstrap_check >>> print("tor_bootstrap_check", file=sys.stderr) @@ -165,15 +154,26 @@ tor is at. This fails under doctest but not from the cmdline ## check_digests >>> print("check_digests", file=sys.stderr) - >>> from support_testing import ignoreStdout >>> from check_digests import iMain >>> sKNOWN_ONION = 'facebookwkhpilnemxj7asaniu7vnjjbiltxjqhye3mhbshg7kx5tfyd' # facebook >>> from stem_examples.introduction_points import lMain as lIPMain - >>> with ignoreStdout(): + >>> lArgs = [] + >>> import stem_examples.support_testing as ts; with ts.ignoreStdout(): ... lArgs = lIPMain([sKNOWN_ONION]) >>> iMain(lArgs) 0 +## interpreter + + >>> print("interpreter", file=sys.stderr) + >>> import interpreter + >>> lArgs = ['GETINFO', 'version'] + >>> interpreter.iMain(lArgs) #doctest: +ELLIPSIS +NORMALIZE_WHITESPACE + 250-version=0.4.8.10 + 250 OK + + 0 + ## outdated_relays List Outdated Relays Time marches on. Tor makes new releases, and at some point needs to drop