@neocompose/cli 0.36.5 → 0.36.7

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,22 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.36.7] - 2026-08-20
4
+
5
+ ### Fixed
6
+
7
+ - Keep braces and parentheses written inside string literals from changing the
8
+ extracted block getter/setter boundary. Project compilation, CLI checks, and
9
+ editor diagnostics now compile the complete authored accessor body.
10
+
11
+ ## [0.36.6] - 2026-08-20
12
+
13
+ ### Fixed
14
+
15
+ - Keep normal pull's in-memory overlay of uncommitted static value seeds valid
16
+ for computed-initializer replay. This lets a pull reconcile source that
17
+ still has pending member identities after a successful remote commit without
18
+ requiring a destructive `neo pull --reset`.
19
+
3
20
  ## [0.36.5] - 2026-08-20
4
21
 
5
22
  ### Fixed
package/dist/neo.mjs CHANGED
@@ -25236,29 +25236,31 @@ function findProjectSourceAccessorBody(source, keyword, containingRange) {
25236
25236
  const body = source.slice(bodyStart, bodyEnd);
25237
25237
  const local = new SourceText(body);
25238
25238
  const tokens = lex2(body);
25239
- if (tokens[0]?.text === "=>") {
25239
+ if (isToken(tokens[0], "op", "=>")) {
25240
25240
  if (keyword !== "get") return null;
25241
25241
  return expressionAccessor(source, full, local, tokens, bodyStart, 1);
25242
25242
  }
25243
25243
  let depth = 0;
25244
25244
  for (let index = 0; index < tokens.length; index++) {
25245
25245
  const token = tokens[index];
25246
- if (token.text === "{") {
25246
+ if (isToken(token, "punct", "{")) {
25247
25247
  depth++;
25248
25248
  continue;
25249
25249
  }
25250
- if (token.text === "}") {
25250
+ if (isToken(token, "punct", "}")) {
25251
25251
  depth--;
25252
25252
  continue;
25253
25253
  }
25254
- if (depth !== 1 || token.text !== keyword) continue;
25254
+ if (depth !== 1 || token.kind !== "ident" && token.kind !== "keyword" || token.text !== keyword) {
25255
+ continue;
25256
+ }
25255
25257
  let openIndex = index + 1;
25256
- if (tokens[openIndex]?.text === "(") {
25258
+ if (isToken(tokens[openIndex], "punct", "(")) {
25257
25259
  let parameterDepth = 1;
25258
25260
  for (let cursor = openIndex + 1; cursor < tokens.length; cursor++) {
25259
25261
  const candidate = tokens[cursor];
25260
- if (candidate.text === "(") parameterDepth++;
25261
- if (candidate.text === ")") parameterDepth--;
25262
+ if (isToken(candidate, "punct", "(")) parameterDepth++;
25263
+ if (isToken(candidate, "punct", ")")) parameterDepth--;
25262
25264
  if (parameterDepth !== 0) continue;
25263
25265
  openIndex = cursor + 1;
25264
25266
  break;
@@ -25266,7 +25268,7 @@ function findProjectSourceAccessorBody(source, keyword, containingRange) {
25266
25268
  if (parameterDepth !== 0) return null;
25267
25269
  }
25268
25270
  const open = tokens[openIndex];
25269
- if (open?.text === "=>") {
25271
+ if (isToken(open, "op", "=>")) {
25270
25272
  return expressionAccessor(
25271
25273
  source,
25272
25274
  full,
@@ -25276,12 +25278,12 @@ function findProjectSourceAccessorBody(source, keyword, containingRange) {
25276
25278
  openIndex + 1
25277
25279
  );
25278
25280
  }
25279
- if (open?.text !== "{") return null;
25281
+ if (open === void 0 || !isToken(open, "punct", "{")) return null;
25280
25282
  let accessorDepth = 1;
25281
25283
  for (let cursor = openIndex + 1; cursor < tokens.length; cursor++) {
25282
25284
  const candidate = tokens[cursor];
25283
- if (candidate.text === "{") accessorDepth++;
25284
- if (candidate.text === "}") accessorDepth--;
25285
+ if (isToken(candidate, "punct", "{")) accessorDepth++;
25286
+ if (isToken(candidate, "punct", "}")) accessorDepth--;
25285
25287
  if (accessorDepth !== 0) continue;
25286
25288
  const start = bodyStart + sourceOffset2(local, open.pos) + 1;
25287
25289
  const end = bodyStart + sourceOffset2(local, candidate.pos);
@@ -25295,6 +25297,9 @@ function findProjectSourceAccessorBody(source, keyword, containingRange) {
25295
25297
  }
25296
25298
  return null;
25297
25299
  }
25300
+ function isToken(token, kind, text) {
25301
+ return token?.kind === kind && token.text === text;
25302
+ }
25298
25303
  function expressionAccessor(source, full, local, tokens, bodyStart, firstIndex) {
25299
25304
  const first = tokens[firstIndex];
25300
25305
  if (!first) return null;
@@ -106486,25 +106491,25 @@ var init_project_file_pull = __esm({
106486
106491
  });
106487
106492
 
106488
106493
  // src/project-source/static-value-seed-records.ts
106489
- function staticValueSeedEmitRecords(status, present) {
106494
+ function staticValueSeedEmitRecords(status, present, projectId) {
106490
106495
  const records2 = /* @__PURE__ */ new Map();
106491
106496
  if (status === null) return records2;
106492
106497
  for (const [memberId, seed] of status.authoredValueSeeds) {
106493
106498
  const rootId = seed.valueId ?? memberValueIdFromRecord(status, memberId);
106494
106499
  if (rootId !== null) {
106495
- addSeedRecord(records2, present, {
106500
+ addSeedRecord(records2, present, projectId, {
106496
106501
  id: rootId,
106497
106502
  memberId,
106498
106503
  ...seed.init === void 0 ? { value: seed.value, classId: seed.classId } : { init: seed.init }
106499
106504
  });
106500
106505
  }
106501
106506
  for (const row of seed.values ?? []) {
106502
- addSeedRecord(records2, present, { ...row });
106507
+ addSeedRecord(records2, present, projectId, { ...row });
106503
106508
  }
106504
106509
  }
106505
106510
  return records2;
106506
106511
  }
106507
- function addSeedRecord(records2, present, data) {
106512
+ function addSeedRecord(records2, present, projectId, data) {
106508
106513
  const key = `value:${data.id}`;
106509
106514
  if (present.has(key)) return;
106510
106515
  if (records2.has(key)) return;
@@ -106514,7 +106519,18 @@ function addSeedRecord(records2, present, data) {
106514
106519
  // A seed has no committed content, so it has no server hash to carry.
106515
106520
  contentHash: "",
106516
106521
  deleted: false,
106517
- data
106522
+ // These records exist only in normal pull's in-memory local projection,
106523
+ // but the value emitter deliberately validates the entire graph before it
106524
+ // replays any computed initializer. Give the seed the same envelope as a
106525
+ // persisted value row so an unrelated replay does not reject a valid
106526
+ // locally-authored static initializer. The overlay is never written to
106527
+ // workspace state or sent to the server.
106528
+ data: {
106529
+ ...data,
106530
+ projectId,
106531
+ createdAt: 0,
106532
+ updatedAt: 0
106533
+ }
106518
106534
  });
106519
106535
  }
106520
106536
  function memberValueIdFromRecord(status, memberId) {
@@ -106854,7 +106870,8 @@ async function finishFormat4Pull(args) {
106854
106870
  const plannedLocalRecords = buildEmitRecordSet(document, plans, "emit");
106855
106871
  for (const [key, record3] of staticValueSeedEmitRecords(
106856
106872
  localStatus,
106857
- new Set(plannedLocalRecords.keys())
106873
+ new Set(plannedLocalRecords.keys()),
106874
+ workspace.config.projectId
106858
106875
  )) {
106859
106876
  plannedLocalRecords.set(key, record3);
106860
106877
  }
@@ -114140,7 +114157,7 @@ var init_registry2 = __esm({
114140
114157
  PROJECT_SCHEMA_CONTRACT = Object.freeze({
114141
114158
  formatVersion: 3,
114142
114159
  contractVersion: "3.14",
114143
- cliVersion: "0.36.5",
114160
+ cliVersion: "0.36.7",
114144
114161
  projectFileUploadBatchSize: 32,
114145
114162
  documentRecords: {
114146
114163
  member: {
@@ -120742,7 +120759,7 @@ There is no --keep-current: preserving current semantic state defines flatten.
120742
120759
  async function main() {
120743
120760
  const args = parseArgs(process.argv.slice(2));
120744
120761
  if (args.command === "--version") {
120745
- console.log("0.36.5");
120762
+ console.log("0.36.7");
120746
120763
  return;
120747
120764
  }
120748
120765
  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.36.5",
3
+ "version": "0.36.7",
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.36.5 -->
12
+ <!-- reviewed-through-cli: 0.36.7 -->
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.36.5 -->
86
+ <!-- reviewed-through-cli: 0.36.7 -->
87
87
  ```
88
88
 
89
89
  The quoted version above is checked too, so this instruction cannot go stale