Skip to content

Commit 7f22ba7

Browse files
authored
Merge pull request #371 from Python-Cardano/chang
Chang support
2 parents 68108ad + ba73b10 commit 7f22ba7

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+3783
-569
lines changed

.github/workflows/main.yml

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ on:
44
push:
55
branches: "**"
66
pull_request:
7-
branches: ["main"]
7+
branches: ["main", "chang"]
88
types: [opened, reopened, edited, synchronize]
99

1010
jobs:
@@ -14,7 +14,7 @@ jobs:
1414
strategy:
1515
matrix:
1616
os: [ubuntu-latest, macos-latest]
17-
python-version: [3.8, 3.9, '3.10', '3.11']
17+
python-version: ['3.8', '3.9', '3.10', '3.11']
1818

1919
steps:
2020
- uses: actions/checkout@v4
@@ -59,18 +59,30 @@ jobs:
5959
python-version: ${{ matrix.python-version }}
6060
cache: 'poetry'
6161

62+
- name: Setup docker-compose
63+
uses: KengoTODA/[email protected]
64+
with:
65+
version: '2.14.2'
66+
6267
- name: Run integration tests
6368
run: |
6469
cd integration-test && ./run_tests.sh
6570
71+
- name: "Upload coverage to Codecov"
72+
if: ${{ matrix.python-version == '3.11' }}
73+
uses: codecov/codecov-action@v4
74+
with:
75+
fail_ci_if_error: true
76+
token: ${{ secrets.CODECOV_TOKEN }}
77+
6678
- name: Dump docker logs
6779
if: failure()
6880
run: |
69-
cd integration-test && docker-compose logs --no-color > integration-test.log
81+
cd integration-test && docker compose logs --no-color > integration-test.log
7082
7183
- name: Upload integration-test.log
7284
if: failure()
73-
uses: actions/upload-artifact@v2
85+
uses: actions/upload-artifact@v4
7486
with:
7587
name: integration-test.log
7688
path: integration-test/integration-test.log

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
cov_html
44
docs/build
55
dist
6+
.mypy_cache
7+
coverage.xml
68

79
# IDE
810
.idea

docs/requirements.txt

Lines changed: 32 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,39 @@
11
alabaster==0.7.13 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
2+
annotated-types==0.7.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
23
asn1crypto==1.5.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
3-
attrs==23.2.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
4-
babel==2.15.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
5-
black==24.4.2 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
4+
attrs==24.2.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
5+
babel==2.16.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
6+
black==24.8.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
67
blinker==1.8.2 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
78
blockfrost-python==0.5.3 ; python_full_version >= "3.8.1" and python_version < "4"
8-
cachetools==5.3.3 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
9-
cbor2==5.6.3 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
10-
certifi==2024.2.2 ; python_full_version >= "3.8.1" and python_version < "4"
9+
cachetools==5.5.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
10+
cardano-tools==2.1.0 ; python_full_version >= "3.8.1" and python_version < "4.0"
11+
cbor2==5.6.4 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
12+
certifi==2024.8.30 ; python_full_version >= "3.8.1" and python_version < "4"
1113
certvalidator==0.11.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
12-
cffi==1.16.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
14+
cffi==1.17.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
1315
charset-normalizer==3.3.2 ; python_full_version >= "3.8.1" and python_version < "4"
1416
click==8.1.7 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
1517
colorama==0.4.6 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0" and (sys_platform == "win32" or platform_system == "Windows")
18+
coloredlogs==15.0.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
1619
cose==0.9.dev8 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
17-
coverage[toml]==7.5.3 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
18-
cryptography==42.0.7 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
20+
coverage[toml]==7.6.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
21+
cryptography==43.0.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
1922
decorator==5.1.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
2023
docker==7.1.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
2124
docutils==0.19 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
2225
ecdsa==0.19.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
2326
ecpy==1.2.5 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
24-
exceptiongroup==1.2.1 ; python_full_version >= "3.8.1" and python_version < "3.11"
27+
exceptiongroup==1.2.2 ; python_full_version >= "3.8.1" and python_version < "3.11"
2528
execnet==2.1.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
26-
flake8==7.0.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
29+
flake8==7.1.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
2730
flask==2.3.3 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
2831
frozendict==2.4.4 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
2932
frozenlist==1.4.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
30-
idna==3.7 ; python_full_version >= "3.8.1" and python_version < "4"
33+
humanfriendly==10.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
34+
idna==3.8 ; python_full_version >= "3.8.1" and python_version < "4"
3135
imagesize==1.4.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
32-
importlib-metadata==7.1.0 ; python_full_version >= "3.8.1" and python_version < "3.10"
36+
importlib-metadata==8.4.0 ; python_full_version >= "3.8.1" and python_version < "3.10"
3337
iniconfig==2.0.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
3438
isort==5.13.2 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
3539
itsdangerous==2.2.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
@@ -39,21 +43,28 @@ mccabe==0.7.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
3943
mnemonic==0.21 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
4044
mypy-extensions==1.0.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
4145
mypy==1.4.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
46+
ogmios @ git+https://gitlab.com/viperscience/ogmios-python.git@0b713e78839341d92828340a5552ef8dd1c6224b ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
47+
orjson==3.10.7 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
4248
oscrypto==1.3.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
43-
packaging==24.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
49+
packaging==24.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
4450
pathspec==0.12.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
51+
pexpect==4.9.0 ; python_full_version >= "3.8.1" and python_version < "4.0"
4552
platformdirs==4.2.2 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
4653
pluggy==1.5.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
4754
pprintpp==0.4.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
55+
ptyprocess==0.7.0 ; python_full_version >= "3.8.1" and python_version < "4.0"
4856
py==1.11.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
49-
pycodestyle==2.11.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
57+
pycodestyle==2.12.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
5058
pycparser==2.22 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
59+
pydantic-core==2.20.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
60+
pydantic==2.8.2 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
5161
pyflakes==3.2.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
5262
pygments==2.18.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
5363
pynacl==1.5.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
64+
pyreadline3==3.4.1 ; sys_platform == "win32" and python_full_version >= "3.8.1" and python_full_version < "4.0.0"
5465
pytest-cov==5.0.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
5566
pytest-xdist==3.6.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
56-
pytest==8.2.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
67+
pytest==8.3.2 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
5768
pytz==2024.1 ; python_full_version >= "3.8.1" and python_version < "3.9"
5869
pywin32==306 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0" and sys_platform == "win32"
5970
requests==2.32.3 ; python_full_version >= "3.8.1" and python_version < "4"
@@ -74,8 +85,9 @@ sphinxcontrib-serializinghtml==1.1.5 ; python_full_version >= "3.8.1" and python
7485
tomli==2.0.1 ; python_full_version >= "3.8.1" and python_full_version <= "3.11.0a6"
7586
typeguard==4.3.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
7687
types-requests==2.31.0.10 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
77-
typing-extensions==4.12.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
78-
urllib3==2.2.1 ; python_full_version >= "3.8.1" and python_version < "4"
88+
typing-extensions==4.12.2 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
89+
urllib3==2.2.2 ; python_full_version >= "3.8.1" and python_version < "4"
7990
websocket-client==1.8.0 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
80-
werkzeug==3.0.3 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
81-
zipp==3.19.1 ; python_full_version >= "3.8.1" and python_version < "3.10"
91+
websockets==13.0.1 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
92+
werkzeug==3.0.4 ; python_full_version >= "3.8.1" and python_full_version < "4.0.0"
93+
zipp==3.20.1 ; python_full_version >= "3.8.1" and python_version < "3.10"

docs/source/api/pycardano.backend.base.rst

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,12 @@ Backend
1111
:undoc-members:
1212
:show-inheritance:
1313

14-
.. automodule:: pycardano.backend.ogmios
14+
.. automodule:: pycardano.backend.ogmios_v6
15+
:members:
16+
:undoc-members:
17+
:show-inheritance:
18+
19+
.. automodule:: pycardano.backend.ogmios_v5
1520
:members:
1621
:undoc-members:
1722
:show-inheritance:

integration-test/bootstrap.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,9 @@ NETWORK=$1
2020

2121
echo "Bootstrapping network: $NETWORK"
2222

23-
if [ "$NETWORK" = "local-alonzo" ] || [ "$NETWORK" = "local-vasil" ]; then
23+
if [ "$NETWORK" = "local-alonzo" ] || [ "$NETWORK" = "local-vasil" ] || [ "$NETWORK" = "local-chang" ]; then
2424
echo "Updating byron startTime to present in local mode, $NETWORK era"
25-
jq -M ".startTime = ""$(date +%s)" configs/"$NETWORK"/byron-genesis.json > \
25+
jq -M ".startTime = ($(date +%s) + 60)" configs/"$NETWORK"/byron-genesis.json > \
2626
tmp_configs/"$NETWORK"/byron-genesis.json
2727
fi
2828

0 commit comments

Comments
 (0)