@floless/app 0.170.0 → 0.171.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/floless-server.cjs +33000 -22928
- package/dist/schemas/steel.model.v2.schema.json +194 -3
- package/dist/skills/floless-app-bridge/SKILL.md +3 -3
- package/dist/skills/floless-app-knowledge/SKILL.md +4 -3
- package/dist/skills/floless-app-onboarding/SKILL.md +5 -4
- package/dist/skills/floless-app-onboarding/references/floless-surfaces.md +0 -3
- package/dist/skills/floless-app-queue/SKILL.md +2 -3
- package/dist/skills/floless-app-report-issue/SKILL.md +2 -2
- package/dist/skills/floless-app-steel-model/SKILL.md +35 -35
- package/dist/skills/floless-app-steel-model/references/custom-connections.md +47 -0
- package/dist/skills/floless-app-steel-model/references/custom-sections.md +32 -0
- package/dist/skills/floless-app-ui/SKILL.md +71 -126
- package/dist/web/add-ons.js +407 -0
- package/dist/web/analytics.js +1 -1
- package/dist/web/app.css +108 -189
- package/dist/web/app.js +11 -12
- package/dist/web/aware.js +49 -29
- package/dist/web/chat.css +6 -1
- package/dist/web/chat.js +133 -18
- package/dist/web/commands-filter.js +23 -0
- package/dist/web/commands-shell.js +39 -67
- package/dist/web/commands-steel.js +9 -1
- package/dist/web/commands-tekla-parser.js +23 -0
- package/dist/web/connections.js +14 -3
- package/dist/web/failure-copy.js +1 -0
- package/dist/web/guide.js +3 -3
- package/dist/web/index.html +29 -56
- package/dist/web/instructor.js +2 -2
- package/dist/web/kb-categories.js +64 -7
- package/dist/web/model-change-findings.js +430 -0
- package/dist/web/model-change-review.js +414 -0
- package/dist/web/model-editor-steel-adapter.js +2 -2
- package/dist/web/project-history.js +7 -1
- package/dist/web/revit-editor.css +85 -0
- package/dist/web/revit-editor.js +36 -1
- package/dist/web/sha256-sync.js +62 -0
- package/dist/web/steel-3d-core.js +7 -0
- package/dist/web/steel-3d-flo.js +127 -3
- package/dist/web/steel-3d-view.js +25 -2
- package/dist/web/steel-custom-connection.js +161 -0
- package/dist/web/steel-custom-sections.js +1796 -0
- package/dist/web/steel-editor.html +279 -41
- package/dist/web/steel-filter-usage.js +299 -0
- package/dist/web/steel-filter.html +101 -4
- package/dist/web/steel-model-v2-client-validation.js +3 -0
- package/dist/web/steel-model-v2-commands.js +95 -6
- package/dist/web/steel-model-v2-projection.js +1 -1
- package/dist/web/steel-read-confidence.js +1 -56
- package/dist/web/tekla-editor.html +1 -0
- package/dist/web/workspaces.js +263 -28
- package/launch.mjs +87 -9
- package/package.json +1 -1
- package/dist/web/panels.js +0 -831
package/launch.mjs
CHANGED
|
@@ -402,7 +402,12 @@ export async function startAndOpen({
|
|
|
402
402
|
export async function cmdOpen({ marker = consumePostUpdateMarker, healthy = ping, ensure = ensureServerUp,
|
|
403
403
|
startOpen = (deps) => startAndOpen(deps), say = log, open = openBrowser, client = undefined, shell = null,
|
|
404
404
|
restore = restoreWindows, updating = updateInProgress, peekMarker = peekPostUpdateMarker,
|
|
405
|
-
shellInstalled = () => shellInfo().installed, preferred = resolveClientForOpen
|
|
405
|
+
shellInstalled = () => shellInfo().installed, preferred = resolveClientForOpen,
|
|
406
|
+
// #3379: the post-update relaunch's own pieces. `claimWindows` takes the windows the update closed; `windowFor` is the
|
|
407
|
+
// FloLess window that shows them; `supervisor` brings back the watchdog the update stopped; `slowWait` is the headless
|
|
408
|
+
// wait for a tab-only person.
|
|
409
|
+
claimWindows = claimRestore, windowFor = (windows) => windowClient({ say, windows }), supervisor = ensureSupervisor,
|
|
410
|
+
slowWait = postUpdateWait } = {}) {
|
|
406
411
|
// The window (desktop shell) is a second client beside the browser tab, never a replacement for it: when it is not
|
|
407
412
|
// installed, or shows nothing, the tab opens instead and the log says why. `client` is 'window' for
|
|
408
413
|
// `FlolessApp.exe window` / floless://window (whatever is stored); a plain `open` follows the person's stored choice
|
|
@@ -447,14 +452,54 @@ export async function cmdOpen({ marker = consumePostUpdateMarker, healthy = ping
|
|
|
447
452
|
}
|
|
448
453
|
}
|
|
449
454
|
if (postUpdate) {
|
|
450
|
-
|
|
451
|
-
//
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
455
|
+
// How the start ended (startAndOpen's answer, or 'ready'/'not-ready' for the headless wait): it decides below whether
|
|
456
|
+
// the supervisor may come back while the server is not answering.
|
|
457
|
+
let outcome = serving ? 'ready' : null;
|
|
458
|
+
let renew = null;
|
|
459
|
+
try {
|
|
460
|
+
if (serving) {
|
|
461
|
+
endUpdate();
|
|
462
|
+
// The update closed the FloLess window first (so its leave guard could run); reopen what was open. Tab-only
|
|
463
|
+
// people have no list, so nothing changes for them: their tab reloads itself onto the new build.
|
|
464
|
+
if (await restore({ say })) { say('post-update relaunch — server up; reopened the FloLess window'); return; }
|
|
465
|
+
say('post-update relaunch — server up; the existing tab reconnects via its health poll (no new tab)');
|
|
466
|
+
return;
|
|
467
|
+
}
|
|
468
|
+
// #3379: the new build's server is still starting. The update hold stays on until that start is over: there is no
|
|
469
|
+
// server-side single-instance lock, so a launch admitted now (a click on the FloLess icon during a slow first start)
|
|
470
|
+
// would see nothing listening yet and start a second server on the same home. Held launches join the restore list
|
|
471
|
+
// and are opened below once the server answers. The hold is renewed while the start lasts (its 10-minute expiry is
|
|
472
|
+
// shorter than the 15-minute wait), so a crashed launcher still lets it lapse within 10 minutes.
|
|
473
|
+
try {
|
|
474
|
+
beginUpdate();
|
|
475
|
+
renew = setInterval(() => { try { beginUpdate(); } catch { /* the next renewal tries again; the expiry is the backstop */ } }, UPDATE_HOLD_RENEW_MS);
|
|
476
|
+
renew.unref?.();
|
|
477
|
+
} catch (error) {
|
|
478
|
+
say(`could not keep the update hold while the server starts (${error?.code ?? error?.message ?? error}); a FloLess launch meanwhile is not held`);
|
|
479
|
+
}
|
|
480
|
+
// The window the update closed comes back NOW, on its starting screen, and turns into the app once the server
|
|
481
|
+
// answers, however long that takes: a slow first start must never look as if FloLess vanished. This is the ordinary
|
|
482
|
+
// slow-start path, so it also falls back to the browser's starting page when no window can be shown, and says
|
|
483
|
+
// plainly if the server stops.
|
|
484
|
+
const windows = claimWindows();
|
|
485
|
+
if (windows.length) {
|
|
486
|
+
say('post-update relaunch — reopening the FloLess window on its starting screen while the server starts');
|
|
487
|
+
outcome = await startOpen(shellInstalled() ? { shell: windowFor(windows) } : {});
|
|
488
|
+
return;
|
|
489
|
+
}
|
|
490
|
+
// Tab-only (or nothing was open): the existing tab shows that FloLess is starting and reconnects by its own health
|
|
491
|
+
// poll. Start the server headless and wait as long as a slow start may take, so the supervisor below comes back too.
|
|
492
|
+
// The wait's own answer is kept: a server that stopped gets its supervisor back below, one still starting does not.
|
|
493
|
+
let waited = null;
|
|
494
|
+
outcome = (await ensure({ wait: async (attempt) => (waited = await slowWait(attempt)) })) ? 'ready' : (waited ?? 'not-ready');
|
|
495
|
+
if (outcome !== 'ready') { process.exitCode = 1; return; }
|
|
496
|
+
say('post-update relaunch — server up; the existing tab reconnects via its health poll (no new tab)');
|
|
497
|
+
return;
|
|
498
|
+
} finally {
|
|
499
|
+
if (renew) clearInterval(renew);
|
|
500
|
+
if (!serving) endUpdate(); // the start is over, answered or not: the next launch goes through normally
|
|
501
|
+
await finishPostUpdate({ startedHere: !serving, outcome, healthy, supervisor, restore, say });
|
|
502
|
+
}
|
|
458
503
|
}
|
|
459
504
|
if (!serving) { await startOpen(win ? { shell: win } : {}); return; }
|
|
460
505
|
if (win && (await win.show('ready')) === 'shown') { log('opened the FloLess window'); return; }
|
|
@@ -493,6 +538,39 @@ export function windowClient({ say = log, launch = launchShell, windows = ['/']
|
|
|
493
538
|
};
|
|
494
539
|
}
|
|
495
540
|
|
|
541
|
+
/** The post-update headless wait (#3379): as long as a slow first start may take, never the bounded 36 s of a plain start. */
|
|
542
|
+
export function postUpdateWait(attempt, options = {}) { return waitForServerAttempt(attempt, { ...options, timeoutMs: GIVE_UP_MS }); }
|
|
543
|
+
|
|
544
|
+
/** How often the post-update relaunch renews the update hold while the new server starts (#3379). */
|
|
545
|
+
export const UPDATE_HOLD_RENEW_MS = 60_000;
|
|
546
|
+
|
|
547
|
+
/**
|
|
548
|
+
* The end of a post-update relaunch (#3379). The update stopped the supervisor so it could not re-lock the install folder;
|
|
549
|
+
* bring it back, or nothing keeps the server alive (or reopens a stranded window) until the next sign-in. It comes back
|
|
550
|
+
* once the server answers, or when the server stopped (nothing is starting, so it cannot start a second one, and it is
|
|
551
|
+
* what restarts the server). While the server may still be starting it stays off, and the log says so: it would see
|
|
552
|
+
* nothing listening and start a second server. Launches held during the start are opened once the server answers.
|
|
553
|
+
* Each step runs on its own, so one failing never skips the other.
|
|
554
|
+
*/
|
|
555
|
+
export async function finishPostUpdate({ startedHere, outcome, healthy, supervisor, restore, say }) {
|
|
556
|
+
let up = false;
|
|
557
|
+
try { up = await healthy(); } catch { up = false; }
|
|
558
|
+
if (up || outcome === 'stopped') {
|
|
559
|
+
try { supervisor({ say }); } catch (error) { say(`could not start the FloLess supervisor (${error?.message ?? error})`); }
|
|
560
|
+
} else {
|
|
561
|
+
say('post-update relaunch — the server is not answering yet, so the supervisor was not restarted; it comes back with '
|
|
562
|
+
+ 'the next FloLess launch or sign-in');
|
|
563
|
+
}
|
|
564
|
+
if (!startedHere) return;
|
|
565
|
+
if (!up) {
|
|
566
|
+
say('post-update relaunch — anything asked for while FloLess was starting stays in the restore list for the supervisor');
|
|
567
|
+
return;
|
|
568
|
+
}
|
|
569
|
+
try {
|
|
570
|
+
if (await restore({ say })) say('post-update relaunch — opened what was asked for while FloLess was starting');
|
|
571
|
+
} catch (error) { say(`could not open what was asked for while FloLess was starting (${error?.message ?? error})`); }
|
|
572
|
+
}
|
|
573
|
+
|
|
496
574
|
/** `FlolessApp.exe window` / floless://window: open the FloLess window whatever the stored preference says. */
|
|
497
575
|
export async function cmdWindow(deps = {}) { return cmdOpen({ ...deps, client: 'window' }); }
|
|
498
576
|
|