Repository navigation
1.0.11
npm 1.0.11 (all 14 @metaobjectsdev/* packages in lockstep), PyPI 1.0.11, NuGet 1.0.11 and
Maven Central 8.0.11. metamodelVersion stays 1.0. Gated by a private 1.0.11-rc.1 build of the
release commit on the adopter estate (rc-gate.sh 7/7) and a full local CI run on that commit.
Docs
- A 1.0.x → 1.0.x upgrade guide (
docs/features/migrations/upgrading-within-1.0.md), written
from nine adopter upgrades to 1.0.10: resync owned generators (meta eject --list; a plain
meta genkeeps the logic you ejected), the monoreporuntimeImportcase, the 1.0.5 projection
URL and percent-encoded filter changes, 1.0.9 date validation, and the 1.0.4 view-join change.
The always-on agent context links it, and now says a project that deliberately owns its schema
outside MetaObjects follows its own migration rule.
Changed
meta verifywarns about whitespace in a node'sname. The loader accepts any
string as a name, in every port. An adopter's metadata, copied from legacy XML, had a field
named"defaultCurrencyId "(trailing space) and an identity named
"account_defaultCurrencyId _fk", and both loaded with no error. A new advisory section,
names, reports every object, field, identity, relationship, validator, view, template or
other named node whose name contains whitespace (the ECMAScript\sclass, so a pasted
no-break space counts). Leading or trailing whitespace getsWARN_NAME_SURROUNDING_WHITESPACE,
which says it is almost certainly unintended. Whitespace inside a name gets the plainer
WARN_NAME_INTERNAL_WHITESPACE. A name inherited throughextendsis reported once, where
it is declared. Requirement names are left to the requirement lint, which already reports
leading or trailing whitespace and still does not report a short multi-word label such as
"Order Recording". Like the other authoring lints it never fails the build. It appears
in text output and asnamesin--format json|toon, and can be muted with
--no-name-lintorMETA_NO_NAME_LINT=1.
Why a warning and not a load error: refusing these names does not pass the correction
bar indocs/compatibility-policy.md. They work on the core path:meta migratequotes the
column ("default_currency_id ") and the ObjectManager reads and writes the key. Multi-word
requirement names are documented to load. So rejecting them would break metadata that does
what its author declared. Upgrading: nothing stops loading. To clear a finding, rename
the node. On a field whose physical column must keep its current name, pin@columnwhen
you rename it.
Fixed
- Generated DELETE routes on Cloudflare D1 answer 204, not 404. The affected-row count
read libsql, Postgres, bun:sqlite and mysql2 result shapes, but not D1's
{ meta: { changes } }, so every D1 delete counted 0 rows and the route answered 404 after
deleting the row (an admin panel showed an error and kept the row on screen). The drizzle
ObjectManager driver had its own copy of the same count and now shares the fixed one.
Upgrading: a project with an ejected adapter copy undercodegen/runtime/takes it with
meta eject routes-hono --force(or merges the one-line change by hand). - The missing-FK-index advisory suggests a name unique to the table. It suggested
by<Field>, so two entities with the same FK field (Citation.auditEntryId,
Approval.auditEntryId) were both toldbyAuditEntryId. Postgres index names are schema-wide,
and applying the advice verbatim failedmeta migratewithERR_DUPLICATE_SQL_NAME. The
suggestion is now<entity>By<Field>(citationByAuditEntryId). - Python
verify --codegenno longer passes while checking nothing. With no
--generatorsit printed a note and exited 0. Since 1.0.4 there is no default suite, so a CI
step written before then regenerated nothing and passed over committed output (one adopter's
gate covered 159 generated files this way). It now fails when--outholds generated files
and nothing is selected, and still passes when there is no generated output. The config
schema and the C#verifyhelp no longer mention a default suite. - TypeScript
meta genregenerates output written outside the project root. Since 1.0.5 such
files (a monorepo target at../shared/src/generated, say) are not recorded, and the next run
REFUSED every one whose content had changed, as "no record of generating this file", though
its own warning said a later run overwrites them unchecked. They are now overwritten
unchecked, as the warning says;--baseline=adoptkeeps its meaning. - A generated form with a blank optional date submits again. 1.0.9 made
field.dateand
field.timestampschemas reject"", and react-hook-form validates the RAW values before the
submit callback, where the blank-field normalizer ran. A create form with a blank optional
date therefore showedmust be an ISO date (YYYY-MM-DD)and never calledonSubmit: Create
did nothing. The form's schema is now preprocessed by the same create/edit rule (a blank is
omitted on create,nullon edit) before validation. Upgrading: runmeta gen; an owned
copy of theformgenerator takes it frommeta eject form. - The "agent context is out of date" hint no longer strips a mixed stack. Python, C# and
Javagen/verifytold you to runnpx meta agent-docs --server <lang>. An explicit
--serverreplaces the stack recorded in.metaobjects/, so on a project that is also
TypeScript (or Kotlin, or has a React client) following the hint dropped those references.
The hint is nownpx meta agent-docs, which keeps the recorded stack. meta ejectno longer copies the HTTP adapter beside an owned generator that predates it.
Since 1.0.9, ejectingentity/routes/routes-honoalso copies the adapter source into
codegen/runtime/, and re-running it fills in a missing copy. Over an owned copy from before
1.0.9, which has noruntimeImportoption and whose output imports the published package,
that copy was dead code, and could be a Drizzle adapter in a project with no database. It is
now skipped for such a copy.meta genwarns when generated code reaches the owned adapter from outside its workspace
package. In a monorepo whose output sits inapps/api/…, the relative import of
codegen/runtime/leaves that package and its build fails (TS6059 … is not under 'rootDir'). The warning names the package and the two fixes: pass
runtimeImport: "@metaobjectsdev/runtime-ts", or move the copy inside the package.meta migrate --slugreports thedown.sqlit writes. It printed only theup.sqlpath.- TanStack hooks and grid hooks import
<Entity>.metafrom beside themselves. The UI
generators write the DB-free<Entity>.meta.tsinto their own target, but the generated
import { Program } from …pointed at the entity module's path plus.meta. On a
multi-target project that is another package'simportBase
(@acme/db/generated/…/Program.meta), where no such file exists, so the web target only
compiled with a hand-writtentsconfigalias. It is now a sibling import
(./Program.meta). Upgrading: runmeta gen; an alias added to work around it can be
removed.