get_economy reports a funded treasury as 0 because an unparseable body is read as an empty series #283
Labels
No labels
burndown-2026-06
headless
autonomy
async-consult
autonomy
epic
autonomy
headless
autonomy
live-collab
c#
priority
P0
priority
P1
priority
P2
priority
P3
priority
P4
role/ai
role/creator
role/design
role/director
role/engineer
role/exec
role/human
role/ops
role/qa
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
coilyco-gaming/eco-app#283
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Slice of #266, filed so PR #279 can close something it actually closes. Angie (ENG,
claudeseat).266 is an invariant across 25 tools. This is one confirmed violation of it, already built.
The defect
Same dataset, same server, same minute.
wages_total,taxes_paid,govt_funds_receivedandnet_tax_floware 0 too, and the health verdict and narrative are derived from them.Cause
Everything downstream was already correct.
_opt_lastreturnsNonefor an absent series and0.0for one read and empty;fetch_economyfiles a name underdatasets_unavailableonly when_fetch_datasetreturnsNone._fetch_datasetnever returnedNonefor a body it could not read. It returns a list — possibly empty — for any 200, so a dict under neitherValuesnorPoints, rows keyed differently, or a non-list non-dict payload all yield zero parsed points, and an empty list is indistinguishable from a genuinely idle dataset.Acceptance
datasets_unavailableand its KPIs arenull.[]and0.0. Nothing happened and nothing was read stay distinct.Why it is filed separately
AGENTS.md: "If a pull request does not fully close the issue that motivated it, file the slice as its own issue and close that one. Do not weaken the reference to satisfy the verb."I wrote 279's body as
refs #266because it does not close the 25-tool sweep, and then did not file this — which left the pull request unmergeable rather than merely unclaimed. Correcting that.Reproduced live against the deployed service, minutes ago, read-only. And it narrows what the fix does. Angie (ENG,
claudeseat).I had been arguing this from source. Here it is from the running service.
Same server, same minute, two answers. The verdict "Economy is healthy" is derived from the five zeros.
The part that sharpens the diagnosis
get_currencydoes not merely report a number — it returns the whole series, 42 points, rising from 0 through 28,081 to 87,775.59. And the dataset is listed as available:So the dataset is readable.
get_currencyreads it fine.get_economyasks for the same name through_fetch_datasetand gets nothing it can parse.What that means for PR 279, stated honestly
279 makes the failure visible — the dataset lands in
datasets_unavailable,govt_fundsbecomesnull, and the KPIs built on it stop asserting zero. That is exactly what #266's rule 1 asks for, and it is the whole of this issue's acceptance.It does not make
govt_fundscorrect. After 279 the tool says "I could not read this" instead of "it is zero", which is the honest answer and not the useful one. Getting the number right means finding why_fetch_datasetcannot parse a seriesget_currencyparses — a different request path, different params, or a different response shape.I am flagging that rather than letting 279 look like it fixes the treasury figure. A null is a correct answer to a question this tool currently gets wrong; a number would be a better one, and that is a separate piece of work.
One thing that is working
The deployed service already bounds
get_currencyand says so:That is #267's rule 2 behaving correctly on the top-level arrays, which matches what I found in source. The holder cap I could not observe at all:
holders.reachableis false on every currency because the stores exporter mod is not answering, soaccountsCountedis 0 and the 15-row cap has nothing to cap.