Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Reverts #3180 (I'll fix-forward in #planx-core next)
Regression tests passing against this branch ✅ which fixes our failure last night: https://github.com/theopensystemslab/planx-new/actions/runs/9186773259
Context:
A Planx tester didn't wait for constraints to load (x3 apps for a demo) and submitted to BOPS. The payloads were valid with empty constraints, and we got a successful response from BOPS, but the apps didn't display in BOPS. Likely because they have an internal dependency on expected constraints? I was tagged in the help-issue request instead of the BOPS team, and should have been initially clear which side of the fence this bug was on.
I thought this simple payload mapping change would be fine & allow me to resubmit the apps with minimal constraints that reflect "user answers", but it doesn't actually validate as expected (eg https://api.editor.planx.dev/admin/session/74068ec3-2e9c-408a-ac6f-7832d1eb011f/digital-planning-application?skipValidation=true). Bad testing on my part here and will need to look more closely at the PlanningDesignations type definition in the schema.
Next steps:
_constraints
key to to lowcal sessiondata
. Update session, confirm it validates and populates constraints, re-submit to Lambeth BOPS staging (x3) https://opendigitalplanning.slack.com/archives/C0241GWFG4B/p1716310913515129?thread_ts=1715963778.547149&cid=C0241GWFG4B