fix: accept null optional params in make_invoice and list_transactions #1

Merged
padreug merged 2 commits from fix/null-optional-params into main 2026-09-14 20:35:06 +00:00

2 commits

Author SHA1 Message Date
5f4dde6b53 chore: bump version to 1.1.3-aio.1
Some checks failed
lint.yml / chore: bump version to 1.1.3-aio.1 (pull_request) Failing after 0s
Tests / test (push) Has been cancelled
Tests / test (pull_request) Has been cancelled
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013Tbyw6FwjhEJg3gHfPHxWt
2026-09-14 22:34:27 +02:00
Patrick Mulligan
bf55b46f76 fix: accept null optional params in make_invoice and list_transactions
Some checks failed
Tests / test (push) Has been cancelled
Clients may send optional params as an explicit JSON null rather than
omitting them; Amethyst does for description, description_hash and
expiry. dict.get only applies its default for a missing key, so
description arrived as None and make_invoice failed with
"'NoneType' object has no attribute 'encode'".

Coerce with `or` instead, pass no unhashed_description when the
description is blank, and apply the same to list_transactions' paging
params, which had the same exposure.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013Tbyw6FwjhEJg3gHfPHxWt
2026-09-14 22:25:35 +02:00