You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 24baf39
Browse filesBrowse the repository at this point in the historyBrowse files
fix(rest, service-automation): the import door and the pull also recognise a package-scoped refusal by its shape
A by-name read's refusal is recognised by class and, as the runtime's
/meta door does, by shape (code RESOURCE_CONFLICT with refusal.status
'refused'), so one that crossed a realm or a second core copy is still
answered as its own 409, never 404. Each reader is pinned with a plain
object of that shape. The pull's comments now say the request carries
callerPackageId and the pull does not read it yet; the changeset gains
a TypeScript note for mapping_name_refused.
Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WGufzhpDMvAM1Pvdqg4Qky
Copy file name to clipboardExpand all lines: .changeset/32071-mapping-name-by-package.md
+3-1Lines changed: 3 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,10 +18,12 @@ Metadata-protocol: none
18
18
1.`GET /api/v1/meta/mapping/NAME` for a name two packages hold answered `200` with the first registered package's mapping. It is now `409 RESOURCE_CONFLICT` naming both.
19
19
2. An import by `mappingName` for such a name read the first holder's mapping: `200` when its target was the request's object, else `400 MAPPING_TARGET_MISMATCH` (the importer of the other package's object could never use its own mapping). It is now `409 RESOURCE_CONFLICT` naming both, and no row is written.
20
20
3. A connector pull of such a name pulled through the first holder's mapping, writing into that mapping's target. It is now refused before any call or write: the pull fails with `409 RESOURCE_CONFLICT` (reason `mapping_name_refused`) naming both, and the job run records that failure.
21
-
4.`GET /api/v1/meta/mapping/NAME?package=X`, `/meta/mapping/NS/NAME` and `/meta/mapping/_env/NAME`, where `X`, `NS` or the environment does not hold the name, answered `200` with the holder's mapping. They are now `409 RESOURCE_CONFLICT` naming the holder: the address is the exact qualifier (ADR-0150 D5), as it already is for apps, pages, dashboards, reports, books, analytics cubes, tools, skillsand agents.
21
+
4.`GET /api/v1/meta/mapping/NAME?package=X`, `/meta/mapping/NS/NAME` and `/meta/mapping/_env/NAME`, where `X`, `NS` or the environment does not hold the name, answered `200` with the holder's mapping. They are now `409 RESOURCE_CONFLICT` naming the holder: the address is the exact qualifier (ADR-0150 D5), as it already is for apps, pages, dashboards, reports, books, analytics cubes, tools, skills, agents and APIs.
22
22
23
23
The fix for each:
24
24
25
25
- FROM a bare read of a two-holder name TO `?package=<id>` or `/meta/mapping/<namespace>/NAME`.
26
26
- FROM importing or pulling by a two-holder name TO renaming one of the two mappings; the import door and the pull do not yet take a package.
27
27
- FROM an address naming a package that does not hold the name TO the holder the refusal names.
28
+
29
+
**TypeScript:**`ConnectorPullRefusalReason` (`@objectstack/service-automation`) gains the member `mapping_name_refused`. A `switch` over the union that must be exhaustive needs a case for it; code that only reads `reason` is unaffected.
0 commit comments