acc: merge repls.json into ACC_REPLS and move it out of the test directory - #6264
Open
denik wants to merge 3 commits into
Open
acc: merge repls.json into ACC_REPLS and move it out of the test directory#6264denik wants to merge 3 commits into
denik wants to merge 3 commits into
Conversation
…ctory Both files were created inside the test directory, so bundle deploy uploaded them to the workspace. There is now a single file at $ACC_REPLS, outside the test directory: the harness writes its replacements there as one JSON object per line, add_repl.py appends "<value>:<NAME>" lines as before. Co-authored-by: Isaac
Collaborator
Integration test reportCommit: 2f141ab
8 interesting tests: 4 SKIP, 3 KNOWN, 1 RECOVERED
Top 27 slowest tests (at least 2 minutes):
|
shreyas-goenka
approved these changes
Aug 13, 2026
| for line := range lines { | ||
| line = strings.TrimSpace(line) | ||
| if len(line) == 0 { | ||
| if len(line) == 0 || strings.HasPrefix(line, "{") { |
Contributor
There was a problem hiding this comment.
Is it possible for the user's replacement to start with {? Like if I am replacing something like {myjson...} with [MYJSON]?
| return result | ||
|
|
||
|
|
||
| def add_repl(value, repl): |
Contributor
There was a problem hiding this comment.
Add an error if the repl starts with {?
Every line is now a JSON object: "Old" for a regular expression from the harness,
"Literal" for a value added by add_repl.py. Previously the two kinds were told apart
by a leading "{", so a value starting with "{" was silently dropped.
The harness skips the lines it wrote itself by their count instead.
Co-authored-by: Isaac
Co-authored-by: Isaac
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Both files were created inside the test directory, so bundle deploy uploaded them to the workspace. They also carried the same data in two formats: repls.json from the harness to diff.py, ACC_REPLS from the scripts back to the harness.
Having it in test directory made file count less stable in #5720
Changes
A single file at $ACC_REPLS, outside the test directory: the harness writes its replacements as one JSON object per line, add_repl.py appends ":" lines as before. Scripts no longer write the file directly - they use the new add_repl helper, which works under MSYS_NO_PATHCONV=1. diff.py and sort_lines.py --repl now apply the script replacements too.