ADORSYS-GIS / ADORSYS-GIS/converse-frontends
[Ticket]: Remove the projectMembers resource and the PDF export toggle
- Dominant language
- TypeScript
- Stars
- 0
- Forks
- 0
- Avg merge
- 1h 49m
- Merged PRs (30d)
- 253
Description
## Type
Technical debt
## Summary
We need to remove two pieces of console surface that look wired but are not: `projectMembers` is
registered as a refine resource but never queried and would fail-closed server-side, and the PDF
export toggle contradicts ADR 0009 Decision 8 (CSV only).
Expected result:
> Both are removed, or explicitly justified in a code comment for why they stay.
> [!IMPORTANT]
> **Scope correction (2026-08-27).** This ticket originally also listed
> `apps/console/src/app/api/usage/[...path]` as a third item. That was wrong and has been removed:
> the route is the console's only path to the usage backend (ADR 0009 Decision 3) and is the
> foundation #304 builds on. It has no caller *yet* — that is work not yet done, not dead surface.
> Do not delete it. The justifying comment now lives in the route file itself.
## Intent
Surface that looks wired but has no live backend support or is contradicted by a settled product
decision is worse than no surface at all — it invites a developer to assume it works, or to build on
top of it before checking. This ticket forces an explicit removal-or-justify decision for each of
the three named items.
## Source of truth (links)
- https://github.com/ADORSYS-GIS/converse-frontends/blob/main/docs/adr/0009-nextjs-console-replacement.md
- https://github.com/ADORSYS-GIS/converse-frontends/blob/main/packages/authz-rpc/schema/authz.cstack#L670-L671
- https://github.com/ADORSYS-GIS/converse-frontends/issues/284
## Current Behavior
`projectMembers` is registered as a refine resource in
`apps/console/src/client/console-providers.tsx:84` but has no querying screen anywhere in the
console, and `model.ProjectMember.*` is deliberately fail-closed and policy-traversal-only per
`packages/authz-rpc/schema/authz.cstack:670-671` — a query against it would fail by design.
The **PDF** format toggle exists in `apps/console/src/client/url-state.ts:168`
(`REPORT_FORMATS = ['csv', 'pdf']`) and in
`packages/ui-web/src/components/report-export-panel/component.tsx:75-80`'s `SegmentedControl`,
despite ADR 0009 Decision 8 specifying CSV-only export.
## Expected Behavior
`projectMembers` and the PDF toggle are removed. Neither has a legitimate reason to remain, given
the fail-closed policy and the settled CSV-only decision respectively.
## Acceptance Criteria
- [ ] Given `projectMembers`, when the resources array in `console-providers.tsx` is reviewed, then
it is either removed or justified in a code comment — default expectation is removal, since
the model is fail-closed by design.
- [ ] Given the PDF toggle, when `url-state.ts` and the report-export panel are reviewed, then
`'pdf'` is removed from `REPORT_FORMATS`/`ReportExportFormat` and from the `SegmentedControl`
options, or the divergence from ADR 0009 Decision 8 is explicitly justified in a code comment.
- [ ] Error cases are handled safely — removal does not leave dangling imports or type errors.
- [ ] Existing behavior is not broken for any screen that currently (even indirectly) exercises
these resources/toggles.
- [ ] Relevant tests are added or updated (remove/update tests referencing removed surface).
- [ ] Verification evidence is provided.
## Out of Scope
- Building a real `projectMembers` screen (out of scope entirely — the model is fail-closed by
design).
- **`/api/usage/[...path]` — do not touch it.** Removed from this ticket's scope entirely (see the
Summary callout). Wiring it to a real consumer is #304.
## Technical Context
Relevant files: `apps/console/src/client/console-providers.tsx:78-99` (resources array),
`apps/console/src/client/url-state.ts:168` (`REPORT_FORMATS`, `ReportExportFormat`),
`packages/ui-web/src/components/report-export-panel/component.tsx:75-80` (`SegmentedControl`
options).
## Risks
Risk: removing `projectMembers` or the PDF toggle turns out to be premature if a near-term product
ask reintroduces either. Mitigation: this is a low-cost reversal (both are thin, no complex state),
and the AC explicitly allows "justify in code comments" as the alternative if removal seems wrong at
implementation time.
## Test Plan
Typecheck/build green after removal; existing test suites updated to drop any references to
`projectMembers` or the PDF format. Manual check: confirm no console screen references the removed
resource/toggle after the change.
## Verification evidence
To be filled in by the implementing engineer at PR time: confirmation of a clean build/typecheck and
no dangling references.
## Human accountable owner
@stephane-segning
## AI Usage Declaration
Ticket decomposition
## Human verification completed
- [ ] I understood the intent
- [ ] I checked the source of truth
- [ ] I reviewed all AI-generated text/code
- [ ] I verified the implementation manually
- [ ] I verified the tests
- [ ] I checked for hallucinated assumptions
- [ ] I documented remaining risks
- [ ] I am the accountable owner and accept responsibility for this ticket.
Contributor guide
Assessment
This issue has not been assessed yet.