pyronear / pyronear/pyro-annotator
Groups list: validated_by_username has no reader since the Reviewed column was replaced
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 0
- Forks
- 1
- Avg merge
- 1d 2h
- Merged PRs (30d)
- 2
Description
Since #316 replaced the groups list's "Reviewed" column with "Annotators", validated_by_username on SequenceGroupListItem has no reader anywhere in the app — and the list query still pays a LEFT JOIN users on every request to populate it.
It was added only three days earlier (#257, docs/specs/2026-08-03-group-validated-by-design.md) to show who validated a group next to the validated badge. That badge is gone from the list; SequenceGroupAnnotatePage shows a "Validated" badge but never the username, so the attribution is now invisible end-to-end.
Where it lives
annotation_api/src/app/api/api_v1/endpoints/sequence_groups.py—User.username.label("validated_by_username")in the list select, plus.outerjoin(User, User.id == SequenceGroup.validated_by_user_id)annotation_api/src/app/schemas/sequence_group.py—SequenceGroupListItem.validated_by_usernamefrontend/src/types/api.ts— same field on the TS interface
SequenceGroup.validated_by_user_id (the column) is not in question — only the denormalized username on the list row.
Decide between
- Drop it — remove the field, the label and the join. Cheapest list query; attribution stays available via
validated_by_user_idif a UI ever wants it again. - Surface it again — show "validated · username" on the group detail page, where the Validated badge already lives, and keep the list field only if that page starts reading the list item.
Either way, is_validated stays on the list item: the "to label" tooltip branches on it (propagation only fires for validated groups).
Worth noting the wider gap: after #316 no row on /classify/groups shows validation state at all, so on the Labeled tab you cannot tell a validated group from an unvalidated one. If that turns out to matter in use, the answer may be a compact validated marker rather than reinstating the whole column — but that is a product call, not part of this cleanup.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the list query in annotation_api/src/app/api/api_v1/endpoints/sequence_groups.py, then inspect the field in annotation_api/src/app/schemas/sequence_group.py and frontend/src/types/api.ts. Decide whether attribution should be removed or surfaced on the detail page, and verify that the chosen outcome removes the unused join and field or makes the username visible where the Validated badge appears.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python, typescript
- Domain
- api, backend, frontend
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100