Skip to content
This repository was archived by the owner on May 29, 2026. It is now read-only.
This repository was archived by the owner on May 29, 2026. It is now read-only.

Bug: Schema designer detail view 404s on namespaced schema slugs (post-wizard) #72

Description

@rubenvdlinde

Symptom

After creating a virtual app via the wizard (#71), the schema list at `/apps/openbuilt/builder/{slug}/schemas?_version={versionSlug}` correctly shows the seeded schemas with their namespaced slugs (e.g. `permit-tracker-production-hello-message`).

But clicking a row — which navigates to `/apps/openbuilt/builder/{slug}/schemas/{schemaId}?_version={versionSlug}` — produces a "Schema not found" state.

Screenshot in tutorial: `docs/tutorials/img/update-02-schema-detail-404.png`.

Root cause

PR #70 namespaces seed-schema slugs with `{appSlug}-{versionSlug}-` so OR's organisation-wide schema-slug uniqueness constraint accepts the same seed in multiple per-version registers. The list view fetches schemas scoped by register and renders the namespaced slugs correctly. But the detail view's lookup pathway uses the slug as a global identifier and doesn't match the per-version-register scope.

Fix options

Two approaches:

  1. Frontend-only: `src/views/SchemaDesigner.vue` / the schemas store reads `_version` from `$route.query` and includes the version slug in the schema lookup. The slug parameter remains the namespaced form; the lookup matches by `register === openbuilt-{appSlug}-{versionSlug}` + `slug === {schemaId}`.
  2. OR-side: relax the organisation-wide schema-slug uniqueness constraint to per-register uniqueness. Then PR fix(wizard): mount Add action, footer nav, namespaced seed schemas + create-app tutorial #70's namespacing becomes unnecessary; revert that and use bare slugs (`hello-message` across all registers). Bigger change; impacts other apps that depend on the current constraint.

Option 1 is the lighter fix; option 2 is the architecturally cleaner one.

Workaround (until fix lands)

Edit schemas via OR's admin UI at `/apps/openregister/schemas` directly. The OpenBuilt designer is unusable for editing today.

Surfaced by

Visual smoke during PR #70 verification. See `docs/tutorials/update-a-virtual-app.md` step 3 for the user-facing impact.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions