@quikit/quikpilot-runner 9.3.0-rc.57 → 9.3.0-rc.59
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/README.md +4 -0
- package/dist/index.js +557 -156
- package/dist/index.js.map +3 -3
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -164,6 +164,10 @@ wrong (a field that arrives from a database row or a request), so it only warns
|
|
|
164
164
|
|
|
165
165
|
**9.3.0-rc.46 — the existing tests to read first include the ones that reach the code through one file in between (QUIKTR-1845).** On the live bug-6 run (QTRIA-17) the design changed `lib/services/issueFilters.ts`, and the two tests that assert the bug import `app/api/issues/route.ts`, which imports it, so the list of existing tests the AI reads before writing (`testsToCheck`, rc.44) was empty. When fewer than 3 test files are found by name or a direct import, the runner now takes one more step: of the files the tests import (code, not a test, not under a denied path; the 150 most shared first) it keeps the ones that import a changed file, and adds the tests that import them, after the others and up to 10 in all. A file in between imported by more than 12 tests only brings the tests named after it (a route by its folder) or after the changed file. Paths only, as before. With 3 or more found the list is exactly as in rc.45. Also in rc.46: everything in rc.45. Nothing else changes.
|
|
166
166
|
|
|
167
|
+
**9.3.0-rc.59 - a throwaway test, run once, its output shown (QUIKTR-1702, contract section 44 `codegen-loop-9`).** Before it writes an expected value the AI sometimes needs to SEE what the code really returns. `call_function` could show it, but only for a plain .js file, one function and plain data, on our own repositories: nothing for a Go, Python or Java project. The new tool `run_scratch {path, content}` has the AI name a NEW test file (named the way the project names its tests, in a folder that exists, never a file that exists) and give its text. The runner writes it next to the AI's changes, runs the space's own "Test one file" command on it once (`commands.testFile`, the path quoted, the same environment allow-list, credential scrub and process-group kill as `run_tests`, 60 seconds), puts the checkout back exactly, and answers with ONE string: `exit N`, then the END of what the run printed (stdout and stderr together, colour codes removed, credentials scrubbed, at most 2,000 characters in all). The AI supplies a file and its text, never what runs it: no command, no interpreter, no flag. The scratch file goes to disk through the overlay window as one extra file and never through the loop's overlay, so the syntax guard, the hunk and scope checks, `show_changes`, the proof run and the proposal never see it, and a scratch answer is never evidence that a test fails. It shares the eight `functionCalls` with `call_function`, and a repeat of the same file on the same change is answered as a duplicate and spends nothing. Offered only when fix first is on (loop-9 is loop-8 plus the tool), the space has a one-file command, and the repository is ours (`deathvadeR-afk`, section 28.2 unchanged) or the workflow sets `QUIKPILOT_RUN_SCRATCH=on` (a trial space); `QUIKPILOT_RUN_SCRATCH=off` closes it everywhere. Needs the AI Runtime of QUIKTR-1702 (`codegen-loop-9`, its own flag); an AI Runtime that refuses it is asked again as `codegen-loop-8`, then `codegen-loop-7`. Logs and the run record carry counts and closed words only (`codegen.run_scratch`: status, reason, exit code, seconds, length), never the path, the text or the output. Also in rc.59: everything in rc.58. Nothing else changes.
|
|
168
|
+
|
|
169
|
+
**9.3.0-rc.58 - write the fix first, then ask once about every existing test it breaks, with proof (QUIKTR-1851, absorbing QUIKTR-1850; release 1).** Until now, when an existing test expected the bug, the run stopped BEFORE any code was written and a person approved a change to that test with nothing to show it could ever pass, and the tests were found one at a time: QTRIA-23 approved a change that moved the status line off 401 and left `expect(body).toEqual({ ..., error: "Unauthorized" })`, which no fix can satisfy, and spent all three stops. Now, when the project switches it on (`packet.fixFirst`; `QUIKPILOT_FIX_FIRST=off` turns it off without a rebuild) the run speaks `codegen-loop-8`: a `report_test_conflict` is a PROPOSAL that does not end the run, the AI writes the tests and the fix and reports every existing test its fix breaks, and at its DONE the runner proves the proposals (`proofCheck.ts`): it runs the project's WHOLE suite (the related-tests planner off, a fresh tool, outside the AI's run allowance) with the fix and every proposed change written over the old code. A proposal whose test still fails is sent back with its name ("change EVERY expectation of it"), and an existing test the fix broke that no proposal covers is sent back by name (never a failure message: QUIKTR-1474), at most twice; one that still fails after that is not offered to a person. Then ONE stop, as before, whose proposals carry `oldCodeChecked` (fails on the old code with the change alone), `newCode` (`passes` / `fails` / `not_checked`) and `newEndLine` (where the changed test now ends, for showing the whole test); no time, no answer or a list of failures cut to fit is `not_checked`, never proven. The tests phase hands its proposals to the code phase. An AI Runtime that refuses `codegen-loop-8` is asked again as loop-7 (nothing else changes), a fix turn stays loop-7, and a project that did not switch it on sends and receives exactly what it did. Release 2 (keeping the fix across the stop) is not in this version: the next job still writes the code again. Also in rc.58: everything in rc.57.
|
|
170
|
+
|
|
167
171
|
**9.3.0-rc.57 - rc.56 and rc.55 together.** rc.56 (QUIKTR-1701 release 2) was built and published from a source that did not yet contain rc.55's turn recovery (QUIKTR-1853: a cut-off answer or a slow turn is asked again once in a smaller step instead of ending the attempt), so a project pinned to rc.56 lost it. rc.57 is the merge of the two and nothing else: everything in rc.56 and everything in rc.55. Also in rc.57: everything in rc.54.
|
|
168
172
|
|
|
169
173
|
**9.3.0-rc.56 - outline and find_definition for eight languages, the last test-file names, and the AI's own tests kept in Python, Go and Java (QUIKTR-1701, release 2).** (1) `definitions.ts` reads the definitions of a Python, Go, Java, Kotlin, C#, Rust, Ruby or PHP file from its tree-sitter tree - functions, classes, methods, structs, interfaces, enums, modules, with exact line ranges and nesting (a Java or C# method, a Kotlin `fun`, a Ruby `valid?` and `def self.x`, a Rust `impl`). `read_file` mode "outline" and the too-large answer use it (`engine: "treesitter"`), and `find_definition` looks a name up in the tree of every file that holds it (at most 80 files are parsed per call; the rest, a file that does not parse and any other language keep the line patterns). The name rule is widened to any language: a letter of any script, `_` or `$`, then letters, digits, `_` or `$`, optionally a Ruby-style `?` or `!` at the end (the AI service checks the same rule first: deploy it BEFORE this runner), and a regular-expression character in a name can no longer break the pattern. The grammars are loaded once at the start of a run for the languages in the repository. (2) Test-file names: Surefire's `Test*.java` and `*TestCase.java`, Failsafe's `*IT.java`, Kotest and ScalaTest `FooSpec.kt/.scala`, Django `tests.py` and every file of a C# test project (`Acme.Tests/`) are test files (same table in the AI service and QuikProjects). (3) A fix may correct a test the AI wrote in this run in a Python, Go or Java file but not remove it, skip it (`@pytest.mark.skip`, `t.Skip()`, `@Disabled`) or leave it with fewer checks (assertion statements, `t.Error`/`t.Fatal`, `pytest.raises`, `fail(...)`), as for JavaScript. `QUIKPILOT_LANG_CHECKS=js` and `QUIKPILOT_TEST_LOCATE=js` switch the readers off. Also in rc.56: everything in rc.54 (rc.55 is QUIKTR-1853, built on its own branch).
|