midsummer-sol 0.3.1 → 0.3.2

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.
Files changed (3) hide show
  1. package/package.json +1 -1
  2. package/sol-mcp.js +5 -4
  3. package/sol.js +5 -4
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "midsummer-sol",
3
- "version": "0.3.1",
3
+ "version": "0.3.2",
4
4
  "description": "Sol — agent-native version control (a new git). CLI, MCP server, and no-filesystem SDK.",
5
5
  "bin": { "sol": "./sol.js", "sol-mcp": "./sol-mcp.js", "sol-secret-mcp": "./sol-secret-mcp.js" },
6
6
  "main": "./index.js",
package/sol-mcp.js CHANGED
@@ -4224,11 +4224,12 @@ async function remotePushChunked(cfg, token, body, batchSizeBytes = DEFAULT_BATC
4224
4224
  const stamp = `${body.head ?? "h"}-${Date.now()}`;
4225
4225
  const nodeBatches = splitNodes(body.nodes, batchSizeBytes);
4226
4226
  const batchIds = [];
4227
+ const CONC = 12;
4228
+ for (let i = 0;i < nodeBatches.length; i++)
4229
+ batchIds.push(`${stamp}-${i}`);
4227
4230
  try {
4228
- for (let i = 0;i < nodeBatches.length; i++) {
4229
- const batchId = `${stamp}-${i}`;
4230
- batchIds.push(batchId);
4231
- await remotePushBatch(cfg, token, batchId, nodeBatches[i], i === 0 ? body.ops : [], i);
4231
+ for (let w = 0;w < nodeBatches.length; w += CONC) {
4232
+ await Promise.all(nodeBatches.slice(w, w + CONC).map((nodes, j) => remotePushBatch(cfg, token, batchIds[w + j], nodes, w + j === 0 ? body.ops : [], w + j)));
4232
4233
  }
4233
4234
  } catch (e) {
4234
4235
  if (e instanceof Error && /-> 404/.test(e.message))
package/sol.js CHANGED
@@ -3457,11 +3457,12 @@ async function remotePushChunked(cfg, token, body, batchSizeBytes = DEFAULT_BATC
3457
3457
  const stamp = `${body.head ?? "h"}-${Date.now()}`;
3458
3458
  const nodeBatches = splitNodes(body.nodes, batchSizeBytes);
3459
3459
  const batchIds = [];
3460
+ const CONC = 12;
3461
+ for (let i = 0;i < nodeBatches.length; i++)
3462
+ batchIds.push(`${stamp}-${i}`);
3460
3463
  try {
3461
- for (let i = 0;i < nodeBatches.length; i++) {
3462
- const batchId = `${stamp}-${i}`;
3463
- batchIds.push(batchId);
3464
- await remotePushBatch(cfg, token, batchId, nodeBatches[i], i === 0 ? body.ops : [], i);
3464
+ for (let w = 0;w < nodeBatches.length; w += CONC) {
3465
+ await Promise.all(nodeBatches.slice(w, w + CONC).map((nodes, j) => remotePushBatch(cfg, token, batchIds[w + j], nodes, w + j === 0 ? body.ops : [], w + j)));
3465
3466
  }
3466
3467
  } catch (e) {
3467
3468
  if (e instanceof Error && /-> 404/.test(e.message))