@indigoai-us/hq-cli 5.345.125 → 5.345.126
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 +3 -0
- package/dist/lib/lanes/session-relink.js +22 -4
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
## [Unreleased]
|
|
4
4
|
|
|
5
|
+
## [5.345.126] — 2026-10-14
|
|
6
|
+
- `hq lanes` resume no longer picks a stale transcript when the same session exists in more than one account home. It uses the copy from the home the lane last ran in, and otherwise refuses with `provider_transcript_ambiguous` naming the homes.
|
|
7
|
+
|
|
5
8
|
## [5.345.125] — 2026-10-14
|
|
6
9
|
- `hq lanes` no longer sets `CLAUDE_CONFIG_DIR` for a Claude account whose
|
|
7
10
|
home is the default `~/.claude`, so lane workers, `claude auth status`
|
|
@@ -172,6 +172,7 @@ function relinkFromAnyProject(input, targetHome, searched) {
|
|
|
172
172
|
scanned.push(path.join(home, "sessions"));
|
|
173
173
|
throw missingTranscript(input, searched, scanned);
|
|
174
174
|
}
|
|
175
|
+
const matches = [];
|
|
175
176
|
for (const home of searched) {
|
|
176
177
|
const found = [];
|
|
177
178
|
const dirs = claudeProjectDirs(home);
|
|
@@ -183,12 +184,30 @@ function relinkFromAnyProject(input, targetHome, searched) {
|
|
|
183
184
|
if (isFile(candidate))
|
|
184
185
|
found.push(candidate);
|
|
185
186
|
}
|
|
186
|
-
if (found.length === 0)
|
|
187
|
-
continue;
|
|
188
187
|
if (found.length > 1) {
|
|
189
188
|
throw new LanesError("provider_transcript_ambiguous", `Multiple claude transcripts for session ${input.sessionId} exist in ${home}`, { provider: input.provider, session_id: input.sessionId, homes_searched: searched, matches: found });
|
|
190
189
|
}
|
|
191
|
-
|
|
190
|
+
if (found.length === 1)
|
|
191
|
+
matches.push({ home, source: found[0] });
|
|
192
|
+
}
|
|
193
|
+
if (matches.length === 0)
|
|
194
|
+
throw missingTranscript(input, searched, scanned);
|
|
195
|
+
// The last-run home holds the newest copy; any other home may hold a stale
|
|
196
|
+
// copy from an earlier account move, so more than one is ambiguous.
|
|
197
|
+
const lastRunHome = input.providerHomeAtSpawn ? path.resolve(input.providerHomeAtSpawn) : undefined;
|
|
198
|
+
const chosen = matches.find((match) => match.home === lastRunHome) ??
|
|
199
|
+
(matches.length === 1 ? matches[0] : undefined);
|
|
200
|
+
if (chosen === undefined) {
|
|
201
|
+
throw new LanesError("provider_transcript_ambiguous", `Provider transcript for session ${input.sessionId} exists in multiple homes: ${matches.map((match) => match.home).join(", ")}`, {
|
|
202
|
+
provider: input.provider,
|
|
203
|
+
session_id: input.sessionId,
|
|
204
|
+
homes_searched: searched,
|
|
205
|
+
matching_homes: matches.map((match) => match.home),
|
|
206
|
+
});
|
|
207
|
+
}
|
|
208
|
+
{
|
|
209
|
+
const home = chosen.home;
|
|
210
|
+
const source = chosen.source;
|
|
192
211
|
const targetDir = path.join(targetHome, "projects", encodeClaudeProjectDir(input.cwd));
|
|
193
212
|
const target = path.join(targetDir, `${input.sessionId}.jsonl`);
|
|
194
213
|
const subagents = path.join(path.dirname(source), input.sessionId);
|
|
@@ -212,7 +231,6 @@ function relinkFromAnyProject(input, targetHome, searched) {
|
|
|
212
231
|
found_outside_cwd: true,
|
|
213
232
|
};
|
|
214
233
|
}
|
|
215
|
-
throw missingTranscript(input, searched, scanned);
|
|
216
234
|
}
|
|
217
235
|
function copyVerifiedTranscript(input, sourceHome, targetHome, searched) {
|
|
218
236
|
let copied;
|