From 9416309dd46fd3c2f5a8721076ddbe59075d7721 Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 11 Aug 2026 03:59:19 +0000 Subject: [PATCH] chore(spec): retire the hand-written config-schema.json, whose generated replacement already exists (#7437) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `packages/spec/config-schema.json` was hand-written while claiming, in its own top-level `description`, to be "Generated from ObjectStackDefinitionSchema". That false provenance is plausibly why nobody re-derived it as the vocabularies moved: it reads as already-generated. Nothing guarded it — no pin test, no gate, no consumer — so it drifted on every enum it carried (#7286 fixed one entry; 6 phantom field types and a hidden `SeedMode` member remained), and its `$id` is still pinned at `v3.0.0` while the spec is v17. Deleted rather than realigned or gated, per the maintainer ruling of 2026-08-11: the correct generated route already exists. `objectstack generate schema` (`packages/cli/src/commands/generate.ts:817-865`) builds this exact schema live from `ObjectStackDefinitionSchema` via `z.toJSONSchema`, so it cannot drift by construction, and `content/docs/api/data-flow.mdx:202` already points authors at it. The published per-schema route, `packages/spec/json-schema/**`, is generated by `packages/spec/scripts/build-schemas.ts` and gated by `check:generated`; this artifact was a stale sibling of neither. Nothing regenerates the path (absent from `.gitattributes`, so not routed `merge=os-regen`; no generator writes it) and nothing ships it (absent from the package's `files` list — `npm pack --dry-run` packs zero entries matching it), so the delete lands and stays landed. The three surviving mentions of the filename are left untouched by design: a pending changeset, the same sentence in published `CHANGELOG.md`, and a code comment in `http-server.zod.ts` narrating a past defect. All three are statements about the past that remain true once the file is gone; rewriting the first two would falsify a release record. No changeset: the artifact is unshipped, so no npm consumer can observe its removal. Same measurement and same disposition as PR #7436, which edited this file under the `skip-changeset` label. --- packages/spec/config-schema.json | 279 ------------------------------- 1 file changed, 279 deletions(-) delete mode 100644 packages/spec/config-schema.json diff --git a/packages/spec/config-schema.json b/packages/spec/config-schema.json deleted file mode 100644 index 920e6c3b18..0000000000 --- a/packages/spec/config-schema.json +++ /dev/null @@ -1,279 +0,0 @@ -{ - "$schema": "https://json-schema.org/draft/2020-12/schema", - "$id": "https://schema.objectstack.io/v3.0.0/objectstack.config.json", - "title": "ObjectStack Configuration", - "description": "JSON Schema for objectstack.config.ts — the root configuration file for ObjectStack projects and plugins. Use this schema for IDE autocomplete and validation. Generated from ObjectStackDefinitionSchema.", - "type": "object", - "properties": { - "manifest": { - "type": "object", - "description": "Project Package Configuration", - "properties": { - "name": { - "type": "string", - "pattern": "^[a-z_][a-z0-9_-]*$", - "description": "Package name (lowercase, hyphens/underscores allowed)" - }, - "version": { - "type": "string", - "description": "Semantic version (e.g. 1.0.0)" - }, - "label": { - "type": "string", - "description": "Human-readable display name" - }, - "description": { - "type": "string", - "description": "Package description" - } - }, - "required": ["name", "version", "label"] - }, - "datasources": { - "type": "array", - "description": "External Data Connections", - "items": { - "type": "object", - "properties": { - "name": { "type": "string" }, - "driver": { "type": "string" } - } - } - }, - "translations": { - "type": "array", - "description": "I18n Translation Bundles", - "items": { "type": "object" } - }, - "objects": { - "type": "array", - "description": "Business Objects definition (owned by this package)", - "items": { - "type": "object", - "properties": { - "name": { - "type": "string", - "pattern": "^[a-z_][a-z0-9_]*$", - "description": "Machine name (snake_case)" - }, - "label": { - "type": "string", - "description": "Human-readable label" - }, - "pluralLabel": { - "type": "string", - "description": "Plural display name" - }, - "ownership": { - "type": "string", - "enum": ["user", "business_unit", "org", "none"], - "description": "Record-ownership model: user (default — injects reassignable owner_id plus owning_business_unit_id) | business_unit (unit-owned: owning_business_unit_id only, no owner_id) | org | none (no per-record owner, neither anchor). Distinct from the package own/extend contribution kind." - }, - "fields": { - "type": "object", - "description": "Field definitions keyed by field name", - "additionalProperties": { - "type": "object", - "properties": { - "type": { - "type": "string", - "enum": [ - "text", "textarea", "richtext", "html", "markdown", - "number", "integer", "currency", "percent", - "boolean", - "date", "datetime", "time", - "email", "phone", "url", - "select", "multiselect", - "lookup", "master_detail", - "formula", "autonumber", - "json", "file", "image", - "password", "slug", "uuid", - "ip_address", "color", "rating", - "geo_point", "vector", "encrypted" - ], - "description": "Field data type" - }, - "label": { "type": "string", "description": "Human-readable label" }, - "required": { "type": "boolean", "description": "Whether the field is required" }, - "maxLength": { "type": "number", "description": "Maximum string length" }, - "multiple": { "type": "boolean", "description": "Allow multiple values (array)" }, - "defaultValue": { "description": "Default value for new records" }, - "options": { - "type": "array", - "description": "Options for select/multiselect fields", - "items": { - "type": "object", - "properties": { - "label": { "type": "string" }, - "value": { "type": "string" } - }, - "required": ["label", "value"] - } - }, - "reference": { - "type": "object", - "description": "Reference configuration for lookup/master_detail fields", - "properties": { - "object": { "type": "string", "description": "Target object name" }, - "labelField": { "type": "string", "description": "Field to display as label" } - }, - "required": ["object"] - } - }, - "required": ["type"] - } - } - }, - "required": ["name", "label"] - } - }, - "objectExtensions": { - "type": "array", - "description": "Extensions to objects owned by other packages", - "items": { - "type": "object", - "properties": { - "extend": { "type": "string", "description": "Name of the object to extend" }, - "fields": { "type": "object", "description": "Fields to add" } - }, - "required": ["extend"] - } - }, - "apps": { - "type": "array", - "description": "Applications", - "items": { "type": "object" } - }, - "views": { - "type": "array", - "description": "List Views", - "items": { "type": "object" } - }, - "pages": { - "type": "array", - "description": "Custom Pages", - "items": { "type": "object" } - }, - "dashboards": { - "type": "array", - "description": "Dashboards", - "items": { "type": "object" } - }, - "reports": { - "type": "array", - "description": "Analytics Reports", - "items": { "type": "object" } - }, - "actions": { - "type": "array", - "description": "Global and Object Actions", - "items": { "type": "object" } - }, - "themes": { - "type": "array", - "description": "UI Themes", - "items": { "type": "object" } - }, - "workflows": { - "type": "array", - "description": "Event-driven workflows", - "items": { "type": "object" } - }, - "approvals": { - "type": "array", - "description": "Approval processes", - "items": { "type": "object" } - }, - "flows": { - "type": "array", - "description": "Screen Flows", - "items": { "type": "object" } - }, - "roles": { - "type": "array", - "description": "User Roles hierarchy", - "items": { "type": "object" } - }, - "permissions": { - "type": "array", - "description": "Permission Sets and Profiles", - "items": { "type": "object" } - }, - "sharingRules": { - "type": "array", - "description": "Record Sharing Rules", - "items": { "type": "object" } - }, - "policies": { - "type": "array", - "description": "Security & Compliance Policies", - "items": { "type": "object" } - }, - "apis": { - "type": "array", - "description": "API Endpoints", - "items": { "type": "object" } - }, - "webhooks": { - "type": "array", - "description": "Outbound Webhooks", - "items": { "type": "object" } - }, - "agents": { - "type": "array", - "description": "AI Agents and Assistants", - "items": { "type": "object" } - }, - "ragPipelines": { - "type": "array", - "description": "RAG Pipelines", - "items": { "type": "object" } - }, - "hooks": { - "type": "array", - "description": "Object Lifecycle Hooks", - "items": { "type": "object" } - }, - "mappings": { - "type": "array", - "description": "Data Import/Export Mappings", - "items": { "type": "object" } - }, - "analyticsCubes": { - "type": "array", - "description": "Analytics Semantic Layer Cubes", - "items": { "type": "object" } - }, - "connectors": { - "type": "array", - "description": "External System Connectors", - "items": { "type": "object" } - }, - "data": { - "type": "array", - "description": "Seed Data / Fixtures for bootstrapping", - "items": { - "type": "object", - "properties": { - "object": { "type": "string", "description": "Target object name" }, - "mode": { - "type": "string", - "enum": ["upsert", "insert", "ignore", "replace"], - "description": "Conflict resolution strategy" - }, - "externalId": { "type": "string", "description": "Idempotency key for upsert matching" }, - "records": { "type": "array", "description": "Record data", "items": { "type": "object" } } - } - } - }, - "plugins": { - "type": "array", - "description": "Plugins to load" - }, - "devPlugins": { - "type": "array", - "description": "Plugins to load only in development (CLI dev command)" - } - }, - "required": ["manifest"] -}