From 37d86489be5627599e957d1966f9b23961d53dac Mon Sep 17 00:00:00 2001 From: The MMGen Project Date: Sun, 23 Aug 2026 09:14:00 +0000 Subject: [PATCH] minor fixes and cleanups --- .github/workflows/lint.yaml | 4 ++-- mmgen/cfg.py | 4 +++- nix/packages.nix | 13 +++++++------ pyproject.toml | 2 +- test/cmdtest_d/base.py | 2 +- 5 files changed, 14 insertions(+), 11 deletions(-) diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml index ffa38099..1ca69810 100644 --- a/.github/workflows/lint.yaml +++ b/.github/workflows/lint.yaml @@ -51,8 +51,8 @@ jobs: run: | ruff check --output-format=github setup.py ruff check --output-format=github mmgen - ruff check --output-format=github test ruff check --output-format=github examples + ruff check --output-format=github test - name: Check code vulnerabilities with Bandit static analyzer run: | @@ -66,6 +66,6 @@ jobs: run: | pylint setup.py pylint mmgen + pylint examples pylint test pylint --disable=relative-beyond-top-level test/cmdtest_d - pylint examples diff --git a/mmgen/cfg.py b/mmgen/cfg.py index 9770d70a..847e5d99 100755 --- a/mmgen/cfg.py +++ b/mmgen/cfg.py @@ -539,9 +539,11 @@ class Config(Lockable): self.alice or self.carol or self.miner or - gc.prog_name == f'{gc.proj_id}-regtest'): + gc.prog_name == 'mmgen-regtest'): if self.coin != 'XMR': self.network = 'regtest' + if gc.prog_name == 'mmgen-regtest' and self.coin != 'BTC': + self.bdb_wallet = True self.test_user = ( 'bob' if self.bob else 'alice' if self.alice else diff --git a/nix/packages.nix b/nix/packages.nix index 815b7b30..57388e74 100644 --- a/nix/packages.nix +++ b/nix/packages.nix @@ -16,7 +16,6 @@ secp256k1 = secp256k1; less = less; # test suite (cmdtest.py regtest) procps = procps; # test suite (pgrep) - ruff = ruff; ## For test suite with --pure: e2fsprogs = e2fsprogs; @@ -25,20 +24,22 @@ }; python-packages = with python.pkgs; { - pip = pip; setuptools = setuptools; build = build; wheel = wheel; + pip = pip; + # setup.cfg: gmpy2 = gmpy2; cryptography = cryptography; pynacl = pynacl; - ecdsa = ecdsa; aiohttp = aiohttp; requests = requests; + lxml = lxml; py-scrypt = py-scrypt; semantic-version = semantic-version; - pexpect = pexpect; # test suite - pycoin = pycoin; # test suite - lxml = lxml; + # test suite: + pycoin = pycoin; + ecdsa = ecdsa; + pexpect = pexpect; }; } diff --git a/pyproject.toml b/pyproject.toml index f0300ade..67c2e34a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,8 +1,8 @@ [build-system] requires = [ "setuptools>=57", - "wheel>=0.36.0", "build>=0.5.1", + "wheel>=0.36.0", ] build-backend = "setuptools.build_meta" diff --git a/test/cmdtest_d/base.py b/test/cmdtest_d/base.py index f7248dee..a6348c57 100755 --- a/test/cmdtest_d/base.py +++ b/test/cmdtest_d/base.py @@ -23,7 +23,7 @@ test.cmdtest_d.base: Base class for the cmdtest.py test suite import sys, os from mmgen.cfg import gc -from mmgen.util import msg, distro_codename +from mmgen.util import msg, distro_codename # pylint: disable=no-name-in-module from mmgen.color import gray, purple, yellow from ..include.common import write_to_file, read_from_file, imsg