@yemi33/minions 0.1.731 → 0.1.733

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 CHANGED
@@ -1,8 +1,14 @@
1
1
  # Changelog
2
2
 
3
- ## 0.1.731 (2026-04-09)
3
+ ## 0.1.733 (2026-04-09)
4
4
 
5
5
  ### Fixes
6
+ - merge localStorage pins to server on migration, always sync cache
7
+
8
+ ## 0.1.732 (2026-04-09)
9
+
10
+ ### Fixes
11
+ - notify user when settings values are clamped to allowed range
6
12
  - raise maxConcurrent cap from 10 to 50
7
13
 
8
14
  ## 0.1.730 (2026-04-09)
@@ -254,10 +254,16 @@ async function saveSettings() {
254
254
  });
255
255
  if (!rRes.ok) { const d = await rRes.json(); throw new Error(d.error); }
256
256
 
257
- status.textContent = 'Saved. Engine picks up changes on next tick.';
258
- status.style.color = 'var(--green)';
257
+ if (result.clamped && result.clamped.length > 0) {
258
+ status.textContent = 'Saved — some values adjusted: ' + result.clamped.join(', ');
259
+ status.style.color = 'var(--yellow)';
260
+ showToast('cmd-toast', 'Settings saved (some values clamped to allowed range)', false);
261
+ } else {
262
+ status.textContent = 'Saved. Engine picks up changes on next tick.';
263
+ status.style.color = 'var(--green)';
264
+ showToast('cmd-toast', 'Settings saved', true);
265
+ }
259
266
  if (saveBtn) { saveBtn.innerHTML = '<svg width="12" height="12" viewBox="0 0 16 16" fill="currentColor"><path d="M13.78 4.22a.75.75 0 010 1.06l-7.25 7.25a.75.75 0 01-1.06 0L2.22 9.28a.75.75 0 011.06-1.06L6 10.94l6.72-6.72a.75.75 0 011.06 0z"/></svg> Saved'; saveBtn.style.color = 'var(--green)'; saveBtn.style.borderColor = 'var(--green)'; }
260
- showToast('cmd-toast', 'Settings saved', true);
261
267
  setTimeout(function() {
262
268
  if (saveBtn) { saveBtn.disabled = false; saveBtn.style.opacity = ''; saveBtn.innerHTML = '<svg width="12" height="12" viewBox="0 0 16 16" fill="currentColor"><path d="M13.78 4.22a.75.75 0 010 1.06l-7.25 7.25a.75.75 0 01-1.06 0L2.22 9.28a.75.75 0 011.06-1.06L6 10.94l6.72-6.72a.75.75 0 011.06 0z"/></svg> Save'; }
263
269
  }, 2000);
@@ -29,11 +29,23 @@ function togglePin(key) {
29
29
  }
30
30
  function _syncPinsFromServer() {
31
31
  fetch('/api/kb-pins').then(function(r) { return r.json(); }).then(function(d) {
32
- if (Array.isArray(d.pins) && d.pins.length > 0) {
33
- _pinsCache = d.pins;
34
- // Clear legacy localStorage
32
+ var serverPins = Array.isArray(d.pins) ? d.pins : [];
33
+ // Migrate: merge localStorage pins into server if not already there
34
+ var localPins = [];
35
+ try { localPins = JSON.parse(localStorage.getItem('minions-pinned-items') || '[]'); } catch {}
36
+ if (localPins.length > 0) {
37
+ var merged = serverPins.slice();
38
+ var changed = false;
39
+ for (var i = 0; i < localPins.length; i++) {
40
+ if (merged.indexOf(localPins[i]) < 0) { merged.unshift(localPins[i]); changed = true; }
41
+ }
42
+ if (changed) {
43
+ fetch('/api/kb-pins', { method: 'POST', headers: { 'Content-Type': 'application/json' }, body: JSON.stringify({ pins: merged }) }).catch(function() {});
44
+ serverPins = merged;
45
+ }
35
46
  localStorage.removeItem('minions-pinned-items');
36
47
  }
48
+ _pinsCache = serverPins;
37
49
  }).catch(function() {});
38
50
  }
39
51
  function inboxPinKey(name) { return 'notes/inbox/' + name; }
package/dashboard.js CHANGED
@@ -3528,11 +3528,14 @@ What would you like to discuss or change? When you're happy, say "approve" and I
3528
3528
  versionCheckInterval: [60000],
3529
3529
  maxBuildFixAttempts: [1, 10],
3530
3530
  };
3531
+ const clamped = [];
3531
3532
  for (const [key, [min, max]] of Object.entries(numericFields)) {
3532
3533
  if (e[key] !== undefined) {
3533
3534
  let val = Number(e[key]) || D[key];
3535
+ const raw = val;
3534
3536
  val = Math.max(min, val);
3535
3537
  if (max !== undefined) val = Math.min(max, val);
3538
+ if (val !== raw) clamped.push(`${key}: ${raw} → ${val} (range: ${min}–${max || '∞'})`);
3536
3539
  config.engine[key] = val;
3537
3540
  }
3538
3541
  }
@@ -3593,7 +3596,10 @@ What would you like to discuss or change? When you're happy, say "approve" and I
3593
3596
  reloadConfig();
3594
3597
  invalidateStatusCache();
3595
3598
  console.log('[settings] Saved config.json — engine keys:', Object.keys(config.engine || {}));
3596
- return jsonReply(res, 200, { ok: true, message: 'Settings saved. Engine picks up changes on next tick.' });
3599
+ const msg = clamped.length > 0
3600
+ ? 'Settings saved. Some values were adjusted: ' + clamped.join('; ')
3601
+ : 'Settings saved. Engine picks up changes on next tick.';
3602
+ return jsonReply(res, 200, { ok: true, message: msg, clamped });
3597
3603
  } catch (e) { return jsonReply(res, 500, { error: e.message }); }
3598
3604
  }
3599
3605
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yemi33/minions",
3
- "version": "0.1.731",
3
+ "version": "0.1.733",
4
4
  "description": "Multi-agent AI dev team that runs from ~/.minions/ — five autonomous agents share a single engine, dashboard, and knowledge base",
5
5
  "bin": {
6
6
  "minions": "bin/minions.js"