@contentful/experience-design-system-cli 2.12.1 → 2.12.2-dev-build-e72ea10.0
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/dist/package.json
CHANGED
|
@@ -49,7 +49,7 @@ import { checkAgentAuth } from '../../generate/agent-runner.js';
|
|
|
49
49
|
import { normalizePath } from '../path-utils.js';
|
|
50
50
|
import { DEFAULT_CONFIGURED_HOST, toConfiguredHost } from '../../host-utils.js';
|
|
51
51
|
import { writeExperiencesCredentials } from '../../credentials-store.js';
|
|
52
|
-
import { nextStepAfterScopeGate, nextStepAfterCredentialsValidated, shouldBypassPreview, buildSkippedPreviewTransition, shouldRefusePush, buildSkippedPushTransition, } from './wizard-state-transitions.js';
|
|
52
|
+
import { nextStepAfterScopeGate, nextStepAfterCredentialsValidated, shouldBypassPreview, buildSkippedPreviewTransition, shouldRefusePush, buildSkippedPushTransition, resolveNoCacheForGenerate, } from './wizard-state-transitions.js';
|
|
53
53
|
function findCliPath() {
|
|
54
54
|
return join(fileURLToPath(import.meta.url), '..', '..', '..', '..', '..', 'bin', 'cli.js');
|
|
55
55
|
}
|
|
@@ -197,6 +197,13 @@ export function WizardApp({ initialSpaceId = '', initialEnvironmentId = 'master'
|
|
|
197
197
|
// `generating-tokens` step which already drives the token-classification
|
|
198
198
|
// subprocess off `state.rawTokensPath`. Modify-entry wins if both are set.
|
|
199
199
|
const rawTokensEntryReady = !modifyEntryReady && !pushFromPickerReady && !!initialRawTokensPath;
|
|
200
|
+
// Fresh session = the wizard is going to create its own extract session via
|
|
201
|
+
// `analyze extract` rather than pick one up from `--modify` / `--push-from-run`.
|
|
202
|
+
// For fresh sessions we force `--no-cache` on the spawned `generate components`
|
|
203
|
+
// so operators aren't silently served classifications cached from a prior
|
|
204
|
+
// session (the generation_cache table is project-wide, not session-scoped).
|
|
205
|
+
const isFreshSession = !seedExtractSessionId;
|
|
206
|
+
const effectiveNoCache = resolveNoCacheForGenerate({ isFreshSession, cliNoCache: noCache });
|
|
200
207
|
const initialStepResolved = modifyEntryReady
|
|
201
208
|
? 'final-review'
|
|
202
209
|
: pushFromPickerReady
|
|
@@ -606,7 +613,7 @@ export function WizardApp({ initialSpaceId = '', initialEnvironmentId = 'master'
|
|
|
606
613
|
tokensPath,
|
|
607
614
|
agent: state.agent,
|
|
608
615
|
...(state.agentModel ? { model: state.agentModel } : {}),
|
|
609
|
-
noCache,
|
|
616
|
+
noCache: effectiveNoCache,
|
|
610
617
|
}),
|
|
611
618
|
];
|
|
612
619
|
let progressCursor = null;
|
|
@@ -681,7 +688,7 @@ export function WizardApp({ initialSpaceId = '', initialEnvironmentId = 'master'
|
|
|
681
688
|
tokensPath,
|
|
682
689
|
agent: state.agent,
|
|
683
690
|
...(state.agentModel ? { model: state.agentModel } : {}),
|
|
684
|
-
noCache,
|
|
691
|
+
noCache: effectiveNoCache,
|
|
685
692
|
generatePromptPath,
|
|
686
693
|
}),
|
|
687
694
|
];
|
|
@@ -43,6 +43,25 @@ export declare function nextStepAfterScopeGate(opts: {
|
|
|
43
43
|
export declare function nextStepAfterCredentialsValidated(opts: {
|
|
44
44
|
acceptedCount: number;
|
|
45
45
|
}): WizardStepAfterCredentials;
|
|
46
|
+
/**
|
|
47
|
+
* Bug fix (2026-07): the `generation_cache` table in pipeline.db is keyed by
|
|
48
|
+
* `(input_hash, prompt_hash, entity_type, component_id)` — with no session
|
|
49
|
+
* scoping. `component_id` is a deterministic hash of `(name, source)`, so a
|
|
50
|
+
* fresh new session on an unchanged codebase always hits the cache and
|
|
51
|
+
* silently skips the LLM. That's the intended behavior for continued sessions
|
|
52
|
+
* (modify / push-from-run) but is surprising for a fresh `experiences import`
|
|
53
|
+
* run: the operator expects a re-classify pass, not cached output from a
|
|
54
|
+
* prior session.
|
|
55
|
+
*
|
|
56
|
+
* Resolution: for a fresh session (no `seedExtractSessionId`), force
|
|
57
|
+
* `--no-cache` on the spawned `generate components` subprocess. For a
|
|
58
|
+
* continued session (modify / push-from-run / picker-seeded), honor the
|
|
59
|
+
* operator's `--no-cache` flag as before.
|
|
60
|
+
*/
|
|
61
|
+
export declare function resolveNoCacheForGenerate(opts: {
|
|
62
|
+
isFreshSession: boolean;
|
|
63
|
+
cliNoCache: boolean;
|
|
64
|
+
}): boolean;
|
|
46
65
|
/**
|
|
47
66
|
* Skip-credentials spec — Task 2. When the operator pressed `s` on the
|
|
48
67
|
* credentials screen, the wizard advanced without validating creds. That
|
|
@@ -43,6 +43,26 @@ export function nextStepAfterScopeGate(opts) {
|
|
|
43
43
|
export function nextStepAfterCredentialsValidated(opts) {
|
|
44
44
|
return opts.acceptedCount > 0 ? 'generating' : 'push-decision-gate';
|
|
45
45
|
}
|
|
46
|
+
/**
|
|
47
|
+
* Bug fix (2026-07): the `generation_cache` table in pipeline.db is keyed by
|
|
48
|
+
* `(input_hash, prompt_hash, entity_type, component_id)` — with no session
|
|
49
|
+
* scoping. `component_id` is a deterministic hash of `(name, source)`, so a
|
|
50
|
+
* fresh new session on an unchanged codebase always hits the cache and
|
|
51
|
+
* silently skips the LLM. That's the intended behavior for continued sessions
|
|
52
|
+
* (modify / push-from-run) but is surprising for a fresh `experiences import`
|
|
53
|
+
* run: the operator expects a re-classify pass, not cached output from a
|
|
54
|
+
* prior session.
|
|
55
|
+
*
|
|
56
|
+
* Resolution: for a fresh session (no `seedExtractSessionId`), force
|
|
57
|
+
* `--no-cache` on the spawned `generate components` subprocess. For a
|
|
58
|
+
* continued session (modify / push-from-run / picker-seeded), honor the
|
|
59
|
+
* operator's `--no-cache` flag as before.
|
|
60
|
+
*/
|
|
61
|
+
export function resolveNoCacheForGenerate(opts) {
|
|
62
|
+
if (opts.isFreshSession)
|
|
63
|
+
return true;
|
|
64
|
+
return opts.cliNoCache;
|
|
65
|
+
}
|
|
46
66
|
/**
|
|
47
67
|
* Skip-credentials spec — Task 2. When the operator pressed `s` on the
|
|
48
68
|
* credentials screen, the wizard advanced without validating creds. That
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@contentful/experience-design-system-cli",
|
|
3
|
-
"version": "2.12.
|
|
3
|
+
"version": "2.12.2-dev-build-e72ea10.0",
|
|
4
4
|
"description": "Contentful Experiences design system import CLI",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"svelte": "^5.56.4",
|
|
38
38
|
"ts-morph": "^27.0.2",
|
|
39
39
|
"typescript": "^5.9.3",
|
|
40
|
-
"@contentful/experience-design-system-types": "2.12.
|
|
40
|
+
"@contentful/experience-design-system-types": "2.12.2-dev-build-e72ea10.0"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
43
|
"@tsconfig/node24": "^24.0.3",
|