Skip to content

Forms version follows coalition forms - #1154

Open
idormenco wants to merge 1 commit into
mainfrom
fix/coalition-forms-version
Open

idormenco wants to merge 1 commit into
mainfrom
fix/coalition-forms-version

Conversation

@idormenco

Copy link
Copy Markdown
Contributor

Problem

In a coalition, observers of member NGOs receive forms owned by the leader (CoalitionFormAccess). Their forms:version cache key was only their own NGO's FormsVersion, which changes only when the member's own forms change. Editing a shared published form, or sharing a form with them, left their key unchanged, so the mobile app kept the old forms.

forms:fetchAll returned a version hashed from form ids only, so it didn't change on content edits either.

Change

  • New ObserverFormsVersion.GetAsync: the key is the NGO's own FormsVersion, plus the FormsVersion of every NGO whose forms are shared with it and the shared form ids (citizen reporting forms excluded, as in fetchAll).
  • GET forms:version and GET forms:fetchAll both return this key.
  • NGOs outside a coalition keep exactly their current key (FormsVersion), so their observers don't refetch.

Testing

  • Feature.Forms builds; Feature.Forms.UnitTests pass (185).
  • Not run against a database; no new tests for the key.

Observers of coalition members receive forms owned by the leader, but their forms:version cache key only followed
their own NGO's FormsVersion, so editing a shared published form (or sharing one) never told their apps to refetch.
The key now also covers the owners' FormsVersion and the shared form ids; forms:fetchAll returns the same key.
NGOs outside a coalition keep their current key.
@vercel

vercel Bot commented Nov 14, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
votemonitor Ready Ready Preview Nov 14, 2026 7:10am UTC

Request Review

This branch was successfully deployed

1 active deployment
Preview — efd50562 Deployed Nov 14, 2026 by vercel[bot]
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