@neocompose/cli 0.31.1 → 0.31.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.31.2] - 2026-08-14
4
+
5
+ ### Fixed
6
+
7
+ - Allow newly authored `@relations` entries to create internal record
8
+ relations without requiring server-owned project and timestamp fields in
9
+ source, for both pending and explicit relation IDs.
10
+
3
11
  ## [0.31.1] - 2026-08-14
4
12
 
5
13
  ### Fixed
package/dist/neo.mjs CHANGED
@@ -79525,7 +79525,7 @@ function createNeoCliPushIntent(change) {
79525
79525
  return createProjectVersionIntent(intentType, { source: "neo-cli" });
79526
79526
  }
79527
79527
  const relationData = change.kind === "delete" ? change.baseData : change.nextData;
79528
- if (!isInternalRecordRelation(relationData)) {
79528
+ if (!isPushIntentInternalRecordRelation(relationData, change.kind)) {
79529
79529
  throw new Error(
79530
79530
  `Cannot push internal record relation "${change.recordId}": ${change.kind} change has invalid relation data.`
79531
79531
  );
@@ -79535,6 +79535,29 @@ function createNeoCliPushIntent(change) {
79535
79535
  relationKind: relationData.relationKind
79536
79536
  });
79537
79537
  }
79538
+ function isPushIntentInternalRecordRelation(value, operation) {
79539
+ if (operation === "create") {
79540
+ return isAuthoredInternalRecordRelation(value);
79541
+ }
79542
+ return isInternalRecordRelation(value);
79543
+ }
79544
+ function isAuthoredInternalRecordRelation(value) {
79545
+ if (!isObjectRecord5(value)) return false;
79546
+ if (!isNonEmptyString3(value.id)) return false;
79547
+ if (!isNonEmptyString3(value.relationKind)) return false;
79548
+ if (!isProjectRecordKind(value.sourceRecordKind)) return false;
79549
+ if (!isNonEmptyString3(value.sourceRecordId)) return false;
79550
+ if (!isProjectRecordKind(value.targetRecordKind)) return false;
79551
+ if (!isNonEmptyString3(value.targetRecordId)) return false;
79552
+ if (value.orderKey === void 0) return true;
79553
+ return isNonEmptyString3(value.orderKey);
79554
+ }
79555
+ function isObjectRecord5(value) {
79556
+ return typeof value === "object" && value !== null && !Array.isArray(value);
79557
+ }
79558
+ function isNonEmptyString3(value) {
79559
+ return typeof value === "string" && value.length > 0;
79560
+ }
79538
79561
  var init_push_change_intent = __esm({
79539
79562
  "src/commands/push-change-intent.ts"() {
79540
79563
  "use strict";
@@ -106501,11 +106524,11 @@ function assertProjectFileAuthoringRecordIdentifiers(recordKind, data) {
106501
106524
  if (recordKind !== "unity-texture-template" && recordKind !== "unity-audio-clip-template") {
106502
106525
  return;
106503
106526
  }
106504
- if (!isObjectRecord5(data) || typeof data.name !== "string") return;
106527
+ if (!isObjectRecord6(data) || typeof data.name !== "string") return;
106505
106528
  const label = recordKind === "unity-texture-template" ? "Unity texture template name" : "Unity audio clip template name";
106506
106529
  assertProjectFileAuthoringIdentifier(data.name, label);
106507
106530
  }
106508
- function isObjectRecord5(value) {
106531
+ function isObjectRecord6(value) {
106509
106532
  return typeof value === "object" && value !== null && !Array.isArray(value);
106510
106533
  }
106511
106534
  var init_project_file_authoring_identifiers = __esm({
@@ -109454,7 +109477,7 @@ var init_registry2 = __esm({
109454
109477
  PROJECT_SCHEMA_CONTRACT = Object.freeze({
109455
109478
  formatVersion: 3,
109456
109479
  contractVersion: "3.12",
109457
- cliVersion: "0.31.1",
109480
+ cliVersion: "0.31.2",
109458
109481
  projectFileUploadBatchSize: 32,
109459
109482
  documentRecords: {
109460
109483
  member: {
@@ -116046,7 +116069,7 @@ There is no --keep-current: preserving current semantic state defines flatten.
116046
116069
  async function main() {
116047
116070
  const args = parseArgs(process.argv.slice(2));
116048
116071
  if (args.command === "--version") {
116049
- console.log("0.31.1");
116072
+ console.log("0.31.2");
116050
116073
  return;
116051
116074
  }
116052
116075
  if (args.command === null || args.command === "help" || args.command === "--help" || args.command === "-h") {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@neocompose/cli",
3
- "version": "0.31.1",
3
+ "version": "0.31.2",
4
4
  "description": "Neo Compose native project-source CLI with bidirectional sync.",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -9,7 +9,7 @@ description: >-
9
9
  `@neocompose/cli` or `node cli/bin/neo.mjs` in the neo-compose repository.
10
10
  ---
11
11
 
12
- <!-- reviewed-through-cli: 0.31.1 -->
12
+ <!-- reviewed-through-cli: 0.31.2 -->
13
13
 
14
14
  # Neo Compose CLI
15
15
 
@@ -83,7 +83,7 @@ wrappers.
83
83
  The marker near the top of `SKILL.md` must exactly match the package version:
84
84
 
85
85
  ```html
86
- <!-- reviewed-through-cli: 0.31.1 -->
86
+ <!-- reviewed-through-cli: 0.31.2 -->
87
87
  ```
88
88
 
89
89
  The quoted version above is checked too, so this instruction cannot go stale