feat: add study validation and ui mcp automation (STUDYU-78) - #903
Draft
johannesvedder wants to merge 39 commits into
Draft
johannesvedder wants to merge 39 commits into
johannesvedder wants to merge 39 commits into
Conversation
- field table: show `field (json_key)` when names differ; add Default column populated from field initializers and @jsonkey(defaultValue:) - remove `<!-- Human prose goes here. -->` placeholder from skeleton and strip it from previously generated pages on next --write run - dispatcher pages (Question, Expression): collect concrete subtype wire values scoped to the same directory, not all classes globally - filter keyType constants so they are not misread as wire values - drift check: fail when metadata describes a field absent from source (unless virtual: true) and when metadata is missing a title - mark SliderQuestion.initial as virtual in _metadata.yaml (getter only) - add doc_metadata_test.dart (7 tests) and expand generated_block_test and page_scope_test with discriminator and fieldLabel coverage - 41 unit tests passing, 0 analyzer warnings
Replace blank default cells with - in generated field tables. Add model_scanner_test.dart covering buildDispatcherDiscriminators and ScannedField/ScannedClass data classes. Regenerate all doc pages to reflect the new placeholder.
…rvention count check
Empty consent at publish level must be an error, not a warning — the CLI section flag test specifies this contract.
…etailed descriptions
…lds and enhance link validation
…atting and descriptions
feat(core): add study_data_docs generator and generated docs tree
Add a two-stage study-data validation pipeline: a fast JSON Schema gate over raw decoded JSON, followed by the existing Study.fromJson plus cross-entity Dart validators only when schema validation succeeds. - core/tool/emit_schema.dart: standalone emitter generating core/lib/src/validators/schema/study.schema.json from the committed model serializers (Draft 7, additionalProperties: false, oneOf discriminators with const, nullable via type arrays/anyOf) - studyu_validator: insert schema pass into validateJson and validateSection, add --schema-only flag and replace schema stub with schema subcommand printing the checked-in schema - .github/workflows/schema-validate.yml: node-only CI validating the portable fixture against the schema with ajv-cli - pubspec.yaml: add docs:study-data:schema melos script - tests: 20 cases proving stage separation, schema-only mode, schema command, and conflicting flag rejection
ajv-cli does not include format validators, causing date-time format in the schema to be rejected. Use ajv + ajv-formats directly instead.
This was referenced Jul 23, 2026
|
Visit the preview URL for this PR (updated for commit f45eee0):
(expires Wed, 05 Aug 2026 13:11:41 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 Sign: 2149dad49ed83535217e50d5c18c0c8c90da629b |
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: trueThanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
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.
Description
Combines and supersedes #866 and #902 in a single branch targeting
dev. Tracks STUDYU-78.studyu_validatorCLI.studyu_mcpserver for participant app and Designer v2 automation through Flutter Driver and the Dart VM service.devand resolves the stacked branches' merge conflicts.Visuals
No user-facing UI changes. A recording of the MCP-driven app flow should be attached before merging.
Testing Steps
scripts/pre-commit-check.fvm exec melos run test --scope studyu_core --scope studyu_validator.cd tools/studyu_mcp && fvm dart test.fvm exec melos run local:app:driver.fvm exec melos run mcp:studyuwith the printed VM-service URI.read_screen,app_complete_onboarding_to_study_list, andapp_get_visible_studies.PR Checklist
fvm exec melos qualitycheckpassesscripts/pre-commit-checkscripts/pre-commit-check