Repository navigation
v0.13.0
Pre-releaseThe release that gave arkhe a client.
Everything the API can do is now reachable from Python without anyone writing their own
requests — and, more to the point, without anyone writing their own idea of which calls
are safe to retry. A ledger whose identifiers cannot be reissued cannot afford that
decision to be made once per caller.
Added
-
A Python client (
clients/python,arkhe-client). It covers every endpoint of
the minter and the resolver, and it makes the three decisions the API document cannot
express:Minting carries an idempotency key. Every
mint()sends arequest_id, generated
when the caller does not supply one, and a retry sends the same one, so a lost answer
cannot leave a number spent with nobody holding it.Ark.resentsays which happened.
mint_many()keys every row, which is what makes an interrupted batch safe to send
again. Only calls that can be sent twice without acting twice are retried; anything
else raisesTransportErrorand leaves the decision to the caller.The 307 to another minter is not followed. Following it would send one
organisation's credential to another organisation's endpoint, and an ARK minted over
there is one this ledger knows nothing about. It is raised asDelegated, carrying
.minterand.about.Refusals carry their
ARKHE-xxxxcode, as typed exceptions underArkheError.
Refusals that carry no code — the{field: what is wrong}shape the domain raises and
the screens show beside the field — keep what they said rather than becoming a bare
400.It is hand-written rather than generated, because what a generator adds is coverage and
coverage is the part that can be checked:clients/python/tests/test_contract.py
compares the client with the published OpenAPI documents in both directions, so an
endpoint added to the server fails the build until someone decides whether the client
should carry it. 39 checks run against a stub and 14 against the real stack. -
The end-to-end suite seeds a namespace whose minting is delegated (
99999/d9), so
that the307can be checked from outside rather than only in a unit test.
Changed
pytestalso collectsclients/python/tests, and the English-only check now
coversclients/. The client is checked in the same net as the server it speaks to.
Changelog in Japanese
· Full Changelog: v0.12.1...v0.13.0