@nightloom/isy 1.0.5 → 1.0.6-next.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/README.md +17 -2
- package/dist/agents/claude.js +3 -2
- package/dist/agents/claude.js.map +1 -1
- package/dist/agents/codex.js +14 -5
- package/dist/agents/codex.js.map +1 -1
- package/dist/agents/index.d.ts +14 -10
- package/dist/agents/index.js +65 -15
- package/dist/agents/index.js.map +1 -1
- package/dist/agents/kimi.js +26 -8
- package/dist/agents/kimi.js.map +1 -1
- package/dist/agents/types.d.ts +12 -3
- package/dist/commands/commit.d.ts +6 -0
- package/dist/commands/commit.js +326 -16
- package/dist/commands/commit.js.map +1 -1
- package/dist/commands/health.js +1 -1
- package/dist/commands/health.js.map +1 -1
- package/dist/commands/init.js +30 -5
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/status.d.ts +2 -0
- package/dist/commands/status.js +7 -4
- package/dist/commands/status.js.map +1 -1
- package/dist/commands/upload.d.ts +8 -1
- package/dist/commands/upload.js +46 -39
- package/dist/commands/upload.js.map +1 -1
- package/dist/detectors.d.ts +32 -0
- package/dist/detectors.js +279 -72
- package/dist/detectors.js.map +1 -1
- package/dist/git.d.ts +52 -0
- package/dist/git.js +166 -9
- package/dist/git.js.map +1 -1
- package/dist/githook.d.ts +18 -7
- package/dist/githook.js +147 -17
- package/dist/githook.js.map +1 -1
- package/dist/hook.d.ts +22 -2
- package/dist/hook.js +28 -3
- package/dist/hook.js.map +1 -1
- package/dist/index.js +14 -5
- package/dist/index.js.map +1 -1
- package/dist/mask-paths.d.ts +4 -3
- package/dist/mask-paths.js +4 -3
- package/dist/mask-paths.js.map +1 -1
- package/dist/parser.d.ts +58 -9
- package/dist/parser.js +337 -58
- package/dist/parser.js.map +1 -1
- package/dist/paths.d.ts +19 -1
- package/dist/paths.js +28 -3
- package/dist/paths.js.map +1 -1
- package/dist/redact.d.ts +2 -0
- package/dist/redact.js +956 -97
- package/dist/redact.js.map +1 -1
- package/dist/stage0.js +27 -8
- package/dist/stage0.js.map +1 -1
- package/dist/state.d.ts +15 -0
- package/dist/state.js +8 -0
- package/dist/state.js.map +1 -1
- package/dist/test/check.test.js +1 -1
- package/dist/test/check.test.js.map +1 -1
- package/dist/test/codex.test.js +27 -4
- package/dist/test/codex.test.js.map +1 -1
- package/dist/test/commit.test.js +1466 -6
- package/dist/test/commit.test.js.map +1 -1
- package/dist/test/e2e-harness.test.d.ts +1 -0
- package/dist/test/e2e-harness.test.js +53 -0
- package/dist/test/e2e-harness.test.js.map +1 -0
- package/dist/test/git.test.js +72 -2
- package/dist/test/git.test.js.map +1 -1
- package/dist/test/hook.test.js +138 -3
- package/dist/test/hook.test.js.map +1 -1
- package/dist/test/init.test.js +60 -1
- package/dist/test/init.test.js.map +1 -1
- package/dist/test/kimi-config.test.js +27 -5
- package/dist/test/kimi-config.test.js.map +1 -1
- package/dist/test/kimi-hook.test.js +1 -1
- package/dist/test/kimi-hook.test.js.map +1 -1
- package/dist/test/kimi-listing.test.js +42 -2
- package/dist/test/kimi-listing.test.js.map +1 -1
- package/dist/test/kimi.test.js +26 -2
- package/dist/test/kimi.test.js.map +1 -1
- package/dist/test/parser.test.js +527 -1
- package/dist/test/parser.test.js.map +1 -1
- package/dist/test/redact.test.js +2442 -14
- package/dist/test/redact.test.js.map +1 -1
- package/dist/test/stage0.test.js +617 -1
- package/dist/test/stage0.test.js.map +1 -1
- package/dist/test/sweep.test.js +99 -3
- package/dist/test/sweep.test.js.map +1 -1
- package/package.json +1 -1
- package/src/agents/claude.ts +3 -2
- package/src/agents/codex.ts +14 -5
- package/src/agents/index.ts +71 -16
- package/src/agents/kimi.ts +28 -8
- package/src/agents/types.ts +12 -3
- package/src/commands/commit.ts +354 -18
- package/src/commands/health.ts +1 -1
- package/src/commands/init.ts +37 -7
- package/src/commands/status.ts +9 -4
- package/src/commands/upload.ts +54 -54
- package/src/detectors.ts +284 -75
- package/src/git.ts +175 -9
- package/src/githook.ts +151 -19
- package/src/hook.ts +30 -3
- package/src/index.ts +15 -5
- package/src/mask-paths.ts +5 -4
- package/src/parser.ts +355 -51
- package/src/paths.ts +30 -3
- package/src/redact.ts +959 -100
- package/src/stage0.ts +28 -8
- package/src/state.ts +18 -0
package/src/commands/init.ts
CHANGED
|
@@ -4,7 +4,7 @@ import { drainAlerts, parkAlert } from "../alert.js";
|
|
|
4
4
|
import { DEFAULT_API_BASE_URL, verifyToken } from "../api.js";
|
|
5
5
|
import { readConfig, writeConfig } from "../config.js";
|
|
6
6
|
import { presentAgents } from "../agents/index.js";
|
|
7
|
-
import { GIT_HOOKS, gitHooksDir, installGitHook } from "../githook.js";
|
|
7
|
+
import { GIT_HOOKS, gitHooksDir, hooksLeftToTheUser, installGitHook } from "../githook.js";
|
|
8
8
|
import { logLine } from "../log.js";
|
|
9
9
|
import { awaitPairedKey, openPairing } from "../pairing.js";
|
|
10
10
|
import type { Pairing } from "../pairing.js";
|
|
@@ -203,14 +203,44 @@ export async function runInit(options: { token?: string }, cwd: string): Promise
|
|
|
203
203
|
if (gitHook === "not-a-repository") {
|
|
204
204
|
console.log(`${cwd} is not a git repository, so no git hooks were added.`);
|
|
205
205
|
} else {
|
|
206
|
-
const
|
|
206
|
+
const left = await hooksLeftToTheUser(cwd);
|
|
207
|
+
const names = GIT_HOOKS.filter((hook) => !left.some((other) => other.name === hook.name))
|
|
208
|
+
.map((hook) => hook.name)
|
|
209
|
+
.join(" and ");
|
|
207
210
|
const where = await gitHooksDir(cwd);
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
211
|
+
if (names) {
|
|
212
|
+
console.log(
|
|
213
|
+
gitHook === "installed"
|
|
214
|
+
? `Added the ${names} ${left.length > 0 ? "hook" : "hooks"} in ${where}`
|
|
215
|
+
: `The ${names} ${left.length > 0 ? "hook is" : "hooks are"} already present in ${where}`,
|
|
216
|
+
);
|
|
217
|
+
}
|
|
218
|
+
for (const hook of left) {
|
|
219
|
+
console.log(
|
|
220
|
+
`The ${hook.name} hook in ${where} is not a shell script (${hook.language}), so isy left it as it was. ` +
|
|
221
|
+
`To send sessions from it, have it run this through sh:\n ${hook.command}`,
|
|
222
|
+
);
|
|
223
|
+
}
|
|
213
224
|
}
|
|
214
225
|
|
|
215
226
|
if (verified.githubLogin) console.log(`Signed in as ${verified.githubLogin}`);
|
|
227
|
+
|
|
228
|
+
// The hooks only send sessions. Nothing tells the server a pull request exists
|
|
229
|
+
// until the App is on its repository, and this machine cannot see whether it
|
|
230
|
+
// is, so without this line the silence that follows explains itself to nobody.
|
|
231
|
+
// The docs page rather than the App's own address: a published CLI cannot
|
|
232
|
+
// follow a rename. No CLI hooked means no session, and nothing to go on to yet.
|
|
233
|
+
if (agents.length > 0) {
|
|
234
|
+
console.log(
|
|
235
|
+
[
|
|
236
|
+
"",
|
|
237
|
+
"Next:",
|
|
238
|
+
" 1. Install the GitHub App on the repositories you want analysed, if it is not there yet:",
|
|
239
|
+
` ${new URL("/docs/github-app", baseUrl)}`,
|
|
240
|
+
" Without it sessions upload, but no pull request ever gets a comment.",
|
|
241
|
+
" 2. Work with your agent as usual and commit. The hooks send the session.",
|
|
242
|
+
" 3. Push and open a pull request. The analysis arrives as one comment on it.",
|
|
243
|
+
].join("\n"),
|
|
244
|
+
);
|
|
245
|
+
}
|
|
216
246
|
}
|
package/src/commands/status.ts
CHANGED
|
@@ -3,7 +3,7 @@ import { series } from "./check.js";
|
|
|
3
3
|
import type { AgentId } from "../agents/index.js";
|
|
4
4
|
import { DEFAULT_API_BASE_URL } from "../api.js";
|
|
5
5
|
import { readConfig } from "../config.js";
|
|
6
|
-
import { gitHookInstalled, gitHooksDir } from "../githook.js";
|
|
6
|
+
import { gitHookInstalled, gitHooksDir, hooksLeftToTheUser } from "../githook.js";
|
|
7
7
|
import { packageVersion, projectSlug } from "../paths.js";
|
|
8
8
|
import { countQueue } from "../queue.js";
|
|
9
9
|
import { updateNotice } from "../update.js";
|
|
@@ -56,6 +56,8 @@ export interface StatusReport {
|
|
|
56
56
|
sessions: number;
|
|
57
57
|
/** The per-repository git hooks that start the fast loop. */
|
|
58
58
|
gitHook: "installed" | "missing" | "not-a-repository";
|
|
59
|
+
/** Hooks written in another language: they take no block, and `isy init` says what to add. */
|
|
60
|
+
gitHooksLeft: string[];
|
|
59
61
|
};
|
|
60
62
|
agents: AgentSessions[];
|
|
61
63
|
/** The newest session for this directory, whichever CLI produced it. */
|
|
@@ -139,6 +141,7 @@ export async function collectStatus(cwd: string): Promise<StatusReport> {
|
|
|
139
141
|
slug: projectSlug(cwd),
|
|
140
142
|
sessions: agents.reduce((total, entry) => total + entry.sessions, 0),
|
|
141
143
|
gitHook,
|
|
144
|
+
gitHooksLeft: (await hooksLeftToTheUser(cwd)).map((hook) => hook.name),
|
|
142
145
|
},
|
|
143
146
|
agents,
|
|
144
147
|
latestSession: newest,
|
|
@@ -181,9 +184,11 @@ export function formatStatus(report: StatusReport): string {
|
|
|
181
184
|
lines.push(
|
|
182
185
|
row(
|
|
183
186
|
"git hooks",
|
|
184
|
-
report.project.gitHook
|
|
185
|
-
? "
|
|
186
|
-
:
|
|
187
|
+
report.project.gitHook !== "installed"
|
|
188
|
+
? "missing — run isy init here to analyse on every commit and push"
|
|
189
|
+
: report.project.gitHooksLeft.length > 0
|
|
190
|
+
? `installed, except ${series(report.project.gitHooksLeft)}: not a shell script, isy init says what to add`
|
|
191
|
+
: "installed",
|
|
187
192
|
),
|
|
188
193
|
);
|
|
189
194
|
}
|
package/src/commands/upload.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { detectAgent, presentAgents } from "../agents/index.js";
|
|
1
|
+
import { detectAgent, presentAgents, sessionsInTree } from "../agents/index.js";
|
|
2
2
|
import type { Agent, AgentId, HookInput } from "../agents/index.js";
|
|
3
3
|
import { DEFAULT_API_BASE_URL, buildTranscriptFields, uploadSession } from "../api.js";
|
|
4
4
|
import type { ApiOptions, UploadPayload } from "../api.js";
|
|
@@ -7,9 +7,9 @@ import { collectGitMetadata } from "../git.js";
|
|
|
7
7
|
import { autoInstallGitHook } from "../githook.js";
|
|
8
8
|
import type { GitMetadata, GitResult } from "../git.js";
|
|
9
9
|
import type { DiscoveredSession, IsyConfig } from "../types.js";
|
|
10
|
-
import { logError, logLine } from "../log.js";
|
|
10
|
+
import { errorMessage, logError, logLine } from "../log.js";
|
|
11
11
|
import { parseLines } from "../parser.js";
|
|
12
|
-
import { packageVersion } from "../paths.js";
|
|
12
|
+
import { SWEEP_WINDOW_MS, packageVersion } from "../paths.js";
|
|
13
13
|
import {
|
|
14
14
|
MAX_ATTEMPTS,
|
|
15
15
|
abandon,
|
|
@@ -24,7 +24,7 @@ import {
|
|
|
24
24
|
import { updateNotice } from "../update.js";
|
|
25
25
|
import { planNotice } from "../plan.js";
|
|
26
26
|
import type { PlanStatus } from "../plan.js";
|
|
27
|
-
import { looksUnchanged, readState, updateSession } from "../state.js";
|
|
27
|
+
import { looksUnchanged, namedBranch, readState, updateSession } from "../state.js";
|
|
28
28
|
import { sessionFingerprint } from "../subagents.js";
|
|
29
29
|
import type { ClientState, CommitMark } from "../state.js";
|
|
30
30
|
|
|
@@ -46,10 +46,14 @@ export interface UploadReport {
|
|
|
46
46
|
updateNotice?: string;
|
|
47
47
|
/** What a SessionEnd run did about this repository's git hooks, when it did anything. */
|
|
48
48
|
gitHook?: "installed" | "shared-hooks";
|
|
49
|
+
/** Which repository, as owner/name: the line is parked, and read wherever the next session starts. */
|
|
50
|
+
gitHookRepository?: string;
|
|
49
51
|
/** Set when the plan has nothing left: the next pull request will not be analysed. */
|
|
50
52
|
planNotice?: string;
|
|
51
53
|
/** Sessions a sweep looked at, across every CLI and every directory. */
|
|
52
54
|
scanned?: number;
|
|
55
|
+
/** Sessions left out because their transcript could not be read. */
|
|
56
|
+
unreadable?: number;
|
|
53
57
|
/** The server's hourly upload allowance ran out; nothing was lost by it. */
|
|
54
58
|
throttled?: boolean;
|
|
55
59
|
/** Why the server refused the key. Nothing was lost by that either. */
|
|
@@ -89,7 +93,7 @@ export async function buildPayload(
|
|
|
89
93
|
git: GitMetadata,
|
|
90
94
|
options: { extraPatterns?: readonly string[]; cwd?: string; commits?: CommitMark[] },
|
|
91
95
|
fallbackSessionId: string,
|
|
92
|
-
): Promise<UploadPayload | undefined> {
|
|
96
|
+
): Promise<{ payload: UploadPayload; gitBranch?: string } | undefined> {
|
|
93
97
|
// Whatever the CLI's native format, this comes back Claude-record shaped:
|
|
94
98
|
// the server re-parses the upload with the same parseLines (cascade.ts).
|
|
95
99
|
const lines = await agent.redactedLines(transcriptPath, options);
|
|
@@ -102,16 +106,19 @@ export async function buildPayload(
|
|
|
102
106
|
const now = new Date().toISOString();
|
|
103
107
|
|
|
104
108
|
return {
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
109
|
+
gitBranch: session.meta.gitBranch,
|
|
110
|
+
payload: {
|
|
111
|
+
sessionId: session.sessionId ?? fallbackSessionId,
|
|
112
|
+
agent: agent.id,
|
|
113
|
+
contentHash,
|
|
114
|
+
startedAt: session.meta.startedAt ?? now,
|
|
115
|
+
endedAt: session.meta.endedAt ?? now,
|
|
116
|
+
claudeVersion: session.meta.claudeVersion ?? "unknown",
|
|
117
|
+
isyVersion: await packageVersion(),
|
|
118
|
+
git,
|
|
119
|
+
transcript,
|
|
120
|
+
...(options.commits && options.commits.length > 0 ? { commits: options.commits } : {}),
|
|
121
|
+
},
|
|
115
122
|
};
|
|
116
123
|
}
|
|
117
124
|
|
|
@@ -185,15 +192,16 @@ interface Target {
|
|
|
185
192
|
/** Set when the target came from a scan, which already knows size and mtime. */
|
|
186
193
|
file?: DiscoveredSession;
|
|
187
194
|
/**
|
|
188
|
-
* Where this session ran
|
|
189
|
-
*
|
|
195
|
+
* Where this session ran, when finding it took reading that: a sweep, or a
|
|
196
|
+
* session from elsewhere in the tree. Every other path knows the directory
|
|
197
|
+
* before it knows the session, because a hook named it.
|
|
190
198
|
*/
|
|
191
199
|
cwd?: string;
|
|
192
200
|
}
|
|
193
201
|
|
|
194
202
|
/**
|
|
195
|
-
* Every session
|
|
196
|
-
*
|
|
203
|
+
* Every session of this work tree whose bytes are not already on the server,
|
|
204
|
+
* across every CLI installed here.
|
|
197
205
|
*
|
|
198
206
|
* Size and mtime both matching the last accepted upload means the content
|
|
199
207
|
* matches, so an unchanged transcript is never read — and a session that ended
|
|
@@ -203,29 +211,15 @@ async function changedSessions(cwd: string, state: ClientState): Promise<Target[
|
|
|
203
211
|
const targets: Target[] = [];
|
|
204
212
|
|
|
205
213
|
for (const agent of await presentAgents()) {
|
|
206
|
-
for (const file of
|
|
214
|
+
for await (const file of sessionsInTree(agent, cwd)) {
|
|
207
215
|
if (looksUnchanged(state[file.path] ?? {}, file)) continue;
|
|
208
|
-
targets.push({ agent, path: file.path, file });
|
|
216
|
+
targets.push({ agent, path: file.path, file, cwd: file.cwd });
|
|
209
217
|
}
|
|
210
218
|
}
|
|
211
219
|
|
|
212
220
|
return targets;
|
|
213
221
|
}
|
|
214
222
|
|
|
215
|
-
/**
|
|
216
|
-
* How far back a sweep looks. A sweep has no baseline to start from — every
|
|
217
|
-
* session it has never seen reads as changed — so without a window the first
|
|
218
|
-
* one on a machine would upload years of transcripts from every directory the
|
|
219
|
-
* CLI was ever used in. Nothing older than this can reach an analysis anyway:
|
|
220
|
-
* sessions are matched to a pull request by commit SHA, and a transcript
|
|
221
|
-
* untouched for a fortnight belongs to commits that were pushed long ago.
|
|
222
|
-
*
|
|
223
|
-
* ponytail: a fixed window, not a high-water mark. A machine that was offline
|
|
224
|
-
* longer than this loses the tail; move the boundary to a `lastSweepAt` in the
|
|
225
|
-
* config if that ever happens to anyone.
|
|
226
|
-
*/
|
|
227
|
-
const SWEEP_WINDOW_MS = 14 * 24 * 60 * 60 * 1000;
|
|
228
|
-
|
|
229
223
|
/**
|
|
230
224
|
* Every recently changed session on this machine, whatever directory it ran in.
|
|
231
225
|
*
|
|
@@ -267,7 +261,7 @@ async function sweptSessions(state: ClientState, report: UploadReport): Promise<
|
|
|
267
261
|
// Counted, not listed. A sweep runs at every session start and the same
|
|
268
262
|
// sessions are skipped every time; one line each would push everything worth
|
|
269
263
|
// reading out of the journal `isy health` shows.
|
|
270
|
-
if (rootless > 0) logLine(`upload: ${rootless} swept session(s) record no working directory`);
|
|
264
|
+
if (rootless > 0) logLine(`upload: ${rootless} swept session(s) record no working directory, or cannot be read`);
|
|
271
265
|
|
|
272
266
|
// Smallest first. The run budget is checked between sessions, and the session
|
|
273
267
|
// still open in the CLI that started this sweep is the biggest and always reads
|
|
@@ -299,20 +293,21 @@ async function sendOne(
|
|
|
299
293
|
fallbackSessionId: string,
|
|
300
294
|
report: UploadReport,
|
|
301
295
|
): Promise<void> {
|
|
302
|
-
const
|
|
296
|
+
const built = await buildPayload(
|
|
303
297
|
target.agent,
|
|
304
298
|
target.path,
|
|
305
299
|
git,
|
|
306
300
|
{
|
|
307
301
|
extraPatterns: config.extraRedactPatterns,
|
|
308
302
|
// A swept session ran where the transcript says it ran, not where this
|
|
309
|
-
// process happens to stand: masking
|
|
303
|
+
// process happens to stand: masking starts from it.
|
|
310
304
|
cwd: target.cwd ?? workingDir,
|
|
311
305
|
commits: state[target.path]?.commits,
|
|
312
306
|
},
|
|
313
307
|
fallbackSessionId,
|
|
314
308
|
);
|
|
315
|
-
if (!
|
|
309
|
+
if (!built) return;
|
|
310
|
+
const { payload, gitBranch } = built;
|
|
316
311
|
|
|
317
312
|
if (await isAbandoned(payload.sessionId, payload.contentHash)) {
|
|
318
313
|
report.skipped = `session ${payload.sessionId} was given up on after ${MAX_ATTEMPTS} attempts`;
|
|
@@ -334,6 +329,7 @@ async function sendOne(
|
|
|
334
329
|
...current,
|
|
335
330
|
uploadedHash: payload.contentHash,
|
|
336
331
|
uploadedCommit: payload.commits?.at(-1)?.sha,
|
|
332
|
+
branch: namedBranch(current.branch, gitBranch, git.branch),
|
|
337
333
|
...seen,
|
|
338
334
|
}));
|
|
339
335
|
await updateConfig({ lastUploadAt: new Date().toISOString() });
|
|
@@ -467,6 +463,8 @@ export async function runUpload(
|
|
|
467
463
|
const outcome = await autoInstallGitHook(workingDir);
|
|
468
464
|
if (outcome === "installed" || outcome === "shared-hooks") {
|
|
469
465
|
report.gitHook = outcome;
|
|
466
|
+
const git = await gitFor(workingDir);
|
|
467
|
+
report.gitHookRepository = git.ok ? git.metadata.remote : workingDir;
|
|
470
468
|
logLine(`upload: git hooks ${outcome} in ${workingDir}`);
|
|
471
469
|
}
|
|
472
470
|
} catch (error) {
|
|
@@ -496,19 +494,20 @@ export async function runUpload(
|
|
|
496
494
|
continue;
|
|
497
495
|
}
|
|
498
496
|
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
api,
|
|
505
|
-
|
|
506
|
-
//
|
|
507
|
-
//
|
|
508
|
-
//
|
|
509
|
-
|
|
510
|
-
report
|
|
511
|
-
|
|
497
|
+
// Per target, not per run: a run covers many sessions, and one fallback
|
|
498
|
+
// shared between them would file them all under the same id — which the
|
|
499
|
+
// server keys on, so each would replace the last.
|
|
500
|
+
const sessionId = target.file?.sessionId ?? hook?.session_id ?? "unknown";
|
|
501
|
+
try {
|
|
502
|
+
await sendOne(target, git.metadata, state, config, api, workingDir, sessionId, report);
|
|
503
|
+
} catch (error) {
|
|
504
|
+
// A `sudo` session's, owned by root, one deleted since the listing, or one
|
|
505
|
+
// redaction throws on. That says nothing about the sessions behind it or the
|
|
506
|
+
// queue, which still go out. It fails again at every run, so the journal gets
|
|
507
|
+
// one reason a run, not a line a file.
|
|
508
|
+
if (!report.unreadable) logError(`upload: ${sessionId} could not be read or sent: ${errorMessage(error)}`);
|
|
509
|
+
report.unreadable = (report.unreadable ?? 0) + 1;
|
|
510
|
+
}
|
|
512
511
|
}
|
|
513
512
|
|
|
514
513
|
if (outside > 0) logLine(`upload: ${outside} changed session(s) ran outside a repository`);
|
|
@@ -533,6 +532,7 @@ export function formatUploadReport(report: UploadReport): string {
|
|
|
533
532
|
if (report.queued > 0) parts.push("session queued for retry");
|
|
534
533
|
if (report.drained > 0) parts.push(`${report.drained} queued session(s) sent`);
|
|
535
534
|
if (report.abandoned > 0) parts.push(`${report.abandoned} session(s) given up on`);
|
|
535
|
+
if (report.unreadable) parts.push(`${report.unreadable} session(s) could not be read, see isy health`);
|
|
536
536
|
|
|
537
537
|
const line = parts.length > 0 ? `isy: ${parts.join(", ")}` : "isy: nothing to upload";
|
|
538
538
|
// Its own line rather than another clause: this one is about the account, and
|
|
@@ -562,9 +562,9 @@ export function formatUploadAlert(report: UploadReport): string | undefined {
|
|
|
562
562
|
if (report.throttled) parts.push("rate limited, the rest upload on the next run");
|
|
563
563
|
if (report.unauthorized) parts.push(report.unauthorized);
|
|
564
564
|
if (report.abandoned > 0) parts.push(`${report.abandoned} session(s) given up on`);
|
|
565
|
-
if (report.gitHook === "installed") parts.push(
|
|
565
|
+
if (report.gitHook === "installed") parts.push(`commit and push hooks added to ${report.gitHookRepository}`);
|
|
566
566
|
if (report.gitHook === "shared-hooks") {
|
|
567
|
-
parts.push(
|
|
567
|
+
parts.push(`no git hooks in ${report.gitHookRepository}: they live in a shared directory, run isy init there to add them`);
|
|
568
568
|
}
|
|
569
569
|
if (report.planNotice) parts.push(report.planNotice);
|
|
570
570
|
if (report.updateNotice) parts.push(report.updateNotice);
|