Skip to content

armgit / Ix

Public Imported from GitHub
0

Understand any codebase instantly. System intelligence for codebases, built for humans and AI.

Merge origin/main into fix/ingest-413-learn-only-stated-size

KageBinary44c62cc0bfd2
diff --cc ix-cli/src/cli/__tests__/ingest-files.test.ts
index e0adb3f5,51b6c3dc..ff191e62
--- a/ix-cli/src/cli/__tests__/ingest-files.test.ts
+++ b/ix-cli/src/cli/__tests__/ingest-files.test.ts
@@@ -1350,11 -1357,15 +1357,15 @@@ describe("ingestFiles against a fake ba
expect(tooLarge()).toBe(1);
expect(summary.commitErrors).toBe(0);
- expect(summary.patchesApplied).toBe(1100);
+ expect(summary.patchesApplied).toBe(560);
expect(backend.singleCount, "no per-file fallback").toBe(0);
+ // Both batches were sent in bounded requests. Without the learned size,
+ // the second batch goes out as one 60-patch request and is refused.
+ const accepted = backend.requests.filter(r => r.path === "/v1/patches/bulk" && r.code !== 413);
+ expect(Math.max(...accepted.map(r => r.patches))).toBeLessThanOrEqual(Math.floor(300 / 7));
});
- it("halves by ops on a 413 that suggests nothing, and later batches start at the learned size", async () => {
+ it("halves on a 413 that suggests nothing, and later batches start at the learned size", async () => {
fixture(1100);
backend.maxBulkOps = 300;