mm-btc 0.5.4__tar.gz → 0.5.6__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {mm_btc-0.5.4 → mm_btc-0.5.6}/.gitignore +1 -0
- mm_btc-0.5.6/CLAUDE.md +13 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/PKG-INFO +4 -4
- {mm_btc-0.5.4 → mm_btc-0.5.6}/pyproject.toml +13 -14
- {mm_btc-0.5.4 → mm_btc-0.5.6}/src/mm_btc/blockstream.py +3 -3
- {mm_btc-0.5.4 → mm_btc-0.5.6}/tests/conftest.py +10 -4
- mm_btc-0.5.6/uv.lock +1708 -0
- mm_btc-0.5.4/uv.lock +0 -1415
- {mm_btc-0.5.4 → mm_btc-0.5.6}/.env.example +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/README.md +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/dict.dic +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/justfile +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/src/mm_btc/__init__.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/src/mm_btc/cli/__init__.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/src/mm_btc/cli/cli.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/src/mm_btc/cli/cmd/__init__.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/src/mm_btc/cli/cmd/address_cmd.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/src/mm_btc/cli/cmd/create_tx_cmd.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/src/mm_btc/cli/cmd/decode_tx_cmd.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/src/mm_btc/cli/cmd/mnemonic_cmd.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/src/mm_btc/cli/cmd/utxo_cmd.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/src/mm_btc/py.typed +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/src/mm_btc/tx.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/src/mm_btc/wallet.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/tests/__init__.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/tests/cmd/__init__.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/tests/cmd/test_mnemonic_cmd.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/tests/test_blockstream.py +0 -0
- {mm_btc-0.5.4 → mm_btc-0.5.6}/tests/test_wallet.py +0 -0
mm_btc-0.5.6/CLAUDE.md
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# Claude Guidelines
|
|
2
|
+
|
|
3
|
+
## Critical Guidelines
|
|
4
|
+
|
|
5
|
+
1. **Always communicate in English** - Regardless of the language the user speaks, always respond in English. All code, comments, and documentation must be in English.
|
|
6
|
+
|
|
7
|
+
2. **Minimal documentation** - Only add comments/documentation when it simplifies understanding and isn't obvious from the code itself. Keep it strictly relevant and concise.
|
|
8
|
+
|
|
9
|
+
3. **Critical thinking** - Always critically evaluate user ideas. Users can make mistakes. Think first about whether the user's idea is good before implementing.
|
|
10
|
+
|
|
11
|
+
4. **Lint after changes** - After making code changes, always run `just lint` to verify code quality and fix any linter issues.
|
|
12
|
+
|
|
13
|
+
5. **No disabling linter rules** - Never use special disabling comments (like `# noqa`, `# type: ignore`, `# ruff: noqa`, etc.) to turn off linter rules without explicit permission. If you believe a rule should be disabled, ask first.
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: mm-btc
|
|
3
|
-
Version: 0.5.
|
|
3
|
+
Version: 0.5.6
|
|
4
4
|
Requires-Python: >=3.13
|
|
5
|
-
Requires-Dist: bitcoinlib~=0.7.
|
|
5
|
+
Requires-Dist: bitcoinlib~=0.7.6
|
|
6
6
|
Requires-Dist: bit~=0.8.0
|
|
7
7
|
Requires-Dist: hdwallet~=3.6.1
|
|
8
|
-
Requires-Dist: mm-web3~=0.5.
|
|
8
|
+
Requires-Dist: mm-web3~=0.5.6
|
|
9
9
|
Requires-Dist: mnemonic~=0.21
|
|
10
|
-
Requires-Dist: typer~=0.
|
|
10
|
+
Requires-Dist: typer~=0.21.1
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "mm-btc"
|
|
3
|
-
version = "0.5.
|
|
3
|
+
version = "0.5.6"
|
|
4
4
|
description = ""
|
|
5
5
|
requires-python = ">=3.13"
|
|
6
6
|
dependencies = [
|
|
7
|
-
"mm-web3~=0.5.
|
|
7
|
+
"mm-web3~=0.5.6",
|
|
8
8
|
"hdwallet~=3.6.1",
|
|
9
9
|
"bit~=0.8.0",
|
|
10
|
-
"bitcoinlib~=0.7.
|
|
10
|
+
"bitcoinlib~=0.7.6",
|
|
11
11
|
"mnemonic~=0.21",
|
|
12
|
-
"typer~=0.
|
|
12
|
+
"typer~=0.21.1",
|
|
13
13
|
]
|
|
14
14
|
[project.scripts]
|
|
15
15
|
mm-btc = "mm_btc.cli.cli:app"
|
|
@@ -19,17 +19,16 @@ mm-btc = "mm_btc.cli.cli:app"
|
|
|
19
19
|
requires = ["hatchling"]
|
|
20
20
|
build-backend = "hatchling.build"
|
|
21
21
|
|
|
22
|
-
[
|
|
23
|
-
dev
|
|
24
|
-
"
|
|
25
|
-
"
|
|
22
|
+
[dependency-groups]
|
|
23
|
+
dev = [
|
|
24
|
+
"bandit~=1.9.2",
|
|
25
|
+
"mypy~=1.19.1",
|
|
26
|
+
"pip-audit~=2.10.0",
|
|
27
|
+
"pytest~=9.0.2",
|
|
28
|
+
"pytest-asyncio~=1.3.0",
|
|
26
29
|
"pytest-xdist~=3.8.0",
|
|
27
|
-
"
|
|
28
|
-
"
|
|
29
|
-
"pip-audit~=2.9.0",
|
|
30
|
-
"bandit~=1.8.6",
|
|
31
|
-
"mypy~=1.17.1",
|
|
32
|
-
"python-dotenv>=1.1.1",
|
|
30
|
+
"ruff~=0.14.11",
|
|
31
|
+
"python-dotenv~=1.2.0",
|
|
33
32
|
]
|
|
34
33
|
|
|
35
34
|
|
|
@@ -70,7 +70,7 @@ class BlockstreamClient:
|
|
|
70
70
|
try:
|
|
71
71
|
if res.status_code == 400:
|
|
72
72
|
return res.to_result_err("400 Bad Request")
|
|
73
|
-
return res.to_result_ok(Address(**res.
|
|
73
|
+
return res.to_result_ok(Address(**res.parse_json()))
|
|
74
74
|
except Exception as e:
|
|
75
75
|
result = res.to_result_err(e)
|
|
76
76
|
return result
|
|
@@ -85,7 +85,7 @@ class BlockstreamClient:
|
|
|
85
85
|
for _ in range(self.attempts):
|
|
86
86
|
res = await self._request(f"/address/{address}/utxo")
|
|
87
87
|
try:
|
|
88
|
-
return res.to_result_ok([Utxo(**out) for out in res.
|
|
88
|
+
return res.to_result_ok([Utxo(**out) for out in res.parse_json()])
|
|
89
89
|
except Exception as e:
|
|
90
90
|
result = res.to_result_err(e)
|
|
91
91
|
return result
|
|
@@ -95,7 +95,7 @@ class BlockstreamClient:
|
|
|
95
95
|
for _ in range(self.attempts):
|
|
96
96
|
res = await self._request("/mempool")
|
|
97
97
|
try:
|
|
98
|
-
return res.to_result_ok(Mempool(**res.
|
|
98
|
+
return res.to_result_ok(Mempool(**res.parse_json()))
|
|
99
99
|
except Exception as e:
|
|
100
100
|
result = res.to_result_err(e)
|
|
101
101
|
return result
|
|
@@ -7,8 +7,6 @@ from typer.testing import CliRunner
|
|
|
7
7
|
|
|
8
8
|
load_dotenv()
|
|
9
9
|
|
|
10
|
-
PROXIES_URL = os.getenv("PROXIES_URL")
|
|
11
|
-
|
|
12
10
|
|
|
13
11
|
@pytest.fixture()
|
|
14
12
|
def mnemonic() -> str:
|
|
@@ -30,9 +28,17 @@ def binance_address() -> str:
|
|
|
30
28
|
return "34xp4vRoCGJym3xR7yCVPFHoCNxv4Twseo"
|
|
31
29
|
|
|
32
30
|
|
|
31
|
+
@pytest.fixture()
|
|
32
|
+
def proxies_url() -> str:
|
|
33
|
+
res = os.getenv("PROXIES_URL")
|
|
34
|
+
if not res:
|
|
35
|
+
raise ValueError("PROXIES_URL env var is not set")
|
|
36
|
+
return res
|
|
37
|
+
|
|
38
|
+
|
|
33
39
|
@pytest.fixture
|
|
34
|
-
def proxies() -> list[str]:
|
|
35
|
-
return fetch_proxies_sync(
|
|
40
|
+
def proxies(proxies_url) -> list[str]:
|
|
41
|
+
return fetch_proxies_sync(proxies_url).unwrap("cannot fetch proxies")
|
|
36
42
|
|
|
37
43
|
|
|
38
44
|
@pytest.fixture
|