A ledger entry that is not an object ends run and seats with an error #6

Open
opened 2026-11-02 18:34:14 +00:00 by jorijnvdgraaf · 0 comments

Ledger::Entry reads a seat's entry with Dyn::Get(e, "cycle"), which throws AttributeError when the entry is not an object. A seat-ledger.json holding, say, "api1": 5 therefore ends run and seats with that error. Everywhere else the ledger is a record, never a dependency: a file that cannot be read or parsed loads as empty.

A fix treats an entry that is not an object as missing (a fresh entry), with a test.

Found by the 1.1.0 push gates.

`Ledger::Entry` reads a seat's entry with `Dyn::Get(e, "cycle")`, which throws `AttributeError` when the entry is not an object. A `seat-ledger.json` holding, say, `"api1": 5` therefore ends `run` and `seats` with that error. Everywhere else the ledger is a record, never a dependency: a file that cannot be read or parsed loads as empty. A fix treats an entry that is not an object as missing (a fresh entry), with a test. Found by the 1.1.0 push gates.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
Catcrafts/Crafter.Review#6
No description provided.