Repository navigation
Conversation
…nthesis Signed-off-by: Sai Asish Y <say.apm35@gmail.com>
Signed-off-by: Sai Asish Y <say.apm35@gmail.com>
joshunrau
requested changes
Oct 25, 2026
joshunrau
left a comment
Collaborator
There was a problem hiding this comment.
Thanks for picking this up. The guard fix and the first-colon split are correct and match #1705, and both new tests fail on main and pass with your change, which is what we want. Two things are needed before this can merge:
- Test the new "field with no colon" rejection.
apps/web/src/utils/upload.ts:171now rejects a field likequantitywith no:as a malformed record. That is a good change, but no test covers it: deletingseparatorIndex === -1 ||leaves the whole suite green. Please add a case to the Zod 3record arrayssuite inapps/web/src/utils/__tests__/upload.test.ts(around lines 509-552). For example,processItems('RECORD_ARRAY(name:item1,quantity)')should reject with"Malformed record at index 1 at column name: 'items' and row number '1'". - Add the end-to-end test. Every change in this repo needs a Playwright test in
testing/as well as a unit test, and #1705 asks for one intesting/src/specs/upload.spec.ts: upload a record-array cell that is missing its closing parenthesis, and assert that the error names the column. One thing to know up front: none of the seeded instruments has a record-array field (the demo catalog inapps/api/src/demo/demo.service.tsseeds only the three forms underpackages/instrument-library/src/forms). So the spec has to create one first. You can post a form bundle with a record-array field toPOST /api/v1/instruments, using a token fromGET /api/v1/auth/create-instrument-token.testing/src/specs/authorization.spec.ts(lines 384-408) shows how to do that. A helper intesting/src/support/api-client.tsis the natural home for it. Make sure the acting user's group has access to the new instrument before the test opens/upload..agents/docs/playbooks/add-e2e-test.mdwalks through the rest.
If you hand this to Claude Code, Opus 5 is the right size. The end-to-end test needs a new way to seed a custom instrument into the suite, and there is no existing pattern to copy.
Reviewed at commit 2ffc557.
This was referenced Oct 26, 2026
Open
Open
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Closes #1705
What changed
The
RECORD_ARRAY(...)guard inextractRecordArrayEntryused&&where it needed||, so a cell missing its closing parenthesis was accepted and lost its last character. Each field was also split on every colon, so a value like10:30was stored as10; fields are now split on their first colon only, and a field with no colon is rejected as a malformed record.