Skip to content

Write the reports down, and say what the list is - #46

Merged
peopleworks merged 1 commit into
mainfrom
feat/report-rendering
Aug 23, 2026
Merged

Write the reports down, and say what the list is#46
peopleworks merged 1 commit into
mainfrom
feat/report-rendering

Conversation

@peopleworks

Copy link
Copy Markdown
Owner

The other half of #37, as split. @MBrekhof's extraction landed in #43; this is the rendering and the honesty sentence.

Reports now appear in the Markdown pages, in AGENTS.md, and through a new xaf_reports MCP tool — each with what it is over, the filter inside its layout, its calculated fields and bound expressions, and the parameters dialog it opens with, including the GetCriteria() that turns the answers into a filter.

The sentence carries more than the list

With ReportsModuleV2 registered, users design reports at run time and those are stored as database rows. An application with forty reports and none in its repository is the ordinary case, not an exotic one — checked against a production application that registers the module, sets ReportStoreMode.XML with ReportDataType = ReportDataV2, and contains no report in source at all.

Printing "no reports" there is not an incomplete answer. It is a wrong one, and the more use an application makes of reports the wronger it gets.

Three states, told apart:

Module In source What is said
not registered n "these are all of them" — no End-User Designer, nothing can appear at run time
registered n "this list is a lower bound"
registered 0 "the true number is not zero but unknown"

An application that registers nothing and ships no layout gets no section at all. "No reports" is worth printing when it is a finding; there it is the default, and a paragraph about nothing would appear in every document we generate.

AGENTS.md gets the strongest wording of the three, because an agent that reads "no reports" designs as though none can exist:

The number is unknown, not zero — do not tell anyone this application has no reports.

Two defects the document showed and the code would not have

Both found by generating the page and reading it, which is the only reason they were found at all.

A citation named a drive on my machine. A layout kept beside the module rather than inside it falls outside the project path, and it was printed as C:/Proyecto/MCP/.../Reporting/RegionSummary.repx — in a file meant to be committed and read elsewhere. Every regeneration on another machine would have rewritten it. Citations now fall back to the solution root (../Reporting/RegionSummary.repx) and then to the file name, never to a path that is correct only here. A test asserts no citation contains a drive, in both languages.

One layout, two registrations, everything twice. The same .repx offered from the navigation and in place on a list view is an ordinary pair, and the second entry repeated the filter, the bindings and the whole of GetCriteria() — burying the only thing that differs between them, which is the options a reader opened it for. The second now says "Same layout and dialog as X, above." A test counts GetCriteria() blocks and expects one.

While here

Citation is one implementation rather than one per generator. WalkthroughGenerator had its own At, and a second copy was about to be written for this section — the same duplication this repository already fixed once, in #10.

Tests

12 new, 450 total. They cover the three states, the absent section, null in-place rendering as absent rather than "no", the deduplication, the unregistered layouts, and both non-Markdown surfaces. The one I would keep if I could keep only one is TheAgentContextRefusesToSayAnApplicationHasNoReports.

🤖 Generated with Claude Code

https://claude.ai/code/session_01W45tzJFX3NoSrk7svtQeKT

The other half of #37. Reports reach the Markdown pages, AGENTS.md and a
new xaf_reports MCP tool: what each is over, the filter in its layout,
its calculated fields and bound expressions, and the parameters dialog
with the GetCriteria() that turns the answers into a filter.

The sentence under the heading carries more than the list. With
ReportsModuleV2 registered, users design reports at run time and those
are stored as database rows, so an application with forty of them and
none in its repository is the ordinary case -- checked against a
production application that registers the module, sets
ReportStoreMode.XML, and contains no report in source at all. Printing
"no reports" there is a wrong answer rather than an incomplete one.
Three states are told apart: the list complete, the list a lower bound,
and the number unknown rather than zero.

Two defects the generated document showed and the code would not have.
A layout kept beside the module was cited by its absolute path -- this
machine's drive, in a file meant to be committed. And two registrations
sharing one .repx printed the filter, the bindings and the whole of
GetCriteria() twice, burying the only thing that differs between them.

Citation is now one implementation rather than one per generator.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01W45tzJFX3NoSrk7svtQeKT
@peopleworks
peopleworks force-pushed the feat/report-rendering branch from f478b7c to 1aaee0c Compare August 23, 2026 22:24
@peopleworks
peopleworks merged commit 3d2dc09 into main Aug 23, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant