CivicDataLab / CivicDataLab/DataSpaceFrontend

[Bug] AI model wizard step 1→2 bypasses all required field validation

Open
#408 1 comment 0 reactions 1 assignee View on GitHub

@Abhishekfm is already working on this.

Since Jun 22, 2026.

bug
Dominant language
TypeScript
Stars
1
Forks
0
Avg merge
1d 7h
Merged PRs (30d)
19

Description

Summary

Clicking Next from the Metadata step (step 1) advances to the Version step (step 2) without validating any required field. All required fields — Sectors*, Tags*, Languages*, Geographies*, Intended Use*, Target Users*, Model Website*, Maximum Tokens* — can be left empty and the wizard proceeds silently.

Validation only triggers at the Publish step (step 3), where the Publish button is disabled and a summary of missing fields is listed.

Impact

  • Users can create a Version record and configure Access Methods on a model with zero metadata
  • Only discover the block at the very last step, after potentially configuring complex API access methods
  • Orphaned Version and Access Method records attached to an incomplete model draft

Steps to Reproduce

  1. Navigate to /dashboard/organization/{org}/aimodels → Add New AI Model
  2. On the Metadata tab, leave all required fields empty
  3. Click Next
  4. Wizard advances to the Version tab with no error shown

Expected Behaviour

Step 1 → 2 transition should validate all required metadata fields and surface inline errors before allowing navigation.

Fix Recommendation

Add per-step validation:

  • Step 1 → 2: all required Metadata fields must be non-empty
  • Step 2 → 3: at least one Access Method must be configured

Environment

  • URL: https://dev.civicdataspace.in/dashboard/organization/civicdatalab/aimodels/edit/168/details
  • Discovered: 2026-06-22 via QA audit
  • Report ref: VALID-001

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.