@mindexec/cli 0.2.203 → 0.2.205

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mindexec/cli",
3
- "version": "0.2.203",
3
+ "version": "0.2.205",
4
4
  "description": "MindExec local runtime and bridge CLI",
5
5
  "main": "server.js",
6
6
  "type": "module",
package/server.js CHANGED
@@ -3771,6 +3771,24 @@ function isRemoteAgentOutputReconnectSignal(text) {
3771
3771
  }
3772
3772
 
3773
3773
  function rememberRemoteAgentSyncReport(report) {
3774
+ if (report?.authenticated !== true
3775
+ && isRemoteAgentRegistryOwned()
3776
+ && isRemoteAgentProcessRunning()
3777
+ && /^(registry-auth-pending-agent-kept|registry-not-authenticated-agent-kept|session-expired-agent-kept)$/i.test(String(report.reason || ''))) {
3778
+ const now = Date.now();
3779
+ const key = `ignored-unauth|${report.reason || ''}|${remoteAgentState.manager || ''}|${remoteAgentState.leaseId || ''}`;
3780
+ if (key !== remoteAgentSyncReportLogKey
3781
+ || now - remoteAgentSyncReportLogAt >= REMOTE_AGENT_SYNC_REPORT_LOG_REPEAT_MS) {
3782
+ remoteAgentSyncReportLogKey = key;
3783
+ remoteAgentSyncReportLogAt = now;
3784
+ logEvent(
3785
+ 'remote',
3786
+ `registry sync ignored stale unauth report ${formatKeyValue('reason', report.reason || '-')} ${formatKeyValue('target', remoteAgentState.manager || '-')} ${formatKeyValue('auth', 'kept')}`,
3787
+ 'remote');
3788
+ }
3789
+ return false;
3790
+ }
3791
+
3774
3792
  remoteAgentSyncReportState = report;
3775
3793
  const reason = report.reason || report.error || (report.ok ? 'ok' : 'failed');
3776
3794
  const status = report.connected
@@ -3807,6 +3825,7 @@ function rememberRemoteAgentSyncReport(report) {
3807
3825
  'remote',
3808
3826
  `registry sync ${status} ${formatKeyValue('reason', reason)} ${formatKeyValue('target', report.targetEndpoint || '-')} ${formatKeyValue('auth', report.authenticated ? 'yes' : 'no')}`,
3809
3827
  'remote');
3828
+ return true;
3810
3829
  }
3811
3830
 
3812
3831
  function appendRemoteAgentOutput(stream, chunk, stateConnectionKey = '') {
@@ -5841,6 +5860,28 @@ async function readFreshSupabaseSessionForRegistry(config, reason = 'registry')
5841
5860
  }
5842
5861
  }
5843
5862
 
5863
+ async function refreshSupabaseSessionAfterRegistryAuthFailure(config, trigger = 'registry-auth-failure') {
5864
+ if (!config?.url || !config?.key) {
5865
+ return {
5866
+ ok: false,
5867
+ reason: 'supabase-config-missing'
5868
+ };
5869
+ }
5870
+
5871
+ const sessionPayload = await readStableAuthSessionPayload();
5872
+ if (!sessionPayload.found) {
5873
+ return {
5874
+ ok: false,
5875
+ reason: 'registry-not-authenticated'
5876
+ };
5877
+ }
5878
+
5879
+ return await refreshSupabaseSessionForRegistry(
5880
+ config,
5881
+ sessionPayload,
5882
+ `registry-auth-failure-${safeRemoteAgentField(trigger || 'timer', 80)}`);
5883
+ }
5884
+
5844
5885
  function readRegistryTargetField(target, ...keys) {
5845
5886
  for (const key of keys) {
5846
5887
  const value = target?.[key];
@@ -6595,8 +6636,9 @@ async function runRemoteRegistryFollowerOnce(trigger = 'timer') {
6595
6636
 
6596
6637
  remoteRegistryFollowerInFlight = true;
6597
6638
  const attemptedAt = new Date().toISOString();
6639
+ let config = null;
6598
6640
  try {
6599
- const config = readSupabaseRuntimeConfig();
6641
+ config = readSupabaseRuntimeConfig();
6600
6642
  if (!config.url || !config.key) {
6601
6643
  closeRemoteRegistryRealtime('supabase-config-missing');
6602
6644
  updateRemoteRegistryFollowerState({
@@ -6968,6 +7010,45 @@ async function runRemoteRegistryFollowerOnce(trigger = 'timer') {
6968
7010
  return serializeRemoteRegistryFollowerState();
6969
7011
  } catch (error) {
6970
7012
  const transientAuth = error?.statusCode === 401 || error?.statusCode === 403;
7013
+ if (transientAuth) {
7014
+ const agentKept = isRemoteAgentRegistryOwned() && isRemoteAgentProcessRunning();
7015
+ const keptManager = agentKept ? safeRemoteAgentField(remoteAgentState.manager, 160) : '';
7016
+ const keptCandidates = agentKept ? normalizeRemoteManagerEndpointList(remoteAgentState.managerCandidates, remoteAgentState.manager) : [];
7017
+ const refreshed = await refreshSupabaseSessionAfterRegistryAuthFailure(config, trigger).catch(refreshError => ({
7018
+ ok: false,
7019
+ reason: refreshError?.message || String(refreshError || 'auth-refresh-failed')
7020
+ }));
7021
+
7022
+ if (refreshed?.ok === true && refreshed.session) {
7023
+ updateRemoteRegistryFollowerState({
7024
+ status: 'auth-refreshed',
7025
+ reason: agentKept ? 'registry-auth-refreshed-agent-kept' : 'registry-auth-refreshed',
7026
+ authenticated: true,
7027
+ lastAttemptAt: attemptedAt,
7028
+ lastError: '',
7029
+ targetEndpoint: keptManager,
7030
+ targetEndpointCandidates: keptCandidates,
7031
+ targetLeaseId: agentKept ? safeRemoteAgentField(remoteAgentState.leaseId, 128) : '',
7032
+ targetNodeId: agentKept ? safeRemoteAgentField(remoteAgentState.nodeId, 128) : '',
7033
+ agentKept
7034
+ });
7035
+ await reportRemoteRegistryFollowerSync({
7036
+ ok: true,
7037
+ skipped: true,
7038
+ reason: agentKept ? 'registry-auth-refreshed-agent-kept' : 'registry-auth-refreshed',
7039
+ trigger,
7040
+ authenticated: true,
7041
+ targetEndpoint: keptManager,
7042
+ targetEndpointCandidates: keptCandidates,
7043
+ targetLeaseId: agentKept ? remoteAgentState.leaseId : '',
7044
+ targetNodeId: agentKept ? remoteAgentState.nodeId : '',
7045
+ agentKept
7046
+ });
7047
+ scheduleRemoteRegistryFollower(0, 'auth-refreshed');
7048
+ return serializeRemoteRegistryFollowerState();
7049
+ }
7050
+ }
7051
+
6971
7052
  updateRemoteRegistryFollowerState({
6972
7053
  status: transientAuth ? 'auth-pending' : 'error',
6973
7054
  reason: transientAuth ? 'registry-auth-pending' : 'registry-sync-failed',
@@ -2432,6 +2432,7 @@ body.is-panning .mind-map-text-overlay-v2-card.is-passive .mind-map-text-overlay
2432
2432
  }
2433
2433
 
2434
2434
  .css3d-resolution-wrapper.node-type-templatelauncher > .map-node-template-card {
2435
+ border: 1px solid #111827 !important;
2435
2436
  border-radius: 8px !important;
2436
2437
  background: #f8fafc;
2437
2438
  box-shadow: none !important;
@@ -2462,8 +2463,11 @@ body.mindcanvas-is-dense .css3d-resolution-wrapper.node-type-templatelauncher.se
2462
2463
  }
2463
2464
 
2464
2465
  .map-node-template-card {
2466
+ border: 1px solid #111827 !important;
2467
+ border-radius: 8px;
2465
2468
  color: #10212f;
2466
2469
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
2470
+ box-shadow: none !important;
2467
2471
  }
2468
2472
 
2469
2473
  .template-card__shell {
@@ -2473,7 +2477,7 @@ body.mindcanvas-is-dense .css3d-resolution-wrapper.node-type-templatelauncher.se
2473
2477
  height: 100%;
2474
2478
  gap: 12px;
2475
2479
  padding: 18px;
2476
- border: 1px solid rgba(15, 23, 42, 0.08);
2480
+ border: 0;
2477
2481
  border-radius: 8px;
2478
2482
  background: #f8fafc;
2479
2483
  overflow: hidden;
@@ -356,6 +356,14 @@
356
356
  border: 1px solid #111827;
357
357
  box-shadow: none;
358
358
  }
359
+ .map-node-template-card {
360
+ border: 1px solid #111827 !important;
361
+ border-radius: 8px;
362
+ box-shadow: none !important;
363
+ }
364
+ .map-node-template-card > .template-card__shell {
365
+ border: 0 !important;
366
+ }
359
367
  .csv-table-scroll {
360
368
  width: 100%;
361
369
  height: 100%;
@@ -7,8 +7,8 @@
7
7
  <title>MindExec | Business Execution OS for solo builders</title>
8
8
  <meta name="description" content="MindExec is an AI business execution OS for solo builders who want to turn notes, research, assets, and repeatable execution Skills into revenue-producing work." />
9
9
  <base href="/" />
10
- <link rel="stylesheet" href="_content/MindExecution.Shared/css/app.css?v=20260618-note-resize-v620-x1" />
11
- <link rel="stylesheet" href="_content/MindExecution.Shared/css/mind-map-overrides.css?v=20260618-note-resize-v620-x1" />
10
+ <link rel="stylesheet" href="_content/MindExecution.Shared/css/app.css?v=20260618-template-mdm-border-v621-x1" />
11
+ <link rel="stylesheet" href="_content/MindExecution.Shared/css/mind-map-overrides.css?v=20260618-template-mdm-border-v621-x1" />
12
12
  <!-- ?占썩뼹??Font Awesome (local) ?占썩뼹??-->
13
13
  <link rel="stylesheet" href="_content/MindExecution.Shared/lib/font-awesome/css/all.min.css" />
14
14
  <!-- ?占썩뼯??-->
@@ -579,7 +579,7 @@
579
579
  }
580
580
 
581
581
  const base = '_content/MindExecution.Shared/js/';
582
- const scriptVersion = '20260618-note-resize-v620-x1';
582
+ const scriptVersion = '20260618-template-mdm-border-v621-x1';
583
583
  const scriptUrl = (script) => `${base}${script}?v=${scriptVersion}`;
584
584
  console.log(`[Script Loader] Shared JS version: ${scriptVersion}`);
585
585
  const criticalScripts = [
@@ -1,5 +1,5 @@
1
1
  self.assetsManifest = {
2
- "version": "Sf3cEris",
2
+ "version": "tmpHHqhh",
3
3
  "assets": [
4
4
  {
5
5
  "hash": "sha256-+CSYMcqLNTsq3VnH11jgYyOCCdxvHzL74CBmo4sCmMU=",
@@ -42,7 +42,7 @@
42
42
  "url": "_content/MindExecution.Shared/css/app.css"
43
43
  },
44
44
  {
45
- "hash": "sha256-Xe8BkdKZDxJcD4yLzOA0iY/fQMYRbvoLfpyvOVs3wIk=",
45
+ "hash": "sha256-f+donrGuscLwnPmugZP05Oyjwt3PvPbURHzhJVE5rWw=",
46
46
  "url": "_content/MindExecution.Shared/css/mind-map-overrides.css"
47
47
  },
48
48
  {
@@ -86,7 +86,7 @@
86
86
  "url": "_content/MindExecution.Shared/js/mind-map-core.js.backup"
87
87
  },
88
88
  {
89
- "hash": "sha256-dxx8NBoFxZXUW3mJ9kE/e6SN4fvl/FoBv5ddeIZ9Rq8=",
89
+ "hash": "sha256-HoINjuHDnlimFfhJ8p1PbllP8a3TaGJxSbR3wT6cOdY=",
90
90
  "url": "_content/MindExecution.Shared/js/mind-map-css3d-manager.js"
91
91
  },
92
92
  {
@@ -834,7 +834,7 @@
834
834
  "url": "image-manifest.json"
835
835
  },
836
836
  {
837
- "hash": "sha256-3Q46gT6qucO1baXOYF+XHeP3NfAzScYrt/qSeQ6F13Y=",
837
+ "hash": "sha256-8SSekv6Rhkb9Q1BEOF3bXHw9yWmR7DN5XdW5wWZZHlA=",
838
838
  "url": "index.html"
839
839
  },
840
840
  {
@@ -1,4 +1,4 @@
1
- /* Manifest version: Sf3cEris */
1
+ /* Manifest version: tmpHHqhh */
2
2
  // Hosted deployments should prefer the network over stale offline caches.
3
3
  // This service worker immediately clears old Blazor offline caches and unregisters itself.
4
4