@vibelord/lanes 1.7.7 → 1.8.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 +13 -9
- package/package.json +1 -1
- package/payload/lanes/VERSION +1 -1
- package/payload/lanes/bin/lanes +26 -4
- package/payload/lanes/bin/lanes-site-serve +4 -8
- package/payload/lanes/bin-rs/BINARIES.json +17 -2
- package/payload/lanes/bin-rs/THIRD-PARTY-NOTICES +18953 -0
- package/payload/lanes/bin-rs/x86_64-unknown-linux-musl/lanes-hook +0 -0
- package/payload/lanes/bin-rs/x86_64-unknown-linux-musl/lanes-terminal +0 -0
- package/payload/lanes/client/lanes-launch +4 -2
- package/payload/lanes/container/lane-mcp +1 -1
- package/payload/lanes/container/lane_core.py +4 -3
- package/payload/lanes/docs/ARCHITECTURE.md +26 -4
- package/payload/lanes/docs/RUNBOOK.md +121 -52
- package/payload/lanes/docs/USERGUIDE.md +28 -0
- package/payload/lanes/install/lanes-host.service.in +25 -0
- package/payload/lanes/install/services.py +243 -0
- package/payload/lanes/libexec/agent_state.py +3 -1
- package/payload/lanes/libexec/attach.py +139 -21
- package/payload/lanes/libexec/cutover.py +24 -4
- package/payload/lanes/libexec/doctor_lanes2.py +3 -3
- package/payload/lanes/libexec/native.sh +2 -2
- package/payload/lanes/libexec/native_bin.py +595 -109
- package/payload/lanes/libexec/shadow.py +51 -3
- package/payload/lanes/libexec/sidebar_status.py +190 -80
- package/payload/lanes/libexec/update.py +12 -3
- package/payload/lanes/site/protocol.py +24 -9
- package/payload/lanes/site/relay.py +292 -0
- package/payload/lanes/site/server.py +31 -3
- package/payload/lanes/web/README.md +6 -6
- package/payload/lanes/web/directory.js +10 -8
- package/payload/lanes/web/generated/README.md +85 -21
- package/payload/lanes/web/generated/lanes2_protocol.d.mts +4190 -188
- package/payload/lanes/web/generated/lanes2_protocol.mjs +14218 -351
- package/payload/lanes/web/inbox.js +8 -6
- package/payload/manifest.json +22 -5
|
@@ -248,6 +248,8 @@
|
|
|
248
248
|
return t;
|
|
249
249
|
}
|
|
250
250
|
|
|
251
|
+
// records.rs read_text
|
|
252
|
+
const readText = ms => (ms < 2534e11 ? `${new Date(ms).toISOString().slice(0, 19)}Z` : `${ms} ms after the epoch`);
|
|
251
253
|
const ageText = s => (s >= 3600 ? `${Math.floor(s / 3600)}h ${Math.floor((s % 3600) / 60)}m` : s >= 60 ? `${Math.floor(s / 60)}m ${s % 60}s` : `${s}s`);
|
|
252
254
|
const stateText = job => (job.label.toLowerCase() === job.state.toLowerCase() ? job.label : `${job.label} (${job.state})`);
|
|
253
255
|
function consequenceOf(job) {
|
|
@@ -260,7 +262,7 @@
|
|
|
260
262
|
const code = job.receipt && job.receipt.exit_code, artifact = job.receipt && job.receipt.artifact_sha256;
|
|
261
263
|
const lines = [`${job.label} (buildctl: ${job.state}) · stage ${job.stage}`,
|
|
262
264
|
`Lane ${job.lane} · profile ${job.profile} · worker ${job.worker ?? '-'}`,
|
|
263
|
-
`Source snapshot ${job.snapshot} · revision ${job.source_revision ?? '-'}`, `Submitted ${ageText(job.
|
|
265
|
+
`Source snapshot ${job.snapshot} · revision ${job.source_revision ?? '-'}`, `Submitted ${ageText(Math.floor(job.age_ms / 1000))} ago`];
|
|
264
266
|
if (job.wait) lines.push(`Waiting: ${job.wait.reason}`, `Provenance: ${job.wait.provenance}`);
|
|
265
267
|
lines.push(...job.priority_detail, `Log: ${job.log.length} verified bytes (${job.log.identity})`);
|
|
266
268
|
if (code != null || artifact != null) lines.push(`Receipt: exit ${code ?? '-'} · artifact ${artifact ?? '-'}`);
|
|
@@ -276,7 +278,7 @@
|
|
|
276
278
|
obj(job, what);
|
|
277
279
|
for (const key of ['id', 'title', 'state', 'label', 'stage', 'lane', 'profile', 'snapshot', 'priority']) str(job[key], `${what}.${key}`);
|
|
278
280
|
for (const key of ['worker', 'source_revision']) optStr(job[key], `${what}.${key}`);
|
|
279
|
-
want(isInt(job.
|
|
281
|
+
want(isInt(job.age_ms), `${what}.age_ms is not a nonnegative integer`);
|
|
280
282
|
want(isId(job.id), `job id ${JSON.stringify(job.id)} is not a record id`);
|
|
281
283
|
if (job.wait !== null) { obj(job.wait, `${what}.wait`); str(job.wait.reason, `${what}.wait.reason`); str(job.wait.provenance, `${what}.wait.provenance`); }
|
|
282
284
|
strings(job.priority_detail, `${what}.priority_detail`);
|
|
@@ -305,7 +307,7 @@
|
|
|
305
307
|
optStr(doc.completeness.label, 'builds.completeness.label');
|
|
306
308
|
want(has(doc, 'unavailable') && (doc.unavailable === null || (typeof doc.unavailable.code === 'string' && typeof doc.unavailable.reason === 'string')), 'builds.unavailable is malformed');
|
|
307
309
|
if (!doc.completeness.complete && doc.completeness.label === null && !doc.unavailable) bad('an incomplete queue carries no label');
|
|
308
|
-
|
|
310
|
+
want(isInt(doc.observed_at_unix_ms), 'builds.observed_at_unix_ms is not an integer');
|
|
309
311
|
for (const key of ['jobs', 'recent', 'lane_waits']) want(Array.isArray(doc[key]), `builds.${key} is not a list`);
|
|
310
312
|
doc.jobs.forEach((job, i) => decodeJob(job, `builds.jobs[${i}]`));
|
|
311
313
|
doc.recent.forEach((job, i) => decodeJob(job, `builds.recent[${i}]`));
|
|
@@ -316,14 +318,14 @@
|
|
|
316
318
|
// records.rs lane_wait_lines and lane_wait_detail
|
|
317
319
|
const laneWait = wait => ({line: `${wait.lane}: ${wait.reason}`, detail: [`Lane ${wait.lane} waits on build ${wait.job} (${wait.state})`,
|
|
318
320
|
wait.reason, `Provenance: ${wait.provenance}`, `Attempt: ${wait.attempt_ref}`]});
|
|
319
|
-
const record = (job, kind) => ({id: job.id, kind, title: job.title, state: stateText(job), when: `${ageText(job.
|
|
321
|
+
const record = (job, kind) => ({id: job.id, kind, title: job.title, state: stateText(job), when: `${ageText(Math.floor(job.age_ms / 1000))} ago`,
|
|
320
322
|
consequence: consequenceOf(job), lines: detailLines(job)});
|
|
321
323
|
const buildRecords = panel => [...panel.jobs.map(job => record(job, 'build')), ...panel.recent.map(job => record(job, 'result'))];
|
|
322
324
|
function buildsHeader(panel) {
|
|
323
325
|
const lines = [];
|
|
324
326
|
if (!panel.completeness.complete && panel.completeness.label) lines.push(panel.completeness.label);
|
|
325
327
|
if (panel.unavailable) lines.push(`Builds unavailable (${panel.unavailable.code}): ${panel.unavailable.reason}`);
|
|
326
|
-
lines.push(`Source: ${panel.source.adapter} · protocol ${panel.source.protocol ?? 'unknown'} · read ${panel.
|
|
328
|
+
lines.push(`Source: ${panel.source.adapter} · protocol ${panel.source.protocol ?? 'unknown'} · read ${readText(panel.observed_at_unix_ms)}`);
|
|
327
329
|
return lines;
|
|
328
330
|
}
|
|
329
331
|
|
|
@@ -491,7 +493,7 @@
|
|
|
491
493
|
return arrived();
|
|
492
494
|
}
|
|
493
495
|
// an older panel never replaces a newer one (records.rs applies a panel at its revision)
|
|
494
|
-
if (st.builds.doc &&
|
|
496
|
+
if (st.builds.doc && doc.observed_at_unix_ms < st.builds.doc.observed_at_unix_ms) return api;
|
|
495
497
|
st.builds = {state: 'ready', doc, records, reason: '', stale: false};
|
|
496
498
|
follow('results', records.map(r => r.id));
|
|
497
499
|
return arrived();
|
package/payload/manifest.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vibelord/lanes",
|
|
3
|
-
"version": "1.
|
|
4
|
-
"commit": "
|
|
5
|
-
"digest": "sha256:
|
|
3
|
+
"version": "1.8.0",
|
|
4
|
+
"commit": "e5bc8704b389d515dd283e0e393cb37694c19a5d",
|
|
5
|
+
"digest": "sha256:37ddfe65b76bfca946e4cbf7c2b9353e164031f32d5c9e32fe661b39946e3c07",
|
|
6
6
|
"executables": [
|
|
7
7
|
"bin/lanes",
|
|
8
8
|
"bin/lanes-site-serve",
|
|
@@ -36,7 +36,9 @@
|
|
|
36
36
|
"libexec/tokens.py",
|
|
37
37
|
"libexec/view.sh",
|
|
38
38
|
"sudo/host-guard.sh",
|
|
39
|
-
"sudo/one-time-root.sh"
|
|
39
|
+
"sudo/one-time-root.sh",
|
|
40
|
+
"bin-rs/x86_64-unknown-linux-musl/lanes-hook",
|
|
41
|
+
"bin-rs/x86_64-unknown-linux-musl/lanes-terminal"
|
|
40
42
|
],
|
|
41
43
|
"sites": [
|
|
42
44
|
"beyondwork"
|
|
@@ -44,5 +46,20 @@
|
|
|
44
46
|
"site_codes": {
|
|
45
47
|
"LN": "beyondwork"
|
|
46
48
|
},
|
|
47
|
-
"binaries": [
|
|
49
|
+
"binaries": [
|
|
50
|
+
{
|
|
51
|
+
"name": "lanes-hook",
|
|
52
|
+
"target": "x86_64-unknown-linux-musl",
|
|
53
|
+
"sha256": "6259018bf2495e0add3298ac96f9ffb5da69dab9d9878a3b43e217f96d2a7823",
|
|
54
|
+
"size": 1250024,
|
|
55
|
+
"commit": "e5bc8704b389d515dd283e0e393cb37694c19a5d"
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
"name": "lanes-terminal",
|
|
59
|
+
"target": "x86_64-unknown-linux-musl",
|
|
60
|
+
"sha256": "4f7a3ba8514658531a0cf6dd7fe19fb3972372e7d743518a38a9fa693093d159",
|
|
61
|
+
"size": 17161512,
|
|
62
|
+
"commit": "e5bc8704b389d515dd283e0e393cb37694c19a5d"
|
|
63
|
+
}
|
|
64
|
+
]
|
|
48
65
|
}
|