servicesToptal commited on
Commit
ec02279
·
0 Parent(s):

EC-SWE dataset

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. .gitattributes +61 -0
  2. LICENSE +32 -0
  3. README.md +417 -0
  4. data/test.parquet +3 -0
  5. harbor/README.md +317 -0
  6. harbor/build_images.py +79 -0
  7. harbor/checksums.json +0 -0
  8. harbor/evidence/coredns/agent-image-scan.txt +14 -0
  9. harbor/evidence/coredns/native-reference.json +121 -0
  10. harbor/evidence/coredns/reports/broken.json +242 -0
  11. harbor/evidence/coredns/reports/infra.json +12 -0
  12. harbor/evidence/coredns/reports/noop.json +16 -0
  13. harbor/evidence/coredns/reports/reference.json +242 -0
  14. harbor/evidence/coredns/reports/tamper.json +16 -0
  15. harbor/evidence/coredns/summary.json +172 -0
  16. harbor/evidence/epicyon/agent-image-scan.txt +26 -0
  17. harbor/evidence/epicyon/author-calibration.txt +188 -0
  18. harbor/evidence/epicyon/native-reference.json +185 -0
  19. harbor/evidence/epicyon/reports/noop.json +377 -0
  20. harbor/evidence/epicyon/reports/reference.json +370 -0
  21. harbor/evidence/epicyon/summary.json +157 -0
  22. harbor/evidence/packages-reproduced-by-final-converter.json +20 -0
  23. harbor/evidence/rope/agent-image-scan.txt +15 -0
  24. harbor/evidence/rope/author-calibration.txt +844 -0
  25. harbor/evidence/rope/native-reference.json +137 -0
  26. harbor/evidence/rope/reports/noop.json +281 -0
  27. harbor/evidence/rope/reports/reference.json +274 -0
  28. harbor/evidence/rope/summary.json +149 -0
  29. harbor/evidence/zod/agent-image-scan.txt +36 -0
  30. harbor/evidence/zod/native-reference.json +204 -0
  31. harbor/evidence/zod/reports/noop.json +108 -0
  32. harbor/evidence/zod/reports/reference.json +405 -0
  33. harbor/evidence/zod/summary.json +150 -0
  34. harbor/manifest.json +527 -0
  35. harbor/run_checks.py +153 -0
  36. harbor/sources/aioftp-v11/.dockerignore +14 -0
  37. harbor/sources/aioftp-v11/.gitignore +9 -0
  38. harbor/sources/aioftp-v11/Dockerfile.hud +126 -0
  39. harbor/sources/aioftp-v11/env.py +700 -0
  40. harbor/sources/aioftp-v11/gold.diff +795 -0
  41. harbor/sources/aioftp-v11/grading/__init__.py +18 -0
  42. harbor/sources/aioftp-v11/grading/adversarial-manifest.json +2082 -0
  43. harbor/sources/aioftp-v11/grading/baseline/pyproject.toml +117 -0
  44. harbor/sources/aioftp-v11/grading/baseline/tests/__pycache__/conftest.cpython-312-pytest-9.1.1.pyc +0 -0
  45. harbor/sources/aioftp-v11/grading/baseline/tests/conftest.py +232 -0
  46. harbor/sources/aioftp-v11/grading/baseline/tests/test_abort.py +96 -0
  47. harbor/sources/aioftp-v11/grading/baseline/tests/test_client_side_socks.py +29 -0
  48. harbor/sources/aioftp-v11/grading/baseline/tests/test_connection.py +336 -0
  49. harbor/sources/aioftp-v11/grading/baseline/tests/test_corner_cases.py +77 -0
  50. harbor/sources/aioftp-v11/grading/baseline/tests/test_current_directory.py +50 -0
.gitattributes ADDED
@@ -0,0 +1,61 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ *.7z filter=lfs diff=lfs merge=lfs -text
2
+ *.arrow filter=lfs diff=lfs merge=lfs -text
3
+ *.avro filter=lfs diff=lfs merge=lfs -text
4
+ *.bin filter=lfs diff=lfs merge=lfs -text
5
+ *.bz2 filter=lfs diff=lfs merge=lfs -text
6
+ *.ckpt filter=lfs diff=lfs merge=lfs -text
7
+ *.ftz filter=lfs diff=lfs merge=lfs -text
8
+ *.gz filter=lfs diff=lfs merge=lfs -text
9
+ *.h5 filter=lfs diff=lfs merge=lfs -text
10
+ *.joblib filter=lfs diff=lfs merge=lfs -text
11
+ *.lfs.* filter=lfs diff=lfs merge=lfs -text
12
+ *.lz4 filter=lfs diff=lfs merge=lfs -text
13
+ *.mds filter=lfs diff=lfs merge=lfs -text
14
+ *.mlmodel filter=lfs diff=lfs merge=lfs -text
15
+ *.model filter=lfs diff=lfs merge=lfs -text
16
+ *.msgpack filter=lfs diff=lfs merge=lfs -text
17
+ *.npy filter=lfs diff=lfs merge=lfs -text
18
+ *.npz filter=lfs diff=lfs merge=lfs -text
19
+ *.onnx filter=lfs diff=lfs merge=lfs -text
20
+ *.ot filter=lfs diff=lfs merge=lfs -text
21
+ *.parquet filter=lfs diff=lfs merge=lfs -text
22
+ *.pb filter=lfs diff=lfs merge=lfs -text
23
+ *.pickle filter=lfs diff=lfs merge=lfs -text
24
+ *.pkl filter=lfs diff=lfs merge=lfs -text
25
+ *.pt filter=lfs diff=lfs merge=lfs -text
26
+ *.pth filter=lfs diff=lfs merge=lfs -text
27
+ *.rar filter=lfs diff=lfs merge=lfs -text
28
+ *.safetensors filter=lfs diff=lfs merge=lfs -text
29
+ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
30
+ *.tar.* filter=lfs diff=lfs merge=lfs -text
31
+ *.tar filter=lfs diff=lfs merge=lfs -text
32
+ *.tflite filter=lfs diff=lfs merge=lfs -text
33
+ *.tgz filter=lfs diff=lfs merge=lfs -text
34
+ *.wasm filter=lfs diff=lfs merge=lfs -text
35
+ *.xz filter=lfs diff=lfs merge=lfs -text
36
+ *.zip filter=lfs diff=lfs merge=lfs -text
37
+ *.zst filter=lfs diff=lfs merge=lfs -text
38
+ *tfevents* filter=lfs diff=lfs merge=lfs -text
39
+ # Audio files - uncompressed
40
+ *.pcm filter=lfs diff=lfs merge=lfs -text
41
+ *.sam filter=lfs diff=lfs merge=lfs -text
42
+ *.raw filter=lfs diff=lfs merge=lfs -text
43
+ # Audio files - compressed
44
+ *.aac filter=lfs diff=lfs merge=lfs -text
45
+ *.flac filter=lfs diff=lfs merge=lfs -text
46
+ *.mp3 filter=lfs diff=lfs merge=lfs -text
47
+ *.ogg filter=lfs diff=lfs merge=lfs -text
48
+ *.wav filter=lfs diff=lfs merge=lfs -text
49
+ # Image files - uncompressed
50
+ *.bmp filter=lfs diff=lfs merge=lfs -text
51
+ *.gif filter=lfs diff=lfs merge=lfs -text
52
+ *.png filter=lfs diff=lfs merge=lfs -text
53
+ *.tiff filter=lfs diff=lfs merge=lfs -text
54
+ # Image files - compressed
55
+ *.jpg filter=lfs diff=lfs merge=lfs -text
56
+ *.jpeg filter=lfs diff=lfs merge=lfs -text
57
+ *.webp filter=lfs diff=lfs merge=lfs -text
58
+ # Video files - compressed
59
+ *.mp4 filter=lfs diff=lfs merge=lfs -text
60
+ *.webm filter=lfs diff=lfs merge=lfs -text
61
+ harbor/sources/druid-v9/task/grader/lib/budget-agent.jar filter=lfs diff=lfs merge=lfs -text
LICENSE ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ This dataset is a collection of tasks. Each task includes code from an
2
+ open-source repository (the `patch`, `test_patch`, `grader_files` and
3
+ `dockerfile` fields may quote or modify it). That code stays under the licence
4
+ of its upstream repository, listed per task below as reported by GitHub.
5
+
6
+ The task text and grader design, where they are not upstream code, are
7
+ copyright 2026 Toptal, LLC. Contact Toptal, LLC for licence terms.
8
+
9
+ - BabylonJS__Babylon.js-babylonjs_scene_remove_owner_refs_contract-382616f8: Apache-2.0 (https://github.com/BabylonJS/Babylon.js)
10
+ - MathNya__umya-spreadsheet-umya_structural_edit_reference_owners_contract: MIT (https://github.com/MathNya/umya-spreadsheet)
11
+ - SickChill__SickChill-sickchill_episode_metadata_files_contract-2e2a49e4: GPL-3.0 (https://github.com/SickChill/SickChill)
12
+ - Zettlr__Zettlr-zettlr_clickable_keywords: GPL-3.0 (https://github.com/Zettlr/Zettlr)
13
+ - agronholm__apscheduler-apscheduler-expired-job-lease: MIT (https://github.com/agronholm/apscheduler)
14
+ - aio-libs__aioftp-aioftp-stream-abort-desynchronization: Apache-2.0 (https://github.com/aio-libs/aioftp)
15
+ - alibaba__druid-druid_lenient_script: Apache-2.0 (https://github.com/alibaba/druid)
16
+ - alibaba__hooks-ahooks_request_cache_races: MIT (https://github.com/alibaba/hooks)
17
+ - apache__geode-geode_oql_index_null_semantics_contract-1c066303: Apache-2.0 (https://github.com/apache/geode)
18
+ - bashrc2__epicyon-epicyon_deleted_post_announce_cache_contract-1c066303: AGPL-3.0 (https://github.com/bashrc2/epicyon)
19
+ - buchgr__bazel-remote-bazel_remote_disk_eviction_accounting_contract-afe5ea56: Apache-2.0 (https://github.com/buchgr/bazel-remote)
20
+ - celery__celery-celery_retry_expires_countdown_contract: NOASSERTION (https://github.com/celery/celery)
21
+ - colinhacks__zod-zod-json-schema-target-legality: MIT (https://github.com/colinhacks/zod)
22
+ - coredns__coredns-coredns__4097: Apache-2.0 (https://github.com/coredns/coredns)
23
+ - dgraph-io__badger-journal_recovery_after_unclean_stop: Apache-2.0 (https://github.com/dgraph-io/badger)
24
+ - dotnet__Open-XML-SDK-open_xml_sdk_deletepart_refs_contract-1c066303: MIT (https://github.com/dotnet/Open-XML-SDK)
25
+ - igniterealtime__Openfire-openfire_userdeleting_last_owner_contract-0163de9c: Apache-2.0 (https://github.com/igniterealtime/Openfire)
26
+ - mikro-orm__mikro-orm-mikro-orm-pessimistic-locking: MIT (https://github.com/mikro-orm/mikro-orm)
27
+ - ory__kratos-kratos_cleanup_stale_flows_courier_contract: Apache-2.0 (https://github.com/ory/kratos)
28
+ - pallets__click-click-help-defaults: BSD-3-Clause (https://github.com/pallets/click)
29
+ - python-rope__rope-rope_rename_all_reexport_owners_contract-1c066303: LGPL-3.0 (https://github.com/python-rope/rope)
30
+ - sequelize__sequelize-sequelize-bulkcreate-ignore-duplicates: MIT (https://github.com/sequelize/sequelize)
31
+ - terser__terser-retained_top_level_names_keep_their_values: NOASSERTION (https://github.com/terser/terser)
32
+ - tsileo__microblog.pub-microblogpub_deleted_object_resurrect_lookup_contract-382616f8: AGPL-3.0 (https://github.com/tsileo/microblog.pub)
README.md ADDED
@@ -0,0 +1,417 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ # Dataset card metadata. Spec: https://github.com/huggingface/hub-docs/blob/main/datasetcard.md?plain=1
3
+ pretty_name: EC SWE
4
+ language:
5
+ - en
6
+ language_details: en-US
7
+ license: other
8
+ license_name: mixed-upstream
9
+ license_link: LICENSE
10
+ license_details: >-
11
+ Each task carries code from an open-source upstream repository (patch,
12
+ test_patch, grader_files, dockerfile), under that repository's licence; the
13
+ repo_license column names it per row. The task text and grader design are
14
+ copyright 2026 Toptal, LLC; contact Toptal, LLC for licence terms.
15
+ tags:
16
+ - code
17
+ - software-engineering
18
+ - swe-bench
19
+ - agents
20
+ - coding-agents
21
+ - benchmark
22
+ - evaluation
23
+ - bug-fixing
24
+ - program-repair
25
+ - multi-language
26
+ annotations_creators:
27
+ - expert-generated
28
+ language_creators:
29
+ - expert-generated
30
+ multilinguality:
31
+ - monolingual
32
+ size_categories:
33
+ - n<1K
34
+ source_datasets:
35
+ - original
36
+ task_categories:
37
+ - text-generation
38
+ task_ids:
39
+ - language-modeling
40
+ configs:
41
+ - config_name: default
42
+ data_files:
43
+ - split: test
44
+ path: data/test.parquet
45
+ dataset_info:
46
+ config_name: default
47
+ features:
48
+ - name: instance_id
49
+ dtype: string
50
+ - name: repo
51
+ dtype: string
52
+ - name: base_commit
53
+ dtype: string
54
+ - name: setup_patch
55
+ dtype: string
56
+ - name: problem_statement
57
+ dtype: string
58
+ - name: patch
59
+ dtype: string
60
+ - name: test_patch
61
+ dtype: string
62
+ - name: patch_files
63
+ list: string
64
+ - name: grader
65
+ list:
66
+ - name: criterion
67
+ dtype: string
68
+ - name: weight
69
+ dtype: float64
70
+ - name: grader_files
71
+ list:
72
+ - name: path
73
+ dtype: string
74
+ - name: encoding
75
+ dtype: string
76
+ - name: content
77
+ dtype: string
78
+ - name: dockerfile
79
+ dtype: string
80
+ - name: language
81
+ dtype: string
82
+ - name: repo_license
83
+ dtype: string
84
+ - name: hud_task
85
+ dtype: string
86
+ - name: difficulty
87
+ dtype: string
88
+ - name: agent_runs
89
+ dtype: int64
90
+ - name: agent_rewards
91
+ list: float64
92
+ - name: agent_mean_reward
93
+ dtype: float64
94
+ - name: agent_solve_rate
95
+ dtype: float64
96
+ - name: agent_models
97
+ list: string
98
+ - name: gold_reward
99
+ dtype: float64
100
+ - name: base_reward
101
+ dtype: float64
102
+ splits:
103
+ - name: test
104
+ num_bytes: 16944456
105
+ num_examples: 24
106
+ download_size: 7713543
107
+ dataset_size: 16944456
108
+ ---
109
+
110
+ # Dataset Card for ExpertCrowd SWE (EC-SWE)
111
+
112
+ This dataset contains real software engineering tasks for evaluating coding
113
+ agents. Each one is a bug or missing behaviour in a real open-source repository, pinned to a
114
+ commit, with a written problem statement, a reference fix, and a weighted
115
+ grader backed by hidden tests. The tasks were chosen to sit at the typical
116
+ difficulty of the pool of reviewed tasks they were drawn from, measured by how
117
+ well current frontier agents scored on them: no outliers at either end. Mean
118
+ agent reward runs from 0.34 to 0.43, and 1.6% of agent runs scored a full 1.0.
119
+
120
+ ## Dataset Details
121
+
122
+ ### Dataset Description
123
+
124
+ Every task was written by a software engineer, run on the HUD evaluation
125
+ platform, and accepted by a human reviewer (review status `verified`). Before a
126
+ task can be accepted, its reference fix has to score 1.0 on every grader
127
+ criterion, the unchanged repository has to fail, and at least 5 agent runs on a
128
+ current frontier model have to be graded. Automated checks also look at the
129
+ prompt (it must state the symptom, not the fix), the grader (weights add up to
130
+ 100, each criterion is one observable requirement), and whether the task
131
+ overlaps a public benchmark.
132
+
133
+ This dataset keeps the tasks closest to the typical difficulty of all verified tasks with agent scores, chosen from those that met every export
134
+ check (see [Curation Rationale](#curation-rationale)).
135
+
136
+ ## Uses
137
+
138
+ ### Direct Use
139
+
140
+ - Evaluating coding agents on realistic repository-level tasks: give the agent
141
+ `problem_statement` and a checkout of `repo` at `base_commit` with
142
+ `setup_patch` applied, then score the resulting diff with the task's grader.
143
+ - Studying difficulty: every task carries the per-run rewards of 128 graded
144
+ agent runs, so results can be compared against a known baseline.
145
+ - Building or validating graders and task-quality tooling, using the reference
146
+ fix, the hidden tests and the weighted criteria together.
147
+
148
+ ## Dataset Structure
149
+
150
+ One split, `test`, with one row per task.
151
+
152
+ | Field | Type | What it holds |
153
+ | --- | --- | --- |
154
+ | `instance_id` | string | `<owner>__<repo>-<task>`, unique |
155
+ | `repo` | string | upstream GitHub repository, `owner/name` |
156
+ | `base_commit` | string | the 40-character upstream commit the task is built on |
157
+ | `setup_patch` | string | a patch the environment applies to `base_commit` before the agent starts; empty for most tasks. Apply it first: `patch` and `test_patch` are written against the result |
158
+ | `problem_statement` | string | the exact prompt the agent was sent, including a short preamble about the workspace (`/workspace/repo`) and resource limits |
159
+ | `patch` | string | the reference fix, non-test files only |
160
+ | `test_patch` | string | test files the reference fix adds or changes (may be empty) |
161
+ | `patch_files` | list of string | every file the reference fix touches |
162
+ | `grader` | list of (criterion, weight) | the grader's criteria and their weights in percent; weights add up to 100 |
163
+ | `grader_files` | list of (path, encoding, content) | the grader as built into the task environment (`grader/`, `grading/` or `protected/`): hidden tests, the repository's regression suite where the grader reruns it, and the script that scores a run. `encoding` is `utf-8`, or `base64` for binary fixtures. The author's calibration notes, control diffs and adversarial manifests are left out |
164
+ | `dockerfile` | string | the environment the agent ran in |
165
+ | `language`, `repo_license` | string | from the GitHub API for `repo` |
166
+ | `hud_task` | string | the task's name on HUD, for tracing a row back |
167
+ | `difficulty` | string | bucket of `agent_mean_reward`: very hard (under 0.2), hard, medium, easy, very easy (0.8 and up) |
168
+ | `agent_runs`, `agent_rewards` | int, list of float | graded agent runs on current models and each run's reward (0 to 1) |
169
+ | `agent_mean_reward`, `agent_solve_rate` | float | mean reward, and the share of runs that scored a full 1.0 |
170
+ | `agent_models` | list of string | the models those runs used |
171
+ | `gold_reward`, `base_reward` | float | reward of the reference fix (1.0) and of the unchanged repository |
172
+
173
+ ```python
174
+ from datasets import load_dataset
175
+
176
+ ds = load_dataset("ExpertCrowd/ec-swe", split="test")
177
+ hard = ds.filter(lambda r: r["difficulty"] in ("very hard", "hard"))
178
+ ```
179
+
180
+ ### At a glance
181
+
182
+ - **Tasks:** one per repository
183
+ - **Graded agent runs behind the difficulty numbers:** 128
184
+ - **Models those runs used:** claude-fable-5, claude-fable-5-1, claude-opus-5, gemini-3.8-flash, gpt-6-astra
185
+
186
+ | Language | Tasks |
187
+ | --- | --- |
188
+ | Python | 8 |
189
+ | TypeScript | 6 |
190
+ | Go | 4 |
191
+ | Java | 3 |
192
+ | JavaScript | 1 |
193
+ | Rust | 1 |
194
+ | C# | 1 |
195
+
196
+ ### Difficulty
197
+
198
+ Difficulty is the mean reward of graded agent runs on current frontier models.
199
+ The tasks sit around the middle of the distribution of every verified task with
200
+ 5 or more graded agent runs, so the mean and median stay close to the pool's
201
+ while the very hard and easy tails are left out:
202
+
203
+ | Mean agent reward | Difficulty | All verified with agent scores (124) | This dataset |
204
+ | --- | --- | --- | --- |
205
+ | 0.0 to 0.2 | very hard | 5 (4%) | 0% |
206
+ | 0.2 to 0.4 | hard | 61 (49%) | 62% |
207
+ | 0.4 to 0.6 | medium | 55 (44%) | 38% |
208
+ | 0.6 to 0.8 | easy | 3 (2%) | 0% |
209
+ | 0.8 to 1.0 | very easy | 0 (0%) | 0% |
210
+ | **mean** | | **0.377** | **0.380** |
211
+ | **median** | | **0.379** | **0.373** |
212
+
213
+ ### Tasks
214
+
215
+ | Instance | Repository | Language | Difficulty | Mean reward |
216
+ | --- | --- | --- | --- | --- |
217
+ | `bashrc2__epicyon-epicyon_deleted_post_announce_cache_contract-1c066303` | bashrc2/epicyon | Python | hard | 0.34 |
218
+ | `apache__geode-geode_oql_index_null_semantics_contract-1c066303` | apache/geode | Java | hard | 0.34 |
219
+ | `coredns__coredns-coredns__4097` | coredns/coredns | Go | hard | 0.34 |
220
+ | `sequelize__sequelize-sequelize-bulkcreate-ignore-duplicates` | sequelize/sequelize | TypeScript | hard | 0.34 |
221
+ | `MathNya__umya-spreadsheet-umya_structural_edit_reference_owners_contract` | MathNya/umya-spreadsheet | Rust | hard | 0.35 |
222
+ | `alibaba__druid-druid_lenient_script` | alibaba/druid | Java | hard | 0.35 |
223
+ | `aio-libs__aioftp-aioftp-stream-abort-desynchronization` | aio-libs/aioftp | Python | hard | 0.35 |
224
+ | `python-rope__rope-rope_rename_all_reexport_owners_contract-1c066303` | python-rope/rope | Python | hard | 0.35 |
225
+ | `SickChill__SickChill-sickchill_episode_metadata_files_contract-2e2a49e4` | SickChill/SickChill | Python | hard | 0.35 |
226
+ | `igniterealtime__Openfire-openfire_userdeleting_last_owner_contract-0163de9c` | igniterealtime/Openfire | Java | hard | 0.36 |
227
+ | `Zettlr__Zettlr-zettlr_clickable_keywords` | Zettlr/Zettlr | TypeScript | hard | 0.36 |
228
+ | `buchgr__bazel-remote-bazel_remote_disk_eviction_accounting_contract-afe5ea56` | buchgr/bazel-remote | Go | hard | 0.37 |
229
+ | `terser__terser-retained_top_level_names_keep_their_values` | terser/terser | JavaScript | hard | 0.38 |
230
+ | `ory__kratos-kratos_cleanup_stale_flows_courier_contract` | ory/kratos | Go | hard | 0.38 |
231
+ | `dotnet__Open-XML-SDK-open_xml_sdk_deletepart_refs_contract-1c066303` | dotnet/Open-XML-SDK | C# | hard | 0.39 |
232
+ | `dgraph-io__badger-journal_recovery_after_unclean_stop` | dgraph-io/badger | Go | medium | 0.40 |
233
+ | `BabylonJS__Babylon.js-babylonjs_scene_remove_owner_refs_contract-382616f8` | BabylonJS/Babylon.js | TypeScript | medium | 0.40 |
234
+ | `alibaba__hooks-ahooks_request_cache_races` | alibaba/hooks | TypeScript | medium | 0.41 |
235
+ | `celery__celery-celery_retry_expires_countdown_contract` | celery/celery | Python | medium | 0.43 |
236
+ | `colinhacks__zod-zod-json-schema-target-legality` | colinhacks/zod | TypeScript | medium | 0.43 |
237
+ | `pallets__click-click-help-defaults` | pallets/click | Python | medium | 0.43 |
238
+ | `tsileo__microblog.pub-microblogpub_deleted_object_resurrect_lookup_contract-382616f8` | tsileo/microblog.pub | Python | medium | 0.43 |
239
+ | `mikro-orm__mikro-orm-mikro-orm-pessimistic-locking` | mikro-orm/mikro-orm | TypeScript | medium | 0.43 |
240
+ | `agronholm__apscheduler-apscheduler-expired-job-lease` | agronholm/apscheduler | Python | medium | 0.43 |
241
+
242
+ ## Running the tasks
243
+
244
+ There are two ways to run a task: on HUD, the platform the tasks were written for, or with
245
+ Harbor on your own machine.
246
+
247
+ ### On HUD
248
+
249
+ Every task runs on HUD, including the nine that have no Harbor package. The tasks are
250
+ published there as the taskset [`ec-swe`](https://www.hud.ai/shared/tasksets/979e6e02-d726-46f6-a066-914afc5c9f44),
251
+ which anyone can view; it is still being filled as its environments are built.
252
+
253
+ To run a task in a HUD workspace of your own: each folder under `harbor/sources/` is the build
254
+ source of one task's HUD environment. With a HUD account, on Linux, macOS or WSL:
255
+
256
+ ```bash
257
+ pip install hud # the hud command
258
+ hud set HUD_API_KEY=<your key> # a key from hud.ai/project/api-keys
259
+ hf download ExpertCrowd/ec-swe --repo-type dataset --include "harbor/sources/**" --local-dir ec-swe
260
+ cd ec-swe/harbor/sources/<task folder>
261
+ hud deploy # builds the environment in your HUD workspace
262
+ hud sync tasks my-ec-swe tasks.py # puts this folder's task into a taskset of yours
263
+ hud eval my-ec-swe claude --full # runs it on the platform with an agent
264
+ ```
265
+
266
+ Results appear as jobs and traces on hud.ai (`hud jobs`). On HUD the agent and the grader
267
+ share one container, kept apart by file permissions, and the four tasks with a criterion
268
+ judged by a model get that judge from HUD's gateway. The commands follow HUD's
269
+ documentation. We rehearsed `hud deploy` and `hud sync tasks` for every folder in their
270
+ dry-run mode and ran them in full for the terser folder; we have not run an agent with
271
+ `hud eval` from this folder.
272
+
273
+ ### With Harbor
274
+
275
+ The `harbor/` folder of this repository makes tasks runnable end
276
+ to end with [Harbor](https://github.com/harbor-framework/harbor) 0.23.0 and
277
+ Docker, and nothing else. Each task is packaged as two containers: one for the
278
+ agent, holding the repository at its base commit and nothing from the grading
279
+ side, and a separate one that grades the patch the agent leaves behind with the
280
+ task's original grader. Both are offline by default. The folder holds each
281
+ task's complete build context, so its environment can be rebuilt from this
282
+ repository alone.
283
+
284
+ ```bash
285
+ hf download ExpertCrowd/ec-swe --repo-type dataset --include "harbor/**" --local-dir ec-swe
286
+ cd ec-swe/harbor
287
+ pip install harbor==0.23.0
288
+ python build_images.py --task <task folder>
289
+ harbor run -p tasks/<task folder> -a oracle # the reference fix: reward 1.0
290
+ harbor run -p tasks/<task folder> -a nop # no change: reward 0.0
291
+ harbor run -p tasks/<task folder> -a <agent> -m <model> --allow-agent-host <model API host>
292
+ ```
293
+
294
+ `harbor/README.md` has the requirements, a table that maps each task folder to
295
+ its `instance_id` here, the scripted checks, and what was recorded for each
296
+ task. Every packaged task was run through Harbor on the files in the folder: an
297
+ empty change scores 0, and the reference fix scores 1.0 with every criterion
298
+ equal to the task's original grading. The folder contains the reference fixes
299
+ and the hidden graders, as the rows of this dataset do.
300
+
301
+ 11 more (badger, bazel-remote, celery, geode, kratos, microblogpub, open-xml-sdk, openfire, terser, umya, zettlr) are packaged and are being re-checked; they are added
302
+ as each one passes.
303
+
304
+ Nine tasks have no Harbor package yet: click, sequelize, druid and hooks (one criterion each
305
+ is judged by a model), SickChill, Babylon.js, mikro-orm, aioftp and apscheduler. The folder
306
+ holds the complete build context of each, and `harbor/README.md` says for each how it is
307
+ built and graded and what it needs.
308
+
309
+ ## Dataset Creation
310
+
311
+ ### Curation Rationale
312
+
313
+ The goal was a public set at the typical difficulty of the full pool: hard
314
+ enough that no current agent solves the tasks reliably, without tasks so hard
315
+ that every agent scores near zero, or so easy that they no longer separate
316
+ models.
317
+
318
+ 1. **Pool.** Every task whose current review status on HUD is `verified'. Validation copies of a task are not tasks and were
319
+ left out.
320
+ 2. **Export checks.** A task was kept only if HUD gave a prompt, a GitHub
321
+ repository and a pinned 40-character commit, a non-empty reference fix,
322
+ grader weights adding up to 100, a reference run on the current task version
323
+ scoring 1.0, and at least 5 graded agent runs on a current model. The
324
+ repository had to be an established upstream project, not one created for
325
+ the task, and the environment could not depend on a task author's personal
326
+ images. Two tasks with the same reference fix, or the same repository and
327
+ scenario, count once.
328
+ 3. **Stratified sample.** All verified tasks with 5 or more
329
+ graded agent runs were ranked by mean agent reward and cut into bins of
330
+ equal size. Each bin contributed one task that passed the export checks,
331
+ preferring a repository not yet in the sample. Matching against the whole
332
+ scored pool, not only the exportable part, keeps the export checks from
333
+ skewing the difficulty curve.
334
+ 4. **Typical difficulty.** From that sample, the tasks whose mean agent
335
+ reward was closest to the sample mean (0.374) were kept: every task within
336
+ 0.059 of it. The nearest task left out was 0.064 away, so the cut does not
337
+ split a tie.
338
+
339
+ ### Source Data
340
+
341
+ #### Data Collection and Processing
342
+
343
+ Task authors chose a bug or missing behaviour in an open-source repository,
344
+ wrote the problem statement, built a container that checks out the repository at
345
+ a pinned commit, wrote a reference fix and a hidden-test grader, and ran the
346
+ task on HUD: a reference run, a run with no fix, and at least 5 agent runs. The
347
+ export reads the prompt from the agent's own trace, the criteria and weights
348
+ from the reference run's grading, and the repository, commit, reference fix and
349
+ grader from the environment build.
350
+
351
+ #### Who are the source data producers?
352
+
353
+ The code comes from the upstream open-source projects named in `repo`, written
354
+ by their contributors. The problem statements, reference fixes, hidden tests and
355
+ graders were written by professional software engineers contracted to build the
356
+ tasks.
357
+
358
+ ### Annotations
359
+
360
+ #### Annotation process
361
+
362
+ Each task was reviewed on HUD by a human reviewer, who could send it back for
363
+ revision or reject it; only tasks marked `verified` are included. Automated
364
+ checks run before review on the prompt, the grader, the reference and baseline
365
+ runs, and overlap with public benchmarks. The difficulty fields come from graded
366
+ agent runs, not from people.
367
+
368
+ #### Who are the annotators?
369
+
370
+ Experienced software engineers acting as reviewers, separate from each task's
371
+ author.
372
+
373
+ #### Personal and Sensitive Information
374
+
375
+ The tasks are about source code. Author and reviewer names were left out of
376
+ the export. Upstream code can contain contributor names in comments, licence
377
+ headers or commit metadata, as it does in the upstream repositories.
378
+
379
+ ## Recommendations
380
+
381
+ Report `agent_solve_rate`-style full solves alongside mean reward, report
382
+ results per difficulty bucket as well as overall, and give the model's training
383
+ cutoff relative to this dataset's release.
384
+
385
+ ## Citation
386
+
387
+ **BibTeX:**
388
+
389
+ ```bibtex
390
+ @misc{toptal2026ecswe,
391
+ author = {{Toptal, LLC}},
392
+ title = {{EC SWE}},
393
+ year = {2026},
394
+ publisher = {Hugging Face},
395
+ howpublished = {\url{https://huggingface.co/datasets/ExpertCrowd/ec-swe}}
396
+ }
397
+ ```
398
+
399
+ **APA:**
400
+
401
+ Toptal, LLC. (2026). *EC SWE* [Data set]. Hugging Face.
402
+ https://huggingface.co/datasets/ExpertCrowd/ec-swe
403
+
404
+ ## Glossary
405
+
406
+ - **Gold run:** the task run with the reference fix applied. It must score 1.0.
407
+ - **Base run:** the task run on the unchanged repository. It should score low.
408
+ - **Reward:** the grader's weighted score for one run, 0 to 1.
409
+ - **Verified:** a task a human reviewer accepted on HUD.
410
+
411
+ ## Dataset Card Authors
412
+
413
+ Toptal, LLC
414
+
415
+ ## Dataset Card Contact
416
+
417
+ Toptal, LLC, through the ExpertCrowd organization on Hugging Face.
data/test.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:8d46fa9d12cfc210336016075e357f6230b5aaa42fdc4276a3a30671ef97d62c
3
+ size 7713543
harbor/README.md ADDED
@@ -0,0 +1,317 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # ExpertCrowd SWE tasks: runnable Harbor packages
2
+
3
+ This folder makes 4 ExpertCrowd software-engineering tasks runnable end
4
+ to end with [Harbor](https://github.com/harbor-framework/harbor) and Docker, and
5
+ nothing else. Each task is a real repository at a fixed commit, a written
6
+ request, and the original hidden rubric that scores a change to that repository.
7
+ An agent works in one container; a second container, which the agent never
8
+ sees, grades the patch it leaves behind. The table under "Recorded
9
+ qualification" maps each task folder to its row in `data/test.parquet`.
10
+
11
+ The folder contains the reference solutions and the hidden graders. A model you
12
+ are evaluating must see only the task prompt and its own sandbox, which is what
13
+ Harbor gives it. Do not put the other files where that model, or its training
14
+ data, can reach them.
15
+
16
+ ## Two ways to run a task
17
+
18
+ - **With Harbor, on your own machine.** 4 tasks are packaged for
19
+ this under `tasks/`. Everything on this page up to "Tasks without a Harbor
20
+ package" is about this route.
21
+ - **On HUD, the platform the tasks were written for.** All 24 tasks run there,
22
+ and the agent results in the dataset come from such runs. The tasks are
23
+ published there as the taskset
24
+ [`ec-swe`](https://www.hud.ai/shared/tasksets/979e6e02-d726-46f6-a066-914afc5c9f44),
25
+ which anyone can view; it is still being filled as its environments are
26
+ built. To run a task in a workspace of your own: each folder under
27
+ `sources/` is the build source of a task's HUD environment. With a HUD
28
+ account and the `hud` command, on Linux, macOS or WSL:
29
+
30
+ ```bash
31
+ pip install hud # the hud command
32
+ hud set HUD_API_KEY=<your key> # a key from hud.ai/project/api-keys
33
+ cd sources/<folder>
34
+ hud deploy # builds the environment in your HUD workspace
35
+ hud sync tasks my-ec-swe tasks.py # puts this folder's task into a taskset of yours
36
+ hud eval my-ec-swe claude --full # runs it on the platform with an agent
37
+ ```
38
+
39
+ Results appear as jobs and traces on hud.ai (`hud jobs`). This is also the
40
+ route for the nine tasks without a Harbor package, including the four with a
41
+ criterion judged by a model, which HUD's gateway serves. The commands follow
42
+ HUD's documentation; we rehearsed `hud deploy` and `hud sync tasks` for every
43
+ folder in their dry-run mode and ran them in full for the terser folder; we
44
+ have not run an agent with `hud eval` from this folder. The build
45
+ sources are the ones the platform built the recorded environments from, with
46
+ the changes listed under "Contents".
47
+
48
+ ## What you need
49
+
50
+ - Docker with Compose and BuildKit, on Linux, macOS or Windows with WSL.
51
+ - Python 3.12 and Harbor 0.23.0: `pip install harbor==0.23.0`.
52
+ - Network access while images are built. Tasks themselves run offline.
53
+ - Disk: allow 5 to 10 GB per task for its images. Each task container is
54
+ limited to 2 CPUs and 8 GiB.
55
+
56
+ No GPU, model account or API key is needed for the checks below.
57
+
58
+ ## Quick start
59
+
60
+ From this folder:
61
+
62
+ ```bash
63
+ python verify_bundle.py
64
+ python build_images.py --task coredns_rewrite_svcb_opt
65
+ harbor run -p tasks/coredns_rewrite_svcb_opt -a oracle # the reference fix: reward 1.0
66
+ harbor run -p tasks/coredns_rewrite_svcb_opt -a nop # no change: reward 0.0
67
+ python run_checks.py --task coredns_rewrite_svcb_opt --output checks-001
68
+ ```
69
+
70
+ 1. `verify_bundle.py` checks every file against `checksums.json`.
71
+ 2. `build_images.py` builds the task's source image from `sources/`. Leave out
72
+ `--task` to build every task. A build takes ten to forty minutes: most tasks
73
+ finish their build by scoring their own reference fix and the untouched
74
+ repository, and refuse to produce an image unless those score 1.0 and 0.0.
75
+ 3. `harbor run` with Harbor's `oracle` agent applies the reference fix and with
76
+ its `nop` agent changes nothing. These two need no script from this folder.
77
+ 4. `run_checks.py` runs five scripted checks per task and exits 0 only if each
78
+ gives what is expected:
79
+
80
+ | Check | What is submitted | Expected |
81
+ | --- | --- | --- |
82
+ | `noop` | nothing | reward 0 |
83
+ | `reference` | the reference fix | reward 1, and the agent's container is isolated |
84
+ | `broken` | the reference fix plus a syntax error | reward 0, graded normally |
85
+ | `infra` | the reference fix, with one grader file removed from the verifier | no reward: the attempt is invalid |
86
+ | `tamper` | nothing, while a process keeps writing a full score to the result file | reward 0 |
87
+
88
+ ## Running an agent
89
+
90
+ ```bash
91
+ harbor run -p tasks/coredns_rewrite_svcb_opt -a <agent> -m <model> --allow-agent-host <model API host>
92
+ ```
93
+
94
+ Harbor's agents run inside the task's container, so they need to reach their
95
+ model. Every task here declares no network for both phases;
96
+ `--allow-agent-host` opens the agent phase to the hosts you name and nothing
97
+ else, and the verifier stays offline. `harbor run --help` lists the agents.
98
+ An agent that installs itself into the container may need further hosts for
99
+ that step (`--allow-environment-host`).
100
+
101
+ Only Harbor's `oracle` and `nop` agents were run for the qualification below.
102
+ No run with a model-backed Harbor agent is part of this folder yet.
103
+
104
+ ## Recorded qualification
105
+
106
+ Every task below was run with stock Harbor 0.23.0 on the files shipped here,
107
+ with these results.
108
+
109
+ | Task folder | `instance_id` in the dataset | Language | Criteria | Empty change | Reference fix | Agent image scan |
110
+ | --- | --- | --- | --- | --- | --- | --- |
111
+ | `coredns_rewrite_svcb_opt` | `coredns__coredns-coredns__4097` | Go | 7 | 0 | 1 | clean |
112
+ | `epicyon_deleted_post_announce_cache_contract` | `bashrc2__epicyon-epicyon_deleted_post_announce_cache_contract-1c066303` | Python | 11 | 0 | 1 | clean |
113
+ | `rope_rename_all_reexport_owners_contract` | `python-rope__rope-rope_rename_all_reexport_owners_contract-1c066303` | Python | 8 | 0 | 1 | clean |
114
+ | `zod_json_schema_target_legality` | `colinhacks__zod-zod-json-schema-target-legality` | TypeScript | 12 | 0 | 1 | clean |
115
+
116
+ The `broken`, `infra` and `tamper` checks, and the author's calibration patches where a task has them, have also been run on these exact files for 1 of the tasks: `coredns_rewrite_svcb_opt`. For the other tasks the `broken` and `infra` checks and the calibration patches last passed on an earlier build of the package, and all of these checks are being repeated on the files here. `manifest.json` records per task which checks ran on which build (`checks_on_shipped_files`, `further_checks`).
117
+
118
+ - **Empty change** and **Reference fix** are the rewards of Harbor's `nop` and
119
+ `oracle` runs.
120
+ - **Reference fix** also means that every criterion's value and weight equals
121
+ what the task's own grading code gives the reference fix inside its
122
+ unmodified source image, and that the isolation check passed: the agent runs
123
+ as an unprivileged user, sees none of the grading files and gets no traffic
124
+ out.
125
+ - **Agent image scan** means no line of the reference patch, the hidden graders
126
+ or the criterion names is in the agent's image, other than lines the public
127
+ repository already contained.
128
+ - **Author's calibration patches** are partial, alternative and cheating
129
+ solutions the task's author shipped with the task. Each patch is submitted
130
+ through the package and has to reproduce the score the author's own build
131
+ recorded.
132
+
133
+ The per-task records are in `evidence/<task>/`: a summary, the native grading
134
+ of the reference, the author's calibration output, each verifier report and the
135
+ agent image scan.
136
+
137
+ ## How a score is produced
138
+
139
+ - The agent's container holds the repository at its base commit with a fresh
140
+ one-commit history, the toolchain, and nothing from the grading side. The
141
+ agent runs as an unprivileged user.
142
+ - When the agent finishes, a hook in the task captures its change as a patch
143
+ against a protected copy of the base commit. Only that patch reaches the
144
+ verifier.
145
+ - The verifier is a fresh container. It checks its own grader files against
146
+ recorded hashes, applies the patch, and runs the task's original grading code
147
+ unchanged. Grader commands, and with them the submitted code, run as an
148
+ unprivileged user; the report, the rubric files and the repository's original
149
+ history belong to root.
150
+ - The reward is the task's original reward: weighted criteria between 0 and 1,
151
+ with partial credit. Most tasks mark some criteria as blockers and cap the
152
+ reward at 0.6 when one fails. A few tasks apply a rule of their own instead
153
+ (`reward_rule` is `authored` in `manifest.json`); their reward is kept as
154
+ computed and cross-checked against the criteria.
155
+ - An attempt is **invalid**, and gets no reward, when grading itself could not
156
+ be completed: a missing grader file or dependency, a grader command that
157
+ timed out or ended outside its pass/fail contract, missing criteria, or a
158
+ report that does not add up. Harbor reports it as an error, not as a score.
159
+ Re-run or exclude it; do not average it in as a zero.
160
+ - A submission that does not compile is not an invalid attempt. Several tasks'
161
+ graders report "could not judge" when the build breaks. The verifier then
162
+ resets the repository and puts the same check to the untouched code. If the
163
+ grader reaches a verdict there, the submission is what broke it: the
164
+ criterion counts as unmet and the attempt is scored. If it cannot judge the
165
+ untouched code either, the environment is at fault and the attempt is invalid.
166
+
167
+ ## Contents
168
+
169
+ - `tasks/<task id>/`: one Harbor task per folder: `instruction.md` (the prompt
170
+ the agent receives), `task.toml`, `environment/` (agent image recipe),
171
+ `tests/` (verifier recipe, verifier and its pinned configuration) and
172
+ `solution/` (reference fix).
173
+ - `sources/`: each task's build context as downloaded from HUD. In eighteen of
174
+ them the environment name was changed to a neutral one (`ec-swe-...`, at most
175
+ three lines in `env.py`, `pyproject.toml` and `tasks.py`), and druid's had
176
+ comments shortened and three unused files removed; `manifest.json` lists the
177
+ changed files per task (`source_edited`). Every packaged task was built and
178
+ checked from the files here. `sources/archives/` holds the original archive
179
+ of each context that was not changed.
180
+ `build_images.py` builds from these.
181
+ - `build_images.py`, `run_checks.py`, `verify_bundle.py`: standard-library
182
+ scripts; `run_checks.py` calls the `harbor` command.
183
+ - `evidence/`: the recorded qualification.
184
+ - `manifest.json`, `checksums.json`: versions, image names and file hashes.
185
+
186
+ ## Limits of what is shown
187
+
188
+ - The checks are scripted. They show that each task can be built, attempted,
189
+ graded and scored as its author intended. They do not measure any model.
190
+ - Everything was qualified on one machine (Docker Desktop on Windows, through
191
+ WSL). It has not been repeated on a second machine. As a test of the download
192
+ itself, this folder was fetched from the Hub into an empty Linux directory on
193
+ that machine, and one task (`retained_top_level_names_keep_their_values`) was
194
+ built and put through all five checks from there.
195
+ - Task images are built on your machine, so their image IDs differ from the
196
+ ones recorded here. What is pinned is the content of the grader files, which
197
+ the verifier checks before every grading.
198
+ - Builds download base images and dependencies. A recipe that builds today can
199
+ stop building when an upstream package is withdrawn.
200
+ - A download gives every file mode 644. The images were qualified from build
201
+ contexts in which every file had mode 777, and some images keep the modes of
202
+ files they copy. `build_images.py` builds from a temporary copy with mode
203
+ 777 for that reason. If you build a `Dockerfile.hud` by hand, give its
204
+ context the same modes first.
205
+ - Run one task at a time on a machine that is otherwise quiet when a score
206
+ matters: some repositories' own test suites are timing-sensitive, and a busy
207
+ machine has turned a correct fix's gate red here.
208
+ - The graders execute the submitted code. The isolation described above is a
209
+ concrete, tested boundary, not a security certification.
210
+
211
+ ## Tasks without a Harbor package
212
+
213
+ Nine of the dataset's 24 tasks have no package under `tasks/` yet. The complete
214
+ build context of each is under `sources/` (unmodified, except druid's: see its
215
+ entry), so you can
216
+ build the task's image and run it in a setup of your own. This section says how
217
+ each is meant to run, what it needs, and what was seen when it was tried here.
218
+ None of these routes gives the isolation of the packaged tasks: the agent and
219
+ the grader share one container, separated by file permissions.
220
+
221
+ **Building.** `python build_images.py --task <name>` builds the image
222
+ `ec-swe-<name>:source-v<n>` from `sources/<name>-v<n>/Dockerfile.hud`, the same
223
+ way as for the packaged tasks. `<name>` is the bold name in the list below.
224
+
225
+ **How these images run a task.** Each image is an environment for the HUD agent
226
+ harness. Its default command, `hud serve tasks.py`, serves the task; a harness
227
+ built on the `hud` Python package (each `Dockerfile.hud` pins the version)
228
+ connects to it, lets the agent work in the checkout as UID 1000, and then calls
229
+ the task's grading in the same container as root. `/hud`, which holds the hidden
230
+ tests, the grader and the reference fix, is readable by root only.
231
+
232
+ **Grading without the harness.** In the standard layout (click, sequelize,
233
+ hooks, sickchill, babylonjs, mikro-orm) two functions in `/app/tasks.py` do the
234
+ work: `_setup()` prepares the checkout in `/workspace/repo`, and
235
+ `_grade(mode)` returns the reward and the criteria. With `mode` `"golden"` it
236
+ grades the reference fix; with `None` it grades the changes made to the
237
+ checkout since setup. The results reported below were obtained by running this
238
+ script inside the image, as root and with no network:
239
+
240
+ ```python
241
+ import asyncio, json, sys
242
+ sys.path.insert(0, "/app")
243
+ import tasks
244
+
245
+ async def main():
246
+ await tasks._setup()
247
+ result = await tasks._grade("golden")
248
+ print(json.dumps(result.model_dump(mode="json")))
249
+
250
+ asyncio.run(main())
251
+ ```
252
+
253
+ ```bash
254
+ docker run --rm -i --network none ec-swe-<name>:source-v<n> /opt/hudvenv/bin/python - < script.py
255
+ ```
256
+
257
+ **The tasks**
258
+
259
+ - **click** (`pallets__click-click-help-defaults`, Python, `sources/click-v9`).
260
+ Standard layout. One criterion, `maintainer_review` (6.25 of 100 points), is
261
+ decided by a language model through HUD's gateway, so grading needs
262
+ `HUD_API_KEY` in the container's environment and network access to that
263
+ gateway. When the judge cannot be reached, the task's own code drops that
264
+ criterion, rescales the others and records `judge_errors` in the result. Not
265
+ built or run here.
266
+ - **sequelize** (`sequelize__sequelize-sequelize-bulkcreate-ignore-duplicates`,
267
+ TypeScript, `sources/sequelize-v27`). As click: `maintainer_review` is 6.25
268
+ points. Not built or run here.
269
+ - **hooks** (`alibaba__hooks-ahooks_request_cache_races`, TypeScript,
270
+ `sources/hooks-v4`). As click: `maintainer_review` is 3 points. Not built or
271
+ run here.
272
+ - **druid** (`alibaba__druid-druid_lenient_script`, Java, `sources/druid-v9`).
273
+ As click: `maintainer_review` is 2 points. The layout differs a little: there
274
+ is no `coding/` folder and no `tasks._grade`, the scenario function in
275
+ `tasks.py` does the grading, and the HUD runtime is in `/opt/hudenv`, so the
276
+ script above does not apply. This build context is not byte-identical to the
277
+ original: comments that recorded internal review history were shortened in
278
+ `tasks.py` and `preflight.sh`, and three files the image build does not read
279
+ were removed. `tasks.py` is the same program. Not built or run here.
280
+ - **sickchill**
281
+ (`SickChill__SickChill-sickchill_episode_metadata_files_contract-2e2a49e4`,
282
+ Python, `sources/sickchill-v7`). Builds here; the build, which has network
283
+ access, ends by scoring the reference fix 1.0 and the untouched repository
284
+ 0.0. Graded afterwards with no network, the reference fix scored 0.6: the
285
+ criteria of the fix itself passed (0.97 before the cap), and the gate failed
286
+ because the repository suite it runs includes tests that fetch from
287
+ pypi.org. Grade it with network access, or add those tests to
288
+ `task/grader/suite_deselect.txt`, the task's own list of network-dependent
289
+ tests, and rebuild.
290
+ - **mikro-orm** (`mikro-orm__mikro-orm-mikro-orm-pessimistic-locking`,
291
+ TypeScript, `sources/mikro-orm-v7`, image about 10 GB). Builds here. Graded
292
+ with the script above, the reference fix scored 1.0. Its grader starts
293
+ database servers (PostgreSQL, MySQL, SQL Server), some of them under their
294
+ own accounts with `runuser`, which needs root. The packaged verifier runs
295
+ grader commands as an unprivileged user, which is why there is no package
296
+ yet.
297
+ - **babylonjs**
298
+ (`BabylonJS__Babylon.js-babylonjs_scene_remove_owner_refs_contract-382616f8`,
299
+ TypeScript, `sources/babylonjs-v8`, image about 10 GB). Builds here. Grading
300
+ the reference fix with the script above did not complete on the
301
+ qualification machine (16 CPUs, 31 GB of memory, Docker Desktop on Windows):
302
+ setup changes the owner of the whole dependency tree and ran into its
303
+ 600-second limit twice, and on a third attempt grading had not finished after
304
+ two hours. It may behave on a Linux host with a fast local disk; that has
305
+ not been tried.
306
+ - **aioftp** (`aio-libs__aioftp-aioftp-stream-abort-desynchronization`, Python,
307
+ `sources/aioftp-v11`) and **apscheduler**
308
+ (`agronholm__apscheduler-apscheduler-expired-job-lease`, Python,
309
+ `sources/apscheduler-v17`). A different layout: the checkout is at
310
+ `/home/ubuntu/<name>`, the HUD runtime is in `/hud/.venv`, and grading is the
311
+ function `grading.runner.grade_repository` in `/hud/grading`. The scenarios
312
+ (the task itself, `reference_gold` and `reference_base`) are defined in
313
+ `env.py`; there is no `tasks._grade`, so the script above does not apply.
314
+ Not built or run here.
315
+
316
+ **Packaged, not yet in `tasks/`.** `badger`, `bazel-remote`, `celery`, `geode`, `kratos`, `microblogpub`, `open-xml-sdk`, `openfire`, `terser`, `umya`, `zettlr`: its build files were given a neutral environment name; the package is being rebuilt and re-checked on them.
317
+
harbor/build_images.py ADDED
@@ -0,0 +1,79 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """Build the task source images from this folder.
2
+
3
+ python build_images.py every packaged task
4
+ python build_images.py --task <task id> one task (repeatable)
5
+
6
+ A task without a package is built only when it is named: its id is the short
7
+ name under "unpackaged" in manifest.json (README, "Tasks without a Harbor
8
+ package").
9
+
10
+ Each image is built from the task's original build context under sources/ and
11
+ tagged with the name its Harbor task expects. A build downloads its base image
12
+ and the repository's dependencies, so it needs network access; nothing is
13
+ downloaded when tasks run. Most builds end with the task's own calibration:
14
+ the reference fix must score 1.0 and the untouched repository 0.0 or the image
15
+ is not produced. Expect ten to forty minutes and several gigabytes per task.
16
+
17
+ The images were qualified from build contexts in which every file had mode 777
18
+ (a Windows disk seen from Linux), and some images keep the modes of files they
19
+ copy. A download gives files mode 644. So that your images match the qualified
20
+ ones, each build runs from a temporary copy of the context with mode 777; the
21
+ files under sources/ are left as they are.
22
+ """
23
+
24
+ import argparse
25
+ import json
26
+ import os
27
+ import shutil
28
+ import subprocess
29
+ import tempfile
30
+ import time
31
+ from pathlib import Path
32
+
33
+ parser = argparse.ArgumentParser(description=__doc__, formatter_class=argparse.RawDescriptionHelpFormatter)
34
+ parser.add_argument("--task", action="append", default=[])
35
+ parser.add_argument("--docker-context")
36
+ args = parser.parse_args()
37
+ root = Path(__file__).resolve().parent
38
+ manifest = json.loads((root / "manifest.json").read_text())
39
+ context = args.docker_context or ("desktop-linux" if os.name == "nt" else None)
40
+ docker = ["docker", *(["--context", context] if context else [])]
41
+ known = {task["task_id"]: task for task in manifest["tasks"]}
42
+ extra = {task["task_id"]: task for task in manifest.get("unpackaged", []) if task["source_folder"]}
43
+ unknown = [name for name in args.task if name not in known and name not in extra]
44
+ if unknown:
45
+ raise SystemExit("Unknown task: " + ", ".join(unknown) + ". See manifest.json.")
46
+ known.update({name: extra[name] for name in args.task if name in extra})
47
+ logs = root / "build-logs"
48
+ logs.mkdir(exist_ok=True)
49
+ built = {}
50
+ for task_id, task in known.items():
51
+ if args.task and task_id not in args.task:
52
+ continue
53
+ source = root / "sources" / task["source_folder"]
54
+ scratch = None
55
+ if os.name != "nt":
56
+ scratch = Path(tempfile.mkdtemp(prefix="ec-swe-build-"))
57
+ source = Path(shutil.copytree(source, scratch / source.name))
58
+ for path in [source, *source.rglob("*")]:
59
+ path.chmod(0o777)
60
+ log = logs / f"{task_id}.log"
61
+ started = time.time()
62
+ print(f"building {task['source_image']} (log: {log.relative_to(root)})", flush=True)
63
+ with log.open("wb") as handle:
64
+ code = subprocess.run(
65
+ [*docker, "build", "--progress=plain", "-f", str(source / task["dockerfile"]),
66
+ "-t", task["source_image"], str(source)],
67
+ stdout=handle, stderr=subprocess.STDOUT,
68
+ ).returncode
69
+ if scratch:
70
+ shutil.rmtree(scratch, ignore_errors=True)
71
+ if code:
72
+ raise SystemExit(f"Build failed for {task_id}; see {log}")
73
+ image_id = subprocess.check_output(
74
+ [*docker, "image", "inspect", task["source_image"], "--format", "{{.Id}}"], text=True
75
+ ).strip()
76
+ built[task_id] = {"image": task["source_image"], "id": image_id, "seconds": round(time.time() - started)}
77
+ print(f" done in {built[task_id]['seconds']}s: {image_id}", flush=True)
78
+ (root / "built-images.json").write_text(json.dumps(built, indent=2) + "\n")
79
+ print(f"Built {len(built)} task image(s)")
harbor/checksums.json ADDED
The diff for this file is too large to render. See raw diff
 
harbor/evidence/coredns/agent-image-scan.txt ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ needles: 71
2
+ 1 matching line(s): /workspace/repo/plugin/rewrite/ttl_test.go
3
+ scan finished
4
+ absent: /hud
5
+ absent: /app
6
+ absent: /tests
7
+ present: /opt/task-tools/baseline.git
8
+ reference-patch lines in the agent's tracked files: 0, of which the pristine checkout lacks: 0
9
+ grader lines in the agent's tracked files: 1, of which the pristine checkout lacks: 0
10
+ reference-patch lines in total: 9, grader lines in total: 60
11
+ private lines in 0 other files outside the checkout: 0, of which upstream lacks: 0
12
+ --- private lines only the agent's checkout holds (expect none)
13
+ --- the agent's checkout: uncommitted changes (expect none), then its history
14
+ b21e6b7 baseline
harbor/evidence/coredns/native-reference.json ADDED
@@ -0,0 +1,121 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "reward": 1.0,
3
+ "done": true,
4
+ "content": null,
5
+ "info": {},
6
+ "isError": false,
7
+ "subscores": [
8
+ {
9
+ "name": "svcb_target_rewrite",
10
+ "weight": 0.25,
11
+ "value": 1.0,
12
+ "children": null,
13
+ "info": {
14
+ "exit_code": 0,
15
+ "stdout": "CRITERION svcb_target_rewrite: PASS\n",
16
+ "stderr": "",
17
+ "_parameters": {
18
+ "command": "bash /hud/grader/run_grading.sh svcb_target_rewrite",
19
+ "cwd": "/workspace/repo",
20
+ "timeout_seconds": 90
21
+ }
22
+ }
23
+ },
24
+ {
25
+ "name": "https_target_rewrite",
26
+ "weight": 0.2,
27
+ "value": 1.0,
28
+ "children": null,
29
+ "info": {
30
+ "exit_code": 0,
31
+ "stdout": "CRITERION https_target_rewrite: PASS\n",
32
+ "stderr": "",
33
+ "_parameters": {
34
+ "command": "bash /hud/grader/run_grading.sh https_target_rewrite",
35
+ "cwd": "/workspace/repo",
36
+ "timeout_seconds": 90
37
+ }
38
+ }
39
+ },
40
+ {
41
+ "name": "soa_mailbox_rewrite",
42
+ "weight": 0.3,
43
+ "value": 1.0,
44
+ "children": null,
45
+ "info": {
46
+ "exit_code": 0,
47
+ "stdout": "CRITERION soa_mailbox_rewrite: PASS\n",
48
+ "stderr": "",
49
+ "_parameters": {
50
+ "command": "bash /hud/grader/run_grading.sh soa_mailbox_rewrite",
51
+ "cwd": "/workspace/repo",
52
+ "timeout_seconds": 90
53
+ }
54
+ }
55
+ },
56
+ {
57
+ "name": "opt_ttl_preserved",
58
+ "weight": 0.25,
59
+ "value": 1.0,
60
+ "children": null,
61
+ "info": {
62
+ "exit_code": 0,
63
+ "stdout": "CRITERION opt_ttl_preserved: PASS\n",
64
+ "stderr": "",
65
+ "_parameters": {
66
+ "command": "bash /hud/grader/run_grading.sh opt_ttl_preserved",
67
+ "cwd": "/workspace/repo",
68
+ "timeout_seconds": 90
69
+ }
70
+ }
71
+ },
72
+ {
73
+ "name": "existing_name_value_rewrite_unaffected",
74
+ "weight": 0.0,
75
+ "value": 1.0,
76
+ "children": null,
77
+ "info": {
78
+ "exit_code": 0,
79
+ "stdout": "CRITERION existing_name_value_rewrite_unaffected: PASS\n",
80
+ "stderr": "",
81
+ "_parameters": {
82
+ "command": "bash /hud/grader/run_grading.sh existing_name_value_rewrite_unaffected",
83
+ "cwd": "/workspace/repo",
84
+ "timeout_seconds": 90
85
+ }
86
+ }
87
+ },
88
+ {
89
+ "name": "ordinary_ttl_clamp_unaffected",
90
+ "weight": 0.0,
91
+ "value": 1.0,
92
+ "children": null,
93
+ "info": {
94
+ "exit_code": 0,
95
+ "stdout": "CRITERION ordinary_ttl_clamp_unaffected: PASS\n",
96
+ "stderr": "",
97
+ "_parameters": {
98
+ "command": "bash /hud/grader/run_grading.sh ordinary_ttl_clamp_unaffected",
99
+ "cwd": "/workspace/repo",
100
+ "timeout_seconds": 90
101
+ }
102
+ }
103
+ },
104
+ {
105
+ "name": "full_suite_regression",
106
+ "weight": 0.0,
107
+ "value": 1.0,
108
+ "children": null,
109
+ "info": {
110
+ "exit_code": 0,
111
+ "stdout": "CRITERION full_suite_regression: PASS\n",
112
+ "stderr": "",
113
+ "_parameters": {
114
+ "command": "bash /hud/grader/run_grading.sh full_suite_regression",
115
+ "cwd": "/workspace/repo",
116
+ "timeout_seconds": 180
117
+ }
118
+ }
119
+ }
120
+ ]
121
+ }
harbor/evidence/coredns/reports/broken.json ADDED
@@ -0,0 +1,242 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "revision": "coding-rubric-v2",
3
+ "task_id": "coredns_rewrite_svcb_opt",
4
+ "grader_version": "0.6.18",
5
+ "commands": [
6
+ {
7
+ "name": "svcb_target_rewrite",
8
+ "weight": 0.25,
9
+ "value": 0.0,
10
+ "children": null,
11
+ "info": {
12
+ "exit_code": 1,
13
+ "stdout": " ----- go test -run ^TestSVCBTargetRewrittenBySuffixAutoAnswerRule$ -v ./plugin/rewrite/... (last 2000 bytes) -----\n | # github.com/coredns/coredns/plugin/rewrite [github.com/coredns/coredns/plugin/rewrite.test]\n | plugin/rewrite/name.go:466:1: syntax error: non-declaration statement outside function body\n | FAIL\tgithub.com/coredns/coredns/plugin/rewrite [build failed]\n | FAIL\n -----\nCRITERION svcb_target_rewrite: FAIL\n",
14
+ "stderr": "",
15
+ "_parameters": {
16
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh svcb_target_rewrite'",
17
+ "cwd": "/workspace/repo",
18
+ "timeout_seconds": 90
19
+ }
20
+ }
21
+ },
22
+ {
23
+ "name": "https_target_rewrite",
24
+ "weight": 0.2,
25
+ "value": 0.0,
26
+ "children": null,
27
+ "info": {
28
+ "exit_code": 1,
29
+ "stdout": " ----- go test -run ^TestHTTPSTargetRewrittenBySuffixAutoAnswerRule$ -v ./plugin/rewrite/... (last 2000 bytes) -----\n | # github.com/coredns/coredns/plugin/rewrite [github.com/coredns/coredns/plugin/rewrite.test]\n | plugin/rewrite/name.go:466:1: syntax error: non-declaration statement outside function body\n | FAIL\tgithub.com/coredns/coredns/plugin/rewrite [build failed]\n | FAIL\n -----\nCRITERION https_target_rewrite: FAIL\n",
30
+ "stderr": "",
31
+ "_parameters": {
32
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh https_target_rewrite'",
33
+ "cwd": "/workspace/repo",
34
+ "timeout_seconds": 90
35
+ }
36
+ }
37
+ },
38
+ {
39
+ "name": "soa_mailbox_rewrite",
40
+ "weight": 0.3,
41
+ "value": 0.0,
42
+ "children": null,
43
+ "info": {
44
+ "exit_code": 1,
45
+ "stdout": " ----- go test -run ^TestSOAMailboxRewrittenBySuffixAutoAnswerRule$ -v ./plugin/rewrite/... (last 2000 bytes) -----\n | # github.com/coredns/coredns/plugin/rewrite [github.com/coredns/coredns/plugin/rewrite.test]\n | plugin/rewrite/name.go:466:1: syntax error: non-declaration statement outside function body\n | FAIL\tgithub.com/coredns/coredns/plugin/rewrite [build failed]\n | FAIL\n -----\nCRITERION soa_mailbox_rewrite: FAIL\n",
46
+ "stderr": "",
47
+ "_parameters": {
48
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh soa_mailbox_rewrite'",
49
+ "cwd": "/workspace/repo",
50
+ "timeout_seconds": 90
51
+ }
52
+ }
53
+ },
54
+ {
55
+ "name": "opt_ttl_preserved",
56
+ "weight": 0.25,
57
+ "value": 0.0,
58
+ "children": null,
59
+ "info": {
60
+ "exit_code": 1,
61
+ "stdout": " ----- go test -run ^TestTTLRuleDoesNotClampOPTPseudoRecord$ -v ./plugin/rewrite/... (last 2000 bytes) -----\n | # github.com/coredns/coredns/plugin/rewrite [github.com/coredns/coredns/plugin/rewrite.test]\n | plugin/rewrite/name.go:466:1: syntax error: non-declaration statement outside function body\n | FAIL\tgithub.com/coredns/coredns/plugin/rewrite [build failed]\n | FAIL\n -----\nCRITERION opt_ttl_preserved: FAIL\n",
62
+ "stderr": "",
63
+ "_parameters": {
64
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh opt_ttl_preserved'",
65
+ "cwd": "/workspace/repo",
66
+ "timeout_seconds": 90
67
+ }
68
+ }
69
+ },
70
+ {
71
+ "name": "existing_name_value_rewrite_unaffected",
72
+ "weight": 0.0,
73
+ "value": 0.0,
74
+ "children": null,
75
+ "info": {
76
+ "exit_code": 1,
77
+ "stdout": " ----- go test -run ^TestValueResponseReverter$ -v ./plugin/rewrite/... (last 2000 bytes) -----\n | # github.com/coredns/coredns/plugin/rewrite [github.com/coredns/coredns/plugin/rewrite.test]\n | plugin/rewrite/name.go:466:1: syntax error: non-declaration statement outside function body\n | FAIL\tgithub.com/coredns/coredns/plugin/rewrite [build failed]\n | FAIL\n -----\nCRITERION existing_name_value_rewrite_unaffected: FAIL\n",
78
+ "stderr": "",
79
+ "_parameters": {
80
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh existing_name_value_rewrite_unaffected'",
81
+ "cwd": "/workspace/repo",
82
+ "timeout_seconds": 90
83
+ }
84
+ }
85
+ },
86
+ {
87
+ "name": "ordinary_ttl_clamp_unaffected",
88
+ "weight": 0.0,
89
+ "value": 0.0,
90
+ "children": null,
91
+ "info": {
92
+ "exit_code": 1,
93
+ "stdout": " ----- go test -run ^TestTtlRewrite$ -v ./plugin/rewrite/... (last 2000 bytes) -----\n | # github.com/coredns/coredns/plugin/rewrite [github.com/coredns/coredns/plugin/rewrite.test]\n | plugin/rewrite/name.go:466:1: syntax error: non-declaration statement outside function body\n | FAIL\tgithub.com/coredns/coredns/plugin/rewrite [build failed]\n | FAIL\n -----\nCRITERION ordinary_ttl_clamp_unaffected: FAIL\n",
94
+ "stderr": "",
95
+ "_parameters": {
96
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh ordinary_ttl_clamp_unaffected'",
97
+ "cwd": "/workspace/repo",
98
+ "timeout_seconds": 90
99
+ }
100
+ }
101
+ },
102
+ {
103
+ "name": "full_suite_regression",
104
+ "weight": 0.0,
105
+ "value": 0.0,
106
+ "children": null,
107
+ "info": {
108
+ "exit_code": 1,
109
+ "stdout": " ----- go test ./plugin/rewrite/... (last 2000 bytes) -----\n | # github.com/coredns/coredns/plugin/rewrite [github.com/coredns/coredns/plugin/rewrite.test]\n | plugin/rewrite/name.go:466:1: syntax error: non-declaration statement outside function body\n | FAIL\tgithub.com/coredns/coredns/plugin/rewrite [build failed]\n | FAIL\n -----\nCRITERION full_suite_regression: FAIL\n",
110
+ "stderr": "",
111
+ "_parameters": {
112
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh full_suite_regression'",
113
+ "cwd": "/workspace/repo",
114
+ "timeout_seconds": 180
115
+ }
116
+ }
117
+ }
118
+ ],
119
+ "status": "graded",
120
+ "patch_sha256": "aa144710c3f317d2e0d59de1514c2759ce4f896e3838d8bd45b9d21200843de8",
121
+ "result": {
122
+ "reward": 0.0,
123
+ "done": true,
124
+ "content": null,
125
+ "info": {},
126
+ "isError": false,
127
+ "subscores": [
128
+ {
129
+ "name": "svcb_target_rewrite",
130
+ "weight": 0.25,
131
+ "value": 0.0,
132
+ "children": null,
133
+ "info": {
134
+ "exit_code": 1,
135
+ "stdout": " ----- go test -run ^TestSVCBTargetRewrittenBySuffixAutoAnswerRule$ -v ./plugin/rewrite/... (last 2000 bytes) -----\n | # github.com/coredns/coredns/plugin/rewrite [github.com/coredns/coredns/plugin/rewrite.test]\n | plugin/rewrite/name.go:466:1: syntax error: non-declaration statement outside function body\n | FAIL\tgithub.com/coredns/coredns/plugin/rewrite [build failed]\n | FAIL\n -----\nCRITERION svcb_target_rewrite: FAIL\n",
136
+ "stderr": "",
137
+ "_parameters": {
138
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh svcb_target_rewrite'",
139
+ "cwd": "/workspace/repo",
140
+ "timeout_seconds": 90
141
+ }
142
+ }
143
+ },
144
+ {
145
+ "name": "https_target_rewrite",
146
+ "weight": 0.2,
147
+ "value": 0.0,
148
+ "children": null,
149
+ "info": {
150
+ "exit_code": 1,
151
+ "stdout": " ----- go test -run ^TestHTTPSTargetRewrittenBySuffixAutoAnswerRule$ -v ./plugin/rewrite/... (last 2000 bytes) -----\n | # github.com/coredns/coredns/plugin/rewrite [github.com/coredns/coredns/plugin/rewrite.test]\n | plugin/rewrite/name.go:466:1: syntax error: non-declaration statement outside function body\n | FAIL\tgithub.com/coredns/coredns/plugin/rewrite [build failed]\n | FAIL\n -----\nCRITERION https_target_rewrite: FAIL\n",
152
+ "stderr": "",
153
+ "_parameters": {
154
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh https_target_rewrite'",
155
+ "cwd": "/workspace/repo",
156
+ "timeout_seconds": 90
157
+ }
158
+ }
159
+ },
160
+ {
161
+ "name": "soa_mailbox_rewrite",
162
+ "weight": 0.3,
163
+ "value": 0.0,
164
+ "children": null,
165
+ "info": {
166
+ "exit_code": 1,
167
+ "stdout": " ----- go test -run ^TestSOAMailboxRewrittenBySuffixAutoAnswerRule$ -v ./plugin/rewrite/... (last 2000 bytes) -----\n | # github.com/coredns/coredns/plugin/rewrite [github.com/coredns/coredns/plugin/rewrite.test]\n | plugin/rewrite/name.go:466:1: syntax error: non-declaration statement outside function body\n | FAIL\tgithub.com/coredns/coredns/plugin/rewrite [build failed]\n | FAIL\n -----\nCRITERION soa_mailbox_rewrite: FAIL\n",
168
+ "stderr": "",
169
+ "_parameters": {
170
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh soa_mailbox_rewrite'",
171
+ "cwd": "/workspace/repo",
172
+ "timeout_seconds": 90
173
+ }
174
+ }
175
+ },
176
+ {
177
+ "name": "opt_ttl_preserved",
178
+ "weight": 0.25,
179
+ "value": 0.0,
180
+ "children": null,
181
+ "info": {
182
+ "exit_code": 1,
183
+ "stdout": " ----- go test -run ^TestTTLRuleDoesNotClampOPTPseudoRecord$ -v ./plugin/rewrite/... (last 2000 bytes) -----\n | # github.com/coredns/coredns/plugin/rewrite [github.com/coredns/coredns/plugin/rewrite.test]\n | plugin/rewrite/name.go:466:1: syntax error: non-declaration statement outside function body\n | FAIL\tgithub.com/coredns/coredns/plugin/rewrite [build failed]\n | FAIL\n -----\nCRITERION opt_ttl_preserved: FAIL\n",
184
+ "stderr": "",
185
+ "_parameters": {
186
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh opt_ttl_preserved'",
187
+ "cwd": "/workspace/repo",
188
+ "timeout_seconds": 90
189
+ }
190
+ }
191
+ },
192
+ {
193
+ "name": "existing_name_value_rewrite_unaffected",
194
+ "weight": 0.0,
195
+ "value": 0.0,
196
+ "children": null,
197
+ "info": {
198
+ "exit_code": 1,
199
+ "stdout": " ----- go test -run ^TestValueResponseReverter$ -v ./plugin/rewrite/... (last 2000 bytes) -----\n | # github.com/coredns/coredns/plugin/rewrite [github.com/coredns/coredns/plugin/rewrite.test]\n | plugin/rewrite/name.go:466:1: syntax error: non-declaration statement outside function body\n | FAIL\tgithub.com/coredns/coredns/plugin/rewrite [build failed]\n | FAIL\n -----\nCRITERION existing_name_value_rewrite_unaffected: FAIL\n",
200
+ "stderr": "",
201
+ "_parameters": {
202
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh existing_name_value_rewrite_unaffected'",
203
+ "cwd": "/workspace/repo",
204
+ "timeout_seconds": 90
205
+ }
206
+ }
207
+ },
208
+ {
209
+ "name": "ordinary_ttl_clamp_unaffected",
210
+ "weight": 0.0,
211
+ "value": 0.0,
212
+ "children": null,
213
+ "info": {
214
+ "exit_code": 1,
215
+ "stdout": " ----- go test -run ^TestTtlRewrite$ -v ./plugin/rewrite/... (last 2000 bytes) -----\n | # github.com/coredns/coredns/plugin/rewrite [github.com/coredns/coredns/plugin/rewrite.test]\n | plugin/rewrite/name.go:466:1: syntax error: non-declaration statement outside function body\n | FAIL\tgithub.com/coredns/coredns/plugin/rewrite [build failed]\n | FAIL\n -----\nCRITERION ordinary_ttl_clamp_unaffected: FAIL\n",
216
+ "stderr": "",
217
+ "_parameters": {
218
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh ordinary_ttl_clamp_unaffected'",
219
+ "cwd": "/workspace/repo",
220
+ "timeout_seconds": 90
221
+ }
222
+ }
223
+ },
224
+ {
225
+ "name": "full_suite_regression",
226
+ "weight": 0.0,
227
+ "value": 0.0,
228
+ "children": null,
229
+ "info": {
230
+ "exit_code": 1,
231
+ "stdout": " ----- go test ./plugin/rewrite/... (last 2000 bytes) -----\n | # github.com/coredns/coredns/plugin/rewrite [github.com/coredns/coredns/plugin/rewrite.test]\n | plugin/rewrite/name.go:466:1: syntax error: non-declaration statement outside function body\n | FAIL\tgithub.com/coredns/coredns/plugin/rewrite [build failed]\n | FAIL\n -----\nCRITERION full_suite_regression: FAIL\n",
232
+ "stderr": "",
233
+ "_parameters": {
234
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh full_suite_regression'",
235
+ "cwd": "/workspace/repo",
236
+ "timeout_seconds": 180
237
+ }
238
+ }
239
+ }
240
+ ]
241
+ }
242
+ }
harbor/evidence/coredns/reports/infra.json ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "revision": "coding-rubric-v2",
3
+ "task_id": "coredns_rewrite_svcb_opt",
4
+ "grader_version": "0.6.18",
5
+ "commands": [],
6
+ "status": "error",
7
+ "patch_sha256": "51f9168417f7ef7d6b8793dcf746d6bf88df29ce28a191190f08f39260727ae7",
8
+ "error": {
9
+ "type": "FileNotFoundError",
10
+ "message": "[Errno 2] No such file or directory: '/hud/grader/run_grading.sh'"
11
+ }
12
+ }
harbor/evidence/coredns/reports/noop.json ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "revision": "coding-rubric-v2",
3
+ "task_id": "coredns_rewrite_svcb_opt",
4
+ "grader_version": "0.6.18",
5
+ "commands": [],
6
+ "status": "empty_patch",
7
+ "patch_sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
8
+ "result": {
9
+ "reward": 0.0,
10
+ "done": true,
11
+ "content": "Empty diff: no changes were made.",
12
+ "info": {},
13
+ "isError": false,
14
+ "subscores": null
15
+ }
16
+ }
harbor/evidence/coredns/reports/reference.json ADDED
@@ -0,0 +1,242 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "revision": "coding-rubric-v2",
3
+ "task_id": "coredns_rewrite_svcb_opt",
4
+ "grader_version": "0.6.18",
5
+ "commands": [
6
+ {
7
+ "name": "svcb_target_rewrite",
8
+ "weight": 0.25,
9
+ "value": 1.0,
10
+ "children": null,
11
+ "info": {
12
+ "exit_code": 0,
13
+ "stdout": "CRITERION svcb_target_rewrite: PASS\n",
14
+ "stderr": "",
15
+ "_parameters": {
16
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh svcb_target_rewrite'",
17
+ "cwd": "/workspace/repo",
18
+ "timeout_seconds": 90
19
+ }
20
+ }
21
+ },
22
+ {
23
+ "name": "https_target_rewrite",
24
+ "weight": 0.2,
25
+ "value": 1.0,
26
+ "children": null,
27
+ "info": {
28
+ "exit_code": 0,
29
+ "stdout": "CRITERION https_target_rewrite: PASS\n",
30
+ "stderr": "",
31
+ "_parameters": {
32
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh https_target_rewrite'",
33
+ "cwd": "/workspace/repo",
34
+ "timeout_seconds": 90
35
+ }
36
+ }
37
+ },
38
+ {
39
+ "name": "soa_mailbox_rewrite",
40
+ "weight": 0.3,
41
+ "value": 1.0,
42
+ "children": null,
43
+ "info": {
44
+ "exit_code": 0,
45
+ "stdout": "CRITERION soa_mailbox_rewrite: PASS\n",
46
+ "stderr": "",
47
+ "_parameters": {
48
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh soa_mailbox_rewrite'",
49
+ "cwd": "/workspace/repo",
50
+ "timeout_seconds": 90
51
+ }
52
+ }
53
+ },
54
+ {
55
+ "name": "opt_ttl_preserved",
56
+ "weight": 0.25,
57
+ "value": 1.0,
58
+ "children": null,
59
+ "info": {
60
+ "exit_code": 0,
61
+ "stdout": "CRITERION opt_ttl_preserved: PASS\n",
62
+ "stderr": "",
63
+ "_parameters": {
64
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh opt_ttl_preserved'",
65
+ "cwd": "/workspace/repo",
66
+ "timeout_seconds": 90
67
+ }
68
+ }
69
+ },
70
+ {
71
+ "name": "existing_name_value_rewrite_unaffected",
72
+ "weight": 0.0,
73
+ "value": 1.0,
74
+ "children": null,
75
+ "info": {
76
+ "exit_code": 0,
77
+ "stdout": "CRITERION existing_name_value_rewrite_unaffected: PASS\n",
78
+ "stderr": "",
79
+ "_parameters": {
80
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh existing_name_value_rewrite_unaffected'",
81
+ "cwd": "/workspace/repo",
82
+ "timeout_seconds": 90
83
+ }
84
+ }
85
+ },
86
+ {
87
+ "name": "ordinary_ttl_clamp_unaffected",
88
+ "weight": 0.0,
89
+ "value": 1.0,
90
+ "children": null,
91
+ "info": {
92
+ "exit_code": 0,
93
+ "stdout": "CRITERION ordinary_ttl_clamp_unaffected: PASS\n",
94
+ "stderr": "",
95
+ "_parameters": {
96
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh ordinary_ttl_clamp_unaffected'",
97
+ "cwd": "/workspace/repo",
98
+ "timeout_seconds": 90
99
+ }
100
+ }
101
+ },
102
+ {
103
+ "name": "full_suite_regression",
104
+ "weight": 0.0,
105
+ "value": 1.0,
106
+ "children": null,
107
+ "info": {
108
+ "exit_code": 0,
109
+ "stdout": "CRITERION full_suite_regression: PASS\n",
110
+ "stderr": "",
111
+ "_parameters": {
112
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh full_suite_regression'",
113
+ "cwd": "/workspace/repo",
114
+ "timeout_seconds": 180
115
+ }
116
+ }
117
+ }
118
+ ],
119
+ "status": "graded",
120
+ "patch_sha256": "51f9168417f7ef7d6b8793dcf746d6bf88df29ce28a191190f08f39260727ae7",
121
+ "result": {
122
+ "reward": 1.0,
123
+ "done": true,
124
+ "content": null,
125
+ "info": {},
126
+ "isError": false,
127
+ "subscores": [
128
+ {
129
+ "name": "svcb_target_rewrite",
130
+ "weight": 0.25,
131
+ "value": 1.0,
132
+ "children": null,
133
+ "info": {
134
+ "exit_code": 0,
135
+ "stdout": "CRITERION svcb_target_rewrite: PASS\n",
136
+ "stderr": "",
137
+ "_parameters": {
138
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh svcb_target_rewrite'",
139
+ "cwd": "/workspace/repo",
140
+ "timeout_seconds": 90
141
+ }
142
+ }
143
+ },
144
+ {
145
+ "name": "https_target_rewrite",
146
+ "weight": 0.2,
147
+ "value": 1.0,
148
+ "children": null,
149
+ "info": {
150
+ "exit_code": 0,
151
+ "stdout": "CRITERION https_target_rewrite: PASS\n",
152
+ "stderr": "",
153
+ "_parameters": {
154
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh https_target_rewrite'",
155
+ "cwd": "/workspace/repo",
156
+ "timeout_seconds": 90
157
+ }
158
+ }
159
+ },
160
+ {
161
+ "name": "soa_mailbox_rewrite",
162
+ "weight": 0.3,
163
+ "value": 1.0,
164
+ "children": null,
165
+ "info": {
166
+ "exit_code": 0,
167
+ "stdout": "CRITERION soa_mailbox_rewrite: PASS\n",
168
+ "stderr": "",
169
+ "_parameters": {
170
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh soa_mailbox_rewrite'",
171
+ "cwd": "/workspace/repo",
172
+ "timeout_seconds": 90
173
+ }
174
+ }
175
+ },
176
+ {
177
+ "name": "opt_ttl_preserved",
178
+ "weight": 0.25,
179
+ "value": 1.0,
180
+ "children": null,
181
+ "info": {
182
+ "exit_code": 0,
183
+ "stdout": "CRITERION opt_ttl_preserved: PASS\n",
184
+ "stderr": "",
185
+ "_parameters": {
186
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh opt_ttl_preserved'",
187
+ "cwd": "/workspace/repo",
188
+ "timeout_seconds": 90
189
+ }
190
+ }
191
+ },
192
+ {
193
+ "name": "existing_name_value_rewrite_unaffected",
194
+ "weight": 0.0,
195
+ "value": 1.0,
196
+ "children": null,
197
+ "info": {
198
+ "exit_code": 0,
199
+ "stdout": "CRITERION existing_name_value_rewrite_unaffected: PASS\n",
200
+ "stderr": "",
201
+ "_parameters": {
202
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh existing_name_value_rewrite_unaffected'",
203
+ "cwd": "/workspace/repo",
204
+ "timeout_seconds": 90
205
+ }
206
+ }
207
+ },
208
+ {
209
+ "name": "ordinary_ttl_clamp_unaffected",
210
+ "weight": 0.0,
211
+ "value": 1.0,
212
+ "children": null,
213
+ "info": {
214
+ "exit_code": 0,
215
+ "stdout": "CRITERION ordinary_ttl_clamp_unaffected: PASS\n",
216
+ "stderr": "",
217
+ "_parameters": {
218
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh ordinary_ttl_clamp_unaffected'",
219
+ "cwd": "/workspace/repo",
220
+ "timeout_seconds": 90
221
+ }
222
+ }
223
+ },
224
+ {
225
+ "name": "full_suite_regression",
226
+ "weight": 0.0,
227
+ "value": 1.0,
228
+ "children": null,
229
+ "info": {
230
+ "exit_code": 0,
231
+ "stdout": "CRITERION full_suite_regression: PASS\n",
232
+ "stderr": "",
233
+ "_parameters": {
234
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh full_suite_regression'",
235
+ "cwd": "/workspace/repo",
236
+ "timeout_seconds": 180
237
+ }
238
+ }
239
+ }
240
+ ]
241
+ }
242
+ }
harbor/evidence/coredns/reports/tamper.json ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "revision": "coding-rubric-v2",
3
+ "task_id": "coredns_rewrite_svcb_opt",
4
+ "grader_version": "0.6.18",
5
+ "commands": [],
6
+ "status": "empty_patch",
7
+ "patch_sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
8
+ "result": {
9
+ "reward": 0.0,
10
+ "done": true,
11
+ "content": "Empty diff: no changes were made.",
12
+ "info": {},
13
+ "isError": false,
14
+ "subscores": null
15
+ }
16
+ }
harbor/evidence/coredns/summary.json ADDED
@@ -0,0 +1,172 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "name": "coredns",
3
+ "task_id": "coredns_rewrite_svcb_opt",
4
+ "image": "ec-swe-coredns:source-v4",
5
+ "build": {
6
+ "ok": true,
7
+ "image_id": "sha256:5f122f58a039aefe65ccf2fd057eceb288c09278edde20f2ff0f2598f52c22e9",
8
+ "ladder": {},
9
+ "seconds": 0
10
+ },
11
+ "qualified": true,
12
+ "measure": {
13
+ "ok": true,
14
+ "hud": "0.6.18",
15
+ "path": "/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games",
16
+ "handed": [],
17
+ "repo_dir": "/workspace/repo",
18
+ "python_usr_local": false,
19
+ "seconds": 14,
20
+ "reused": true
21
+ },
22
+ "parity": {
23
+ "ok": true,
24
+ "reward": 1.0,
25
+ "criteria": 7,
26
+ "unmet": [],
27
+ "info": null,
28
+ "seconds": 25,
29
+ "reused": true
30
+ },
31
+ "prepare": {
32
+ "ok": true,
33
+ "bundle": "coredns-r4",
34
+ "converter": "b8bba68767da888f",
35
+ "pinned_files": 9,
36
+ "criteria": 7,
37
+ "seconds": 2
38
+ },
39
+ "controls": {
40
+ "ok": true,
41
+ "checks": {
42
+ "noop_is_zero": true,
43
+ "reference_is_one": true,
44
+ "reference_equals_native": true,
45
+ "broken_is_graded_zero": true,
46
+ "missing_grader_is_invalid": true,
47
+ "agent_is_isolated": true,
48
+ "planted_reward_is_ignored": true
49
+ },
50
+ "results": {
51
+ "noop": {
52
+ "run": "coredns-r4-control-noop-1791885502",
53
+ "reward": 0.0,
54
+ "stop": "completed",
55
+ "error": null,
56
+ "seconds": 175,
57
+ "probe": false,
58
+ "status": "empty_patch",
59
+ "verifier_error": null,
60
+ "exit_codes": [],
61
+ "attempts": 1
62
+ },
63
+ "reference": {
64
+ "run": "coredns-r4-control-reference-1791885502",
65
+ "reward": 1.0,
66
+ "stop": "completed",
67
+ "error": null,
68
+ "seconds": 185,
69
+ "probe": true,
70
+ "status": "graded",
71
+ "verifier_error": null,
72
+ "exit_codes": [
73
+ 0
74
+ ],
75
+ "subscores": {
76
+ "svcb_target_rewrite": [
77
+ 1.0,
78
+ 0.25
79
+ ],
80
+ "https_target_rewrite": [
81
+ 1.0,
82
+ 0.2
83
+ ],
84
+ "soa_mailbox_rewrite": [
85
+ 1.0,
86
+ 0.3
87
+ ],
88
+ "opt_ttl_preserved": [
89
+ 1.0,
90
+ 0.25
91
+ ],
92
+ "existing_name_value_rewrite_unaffected": [
93
+ 1.0,
94
+ 0.0
95
+ ],
96
+ "ordinary_ttl_clamp_unaffected": [
97
+ 1.0,
98
+ 0.0
99
+ ],
100
+ "full_suite_regression": [
101
+ 1.0,
102
+ 0.0
103
+ ]
104
+ },
105
+ "attempts": 1
106
+ },
107
+ "broken": {
108
+ "run": "coredns-r4-control-broken-1791885678",
109
+ "reward": 0.0,
110
+ "stop": "completed",
111
+ "error": null,
112
+ "seconds": 111,
113
+ "probe": false,
114
+ "status": "graded",
115
+ "verifier_error": null,
116
+ "exit_codes": [
117
+ 1
118
+ ],
119
+ "attempts": 1
120
+ },
121
+ "infra": {
122
+ "run": "coredns-r4-control-infra-1791885688",
123
+ "reward": null,
124
+ "stop": "error",
125
+ "error": "RewardFileNotFoundError: No reward file found at <jobs>/jobs/coredns-r4-control-infra-1791885688/coredns_rewrite_svcb_opt__8gHWTyF/verifier/reward.txt or <jobs>/jobs/coredns-r4-control-infra-1791885688/coredns_rewrite_svcb_opt__8gHWTyF/verifier/reward.json",
126
+ "seconds": 92,
127
+ "probe": false,
128
+ "status": "error",
129
+ "verifier_error": "[Errno 2] No such file or directory: '/hud/grader/run_grading.sh'",
130
+ "exit_codes": [],
131
+ "attempts": 1
132
+ },
133
+ "tamper": {
134
+ "run": "coredns-r4-control-tamper-1791885780",
135
+ "reward": 0.0,
136
+ "stop": "completed",
137
+ "error": null,
138
+ "seconds": 104,
139
+ "probe": false,
140
+ "status": "empty_patch",
141
+ "verifier_error": null,
142
+ "exit_codes": [],
143
+ "attempts": 1
144
+ }
145
+ },
146
+ "bundle": "coredns-r4",
147
+ "seconds": 383
148
+ },
149
+ "patches": {
150
+ "ok": true,
151
+ "skipped": "no calibration patches in the source",
152
+ "seconds": 0
153
+ },
154
+ "leak": {
155
+ "scan_finished": true,
156
+ "hits_outside_checkout": [],
157
+ "other_files_holding_only_upstream_lines": 0,
158
+ "library_files_sharing_a_line": 0,
159
+ "most_lines_shared_by_one_library_file": 0,
160
+ "private_paths_absent": true,
161
+ "public_lines_shared_with_patch_and_graders": [
162
+ 0,
163
+ 1
164
+ ],
165
+ "private_lines_only_in_agent_checkout": [
166
+ 0,
167
+ 0
168
+ ],
169
+ "ok": true,
170
+ "seconds": 31
171
+ }
172
+ }
harbor/evidence/epicyon/agent-image-scan.txt ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ needles: 391
2
+ 1 matching line(s): /workspace/repo/src/webapp_hashtagswarm.py
3
+ 5 matching line(s): /workspace/repo/src/webapp_utils.py
4
+ 1 matching line(s): /workspace/repo/src/gemini.py
5
+ 1 matching line(s): /workspace/repo/src/webapp_column_right.py
6
+ 8 matching line(s): /workspace/repo/src/utils.py
7
+ 1 matching line(s): /workspace/repo/src/webapp_post.py
8
+ 2 matching line(s): /workspace/repo/src/person.py
9
+ 2 matching line(s): /workspace/repo/src/markdown.py
10
+ 1 matching line(s): /workspace/repo/src/webapp_timeline.py
11
+ 3 matching line(s): /workspace/repo/src/webapp_search.py
12
+ 2 matching line(s): /workspace/repo/src/webapp_profile.py
13
+ 1 matching line(s): /workspace/repo/src/daemon_get_collections.py
14
+ 1 matching line(s): /workspace/repo/src/follow.py
15
+ scan finished
16
+ absent: /hud
17
+ absent: /app
18
+ absent: /tests
19
+ present: /opt/task-tools/baseline.git
20
+ reference-patch lines in the agent's tracked files: 6, of which the pristine checkout lacks: 0
21
+ grader lines in the agent's tracked files: 0, of which the pristine checkout lacks: 0
22
+ reference-patch lines in total: 129, grader lines in total: 251
23
+ private lines in 0 other files outside the checkout: 0, of which upstream lacks: 0
24
+ --- private lines only the agent's checkout holds (expect none)
25
+ --- the agent's checkout: uncommitted changes (expect none), then its history
26
+ 54dfc93 baseline
harbor/evidence/epicyon/author-calibration.txt ADDED
@@ -0,0 +1,188 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ === gold ===
2
+ PASS media_file_of_a_deleted_post_is_removed w=0.0550 blocker 8.9s
3
+ PASS: media_file_of_a_deleted_post_is_removed — 2 fresh runs agree
4
+ PASS hashtag_index_forgets_a_deleted_post w=0.0550 0.0s
5
+ PASS: hashtag_index_forgets_a_deleted_post — 2 fresh runs agree
6
+ PASS a_deleted_blog_post_leaves_no_rendition w=0.0550 0.0s
7
+ PASS: a_deleted_blog_post_leaves_no_rendition — 2 fresh runs agree
8
+ PASS deleted_post_is_delisted_from_the_media_log w=0.0550 0.0s
9
+ PASS: deleted_post_is_delisted_from_the_media_log — 2 fresh runs agree
10
+ PASS a_deleted_blog_post_leaves_no_json_or_attachment w=0.0550 0.0s
11
+ PASS: a_deleted_blog_post_leaves_no_json_or_attachment — 2 fresh runs agree
12
+ PASS timeline_indexes_forget_a_deleted_post w=0.0550 0.0s
13
+ PASS: timeline_indexes_forget_a_deleted_post — 2 fresh runs agree
14
+ PASS features_copy_of_a_deleted_article_is_removed w=0.1600 0.0s
15
+ PASS: features_copy_of_a_deleted_article_is_removed — 2 fresh runs agree
16
+ PASS features_index_forgets_a_deleted_article w=0.1600 0.0s
17
+ PASS: features_index_forgets_a_deleted_article — 2 fresh runs agree
18
+ PASS event_category_index_forgets_a_deleted_event w=0.1600 0.0s
19
+ PASS: event_category_index_forgets_a_deleted_event — 2 fresh runs agree
20
+ PASS split_event_category_indexes_forget_a_deleted_event w=0.1600 0.0s
21
+ PASS: split_event_category_indexes_forget_a_deleted_event — 2 fresh runs agree
22
+ ... calibration still running (12:40:09) ...
23
+ PASS gate_repo_suite_green_and_tests_untouched w=0.0300 blocker 99.5s CORE_GREEN=1
24
+ PASS: the repository's own checks are all there and its suite is green
25
+ -> uncapped 1.000, failed blockers none, reward 1.000
26
+
27
+ === base ===
28
+ ... calibration still running (12:41:09) ...
29
+ FAIL media_file_of_a_deleted_post_is_removed w=0.0550 blocker 9.1s
30
+ FAIL: the deleted post's media is still on disk: /media/2962/PmShgwJNlHh9vzi0oYe2DvamtaXhy4NK.png
31
+ FAIL hashtag_index_forgets_a_deleted_post w=0.0550 0.0s
32
+ FAIL: the hashtag index still points at the deleted post
33
+ FAIL a_deleted_blog_post_leaves_no_rendition w=0.0550 0.0s
34
+ FAIL: the deleted blog post is still published as markdown, micron
35
+ FAIL deleted_post_is_delisted_from_the_media_log w=0.0550 0.0s
36
+ FAIL: the media log still lists the deleted post's media: /media/2962/VYXCsOVxGn9aXtE6hXCQSEOAtXlGFMtq.png
37
+ FAIL a_deleted_blog_post_leaves_no_json_or_attachment w=0.0550 0.0s
38
+ FAIL: the deleted blog post's own json is still there
39
+ FAIL timeline_indexes_forget_a_deleted_post w=0.0550 0.0s
40
+ FAIL: the outbox index still lists the deleted post
41
+ FAIL features_copy_of_a_deleted_article_is_removed w=0.1600 0.0s
42
+ FAIL: the news actor still holds a copy of the deleted article
43
+ FAIL features_index_forgets_a_deleted_article w=0.1600 0.0s
44
+ FAIL: the news actor's index still lists the deleted article
45
+ FAIL event_category_index_forgets_a_deleted_event w=0.1600 0.0s
46
+ FAIL: the Music tag index still lists the deleted event
47
+ FAIL split_event_category_indexes_forget_a_deleted_event w=0.1600 0.0s
48
+ FAIL: the Outdoors tag index still lists the deleted event
49
+ ... calibration still running (12:42:09) ...
50
+ FAIL gate_repo_suite_green_and_tests_untouched w=0.0300 blocker 98.2s CORE_GREEN=0
51
+ FAIL: no scored behaviour was fixed — this gate does not pay for an empty change
52
+ (conditional: gate_repo_suite_green_and_tests_untouched was told the core is dead and refused its weight itself; it reports FAIL and exits non-zero)
53
+ -> uncapped 0.000, failed blockers ['media_file_of_a_deleted_post_is_removed', 'gate_repo_suite_green_and_tests_untouched'], reward 0.000
54
+
55
+ === noop ===
56
+ FAIL media_file_of_a_deleted_post_is_removed w=0.0550 blocker 9.0s
57
+ FAIL: the deleted post's media is still on disk: /media/2962/nf7xpIWDBCvhJk9tvhysMdZZXQyBebMZ.png
58
+ FAIL hashtag_index_forgets_a_deleted_post w=0.0550 0.0s
59
+ FAIL: the hashtag index still points at the deleted post
60
+ FAIL a_deleted_blog_post_leaves_no_rendition w=0.0550 0.0s
61
+ FAIL: the deleted blog post is still published as markdown, micron
62
+ FAIL deleted_post_is_delisted_from_the_media_log w=0.0550 0.0s
63
+ FAIL: the media log still lists the deleted post's media: /media/2962/OXkJVwcseZBktiqdtA1YCSPU3Vb2Q6x4.png
64
+ FAIL a_deleted_blog_post_leaves_no_json_or_attachment w=0.0550 0.0s
65
+ FAIL: the deleted blog post's own json is still there
66
+ FAIL timeline_indexes_forget_a_deleted_post w=0.0550 0.0s
67
+ FAIL: the outbox index still lists the deleted post
68
+ FAIL features_copy_of_a_deleted_article_is_removed w=0.1600 0.0s
69
+ FAIL: the news actor still holds a copy of the deleted article
70
+ FAIL features_index_forgets_a_deleted_article w=0.1600 0.0s
71
+ FAIL: the news actor's index still lists the deleted article
72
+ FAIL event_category_index_forgets_a_deleted_event w=0.1600 0.0s
73
+ FAIL: the Music tag index still lists the deleted event
74
+ FAIL split_event_category_indexes_forget_a_deleted_event w=0.1600 0.0s
75
+ FAIL: the Outdoors tag index still lists the deleted event
76
+ ... calibration still running (12:43:09) ...
77
+ ... calibration still running (12:44:09) ...
78
+ FAIL gate_repo_suite_green_and_tests_untouched w=0.0300 blocker 97.7s CORE_GREEN=0
79
+ FAIL: no scored behaviour was fixed — this gate does not pay for an empty change
80
+ (conditional: gate_repo_suite_green_and_tests_untouched was told the core is dead and refused its weight itself; it reports FAIL and exits non-zero)
81
+ -> uncapped 0.000, failed blockers ['media_file_of_a_deleted_post_is_removed', 'gate_repo_suite_green_and_tests_untouched'], reward 0.000
82
+
83
+ === lazy ===
84
+ FAIL media_file_of_a_deleted_post_is_removed w=0.0550 blocker 8.8s
85
+ FAIL: another post's media was removed too: /media/2962/S0ERe3NbiHgjFwDs9XA1aDIqAHKSiduC.png
86
+ FAIL hashtag_index_forgets_a_deleted_post w=0.0550 0.0s
87
+ FAIL: the hashtag index still points at the deleted post
88
+ FAIL a_deleted_blog_post_leaves_no_rendition w=0.0550 0.0s
89
+ FAIL: the deleted blog post is still published as markdown, micron
90
+ FAIL deleted_post_is_delisted_from_the_media_log w=0.0550 0.0s
91
+ FAIL: the media log still lists the deleted post's media: /media/2962/HlzRTOE90XNJdTWuocCt6eTJKgu2ZqRq.png
92
+ FAIL a_deleted_blog_post_leaves_no_json_or_attachment w=0.0550 0.0s
93
+ FAIL: the deleted blog post's own json is still there
94
+ PASS timeline_indexes_forget_a_deleted_post w=0.0550 0.0s
95
+ PASS: timeline_indexes_forget_a_deleted_post — 2 fresh runs agree
96
+ FAIL features_copy_of_a_deleted_article_is_removed w=0.1600 0.0s
97
+ FAIL: the news actor still holds a copy of the deleted article
98
+ FAIL features_index_forgets_a_deleted_article w=0.1600 0.0s
99
+ FAIL: the news actor's index still lists the deleted article
100
+ FAIL event_category_index_forgets_a_deleted_event w=0.1600 0.0s
101
+ FAIL: the Music tag index still lists the deleted event
102
+ FAIL split_event_category_indexes_forget_a_deleted_event w=0.1600 0.0s
103
+ FAIL: the Outdoors tag index still lists the deleted event
104
+ ... calibration still running (12:45:09) ...
105
+ ... calibration still running (12:46:09) ...
106
+ PASS gate_repo_suite_green_and_tests_untouched w=0.0300 blocker 96.1s CORE_GREEN=1
107
+ PASS: the repository's own checks are all there and its suite is green
108
+ -> uncapped 0.085, failed blockers ['media_file_of_a_deleted_post_is_removed'], reward 0.085
109
+
110
+ === alt ===
111
+ PASS media_file_of_a_deleted_post_is_removed w=0.0550 blocker 9.4s
112
+ PASS: media_file_of_a_deleted_post_is_removed — 2 fresh runs agree
113
+ PASS hashtag_index_forgets_a_deleted_post w=0.0550 0.0s
114
+ PASS: hashtag_index_forgets_a_deleted_post — 2 fresh runs agree
115
+ PASS a_deleted_blog_post_leaves_no_rendition w=0.0550 0.0s
116
+ PASS: a_deleted_blog_post_leaves_no_rendition — 2 fresh runs agree
117
+ PASS deleted_post_is_delisted_from_the_media_log w=0.0550 0.0s
118
+ PASS: deleted_post_is_delisted_from_the_media_log — 2 fresh runs agree
119
+ PASS a_deleted_blog_post_leaves_no_json_or_attachment w=0.0550 0.0s
120
+ PASS: a_deleted_blog_post_leaves_no_json_or_attachment — 2 fresh runs agree
121
+ PASS timeline_indexes_forget_a_deleted_post w=0.0550 0.0s
122
+ PASS: timeline_indexes_forget_a_deleted_post — 2 fresh runs agree
123
+ PASS features_copy_of_a_deleted_article_is_removed w=0.1600 0.0s
124
+ PASS: features_copy_of_a_deleted_article_is_removed — 2 fresh runs agree
125
+ PASS features_index_forgets_a_deleted_article w=0.1600 0.0s
126
+ PASS: features_index_forgets_a_deleted_article — 2 fresh runs agree
127
+ PASS event_category_index_forgets_a_deleted_event w=0.1600 0.0s
128
+ PASS: event_category_index_forgets_a_deleted_event — 2 fresh runs agree
129
+ PASS split_event_category_indexes_forget_a_deleted_event w=0.1600 0.0s
130
+ PASS: split_event_category_indexes_forget_a_deleted_event — 2 fresh runs agree
131
+ ... calibration still running (12:47:09) ...
132
+ ... calibration still running (12:48:09) ...
133
+ PASS gate_repo_suite_green_and_tests_untouched w=0.0300 blocker 99.1s CORE_GREEN=1
134
+ PASS: the repository's own checks are all there and its suite is green
135
+ -> uncapped 1.000, failed blockers none, reward 1.000
136
+
137
+ === cheat ===
138
+ PASS media_file_of_a_deleted_post_is_removed w=0.0550 blocker 9.3s
139
+ PASS: media_file_of_a_deleted_post_is_removed — 2 fresh runs agree
140
+ PASS hashtag_index_forgets_a_deleted_post w=0.0550 0.0s
141
+ PASS: hashtag_index_forgets_a_deleted_post — 2 fresh runs agree
142
+ PASS a_deleted_blog_post_leaves_no_rendition w=0.0550 0.0s
143
+ PASS: a_deleted_blog_post_leaves_no_rendition — 2 fresh runs agree
144
+ PASS deleted_post_is_delisted_from_the_media_log w=0.0550 0.0s
145
+ PASS: deleted_post_is_delisted_from_the_media_log — 2 fresh runs agree
146
+ PASS a_deleted_blog_post_leaves_no_json_or_attachment w=0.0550 0.0s
147
+ PASS: a_deleted_blog_post_leaves_no_json_or_attachment — 2 fresh runs agree
148
+ PASS timeline_indexes_forget_a_deleted_post w=0.0550 0.0s
149
+ PASS: timeline_indexes_forget_a_deleted_post — 2 fresh runs agree
150
+ PASS features_copy_of_a_deleted_article_is_removed w=0.1600 0.0s
151
+ PASS: features_copy_of_a_deleted_article_is_removed — 2 fresh runs agree
152
+ PASS features_index_forgets_a_deleted_article w=0.1600 0.0s
153
+ PASS: features_index_forgets_a_deleted_article — 2 fresh runs agree
154
+ PASS event_category_index_forgets_a_deleted_event w=0.1600 0.0s
155
+ PASS: event_category_index_forgets_a_deleted_event — 2 fresh runs agree
156
+ PASS split_event_category_indexes_forget_a_deleted_event w=0.1600 0.0s
157
+ PASS: split_event_category_indexes_forget_a_deleted_event — 2 fresh runs agree
158
+ FAIL gate_repo_suite_green_and_tests_untouched w=0.0300 blocker 2.4s CORE_GREEN=1
159
+ FAIL: the repository's own checks were changed or removed
160
+ -> uncapped 0.970, failed blockers ['gate_repo_suite_green_and_tests_untouched'], reward 0.600
161
+
162
+ === calibration ===
163
+ REWARD gold 1.000
164
+ REWARD base 0.000
165
+ REWARD noop 0.000
166
+ REWARD lazy 0.085
167
+ REWARD alt 1.000
168
+ REWARD cheat 0.600
169
+ gold: **1.00** (expected 1.00) OK
170
+ base: **0.00** (expected 0.00) OK
171
+ gold: all criteria green, one by one
172
+ base: all cells red one by one; the gate's own suite is green on the untouched checkout (G-4) and the gate refuses to be paid for it (G-5')
173
+ noop: 0.000 OK
174
+ lazy: 0.085 (< 0.50) OK
175
+ alt: 1.000 (>= 0.80) OK
176
+ cheat: 0.600 (uncapped 0.970, capped by gate_repo_suite_green_and_tests_untouched) OK
177
+ LADDER gold=1.000 base=0.000 noop=0.000 lazy=0.085 alt=1.000 cheat=0.600
178
+
179
+ CALIBRATION OK; written to /hud/.calib/calibration.json
180
+ gold: **1.00** (expected 1.00) OK
181
+ base: **0.00** (expected 0.00) OK
182
+ gold: all criteria green, one by one
183
+ base: all cells red one by one; the gate's own suite is green on the untouched checkout (G-4) and the gate refuses to be paid for it (G-5')
184
+ noop: 0.000 OK
185
+ lazy: 0.085 (< 0.50) OK
186
+ alt: 1.000 (>= 0.80) OK
187
+ cheat: 0.600 (uncapped 0.970, capped by gate_repo_suite_green_and_tests_untouched) OK
188
+ LADDER gold=1.000 base=0.000 noop=0.000 lazy=0.085 alt=1.000 cheat=0.600
harbor/evidence/epicyon/native-reference.json ADDED
@@ -0,0 +1,185 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "reward": 1.0,
3
+ "done": true,
4
+ "content": null,
5
+ "info": {},
6
+ "isError": false,
7
+ "subscores": [
8
+ {
9
+ "name": "media_file_of_a_deleted_post_is_removed",
10
+ "weight": 0.055,
11
+ "value": 1.0,
12
+ "children": null,
13
+ "info": {
14
+ "exit_code": 0,
15
+ "stdout": "PASS: media_file_of_a_deleted_post_is_removed \u2014 2 fresh runs agree\n",
16
+ "stderr": "",
17
+ "_parameters": {
18
+ "command": "CORE_GREEN=1 bash /hud/grader/run_grading.sh media_file_of_a_deleted_post_is_removed 600",
19
+ "cwd": "/workspace/repo",
20
+ "timeout_seconds": 600
21
+ }
22
+ }
23
+ },
24
+ {
25
+ "name": "hashtag_index_forgets_a_deleted_post",
26
+ "weight": 0.055,
27
+ "value": 1.0,
28
+ "children": null,
29
+ "info": {
30
+ "exit_code": 0,
31
+ "stdout": "PASS: hashtag_index_forgets_a_deleted_post \u2014 2 fresh runs agree\n",
32
+ "stderr": "",
33
+ "_parameters": {
34
+ "command": "CORE_GREEN=1 bash /hud/grader/run_grading.sh hashtag_index_forgets_a_deleted_post 600",
35
+ "cwd": "/workspace/repo",
36
+ "timeout_seconds": 600
37
+ }
38
+ }
39
+ },
40
+ {
41
+ "name": "a_deleted_blog_post_leaves_no_rendition",
42
+ "weight": 0.055,
43
+ "value": 1.0,
44
+ "children": null,
45
+ "info": {
46
+ "exit_code": 0,
47
+ "stdout": "PASS: a_deleted_blog_post_leaves_no_rendition \u2014 2 fresh runs agree\n",
48
+ "stderr": "",
49
+ "_parameters": {
50
+ "command": "CORE_GREEN=1 bash /hud/grader/run_grading.sh a_deleted_blog_post_leaves_no_rendition 600",
51
+ "cwd": "/workspace/repo",
52
+ "timeout_seconds": 600
53
+ }
54
+ }
55
+ },
56
+ {
57
+ "name": "deleted_post_is_delisted_from_the_media_log",
58
+ "weight": 0.055,
59
+ "value": 1.0,
60
+ "children": null,
61
+ "info": {
62
+ "exit_code": 0,
63
+ "stdout": "PASS: deleted_post_is_delisted_from_the_media_log \u2014 2 fresh runs agree\n",
64
+ "stderr": "",
65
+ "_parameters": {
66
+ "command": "CORE_GREEN=1 bash /hud/grader/run_grading.sh deleted_post_is_delisted_from_the_media_log 600",
67
+ "cwd": "/workspace/repo",
68
+ "timeout_seconds": 600
69
+ }
70
+ }
71
+ },
72
+ {
73
+ "name": "a_deleted_blog_post_leaves_no_json_or_attachment",
74
+ "weight": 0.055,
75
+ "value": 1.0,
76
+ "children": null,
77
+ "info": {
78
+ "exit_code": 0,
79
+ "stdout": "PASS: a_deleted_blog_post_leaves_no_json_or_attachment \u2014 2 fresh runs agree\n",
80
+ "stderr": "",
81
+ "_parameters": {
82
+ "command": "CORE_GREEN=1 bash /hud/grader/run_grading.sh a_deleted_blog_post_leaves_no_json_or_attachment 600",
83
+ "cwd": "/workspace/repo",
84
+ "timeout_seconds": 600
85
+ }
86
+ }
87
+ },
88
+ {
89
+ "name": "timeline_indexes_forget_a_deleted_post",
90
+ "weight": 0.055,
91
+ "value": 1.0,
92
+ "children": null,
93
+ "info": {
94
+ "exit_code": 0,
95
+ "stdout": "PASS: timeline_indexes_forget_a_deleted_post \u2014 2 fresh runs agree\n",
96
+ "stderr": "",
97
+ "_parameters": {
98
+ "command": "CORE_GREEN=1 bash /hud/grader/run_grading.sh timeline_indexes_forget_a_deleted_post 600",
99
+ "cwd": "/workspace/repo",
100
+ "timeout_seconds": 600
101
+ }
102
+ }
103
+ },
104
+ {
105
+ "name": "features_copy_of_a_deleted_article_is_removed",
106
+ "weight": 0.16,
107
+ "value": 1.0,
108
+ "children": null,
109
+ "info": {
110
+ "exit_code": 0,
111
+ "stdout": "PASS: features_copy_of_a_deleted_article_is_removed \u2014 2 fresh runs agree\n",
112
+ "stderr": "",
113
+ "_parameters": {
114
+ "command": "CORE_GREEN=1 bash /hud/grader/run_grading.sh features_copy_of_a_deleted_article_is_removed 600",
115
+ "cwd": "/workspace/repo",
116
+ "timeout_seconds": 600
117
+ }
118
+ }
119
+ },
120
+ {
121
+ "name": "features_index_forgets_a_deleted_article",
122
+ "weight": 0.16,
123
+ "value": 1.0,
124
+ "children": null,
125
+ "info": {
126
+ "exit_code": 0,
127
+ "stdout": "PASS: features_index_forgets_a_deleted_article \u2014 2 fresh runs agree\n",
128
+ "stderr": "",
129
+ "_parameters": {
130
+ "command": "CORE_GREEN=1 bash /hud/grader/run_grading.sh features_index_forgets_a_deleted_article 600",
131
+ "cwd": "/workspace/repo",
132
+ "timeout_seconds": 600
133
+ }
134
+ }
135
+ },
136
+ {
137
+ "name": "event_category_index_forgets_a_deleted_event",
138
+ "weight": 0.16,
139
+ "value": 1.0,
140
+ "children": null,
141
+ "info": {
142
+ "exit_code": 0,
143
+ "stdout": "PASS: event_category_index_forgets_a_deleted_event \u2014 2 fresh runs agree\n",
144
+ "stderr": "",
145
+ "_parameters": {
146
+ "command": "CORE_GREEN=1 bash /hud/grader/run_grading.sh event_category_index_forgets_a_deleted_event 600",
147
+ "cwd": "/workspace/repo",
148
+ "timeout_seconds": 600
149
+ }
150
+ }
151
+ },
152
+ {
153
+ "name": "split_event_category_indexes_forget_a_deleted_event",
154
+ "weight": 0.16,
155
+ "value": 1.0,
156
+ "children": null,
157
+ "info": {
158
+ "exit_code": 0,
159
+ "stdout": "PASS: split_event_category_indexes_forget_a_deleted_event \u2014 2 fresh runs agree\n",
160
+ "stderr": "",
161
+ "_parameters": {
162
+ "command": "CORE_GREEN=1 bash /hud/grader/run_grading.sh split_event_category_indexes_forget_a_deleted_event 600",
163
+ "cwd": "/workspace/repo",
164
+ "timeout_seconds": 600
165
+ }
166
+ }
167
+ },
168
+ {
169
+ "name": "gate_repo_suite_green_and_tests_untouched",
170
+ "weight": 0.03,
171
+ "value": 1.0,
172
+ "children": null,
173
+ "info": {
174
+ "exit_code": 0,
175
+ "stdout": "PASS: the repository's own checks are all there and its suite is green\n",
176
+ "stderr": "",
177
+ "_parameters": {
178
+ "command": "CORE_GREEN=1 bash /hud/grader/run_grading.sh gate_repo_suite_green_and_tests_untouched 900",
179
+ "cwd": "/workspace/repo",
180
+ "timeout_seconds": 900
181
+ }
182
+ }
183
+ }
184
+ ]
185
+ }
harbor/evidence/epicyon/reports/noop.json ADDED
@@ -0,0 +1,377 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "revision": "coding-rubric-v2",
3
+ "task_id": "epicyon_deleted_post_announce_cache_contract",
4
+ "grader_version": "0.6.15",
5
+ "commands": [
6
+ {
7
+ "name": "media_file_of_a_deleted_post_is_removed",
8
+ "weight": 0.055,
9
+ "value": 0.0,
10
+ "children": null,
11
+ "info": {
12
+ "exit_code": 1,
13
+ "stdout": "FAIL: the deleted post's media is still on disk: /media/2962/2E0Haokz35sNz4rtdcPOAD8fim5pp00C.png\n CELL=media_file_of_a_deleted_post_is_removed FAIL the deleted post's media is still on disk: /media/2962/2E0Haokz35sNz4rtdcPOAD8fim5pp00C.png\n",
14
+ "stderr": "",
15
+ "_parameters": {
16
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh media_file_of_a_deleted_post_is_removed 600'",
17
+ "cwd": "/workspace/repo",
18
+ "timeout_seconds": 600
19
+ }
20
+ }
21
+ },
22
+ {
23
+ "name": "hashtag_index_forgets_a_deleted_post",
24
+ "weight": 0.055,
25
+ "value": 0.0,
26
+ "children": null,
27
+ "info": {
28
+ "exit_code": 1,
29
+ "stdout": "FAIL: the hashtag index still points at the deleted post\n CELL=hashtag_index_forgets_a_deleted_post FAIL the hashtag index still points at the deleted post\n",
30
+ "stderr": "",
31
+ "_parameters": {
32
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh hashtag_index_forgets_a_deleted_post 600'",
33
+ "cwd": "/workspace/repo",
34
+ "timeout_seconds": 600
35
+ }
36
+ }
37
+ },
38
+ {
39
+ "name": "a_deleted_blog_post_leaves_no_rendition",
40
+ "weight": 0.055,
41
+ "value": 0.0,
42
+ "children": null,
43
+ "info": {
44
+ "exit_code": 1,
45
+ "stdout": "FAIL: the deleted blog post is still published as markdown, micron\n CELL=a_deleted_blog_post_leaves_no_rendition FAIL the deleted blog post is still published as markdown, micron\n",
46
+ "stderr": "",
47
+ "_parameters": {
48
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh a_deleted_blog_post_leaves_no_rendition 600'",
49
+ "cwd": "/workspace/repo",
50
+ "timeout_seconds": 600
51
+ }
52
+ }
53
+ },
54
+ {
55
+ "name": "deleted_post_is_delisted_from_the_media_log",
56
+ "weight": 0.055,
57
+ "value": 0.0,
58
+ "children": null,
59
+ "info": {
60
+ "exit_code": 1,
61
+ "stdout": "FAIL: the media log still lists the deleted post's media: /media/2962/MupdsseYdqxwX1nmyj2fRxETTraXMtfU.png\n CELL=deleted_post_is_delisted_from_the_media_log FAIL the media log still lists the deleted post's media: /media/2962/MupdsseYdqxwX1nmyj2fRxETTraXMtfU.png\n",
62
+ "stderr": "",
63
+ "_parameters": {
64
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh deleted_post_is_delisted_from_the_media_log 600'",
65
+ "cwd": "/workspace/repo",
66
+ "timeout_seconds": 600
67
+ }
68
+ }
69
+ },
70
+ {
71
+ "name": "a_deleted_blog_post_leaves_no_json_or_attachment",
72
+ "weight": 0.055,
73
+ "value": 0.0,
74
+ "children": null,
75
+ "info": {
76
+ "exit_code": 1,
77
+ "stdout": "FAIL: the deleted blog post's own json is still there\n CELL=a_deleted_blog_post_leaves_no_json_or_attachment FAIL the deleted blog post's own json is still there\n",
78
+ "stderr": "",
79
+ "_parameters": {
80
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh a_deleted_blog_post_leaves_no_json_or_attachment 600'",
81
+ "cwd": "/workspace/repo",
82
+ "timeout_seconds": 600
83
+ }
84
+ }
85
+ },
86
+ {
87
+ "name": "timeline_indexes_forget_a_deleted_post",
88
+ "weight": 0.055,
89
+ "value": 0.0,
90
+ "children": null,
91
+ "info": {
92
+ "exit_code": 1,
93
+ "stdout": "FAIL: the outbox index still lists the deleted post\n CELL=timeline_indexes_forget_a_deleted_post FAIL the outbox index still lists the deleted post\n",
94
+ "stderr": "",
95
+ "_parameters": {
96
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh timeline_indexes_forget_a_deleted_post 600'",
97
+ "cwd": "/workspace/repo",
98
+ "timeout_seconds": 600
99
+ }
100
+ }
101
+ },
102
+ {
103
+ "name": "features_copy_of_a_deleted_article_is_removed",
104
+ "weight": 0.16,
105
+ "value": 0.0,
106
+ "children": null,
107
+ "info": {
108
+ "exit_code": 1,
109
+ "stdout": "FAIL: the news actor still holds a copy of the deleted article\n CELL=features_copy_of_a_deleted_article_is_removed FAIL the news actor still holds a copy of the deleted article\n",
110
+ "stderr": "",
111
+ "_parameters": {
112
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh features_copy_of_a_deleted_article_is_removed 600'",
113
+ "cwd": "/workspace/repo",
114
+ "timeout_seconds": 600
115
+ }
116
+ }
117
+ },
118
+ {
119
+ "name": "features_index_forgets_a_deleted_article",
120
+ "weight": 0.16,
121
+ "value": 0.0,
122
+ "children": null,
123
+ "info": {
124
+ "exit_code": 1,
125
+ "stdout": "FAIL: the news actor's index still lists the deleted article\n CELL=features_index_forgets_a_deleted_article FAIL the news actor's index still lists the deleted article\n",
126
+ "stderr": "",
127
+ "_parameters": {
128
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh features_index_forgets_a_deleted_article 600'",
129
+ "cwd": "/workspace/repo",
130
+ "timeout_seconds": 600
131
+ }
132
+ }
133
+ },
134
+ {
135
+ "name": "event_category_index_forgets_a_deleted_event",
136
+ "weight": 0.16,
137
+ "value": 0.0,
138
+ "children": null,
139
+ "info": {
140
+ "exit_code": 1,
141
+ "stdout": "FAIL: the Music tag index still lists the deleted event\n CELL=event_category_index_forgets_a_deleted_event FAIL the Music tag index still lists the deleted event\n",
142
+ "stderr": "",
143
+ "_parameters": {
144
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh event_category_index_forgets_a_deleted_event 600'",
145
+ "cwd": "/workspace/repo",
146
+ "timeout_seconds": 600
147
+ }
148
+ }
149
+ },
150
+ {
151
+ "name": "split_event_category_indexes_forget_a_deleted_event",
152
+ "weight": 0.16,
153
+ "value": 0.0,
154
+ "children": null,
155
+ "info": {
156
+ "exit_code": 1,
157
+ "stdout": "FAIL: the Outdoors tag index still lists the deleted event\n CELL=split_event_category_indexes_forget_a_deleted_event FAIL the Outdoors tag index still lists the deleted event\n",
158
+ "stderr": "",
159
+ "_parameters": {
160
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh split_event_category_indexes_forget_a_deleted_event 600'",
161
+ "cwd": "/workspace/repo",
162
+ "timeout_seconds": 600
163
+ }
164
+ }
165
+ },
166
+ {
167
+ "name": "gate_repo_suite_green_and_tests_untouched",
168
+ "weight": 0.03,
169
+ "value": 0.0,
170
+ "children": null,
171
+ "info": {
172
+ "exit_code": 1,
173
+ "stdout": "the repository's own tests: green \u2014 the repository's own checks are all there and its suite is green\nFAIL: no scored behaviour was fixed \u2014 this gate does not pay for an empty change\n",
174
+ "stderr": "",
175
+ "_parameters": {
176
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=0 bash /hud/grader/run_grading.sh gate_repo_suite_green_and_tests_untouched 900'",
177
+ "cwd": "/workspace/repo",
178
+ "timeout_seconds": 900
179
+ }
180
+ }
181
+ }
182
+ ],
183
+ "status": "graded",
184
+ "patch_sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
185
+ "result": {
186
+ "reward": 0.0,
187
+ "done": true,
188
+ "content": "Blocker criteria failed (gate_repo_suite_green_and_tests_untouched, media_file_of_a_deleted_post_is_removed); cap 0.60, reward 0.000 (uncapped 0.000).",
189
+ "info": {
190
+ "uncapped_reward": 0.0,
191
+ "failed_blockers": [
192
+ "gate_repo_suite_green_and_tests_untouched",
193
+ "media_file_of_a_deleted_post_is_removed"
194
+ ],
195
+ "blocker_cap": 0.6
196
+ },
197
+ "isError": false,
198
+ "subscores": [
199
+ {
200
+ "name": "media_file_of_a_deleted_post_is_removed",
201
+ "weight": 0.055,
202
+ "value": 0.0,
203
+ "children": null,
204
+ "info": {
205
+ "exit_code": 1,
206
+ "stdout": "FAIL: the deleted post's media is still on disk: /media/2962/2E0Haokz35sNz4rtdcPOAD8fim5pp00C.png\n CELL=media_file_of_a_deleted_post_is_removed FAIL the deleted post's media is still on disk: /media/2962/2E0Haokz35sNz4rtdcPOAD8fim5pp00C.png\n",
207
+ "stderr": "",
208
+ "_parameters": {
209
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh media_file_of_a_deleted_post_is_removed 600'",
210
+ "cwd": "/workspace/repo",
211
+ "timeout_seconds": 600
212
+ }
213
+ }
214
+ },
215
+ {
216
+ "name": "hashtag_index_forgets_a_deleted_post",
217
+ "weight": 0.055,
218
+ "value": 0.0,
219
+ "children": null,
220
+ "info": {
221
+ "exit_code": 1,
222
+ "stdout": "FAIL: the hashtag index still points at the deleted post\n CELL=hashtag_index_forgets_a_deleted_post FAIL the hashtag index still points at the deleted post\n",
223
+ "stderr": "",
224
+ "_parameters": {
225
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh hashtag_index_forgets_a_deleted_post 600'",
226
+ "cwd": "/workspace/repo",
227
+ "timeout_seconds": 600
228
+ }
229
+ }
230
+ },
231
+ {
232
+ "name": "a_deleted_blog_post_leaves_no_rendition",
233
+ "weight": 0.055,
234
+ "value": 0.0,
235
+ "children": null,
236
+ "info": {
237
+ "exit_code": 1,
238
+ "stdout": "FAIL: the deleted blog post is still published as markdown, micron\n CELL=a_deleted_blog_post_leaves_no_rendition FAIL the deleted blog post is still published as markdown, micron\n",
239
+ "stderr": "",
240
+ "_parameters": {
241
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh a_deleted_blog_post_leaves_no_rendition 600'",
242
+ "cwd": "/workspace/repo",
243
+ "timeout_seconds": 600
244
+ }
245
+ }
246
+ },
247
+ {
248
+ "name": "deleted_post_is_delisted_from_the_media_log",
249
+ "weight": 0.055,
250
+ "value": 0.0,
251
+ "children": null,
252
+ "info": {
253
+ "exit_code": 1,
254
+ "stdout": "FAIL: the media log still lists the deleted post's media: /media/2962/MupdsseYdqxwX1nmyj2fRxETTraXMtfU.png\n CELL=deleted_post_is_delisted_from_the_media_log FAIL the media log still lists the deleted post's media: /media/2962/MupdsseYdqxwX1nmyj2fRxETTraXMtfU.png\n",
255
+ "stderr": "",
256
+ "_parameters": {
257
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh deleted_post_is_delisted_from_the_media_log 600'",
258
+ "cwd": "/workspace/repo",
259
+ "timeout_seconds": 600
260
+ }
261
+ }
262
+ },
263
+ {
264
+ "name": "a_deleted_blog_post_leaves_no_json_or_attachment",
265
+ "weight": 0.055,
266
+ "value": 0.0,
267
+ "children": null,
268
+ "info": {
269
+ "exit_code": 1,
270
+ "stdout": "FAIL: the deleted blog post's own json is still there\n CELL=a_deleted_blog_post_leaves_no_json_or_attachment FAIL the deleted blog post's own json is still there\n",
271
+ "stderr": "",
272
+ "_parameters": {
273
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh a_deleted_blog_post_leaves_no_json_or_attachment 600'",
274
+ "cwd": "/workspace/repo",
275
+ "timeout_seconds": 600
276
+ }
277
+ }
278
+ },
279
+ {
280
+ "name": "timeline_indexes_forget_a_deleted_post",
281
+ "weight": 0.055,
282
+ "value": 0.0,
283
+ "children": null,
284
+ "info": {
285
+ "exit_code": 1,
286
+ "stdout": "FAIL: the outbox index still lists the deleted post\n CELL=timeline_indexes_forget_a_deleted_post FAIL the outbox index still lists the deleted post\n",
287
+ "stderr": "",
288
+ "_parameters": {
289
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh timeline_indexes_forget_a_deleted_post 600'",
290
+ "cwd": "/workspace/repo",
291
+ "timeout_seconds": 600
292
+ }
293
+ }
294
+ },
295
+ {
296
+ "name": "features_copy_of_a_deleted_article_is_removed",
297
+ "weight": 0.16,
298
+ "value": 0.0,
299
+ "children": null,
300
+ "info": {
301
+ "exit_code": 1,
302
+ "stdout": "FAIL: the news actor still holds a copy of the deleted article\n CELL=features_copy_of_a_deleted_article_is_removed FAIL the news actor still holds a copy of the deleted article\n",
303
+ "stderr": "",
304
+ "_parameters": {
305
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh features_copy_of_a_deleted_article_is_removed 600'",
306
+ "cwd": "/workspace/repo",
307
+ "timeout_seconds": 600
308
+ }
309
+ }
310
+ },
311
+ {
312
+ "name": "features_index_forgets_a_deleted_article",
313
+ "weight": 0.16,
314
+ "value": 0.0,
315
+ "children": null,
316
+ "info": {
317
+ "exit_code": 1,
318
+ "stdout": "FAIL: the news actor's index still lists the deleted article\n CELL=features_index_forgets_a_deleted_article FAIL the news actor's index still lists the deleted article\n",
319
+ "stderr": "",
320
+ "_parameters": {
321
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh features_index_forgets_a_deleted_article 600'",
322
+ "cwd": "/workspace/repo",
323
+ "timeout_seconds": 600
324
+ }
325
+ }
326
+ },
327
+ {
328
+ "name": "event_category_index_forgets_a_deleted_event",
329
+ "weight": 0.16,
330
+ "value": 0.0,
331
+ "children": null,
332
+ "info": {
333
+ "exit_code": 1,
334
+ "stdout": "FAIL: the Music tag index still lists the deleted event\n CELL=event_category_index_forgets_a_deleted_event FAIL the Music tag index still lists the deleted event\n",
335
+ "stderr": "",
336
+ "_parameters": {
337
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh event_category_index_forgets_a_deleted_event 600'",
338
+ "cwd": "/workspace/repo",
339
+ "timeout_seconds": 600
340
+ }
341
+ }
342
+ },
343
+ {
344
+ "name": "split_event_category_indexes_forget_a_deleted_event",
345
+ "weight": 0.16,
346
+ "value": 0.0,
347
+ "children": null,
348
+ "info": {
349
+ "exit_code": 1,
350
+ "stdout": "FAIL: the Outdoors tag index still lists the deleted event\n CELL=split_event_category_indexes_forget_a_deleted_event FAIL the Outdoors tag index still lists the deleted event\n",
351
+ "stderr": "",
352
+ "_parameters": {
353
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh split_event_category_indexes_forget_a_deleted_event 600'",
354
+ "cwd": "/workspace/repo",
355
+ "timeout_seconds": 600
356
+ }
357
+ }
358
+ },
359
+ {
360
+ "name": "gate_repo_suite_green_and_tests_untouched",
361
+ "weight": 0.03,
362
+ "value": 0.0,
363
+ "children": null,
364
+ "info": {
365
+ "exit_code": 1,
366
+ "stdout": "the repository's own tests: green \u2014 the repository's own checks are all there and its suite is green\nFAIL: no scored behaviour was fixed \u2014 this gate does not pay for an empty change\n",
367
+ "stderr": "",
368
+ "_parameters": {
369
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=0 bash /hud/grader/run_grading.sh gate_repo_suite_green_and_tests_untouched 900'",
370
+ "cwd": "/workspace/repo",
371
+ "timeout_seconds": 900
372
+ }
373
+ }
374
+ }
375
+ ]
376
+ }
377
+ }
harbor/evidence/epicyon/reports/reference.json ADDED
@@ -0,0 +1,370 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "revision": "coding-rubric-v2",
3
+ "task_id": "epicyon_deleted_post_announce_cache_contract",
4
+ "grader_version": "0.6.15",
5
+ "commands": [
6
+ {
7
+ "name": "media_file_of_a_deleted_post_is_removed",
8
+ "weight": 0.055,
9
+ "value": 1.0,
10
+ "children": null,
11
+ "info": {
12
+ "exit_code": 0,
13
+ "stdout": "PASS: media_file_of_a_deleted_post_is_removed \u2014 2 fresh runs agree\n",
14
+ "stderr": "",
15
+ "_parameters": {
16
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh media_file_of_a_deleted_post_is_removed 600'",
17
+ "cwd": "/workspace/repo",
18
+ "timeout_seconds": 600
19
+ }
20
+ }
21
+ },
22
+ {
23
+ "name": "hashtag_index_forgets_a_deleted_post",
24
+ "weight": 0.055,
25
+ "value": 1.0,
26
+ "children": null,
27
+ "info": {
28
+ "exit_code": 0,
29
+ "stdout": "PASS: hashtag_index_forgets_a_deleted_post \u2014 2 fresh runs agree\n",
30
+ "stderr": "",
31
+ "_parameters": {
32
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh hashtag_index_forgets_a_deleted_post 600'",
33
+ "cwd": "/workspace/repo",
34
+ "timeout_seconds": 600
35
+ }
36
+ }
37
+ },
38
+ {
39
+ "name": "a_deleted_blog_post_leaves_no_rendition",
40
+ "weight": 0.055,
41
+ "value": 1.0,
42
+ "children": null,
43
+ "info": {
44
+ "exit_code": 0,
45
+ "stdout": "PASS: a_deleted_blog_post_leaves_no_rendition \u2014 2 fresh runs agree\n",
46
+ "stderr": "",
47
+ "_parameters": {
48
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh a_deleted_blog_post_leaves_no_rendition 600'",
49
+ "cwd": "/workspace/repo",
50
+ "timeout_seconds": 600
51
+ }
52
+ }
53
+ },
54
+ {
55
+ "name": "deleted_post_is_delisted_from_the_media_log",
56
+ "weight": 0.055,
57
+ "value": 1.0,
58
+ "children": null,
59
+ "info": {
60
+ "exit_code": 0,
61
+ "stdout": "PASS: deleted_post_is_delisted_from_the_media_log \u2014 2 fresh runs agree\n",
62
+ "stderr": "",
63
+ "_parameters": {
64
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh deleted_post_is_delisted_from_the_media_log 600'",
65
+ "cwd": "/workspace/repo",
66
+ "timeout_seconds": 600
67
+ }
68
+ }
69
+ },
70
+ {
71
+ "name": "a_deleted_blog_post_leaves_no_json_or_attachment",
72
+ "weight": 0.055,
73
+ "value": 1.0,
74
+ "children": null,
75
+ "info": {
76
+ "exit_code": 0,
77
+ "stdout": "PASS: a_deleted_blog_post_leaves_no_json_or_attachment \u2014 2 fresh runs agree\n",
78
+ "stderr": "",
79
+ "_parameters": {
80
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh a_deleted_blog_post_leaves_no_json_or_attachment 600'",
81
+ "cwd": "/workspace/repo",
82
+ "timeout_seconds": 600
83
+ }
84
+ }
85
+ },
86
+ {
87
+ "name": "timeline_indexes_forget_a_deleted_post",
88
+ "weight": 0.055,
89
+ "value": 1.0,
90
+ "children": null,
91
+ "info": {
92
+ "exit_code": 0,
93
+ "stdout": "PASS: timeline_indexes_forget_a_deleted_post \u2014 2 fresh runs agree\n",
94
+ "stderr": "",
95
+ "_parameters": {
96
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh timeline_indexes_forget_a_deleted_post 600'",
97
+ "cwd": "/workspace/repo",
98
+ "timeout_seconds": 600
99
+ }
100
+ }
101
+ },
102
+ {
103
+ "name": "features_copy_of_a_deleted_article_is_removed",
104
+ "weight": 0.16,
105
+ "value": 1.0,
106
+ "children": null,
107
+ "info": {
108
+ "exit_code": 0,
109
+ "stdout": "PASS: features_copy_of_a_deleted_article_is_removed \u2014 2 fresh runs agree\n",
110
+ "stderr": "",
111
+ "_parameters": {
112
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh features_copy_of_a_deleted_article_is_removed 600'",
113
+ "cwd": "/workspace/repo",
114
+ "timeout_seconds": 600
115
+ }
116
+ }
117
+ },
118
+ {
119
+ "name": "features_index_forgets_a_deleted_article",
120
+ "weight": 0.16,
121
+ "value": 1.0,
122
+ "children": null,
123
+ "info": {
124
+ "exit_code": 0,
125
+ "stdout": "PASS: features_index_forgets_a_deleted_article \u2014 2 fresh runs agree\n",
126
+ "stderr": "",
127
+ "_parameters": {
128
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh features_index_forgets_a_deleted_article 600'",
129
+ "cwd": "/workspace/repo",
130
+ "timeout_seconds": 600
131
+ }
132
+ }
133
+ },
134
+ {
135
+ "name": "event_category_index_forgets_a_deleted_event",
136
+ "weight": 0.16,
137
+ "value": 1.0,
138
+ "children": null,
139
+ "info": {
140
+ "exit_code": 0,
141
+ "stdout": "PASS: event_category_index_forgets_a_deleted_event \u2014 2 fresh runs agree\n",
142
+ "stderr": "",
143
+ "_parameters": {
144
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh event_category_index_forgets_a_deleted_event 600'",
145
+ "cwd": "/workspace/repo",
146
+ "timeout_seconds": 600
147
+ }
148
+ }
149
+ },
150
+ {
151
+ "name": "split_event_category_indexes_forget_a_deleted_event",
152
+ "weight": 0.16,
153
+ "value": 1.0,
154
+ "children": null,
155
+ "info": {
156
+ "exit_code": 0,
157
+ "stdout": "PASS: split_event_category_indexes_forget_a_deleted_event \u2014 2 fresh runs agree\n",
158
+ "stderr": "",
159
+ "_parameters": {
160
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh split_event_category_indexes_forget_a_deleted_event 600'",
161
+ "cwd": "/workspace/repo",
162
+ "timeout_seconds": 600
163
+ }
164
+ }
165
+ },
166
+ {
167
+ "name": "gate_repo_suite_green_and_tests_untouched",
168
+ "weight": 0.03,
169
+ "value": 1.0,
170
+ "children": null,
171
+ "info": {
172
+ "exit_code": 0,
173
+ "stdout": "PASS: the repository's own checks are all there and its suite is green\n",
174
+ "stderr": "",
175
+ "_parameters": {
176
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh gate_repo_suite_green_and_tests_untouched 900'",
177
+ "cwd": "/workspace/repo",
178
+ "timeout_seconds": 900
179
+ }
180
+ }
181
+ }
182
+ ],
183
+ "status": "graded",
184
+ "patch_sha256": "b5866d660e5151ed07222c809e6e92e4ff78f28d7a154d244b65d4cba0f847bf",
185
+ "result": {
186
+ "reward": 1.0,
187
+ "done": true,
188
+ "content": null,
189
+ "info": {},
190
+ "isError": false,
191
+ "subscores": [
192
+ {
193
+ "name": "media_file_of_a_deleted_post_is_removed",
194
+ "weight": 0.055,
195
+ "value": 1.0,
196
+ "children": null,
197
+ "info": {
198
+ "exit_code": 0,
199
+ "stdout": "PASS: media_file_of_a_deleted_post_is_removed \u2014 2 fresh runs agree\n",
200
+ "stderr": "",
201
+ "_parameters": {
202
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh media_file_of_a_deleted_post_is_removed 600'",
203
+ "cwd": "/workspace/repo",
204
+ "timeout_seconds": 600
205
+ }
206
+ }
207
+ },
208
+ {
209
+ "name": "hashtag_index_forgets_a_deleted_post",
210
+ "weight": 0.055,
211
+ "value": 1.0,
212
+ "children": null,
213
+ "info": {
214
+ "exit_code": 0,
215
+ "stdout": "PASS: hashtag_index_forgets_a_deleted_post \u2014 2 fresh runs agree\n",
216
+ "stderr": "",
217
+ "_parameters": {
218
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh hashtag_index_forgets_a_deleted_post 600'",
219
+ "cwd": "/workspace/repo",
220
+ "timeout_seconds": 600
221
+ }
222
+ }
223
+ },
224
+ {
225
+ "name": "a_deleted_blog_post_leaves_no_rendition",
226
+ "weight": 0.055,
227
+ "value": 1.0,
228
+ "children": null,
229
+ "info": {
230
+ "exit_code": 0,
231
+ "stdout": "PASS: a_deleted_blog_post_leaves_no_rendition \u2014 2 fresh runs agree\n",
232
+ "stderr": "",
233
+ "_parameters": {
234
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh a_deleted_blog_post_leaves_no_rendition 600'",
235
+ "cwd": "/workspace/repo",
236
+ "timeout_seconds": 600
237
+ }
238
+ }
239
+ },
240
+ {
241
+ "name": "deleted_post_is_delisted_from_the_media_log",
242
+ "weight": 0.055,
243
+ "value": 1.0,
244
+ "children": null,
245
+ "info": {
246
+ "exit_code": 0,
247
+ "stdout": "PASS: deleted_post_is_delisted_from_the_media_log \u2014 2 fresh runs agree\n",
248
+ "stderr": "",
249
+ "_parameters": {
250
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh deleted_post_is_delisted_from_the_media_log 600'",
251
+ "cwd": "/workspace/repo",
252
+ "timeout_seconds": 600
253
+ }
254
+ }
255
+ },
256
+ {
257
+ "name": "a_deleted_blog_post_leaves_no_json_or_attachment",
258
+ "weight": 0.055,
259
+ "value": 1.0,
260
+ "children": null,
261
+ "info": {
262
+ "exit_code": 0,
263
+ "stdout": "PASS: a_deleted_blog_post_leaves_no_json_or_attachment \u2014 2 fresh runs agree\n",
264
+ "stderr": "",
265
+ "_parameters": {
266
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh a_deleted_blog_post_leaves_no_json_or_attachment 600'",
267
+ "cwd": "/workspace/repo",
268
+ "timeout_seconds": 600
269
+ }
270
+ }
271
+ },
272
+ {
273
+ "name": "timeline_indexes_forget_a_deleted_post",
274
+ "weight": 0.055,
275
+ "value": 1.0,
276
+ "children": null,
277
+ "info": {
278
+ "exit_code": 0,
279
+ "stdout": "PASS: timeline_indexes_forget_a_deleted_post \u2014 2 fresh runs agree\n",
280
+ "stderr": "",
281
+ "_parameters": {
282
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh timeline_indexes_forget_a_deleted_post 600'",
283
+ "cwd": "/workspace/repo",
284
+ "timeout_seconds": 600
285
+ }
286
+ }
287
+ },
288
+ {
289
+ "name": "features_copy_of_a_deleted_article_is_removed",
290
+ "weight": 0.16,
291
+ "value": 1.0,
292
+ "children": null,
293
+ "info": {
294
+ "exit_code": 0,
295
+ "stdout": "PASS: features_copy_of_a_deleted_article_is_removed \u2014 2 fresh runs agree\n",
296
+ "stderr": "",
297
+ "_parameters": {
298
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh features_copy_of_a_deleted_article_is_removed 600'",
299
+ "cwd": "/workspace/repo",
300
+ "timeout_seconds": 600
301
+ }
302
+ }
303
+ },
304
+ {
305
+ "name": "features_index_forgets_a_deleted_article",
306
+ "weight": 0.16,
307
+ "value": 1.0,
308
+ "children": null,
309
+ "info": {
310
+ "exit_code": 0,
311
+ "stdout": "PASS: features_index_forgets_a_deleted_article \u2014 2 fresh runs agree\n",
312
+ "stderr": "",
313
+ "_parameters": {
314
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh features_index_forgets_a_deleted_article 600'",
315
+ "cwd": "/workspace/repo",
316
+ "timeout_seconds": 600
317
+ }
318
+ }
319
+ },
320
+ {
321
+ "name": "event_category_index_forgets_a_deleted_event",
322
+ "weight": 0.16,
323
+ "value": 1.0,
324
+ "children": null,
325
+ "info": {
326
+ "exit_code": 0,
327
+ "stdout": "PASS: event_category_index_forgets_a_deleted_event \u2014 2 fresh runs agree\n",
328
+ "stderr": "",
329
+ "_parameters": {
330
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh event_category_index_forgets_a_deleted_event 600'",
331
+ "cwd": "/workspace/repo",
332
+ "timeout_seconds": 600
333
+ }
334
+ }
335
+ },
336
+ {
337
+ "name": "split_event_category_indexes_forget_a_deleted_event",
338
+ "weight": 0.16,
339
+ "value": 1.0,
340
+ "children": null,
341
+ "info": {
342
+ "exit_code": 0,
343
+ "stdout": "PASS: split_event_category_indexes_forget_a_deleted_event \u2014 2 fresh runs agree\n",
344
+ "stderr": "",
345
+ "_parameters": {
346
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh split_event_category_indexes_forget_a_deleted_event 600'",
347
+ "cwd": "/workspace/repo",
348
+ "timeout_seconds": 600
349
+ }
350
+ }
351
+ },
352
+ {
353
+ "name": "gate_repo_suite_green_and_tests_untouched",
354
+ "weight": 0.03,
355
+ "value": 1.0,
356
+ "children": null,
357
+ "info": {
358
+ "exit_code": 0,
359
+ "stdout": "PASS: the repository's own checks are all there and its suite is green\n",
360
+ "stderr": "",
361
+ "_parameters": {
362
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh gate_repo_suite_green_and_tests_untouched 900'",
363
+ "cwd": "/workspace/repo",
364
+ "timeout_seconds": 900
365
+ }
366
+ }
367
+ }
368
+ ]
369
+ }
370
+ }
harbor/evidence/epicyon/summary.json ADDED
@@ -0,0 +1,157 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "name": "epicyon",
3
+ "measure": {
4
+ "ok": true,
5
+ "hud": "0.6.15",
6
+ "path": "/opt/agentvenv/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games",
7
+ "handed": [
8
+ "PYTHONDONTWRITEBYTECODE",
9
+ "PYTHONNOUSERSITE",
10
+ "PYTHONPATH",
11
+ "PYTHONUNBUFFERED"
12
+ ],
13
+ "repo_dir": "/workspace/repo",
14
+ "python_usr_local": true,
15
+ "seconds": 4
16
+ },
17
+ "parity": {
18
+ "ok": true,
19
+ "reward": 1.0,
20
+ "criteria": 11,
21
+ "unmet": [],
22
+ "info": null,
23
+ "seconds": 157
24
+ },
25
+ "task_id": "epicyon_deleted_post_announce_cache_contract",
26
+ "image": "ec-swe-epicyon:source-v7",
27
+ "build": {
28
+ "ok": true,
29
+ "image_id": "sha256:74752fd4e8ebf481d6f0c01fd9b7e542c539f850bf9eed8503f41aaeabd7d99d",
30
+ "ladder": {
31
+ "gold": 1.0,
32
+ "base": 0.0,
33
+ "noop": 0.0,
34
+ "lazy": 0.085,
35
+ "alt": 1.0,
36
+ "cheat": 0.6
37
+ },
38
+ "source_digest": "d8f491bc55257bb8",
39
+ "source": "edited",
40
+ "seconds": 0
41
+ },
42
+ "prepare": {
43
+ "ok": true,
44
+ "bundle": "epicyon-r7",
45
+ "converter": "b8bba68767da888f",
46
+ "pinned_files": 9,
47
+ "criteria": 11,
48
+ "seconds": 1
49
+ },
50
+ "qualified": false,
51
+ "controls": {
52
+ "ok": false,
53
+ "checks": {
54
+ "noop_is_zero": true,
55
+ "reference_is_one": true,
56
+ "reference_equals_native": true,
57
+ "agent_is_isolated": true
58
+ },
59
+ "results": {
60
+ "noop": {
61
+ "run": "epicyon-r7-control-noop-1791898762",
62
+ "reward": 0.0,
63
+ "stop": "completed",
64
+ "error": null,
65
+ "seconds": 351,
66
+ "probe": false,
67
+ "status": "graded",
68
+ "verifier_error": null,
69
+ "exit_codes": [
70
+ 1
71
+ ],
72
+ "attempts": 1
73
+ },
74
+ "reference": {
75
+ "run": "epicyon-r7-control-reference-1791899113",
76
+ "reward": 1.0,
77
+ "stop": "completed",
78
+ "error": null,
79
+ "seconds": 413,
80
+ "probe": true,
81
+ "status": "graded",
82
+ "verifier_error": null,
83
+ "exit_codes": [
84
+ 0
85
+ ],
86
+ "subscores": {
87
+ "media_file_of_a_deleted_post_is_removed": [
88
+ 1.0,
89
+ 0.055
90
+ ],
91
+ "hashtag_index_forgets_a_deleted_post": [
92
+ 1.0,
93
+ 0.055
94
+ ],
95
+ "a_deleted_blog_post_leaves_no_rendition": [
96
+ 1.0,
97
+ 0.055
98
+ ],
99
+ "deleted_post_is_delisted_from_the_media_log": [
100
+ 1.0,
101
+ 0.055
102
+ ],
103
+ "a_deleted_blog_post_leaves_no_json_or_attachment": [
104
+ 1.0,
105
+ 0.055
106
+ ],
107
+ "timeline_indexes_forget_a_deleted_post": [
108
+ 1.0,
109
+ 0.055
110
+ ],
111
+ "features_copy_of_a_deleted_article_is_removed": [
112
+ 1.0,
113
+ 0.16
114
+ ],
115
+ "features_index_forgets_a_deleted_article": [
116
+ 1.0,
117
+ 0.16
118
+ ],
119
+ "event_category_index_forgets_a_deleted_event": [
120
+ 1.0,
121
+ 0.16
122
+ ],
123
+ "split_event_category_indexes_forget_a_deleted_event": [
124
+ 1.0,
125
+ 0.16
126
+ ],
127
+ "gate_repo_suite_green_and_tests_untouched": [
128
+ 1.0,
129
+ 0.03
130
+ ]
131
+ },
132
+ "attempts": 1
133
+ }
134
+ },
135
+ "bundle": "epicyon-r7",
136
+ "complete": false,
137
+ "seconds": 765
138
+ },
139
+ "leak": {
140
+ "scan_finished": true,
141
+ "hits_outside_checkout": [],
142
+ "other_files_holding_only_upstream_lines": 0,
143
+ "library_files_sharing_a_line": 0,
144
+ "most_lines_shared_by_one_library_file": 0,
145
+ "private_paths_absent": true,
146
+ "public_lines_shared_with_patch_and_graders": [
147
+ 6,
148
+ 0
149
+ ],
150
+ "private_lines_only_in_agent_checkout": [
151
+ 0,
152
+ 0
153
+ ],
154
+ "ok": true,
155
+ "seconds": 26
156
+ }
157
+ }
harbor/evidence/packages-reproduced-by-final-converter.json ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "converter": "b8bba68767da888f",
3
+ "packages": {
4
+ "badger": "differs: tests/docker-compose.yaml",
5
+ "bazel-remote": "differs: tests/docker-compose.yaml",
6
+ "celery": "differs: tests/docker-compose.yaml",
7
+ "coredns": "differs: tests/docker-compose.yaml",
8
+ "epicyon": "differs: tests/docker-compose.yaml",
9
+ "geode": "differs: tests/docker-compose.yaml",
10
+ "kratos": "differs: task.toml, environment/Dockerfile, environment/capture.py, environment/capture_submission.py, environment/docker-compose.yaml, environment/sanitize.py",
11
+ "microblogpub": "differs: tests/docker-compose.yaml",
12
+ "open-xml-sdk": "differs: task.toml, environment/Dockerfile, environment/capture.py, environment/capture_submission.py, environment/docker-compose.yaml, environment/sanitize.py",
13
+ "openfire": "differs: task.toml, environment/Dockerfile, environment/capture.py, environment/capture_submission.py, environment/docker-compose.yaml, environment/sanitize.py",
14
+ "rope": "differs: tests/docker-compose.yaml",
15
+ "terser": "differs: tests/docker-compose.yaml",
16
+ "umya": "differs: task.toml, environment/Dockerfile, environment/capture.py, environment/capture_submission.py, environment/docker-compose.yaml, environment/sanitize.py",
17
+ "zettlr": "differs: tests/docker-compose.yaml",
18
+ "zod": "differs: tests/docker-compose.yaml"
19
+ }
20
+ }
harbor/evidence/rope/agent-image-scan.txt ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ needles: 855
2
+ 1 matching line(s): /workspace/repo/ropetest/pycoretest.py
3
+ 4 matching line(s): /workspace/repo/ropetest/refactor/renametest.py
4
+ scan finished
5
+ absent: /hud
6
+ absent: /app
7
+ absent: /tests
8
+ present: /opt/task-tools/baseline.git
9
+ reference-patch lines in the agent's tracked files: 3, of which the pristine checkout lacks: 0
10
+ grader lines in the agent's tracked files: 0, of which the pristine checkout lacks: 0
11
+ reference-patch lines in total: 363, grader lines in total: 485
12
+ private lines in 0 other files outside the checkout: 0, of which upstream lacks: 0
13
+ --- private lines only the agent's checkout holds (expect none)
14
+ --- the agent's checkout: uncommitted changes (expect none), then its history
15
+ 9c94847 baseline
harbor/evidence/rope/author-calibration.txt ADDED
@@ -0,0 +1,844 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ === gold ===
2
+ PASS export_list_follows_the_rename w=0.08 3.0s
3
+ PASS: the defining module's export list
4
+ PASS: an export list written as a tuple over several lines
5
+ PASS: the export list of a package that re-exports the name
6
+ PASS: an export list naming a module that is being renamed
7
+ PASS: an export list extended in place
8
+ PASS: prose and an unrelated list of the same word
9
+ PASS: another module that exports a name of its own
10
+ PASS: an export list built through a variable
11
+ PASS: an export list added to another list
12
+ PASS: an export list written as one string of names
13
+ PASS: an export list written as a block of names
14
+ PASS: export_list_follows_the_rename (11 scenarios)
15
+ PASS type_constructor_names_follow_the_rename w=0.08 1.7s
16
+ PASS: the name a new type is given
17
+ PASS: a new type built from a directly imported constructor
18
+ PASS: the bound of a type variable
19
+ PASS: a type whose name is spelled like something else
20
+ PASS: a constraint of a type variable
21
+ PASS: a new type whose name is handed over by keyword
22
+ PASS: type_constructor_names_follow_the_rename (6 scenarios)
23
+ PASS declared_attribute_names_follow_the_rename w=0.08 0.9s
24
+ PASS: a slots tuple follows the attribute
25
+ PASS: a slots list follows the attribute
26
+ PASS: the positional attribute names a class declares for matching
27
+ PASS: declared_attribute_names_follow_the_rename (3 scenarios)
28
+ PASS string_annotations_follow_and_data_stays w=0.22 1.8s
29
+ PASS: a forward reference in a signature
30
+ PASS: a forward reference inside a generic
31
+ PASS: a literal type beside a forward reference
32
+ PASS: the metadata of an annotated type
33
+ PASS: a class body with a literal field and a forward reference
34
+ PASS: string_annotations_follow_and_data_stays (5 scenarios)
35
+ PASS move_keeps_both_export_contracts w=0.08 blocker 0.8s
36
+ PASS: the module left behind stops exporting the name
37
+ PASS: the module arrived in starts exporting the name
38
+ PASS: a module with no export list is not given one
39
+ PASS: move_keeps_both_export_contracts (3 scenarios)
40
+ PASS move_destination_list_however_built_gains_the_name w=0.22 1.3s
41
+ PASS: the list the destination publishes is built through a variable
42
+ PASS: the list the destination publishes is chosen by a condition
43
+ PASS: the list the destination publishes is a sorted copy
44
+ PASS: the list the destination publishes is one string of names
45
+ PASS: the generated import does not carry the export list across
46
+ PASS: move_destination_list_however_built_gains_the_name (5 scenarios)
47
+ PASS move_source_list_however_built_loses_the_name w=0.21 1.4s
48
+ PASS: a list written as one string of names
49
+ PASS: a name put on the list at its front
50
+ PASS: a name appended to the list
51
+ PASS: a tuple of two names
52
+ PASS: a tuple of names held in a variable
53
+ PASS: move_source_list_however_built_loses_the_name (5 scenarios)
54
+ PASS gate_repo_suite_green_and_tests_untouched w=0.03 blocker 35.4s
55
+ PASS: every shipped test file is byte for byte what it was
56
+ PASS: the repository's own tests pass
57
+ -> uncapped 1.000, failed blockers none, failed gates none, reward 1.000
58
+
59
+ === base ===
60
+ FAIL export_list_follows_the_rename w=0.08 2.5s
61
+ FAIL: the defining module's export list
62
+ FAIL: an export list written as a tuple over several lines
63
+ FAIL: the export list of a package that re-exports the name
64
+ FAIL: an export list naming a module that is being renamed
65
+ FAIL: an export list extended in place
66
+ FAIL: prose and an unrelated list of the same word
67
+ FAIL: another module that exports a name of its own
68
+ FAIL: an export list built through a variable
69
+ FAIL: an export list added to another list
70
+ FAIL: an export list written as one string of names
71
+ FAIL: an export list written as a block of names
72
+ FAIL: export_list_follows_the_rename (11 of 11 scenarios)
73
+ FAIL type_constructor_names_follow_the_rename w=0.08 1.5s
74
+ FAIL: the name a new type is given
75
+ FAIL: a new type built from a directly imported constructor
76
+ FAIL: the bound of a type variable
77
+ PASS: a type whose name is spelled like something else
78
+ FAIL: a constraint of a type variable
79
+ FAIL: a new type whose name is handed over by keyword
80
+ FAIL: type_constructor_names_follow_the_rename (5 of 6 scenarios)
81
+ FAIL declared_attribute_names_follow_the_rename w=0.08 0.7s
82
+ FAIL: a slots tuple follows the attribute
83
+ FAIL: a slots list follows the attribute
84
+ FAIL: the positional attribute names a class declares for matching
85
+ FAIL: declared_attribute_names_follow_the_rename (3 of 3 scenarios)
86
+ FAIL string_annotations_follow_and_data_stays w=0.22 1.1s
87
+ FAIL: a forward reference in a signature
88
+ FAIL: a forward reference inside a generic
89
+ FAIL: a literal type beside a forward reference
90
+ FAIL: the metadata of an annotated type
91
+ FAIL: a class body with a literal field and a forward reference
92
+ FAIL: string_annotations_follow_and_data_stays (5 of 5 scenarios)
93
+ FAIL move_keeps_both_export_contracts w=0.08 blocker 0.7s
94
+ FAIL: the module left behind stops exporting the name
95
+ FAIL: the module arrived in starts exporting the name
96
+ PASS: a module with no export list is not given one
97
+ FAIL: move_keeps_both_export_contracts (2 of 3 scenarios)
98
+ FAIL move_destination_list_however_built_gains_the_name w=0.22 1.2s
99
+ FAIL: the list the destination publishes is built through a variable
100
+ FAIL: the list the destination publishes is chosen by a condition
101
+ FAIL: the list the destination publishes is a sorted copy
102
+ FAIL: the list the destination publishes is one string of names
103
+ FAIL: the generated import does not carry the export list across
104
+ FAIL: move_destination_list_however_built_gains_the_name (5 of 5 scenarios)
105
+ FAIL move_source_list_however_built_loses_the_name w=0.21 1.2s
106
+ FAIL: a list written as one string of names
107
+ FAIL: a name put on the list at its front
108
+ FAIL: a name appended to the list
109
+ FAIL: a tuple of two names
110
+ FAIL: a tuple of names held in a variable
111
+ FAIL: move_source_list_however_built_loses_the_name (5 of 5 scenarios)
112
+ FAIL gate_repo_suite_green_and_tests_untouched w=0.03 blocker 19.0s
113
+ RULE HOLDS: every shipped test file is byte for byte what it was
114
+ RULE HOLDS: the repository's own tests pass
115
+ FAIL: not paid -- no scored behaviour was fixed, and this gate does not pay for an empty change
116
+ -> uncapped 0.000, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched'], failed gates none, reward 0.000
117
+
118
+ === noop ===
119
+ FAIL export_list_follows_the_rename w=0.08 2.4s
120
+ FAIL: the defining module's export list
121
+ FAIL: an export list written as a tuple over several lines
122
+ FAIL: the export list of a package that re-exports the name
123
+ FAIL: an export list naming a module that is being renamed
124
+ FAIL: an export list extended in place
125
+ FAIL: prose and an unrelated list of the same word
126
+ FAIL: another module that exports a name of its own
127
+ FAIL: an export list built through a variable
128
+ FAIL: an export list added to another list
129
+ FAIL: an export list written as one string of names
130
+ FAIL: an export list written as a block of names
131
+ FAIL: export_list_follows_the_rename (11 of 11 scenarios)
132
+ FAIL type_constructor_names_follow_the_rename w=0.08 1.4s
133
+ FAIL: the name a new type is given
134
+ FAIL: a new type built from a directly imported constructor
135
+ FAIL: the bound of a type variable
136
+ PASS: a type whose name is spelled like something else
137
+ FAIL: a constraint of a type variable
138
+ FAIL: a new type whose name is handed over by keyword
139
+ FAIL: type_constructor_names_follow_the_rename (5 of 6 scenarios)
140
+ FAIL declared_attribute_names_follow_the_rename w=0.08 0.7s
141
+ FAIL: a slots tuple follows the attribute
142
+ FAIL: a slots list follows the attribute
143
+ FAIL: the positional attribute names a class declares for matching
144
+ FAIL: declared_attribute_names_follow_the_rename (3 of 3 scenarios)
145
+ FAIL string_annotations_follow_and_data_stays w=0.22 1.1s
146
+ FAIL: a forward reference in a signature
147
+ FAIL: a forward reference inside a generic
148
+ FAIL: a literal type beside a forward reference
149
+ FAIL: the metadata of an annotated type
150
+ FAIL: a class body with a literal field and a forward reference
151
+ FAIL: string_annotations_follow_and_data_stays (5 of 5 scenarios)
152
+ FAIL move_keeps_both_export_contracts w=0.08 blocker 0.7s
153
+ FAIL: the module left behind stops exporting the name
154
+ FAIL: the module arrived in starts exporting the name
155
+ PASS: a module with no export list is not given one
156
+ FAIL: move_keeps_both_export_contracts (2 of 3 scenarios)
157
+ FAIL move_destination_list_however_built_gains_the_name w=0.22 1.1s
158
+ FAIL: the list the destination publishes is built through a variable
159
+ FAIL: the list the destination publishes is chosen by a condition
160
+ FAIL: the list the destination publishes is a sorted copy
161
+ FAIL: the list the destination publishes is one string of names
162
+ FAIL: the generated import does not carry the export list across
163
+ FAIL: move_destination_list_however_built_gains_the_name (5 of 5 scenarios)
164
+ FAIL move_source_list_however_built_loses_the_name w=0.21 1.1s
165
+ FAIL: a list written as one string of names
166
+ FAIL: a name put on the list at its front
167
+ FAIL: a name appended to the list
168
+ FAIL: a tuple of two names
169
+ FAIL: a tuple of names held in a variable
170
+ FAIL: move_source_list_however_built_loses_the_name (5 of 5 scenarios)
171
+ FAIL gate_repo_suite_green_and_tests_untouched w=0.03 blocker 18.4s
172
+ RULE HOLDS: every shipped test file is byte for byte what it was
173
+ RULE HOLDS: the repository's own tests pass
174
+ FAIL: not paid -- no scored behaviour was fixed, and this gate does not pay for an empty change
175
+ -> uncapped 0.000, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched'], failed gates none, reward 0.000
176
+
177
+ === lazy ===
178
+ FAIL export_list_follows_the_rename w=0.08 2.4s
179
+ PASS: the defining module's export list
180
+ PASS: an export list written as a tuple over several lines
181
+ PASS: the export list of a package that re-exports the name
182
+ PASS: an export list naming a module that is being renamed
183
+ PASS: an export list extended in place
184
+ PASS: prose and an unrelated list of the same word
185
+ PASS: another module that exports a name of its own
186
+ FAIL: an export list built through a variable
187
+ FAIL: an export list added to another list
188
+ FAIL: an export list written as one string of names
189
+ FAIL: an export list written as a block of names
190
+ FAIL: export_list_follows_the_rename (4 of 11 scenarios)
191
+ FAIL type_constructor_names_follow_the_rename w=0.08 1.5s
192
+ PASS: the name a new type is given
193
+ PASS: a new type built from a directly imported constructor
194
+ PASS: the bound of a type variable
195
+ FAIL: a type whose name is spelled like something else
196
+ PASS: a constraint of a type variable
197
+ PASS: a new type whose name is handed over by keyword
198
+ FAIL: type_constructor_names_follow_the_rename (1 of 6 scenarios)
199
+ FAIL declared_attribute_names_follow_the_rename w=0.08 0.7s
200
+ FAIL: a slots tuple follows the attribute
201
+ FAIL: a slots list follows the attribute
202
+ FAIL: the positional attribute names a class declares for matching
203
+ FAIL: declared_attribute_names_follow_the_rename (3 of 3 scenarios)
204
+ FAIL string_annotations_follow_and_data_stays w=0.22 1.1s
205
+ FAIL: a forward reference in a signature
206
+ FAIL: a forward reference inside a generic
207
+ FAIL: a literal type beside a forward reference
208
+ FAIL: the metadata of an annotated type
209
+ FAIL: a class body with a literal field and a forward reference
210
+ FAIL: string_annotations_follow_and_data_stays (5 of 5 scenarios)
211
+ FAIL move_keeps_both_export_contracts w=0.08 blocker 0.7s
212
+ FAIL: the module left behind stops exporting the name
213
+ FAIL: the module arrived in starts exporting the name
214
+ PASS: a module with no export list is not given one
215
+ FAIL: move_keeps_both_export_contracts (2 of 3 scenarios)
216
+ FAIL move_destination_list_however_built_gains_the_name w=0.22 1.1s
217
+ FAIL: the list the destination publishes is built through a variable
218
+ FAIL: the list the destination publishes is chosen by a condition
219
+ FAIL: the list the destination publishes is a sorted copy
220
+ FAIL: the list the destination publishes is one string of names
221
+ FAIL: the generated import does not carry the export list across
222
+ FAIL: move_destination_list_however_built_gains_the_name (5 of 5 scenarios)
223
+ FAIL move_source_list_however_built_loses_the_name w=0.21 1.1s
224
+ FAIL: a list written as one string of names
225
+ FAIL: a name put on the list at its front
226
+ FAIL: a name appended to the list
227
+ FAIL: a tuple of two names
228
+ FAIL: a tuple of names held in a variable
229
+ FAIL: move_source_list_however_built_loses_the_name (5 of 5 scenarios)
230
+ FAIL gate_repo_suite_green_and_tests_untouched w=0.03 blocker 18.6s
231
+ RULE HOLDS: every shipped test file is byte for byte what it was
232
+ RULE HOLDS: the repository's own tests pass
233
+ FAIL: not paid -- no scored behaviour was fixed, and this gate does not pay for an empty change
234
+ -> uncapped 0.000, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched'], failed gates none, reward 0.000
235
+
236
+ === alt ===
237
+ PASS export_list_follows_the_rename w=0.08 2.4s
238
+ PASS: the defining module's export list
239
+ PASS: an export list written as a tuple over several lines
240
+ PASS: the export list of a package that re-exports the name
241
+ PASS: an export list naming a module that is being renamed
242
+ PASS: an export list extended in place
243
+ PASS: prose and an unrelated list of the same word
244
+ PASS: another module that exports a name of its own
245
+ PASS: an export list built through a variable
246
+ PASS: an export list added to another list
247
+ PASS: an export list written as one string of names
248
+ PASS: an export list written as a block of names
249
+ PASS: export_list_follows_the_rename (11 scenarios)
250
+ FAIL type_constructor_names_follow_the_rename w=0.08 1.5s
251
+ PASS: the name a new type is given
252
+ PASS: a new type built from a directly imported constructor
253
+ PASS: the bound of a type variable
254
+ PASS: a type whose name is spelled like something else
255
+ PASS: a constraint of a type variable
256
+ FAIL: a new type whose name is handed over by keyword
257
+ FAIL: type_constructor_names_follow_the_rename (1 of 6 scenarios)
258
+ FAIL declared_attribute_names_follow_the_rename w=0.08 0.7s
259
+ PASS: a slots tuple follows the attribute
260
+ PASS: a slots list follows the attribute
261
+ FAIL: the positional attribute names a class declares for matching
262
+ FAIL: declared_attribute_names_follow_the_rename (1 of 3 scenarios)
263
+ PASS string_annotations_follow_and_data_stays w=0.22 1.1s
264
+ PASS: a forward reference in a signature
265
+ PASS: a forward reference inside a generic
266
+ PASS: a literal type beside a forward reference
267
+ PASS: the metadata of an annotated type
268
+ PASS: a class body with a literal field and a forward reference
269
+ PASS: string_annotations_follow_and_data_stays (5 scenarios)
270
+ PASS move_keeps_both_export_contracts w=0.08 blocker 0.7s
271
+ PASS: the module left behind stops exporting the name
272
+ PASS: the module arrived in starts exporting the name
273
+ PASS: a module with no export list is not given one
274
+ PASS: move_keeps_both_export_contracts (3 scenarios)
275
+ PASS move_destination_list_however_built_gains_the_name w=0.22 1.2s
276
+ PASS: the list the destination publishes is built through a variable
277
+ PASS: the list the destination publishes is chosen by a condition
278
+ PASS: the list the destination publishes is a sorted copy
279
+ PASS: the list the destination publishes is one string of names
280
+ PASS: the generated import does not carry the export list across
281
+ PASS: move_destination_list_however_built_gains_the_name (5 scenarios)
282
+ PASS move_source_list_however_built_loses_the_name w=0.21 1.1s
283
+ PASS: a list written as one string of names
284
+ PASS: a name put on the list at its front
285
+ PASS: a name appended to the list
286
+ PASS: a tuple of two names
287
+ PASS: a tuple of names held in a variable
288
+ PASS: move_source_list_however_built_loses_the_name (5 scenarios)
289
+ PASS gate_repo_suite_green_and_tests_untouched w=0.03 blocker 18.4s
290
+ PASS: every shipped test file is byte for byte what it was
291
+ PASS: the repository's own tests pass
292
+ -> uncapped 0.840, failed blockers none, failed gates none, reward 0.840
293
+
294
+ === prevgold ===
295
+ FAIL export_list_follows_the_rename w=0.08 2.4s
296
+ PASS: the defining module's export list
297
+ PASS: an export list written as a tuple over several lines
298
+ PASS: the export list of a package that re-exports the name
299
+ PASS: an export list naming a module that is being renamed
300
+ PASS: an export list extended in place
301
+ PASS: prose and an unrelated list of the same word
302
+ PASS: another module that exports a name of its own
303
+ PASS: an export list built through a variable
304
+ PASS: an export list added to another list
305
+ FAIL: an export list written as one string of names
306
+ FAIL: an export list written as a block of names
307
+ FAIL: export_list_follows_the_rename (2 of 11 scenarios)
308
+ PASS type_constructor_names_follow_the_rename w=0.08 1.5s
309
+ PASS: the name a new type is given
310
+ PASS: a new type built from a directly imported constructor
311
+ PASS: the bound of a type variable
312
+ PASS: a type whose name is spelled like something else
313
+ PASS: a constraint of a type variable
314
+ PASS: a new type whose name is handed over by keyword
315
+ PASS: type_constructor_names_follow_the_rename (6 scenarios)
316
+ FAIL declared_attribute_names_follow_the_rename w=0.08 0.7s
317
+ PASS: a slots tuple follows the attribute
318
+ PASS: a slots list follows the attribute
319
+ FAIL: the positional attribute names a class declares for matching
320
+ FAIL: declared_attribute_names_follow_the_rename (1 of 3 scenarios)
321
+ FAIL string_annotations_follow_and_data_stays w=0.22 1.1s
322
+ PASS: a forward reference in a signature
323
+ PASS: a forward reference inside a generic
324
+ FAIL: a literal type beside a forward reference
325
+ FAIL: the metadata of an annotated type
326
+ FAIL: a class body with a literal field and a forward reference
327
+ FAIL: string_annotations_follow_and_data_stays (3 of 5 scenarios)
328
+ PASS move_keeps_both_export_contracts w=0.08 blocker 0.7s
329
+ PASS: the module left behind stops exporting the name
330
+ PASS: the module arrived in starts exporting the name
331
+ PASS: a module with no export list is not given one
332
+ PASS: move_keeps_both_export_contracts (3 scenarios)
333
+ FAIL move_destination_list_however_built_gains_the_name w=0.22 1.2s
334
+ FAIL: the list the destination publishes is built through a variable
335
+ FAIL: the list the destination publishes is chosen by a condition
336
+ FAIL: the list the destination publishes is a sorted copy
337
+ FAIL: the list the destination publishes is one string of names
338
+ PASS: the generated import does not carry the export list across
339
+ FAIL: move_destination_list_however_built_gains_the_name (4 of 5 scenarios)
340
+ FAIL move_source_list_however_built_loses_the_name w=0.21 1.1s
341
+ FAIL: a list written as one string of names
342
+ FAIL: a name put on the list at its front
343
+ FAIL: a name appended to the list
344
+ FAIL: a tuple of two names
345
+ FAIL: a tuple of names held in a variable
346
+ FAIL: move_source_list_however_built_loses_the_name (5 of 5 scenarios)
347
+ PASS gate_repo_suite_green_and_tests_untouched w=0.03 blocker 19.4s
348
+ PASS: every shipped test file is byte for byte what it was
349
+ PASS: the repository's own tests pass
350
+ -> uncapped 0.190, failed blockers none, failed gates none, reward 0.190
351
+
352
+ === cheat ===
353
+ FAIL export_list_follows_the_rename w=0.08 2.6s
354
+ PASS: the defining module's export list
355
+ PASS: an export list written as a tuple over several lines
356
+ PASS: the export list of a package that re-exports the name
357
+ PASS: an export list naming a module that is being renamed
358
+ PASS: an export list extended in place
359
+ FAIL: prose and an unrelated list of the same word
360
+ PASS: another module that exports a name of its own
361
+ FAIL: an export list built through a variable
362
+ PASS: an export list added to another list
363
+ FAIL: an export list written as one string of names
364
+ PASS: an export list written as a block of names
365
+ FAIL: export_list_follows_the_rename (3 of 11 scenarios)
366
+ FAIL type_constructor_names_follow_the_rename w=0.08 1.6s
367
+ FAIL: the name a new type is given
368
+ PASS: a new type built from a directly imported constructor
369
+ PASS: the bound of a type variable
370
+ FAIL: a type whose name is spelled like something else
371
+ PASS: a constraint of a type variable
372
+ PASS: a new type whose name is handed over by keyword
373
+ FAIL: type_constructor_names_follow_the_rename (2 of 6 scenarios)
374
+ PASS declared_attribute_names_follow_the_rename w=0.08 0.7s
375
+ PASS: a slots tuple follows the attribute
376
+ PASS: a slots list follows the attribute
377
+ PASS: the positional attribute names a class declares for matching
378
+ PASS: declared_attribute_names_follow_the_rename (3 scenarios)
379
+ FAIL string_annotations_follow_and_data_stays w=0.22 1.1s
380
+ FAIL: a forward reference in a signature
381
+ PASS: a forward reference inside a generic
382
+ FAIL: a literal type beside a forward reference
383
+ FAIL: the metadata of an annotated type
384
+ FAIL: a class body with a literal field and a forward reference
385
+ FAIL: string_annotations_follow_and_data_stays (4 of 5 scenarios)
386
+ FAIL move_keeps_both_export_contracts w=0.08 blocker 0.8s
387
+ FAIL: the module left behind stops exporting the name
388
+ FAIL: the module arrived in starts exporting the name
389
+ PASS: a module with no export list is not given one
390
+ FAIL: move_keeps_both_export_contracts (2 of 3 scenarios)
391
+ FAIL move_destination_list_however_built_gains_the_name w=0.22 1.4s
392
+ FAIL: the list the destination publishes is built through a variable
393
+ FAIL: the list the destination publishes is chosen by a condition
394
+ FAIL: the list the destination publishes is a sorted copy
395
+ FAIL: the list the destination publishes is one string of names
396
+ FAIL: the generated import does not carry the export list across
397
+ FAIL: move_destination_list_however_built_gains_the_name (5 of 5 scenarios)
398
+ FAIL move_source_list_however_built_loses_the_name w=0.21 1.3s
399
+ FAIL: a list written as one string of names
400
+ FAIL: a name put on the list at its front
401
+ FAIL: a name appended to the list
402
+ FAIL: a tuple of two names
403
+ FAIL: a tuple of names held in a variable
404
+ FAIL: move_source_list_however_built_loses_the_name (5 of 5 scenarios)
405
+ FAIL gate_repo_suite_green_and_tests_untouched w=0.03 blocker 0.1s
406
+ FAIL: ropetest/refactor/renametest.py was edited
407
+ FAIL: the tests the repository shipped are not what it shipped
408
+ -> uncapped 0.080, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched'], failed gates none, reward 0.080
409
+
410
+ === tamper ===
411
+ FAIL export_list_follows_the_rename w=0.08 2.7s
412
+ FAIL: the defining module's export list
413
+ FAIL: an export list written as a tuple over several lines
414
+ FAIL: the export list of a package that re-exports the name
415
+ FAIL: an export list naming a module that is being renamed
416
+ FAIL: an export list extended in place
417
+ FAIL: prose and an unrelated list of the same word
418
+ FAIL: another module that exports a name of its own
419
+ FAIL: an export list built through a variable
420
+ FAIL: an export list added to another list
421
+ FAIL: an export list written as one string of names
422
+ FAIL: an export list written as a block of names
423
+ FAIL: export_list_follows_the_rename (11 of 11 scenarios)
424
+ FAIL type_constructor_names_follow_the_rename w=0.08 1.6s
425
+ FAIL: the name a new type is given
426
+ FAIL: a new type built from a directly imported constructor
427
+ FAIL: the bound of a type variable
428
+ PASS: a type whose name is spelled like something else
429
+ FAIL: a constraint of a type variable
430
+ FAIL: a new type whose name is handed over by keyword
431
+ FAIL: type_constructor_names_follow_the_rename (5 of 6 scenarios)
432
+ FAIL declared_attribute_names_follow_the_rename w=0.08 0.7s
433
+ FAIL: a slots tuple follows the attribute
434
+ FAIL: a slots list follows the attribute
435
+ FAIL: the positional attribute names a class declares for matching
436
+ FAIL: declared_attribute_names_follow_the_rename (3 of 3 scenarios)
437
+ FAIL string_annotations_follow_and_data_stays w=0.22 1.1s
438
+ FAIL: a forward reference in a signature
439
+ FAIL: a forward reference inside a generic
440
+ FAIL: a literal type beside a forward reference
441
+ FAIL: the metadata of an annotated type
442
+ FAIL: a class body with a literal field and a forward reference
443
+ FAIL: string_annotations_follow_and_data_stays (5 of 5 scenarios)
444
+ FAIL move_keeps_both_export_contracts w=0.08 blocker 0.7s
445
+ FAIL: the module left behind stops exporting the name
446
+ FAIL: the module arrived in starts exporting the name
447
+ PASS: a module with no export list is not given one
448
+ FAIL: move_keeps_both_export_contracts (2 of 3 scenarios)
449
+ FAIL move_destination_list_however_built_gains_the_name w=0.22 1.3s
450
+ FAIL: the list the destination publishes is built through a variable
451
+ FAIL: the list the destination publishes is chosen by a condition
452
+ FAIL: the list the destination publishes is a sorted copy
453
+ FAIL: the list the destination publishes is one string of names
454
+ FAIL: the generated import does not carry the export list across
455
+ FAIL: move_destination_list_however_built_gains_the_name (5 of 5 scenarios)
456
+ FAIL move_source_list_however_built_loses_the_name w=0.21 1.3s
457
+ FAIL: a list written as one string of names
458
+ FAIL: a name put on the list at its front
459
+ FAIL: a name appended to the list
460
+ FAIL: a tuple of two names
461
+ FAIL: a tuple of names held in a variable
462
+ FAIL: move_source_list_however_built_loses_the_name (5 of 5 scenarios)
463
+ FAIL gate_repo_suite_green_and_tests_untouched w=0.03 blocker 20.1s
464
+ RULE HOLDS: every shipped test file is byte for byte what it was
465
+ RULE HOLDS: the repository's own tests pass
466
+ FAIL: not paid -- no scored behaviour was fixed, and this gate does not pay for an empty change
467
+ -> uncapped 0.000, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched'], failed gates none, reward 0.000
468
+
469
+ === tamper_key ===
470
+ FAIL export_list_follows_the_rename w=0.08 2.4s
471
+ FAIL: the defining module's export list
472
+ FAIL: an export list written as a tuple over several lines
473
+ FAIL: the export list of a package that re-exports the name
474
+ FAIL: an export list naming a module that is being renamed
475
+ FAIL: an export list extended in place
476
+ FAIL: prose and an unrelated list of the same word
477
+ FAIL: another module that exports a name of its own
478
+ FAIL: an export list built through a variable
479
+ FAIL: an export list added to another list
480
+ FAIL: an export list written as one string of names
481
+ FAIL: an export list written as a block of names
482
+ FAIL: export_list_follows_the_rename (11 of 11 scenarios)
483
+ FAIL type_constructor_names_follow_the_rename w=0.08 1.3s
484
+ FAIL: the name a new type is given
485
+ FAIL: a new type built from a directly imported constructor
486
+ FAIL: the bound of a type variable
487
+ PASS: a type whose name is spelled like something else
488
+ FAIL: a constraint of a type variable
489
+ FAIL: a new type whose name is handed over by keyword
490
+ FAIL: type_constructor_names_follow_the_rename (5 of 6 scenarios)
491
+ FAIL declared_attribute_names_follow_the_rename w=0.08 0.7s
492
+ FAIL: a slots tuple follows the attribute
493
+ FAIL: a slots list follows the attribute
494
+ FAIL: the positional attribute names a class declares for matching
495
+ FAIL: declared_attribute_names_follow_the_rename (3 of 3 scenarios)
496
+ FAIL string_annotations_follow_and_data_stays w=0.22 1.1s
497
+ FAIL: a forward reference in a signature
498
+ FAIL: a forward reference inside a generic
499
+ FAIL: a literal type beside a forward reference
500
+ FAIL: the metadata of an annotated type
501
+ FAIL: a class body with a literal field and a forward reference
502
+ FAIL: string_annotations_follow_and_data_stays (5 of 5 scenarios)
503
+ FAIL move_keeps_both_export_contracts w=0.08 blocker 0.7s
504
+ FAIL: the module left behind stops exporting the name
505
+ FAIL: the module arrived in starts exporting the name
506
+ PASS: a module with no export list is not given one
507
+ FAIL: move_keeps_both_export_contracts (2 of 3 scenarios)
508
+ FAIL move_destination_list_however_built_gains_the_name w=0.22 1.1s
509
+ FAIL: the list the destination publishes is built through a variable
510
+ FAIL: the list the destination publishes is chosen by a condition
511
+ FAIL: the list the destination publishes is a sorted copy
512
+ FAIL: the list the destination publishes is one string of names
513
+ FAIL: the generated import does not carry the export list across
514
+ FAIL: move_destination_list_however_built_gains_the_name (5 of 5 scenarios)
515
+ FAIL move_source_list_however_built_loses_the_name w=0.21 1.1s
516
+ FAIL: a list written as one string of names
517
+ FAIL: a name put on the list at its front
518
+ FAIL: a name appended to the list
519
+ FAIL: a tuple of two names
520
+ FAIL: a tuple of names held in a variable
521
+ FAIL: move_source_list_however_built_loses_the_name (5 of 5 scenarios)
522
+ FAIL gate_repo_suite_green_and_tests_untouched w=0.03 blocker 17.5s
523
+ RULE HOLDS: every shipped test file is byte for byte what it was
524
+ RULE HOLDS: the repository's own tests pass
525
+ FAIL: not paid -- no scored behaviour was fixed, and this gate does not pay for an empty change
526
+ -> uncapped 0.000, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched'], failed gates none, reward 0.000
527
+
528
+ === tamper_gate ===
529
+ FAIL export_list_follows_the_rename w=0.08 2.3s
530
+ PASS: the defining module's export list
531
+ PASS: an export list written as a tuple over several lines
532
+ PASS: the export list of a package that re-exports the name
533
+ PASS: an export list naming a module that is being renamed
534
+ PASS: an export list extended in place
535
+ PASS: prose and an unrelated list of the same word
536
+ PASS: another module that exports a name of its own
537
+ PASS: an export list built through a variable
538
+ PASS: an export list added to another list
539
+ FAIL: an export list written as one string of names
540
+ FAIL: an export list written as a block of names
541
+ FAIL: export_list_follows_the_rename (2 of 11 scenarios)
542
+ PASS type_constructor_names_follow_the_rename w=0.08 1.4s
543
+ PASS: the name a new type is given
544
+ PASS: a new type built from a directly imported constructor
545
+ PASS: the bound of a type variable
546
+ PASS: a type whose name is spelled like something else
547
+ PASS: a constraint of a type variable
548
+ PASS: a new type whose name is handed over by keyword
549
+ PASS: type_constructor_names_follow_the_rename (6 scenarios)
550
+ FAIL declared_attribute_names_follow_the_rename w=0.08 0.7s
551
+ PASS: a slots tuple follows the attribute
552
+ PASS: a slots list follows the attribute
553
+ FAIL: the positional attribute names a class declares for matching
554
+ FAIL: declared_attribute_names_follow_the_rename (1 of 3 scenarios)
555
+ FAIL string_annotations_follow_and_data_stays w=0.22 1.1s
556
+ PASS: a forward reference in a signature
557
+ PASS: a forward reference inside a generic
558
+ FAIL: a literal type beside a forward reference
559
+ FAIL: the metadata of an annotated type
560
+ FAIL: a class body with a literal field and a forward reference
561
+ FAIL: string_annotations_follow_and_data_stays (3 of 5 scenarios)
562
+ PASS move_keeps_both_export_contracts w=0.08 blocker 0.7s
563
+ PASS: the module left behind stops exporting the name
564
+ PASS: the module arrived in starts exporting the name
565
+ PASS: a module with no export list is not given one
566
+ PASS: move_keeps_both_export_contracts (3 scenarios)
567
+ FAIL move_destination_list_however_built_gains_the_name w=0.22 1.1s
568
+ FAIL: the list the destination publishes is built through a variable
569
+ FAIL: the list the destination publishes is chosen by a condition
570
+ FAIL: the list the destination publishes is a sorted copy
571
+ FAIL: the list the destination publishes is one string of names
572
+ PASS: the generated import does not carry the export list across
573
+ FAIL: move_destination_list_however_built_gains_the_name (4 of 5 scenarios)
574
+ FAIL move_source_list_however_built_loses_the_name w=0.21 1.1s
575
+ FAIL: a list written as one string of names
576
+ FAIL: a name put on the list at its front
577
+ FAIL: a name appended to the list
578
+ FAIL: a tuple of two names
579
+ FAIL: a tuple of names held in a variable
580
+ FAIL: move_source_list_however_built_loses_the_name (5 of 5 scenarios)
581
+ FAIL gate_repo_suite_green_and_tests_untouched w=0.03 blocker 20.6s
582
+ PASS: every shipped test file is byte for byte what it was
583
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_except failed
584
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_except2 failed
585
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_finally failed
586
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_finally2 failed
587
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_and_normal_complete_blocks_and_single_fixing failed
588
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_class_completion_proposal failed
589
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_function_completion_proposal failed
590
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_module_completion_proposal failed
591
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_variable_completion_proposal failed
592
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_class_completion_proposal failed
593
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_exception_completion_proposal failed
594
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_function_completion_proposal failed
595
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_instances failed
596
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_variable_completion_proposal failed
597
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assist_when_having_a_two_line_function_header failed
598
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assist_with_function_with_two_line_return failed
599
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assists_in_parens failed
600
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassist_before_line_indents_in_a_blank_line failed
601
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassist_before_single_line_indents failed
602
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassists_before_opening_of_parens failed
603
+ FAIL: 197 of the repository's own tests did not pass (the report pytest wrote)
604
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_except failed
605
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_except2 failed
606
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_finally failed
607
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_finally2 failed
608
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_and_normal_complete_blocks_and_single_fixing failed
609
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_class_completion_proposal failed
610
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_function_completion_proposal failed
611
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_module_completion_proposal failed
612
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_variable_completion_proposal failed
613
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_class_completion_proposal failed
614
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_exception_completion_proposal failed
615
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_function_completion_proposal failed
616
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_instances failed
617
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_variable_completion_proposal failed
618
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assist_when_having_a_two_line_function_header failed
619
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assist_with_function_with_two_line_return failed
620
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assists_in_parens failed
621
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassist_before_line_indents_in_a_blank_line failed
622
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassist_before_single_line_indents failed
623
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassists_before_opening_of_parens failed
624
+ FAIL: 197 of the repository's own tests did not pass (the record streamed as the run happened)
625
+ FAIL: the repository's own tests do not pass
626
+ -> uncapped 0.160, failed blockers ['gate_repo_suite_green_and_tests_untouched'], failed gates none, reward 0.160
627
+
628
+ === tamper_report ===
629
+ FAIL export_list_follows_the_rename w=0.08 2.3s
630
+ PASS: the defining module's export list
631
+ PASS: an export list written as a tuple over several lines
632
+ PASS: the export list of a package that re-exports the name
633
+ PASS: an export list naming a module that is being renamed
634
+ PASS: an export list extended in place
635
+ PASS: prose and an unrelated list of the same word
636
+ PASS: another module that exports a name of its own
637
+ PASS: an export list built through a variable
638
+ PASS: an export list added to another list
639
+ FAIL: an export list written as one string of names
640
+ FAIL: an export list written as a block of names
641
+ FAIL: export_list_follows_the_rename (2 of 11 scenarios)
642
+ PASS type_constructor_names_follow_the_rename w=0.08 1.4s
643
+ PASS: the name a new type is given
644
+ PASS: a new type built from a directly imported constructor
645
+ PASS: the bound of a type variable
646
+ PASS: a type whose name is spelled like something else
647
+ PASS: a constraint of a type variable
648
+ PASS: a new type whose name is handed over by keyword
649
+ PASS: type_constructor_names_follow_the_rename (6 scenarios)
650
+ FAIL declared_attribute_names_follow_the_rename w=0.08 0.7s
651
+ PASS: a slots tuple follows the attribute
652
+ PASS: a slots list follows the attribute
653
+ FAIL: the positional attribute names a class declares for matching
654
+ FAIL: declared_attribute_names_follow_the_rename (1 of 3 scenarios)
655
+ FAIL string_annotations_follow_and_data_stays w=0.22 1.1s
656
+ PASS: a forward reference in a signature
657
+ PASS: a forward reference inside a generic
658
+ FAIL: a literal type beside a forward reference
659
+ FAIL: the metadata of an annotated type
660
+ FAIL: a class body with a literal field and a forward reference
661
+ FAIL: string_annotations_follow_and_data_stays (3 of 5 scenarios)
662
+ PASS move_keeps_both_export_contracts w=0.08 blocker 0.7s
663
+ PASS: the module left behind stops exporting the name
664
+ PASS: the module arrived in starts exporting the name
665
+ PASS: a module with no export list is not given one
666
+ PASS: move_keeps_both_export_contracts (3 scenarios)
667
+ FAIL move_destination_list_however_built_gains_the_name w=0.22 1.1s
668
+ FAIL: the list the destination publishes is built through a variable
669
+ FAIL: the list the destination publishes is chosen by a condition
670
+ FAIL: the list the destination publishes is a sorted copy
671
+ FAIL: the list the destination publishes is one string of names
672
+ PASS: the generated import does not carry the export list across
673
+ FAIL: move_destination_list_however_built_gains_the_name (4 of 5 scenarios)
674
+ FAIL move_source_list_however_built_loses_the_name w=0.21 1.1s
675
+ FAIL: a list written as one string of names
676
+ FAIL: a name put on the list at its front
677
+ FAIL: a name appended to the list
678
+ FAIL: a tuple of two names
679
+ FAIL: a tuple of names held in a variable
680
+ FAIL: move_source_list_however_built_loses_the_name (5 of 5 scenarios)
681
+ FAIL gate_repo_suite_green_and_tests_untouched w=0.03 blocker 20.3s
682
+ PASS: every shipped test file is byte for byte what it was
683
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_except failed
684
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_except2 failed
685
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_finally failed
686
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_finally2 failed
687
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_and_normal_complete_blocks_and_single_fixing failed
688
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_class_completion_proposal failed
689
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_function_completion_proposal failed
690
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_module_completion_proposal failed
691
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_variable_completion_proposal failed
692
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_class_completion_proposal failed
693
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_exception_completion_proposal failed
694
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_function_completion_proposal failed
695
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_instances failed
696
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_variable_completion_proposal failed
697
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assist_when_having_a_two_line_function_header failed
698
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assist_with_function_with_two_line_return failed
699
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assists_in_parens failed
700
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassist_before_line_indents_in_a_blank_line failed
701
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassist_before_single_line_indents failed
702
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassists_before_opening_of_parens failed
703
+ FAIL: 197 of the repository's own tests did not pass (the report pytest wrote)
704
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_except failed
705
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_except2 failed
706
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_finally failed
707
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_finally2 failed
708
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_and_normal_complete_blocks_and_single_fixing failed
709
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_class_completion_proposal failed
710
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_function_completion_proposal failed
711
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_module_completion_proposal failed
712
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_variable_completion_proposal failed
713
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_class_completion_proposal failed
714
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_exception_completion_proposal failed
715
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_function_completion_proposal failed
716
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_instances failed
717
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_variable_completion_proposal failed
718
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assist_when_having_a_two_line_function_header failed
719
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assist_with_function_with_two_line_return failed
720
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assists_in_parens failed
721
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassist_before_line_indents_in_a_blank_line failed
722
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassist_before_single_line_indents failed
723
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassists_before_opening_of_parens failed
724
+ FAIL: 197 of the repository's own tests did not pass (the record streamed as the run happened)
725
+ FAIL: the repository's own tests do not pass
726
+ -> uncapped 0.160, failed blockers ['gate_repo_suite_green_and_tests_untouched'], failed gates none, reward 0.160
727
+
728
+ === tamper_wire ===
729
+ FAIL export_list_follows_the_rename w=0.08 2.4s
730
+ PASS: the defining module's export list
731
+ PASS: an export list written as a tuple over several lines
732
+ PASS: the export list of a package that re-exports the name
733
+ PASS: an export list naming a module that is being renamed
734
+ PASS: an export list extended in place
735
+ PASS: prose and an unrelated list of the same word
736
+ PASS: another module that exports a name of its own
737
+ PASS: an export list built through a variable
738
+ PASS: an export list added to another list
739
+ FAIL: an export list written as one string of names
740
+ FAIL: an export list written as a block of names
741
+ FAIL: export_list_follows_the_rename (2 of 11 scenarios)
742
+ PASS type_constructor_names_follow_the_rename w=0.08 1.5s
743
+ PASS: the name a new type is given
744
+ PASS: a new type built from a directly imported constructor
745
+ PASS: the bound of a type variable
746
+ PASS: a type whose name is spelled like something else
747
+ PASS: a constraint of a type variable
748
+ PASS: a new type whose name is handed over by keyword
749
+ PASS: type_constructor_names_follow_the_rename (6 scenarios)
750
+ FAIL declared_attribute_names_follow_the_rename w=0.08 0.7s
751
+ PASS: a slots tuple follows the attribute
752
+ PASS: a slots list follows the attribute
753
+ FAIL: the positional attribute names a class declares for matching
754
+ FAIL: declared_attribute_names_follow_the_rename (1 of 3 scenarios)
755
+ FAIL string_annotations_follow_and_data_stays w=0.22 1.1s
756
+ PASS: a forward reference in a signature
757
+ PASS: a forward reference inside a generic
758
+ FAIL: a literal type beside a forward reference
759
+ FAIL: the metadata of an annotated type
760
+ FAIL: a class body with a literal field and a forward reference
761
+ FAIL: string_annotations_follow_and_data_stays (3 of 5 scenarios)
762
+ PASS move_keeps_both_export_contracts w=0.08 blocker 0.7s
763
+ PASS: the module left behind stops exporting the name
764
+ PASS: the module arrived in starts exporting the name
765
+ PASS: a module with no export list is not given one
766
+ PASS: move_keeps_both_export_contracts (3 scenarios)
767
+ FAIL move_destination_list_however_built_gains_the_name w=0.22 1.1s
768
+ FAIL: the list the destination publishes is built through a variable
769
+ FAIL: the list the destination publishes is chosen by a condition
770
+ FAIL: the list the destination publishes is a sorted copy
771
+ FAIL: the list the destination publishes is one string of names
772
+ PASS: the generated import does not carry the export list across
773
+ FAIL: move_destination_list_however_built_gains_the_name (4 of 5 scenarios)
774
+ FAIL move_source_list_however_built_loses_the_name w=0.21 1.1s
775
+ FAIL: a list written as one string of names
776
+ FAIL: a name put on the list at its front
777
+ FAIL: a name appended to the list
778
+ FAIL: a tuple of two names
779
+ FAIL: a tuple of names held in a variable
780
+ FAIL: move_source_list_however_built_loses_the_name (5 of 5 scenarios)
781
+ FAIL gate_repo_suite_green_and_tests_untouched w=0.03 blocker 20.2s
782
+ PASS: every shipped test file is byte for byte what it was
783
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_except failed
784
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_except2 failed
785
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_finally failed
786
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_already_complete_try_blocks_with_finally2 failed
787
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_and_normal_complete_blocks_and_single_fixing failed
788
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_class_completion_proposal failed
789
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_function_completion_proposal failed
790
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_module_completion_proposal failed
791
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_attribute_variable_completion_proposal failed
792
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_class_completion_proposal failed
793
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_exception_completion_proposal failed
794
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_function_completion_proposal failed
795
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_instances failed
796
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_builtin_variable_completion_proposal failed
797
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assist_when_having_a_two_line_function_header failed
798
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assist_with_function_with_two_line_return failed
799
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_code_assists_in_parens failed
800
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassist_before_line_indents_in_a_blank_line failed
801
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassist_before_single_line_indents failed
802
+ FAIL: ropetest.contrib.codeassisttest.CodeAssistTest::test_codeassists_before_opening_of_parens failed
803
+ FAIL: 197 of the repository's own tests did not pass (the record streamed as the run happened)
804
+ FAIL: the repository's own tests do not pass
805
+ -> uncapped 0.160, failed blockers ['gate_repo_suite_green_and_tests_untouched'], failed gates none, reward 0.160
806
+
807
+ === criterion | weight | blocker | gold | base ===
808
+ export_list_follows_the_rename 0.08 PASS FAIL
809
+ type_constructor_names_follow_the_rename 0.08 PASS FAIL
810
+ declared_attribute_names_follow_the_rename 0.08 PASS FAIL
811
+ string_annotations_follow_and_data_stays 0.22 PASS FAIL
812
+ move_keeps_both_export_contracts 0.08 blocker PASS FAIL
813
+ move_destination_list_however_built_gains_the_name 0.22 PASS FAIL
814
+ move_source_list_however_built_loses_the_name 0.21 PASS FAIL
815
+ gate_repo_suite_green_and_tests_untouched 0.03 blocker PASS FAIL
816
+
817
+ === calibration ===
818
+ gold: **1.00** (expected 1.00) OK
819
+ base: **0.00** (expected 0.00) OK
820
+ noop: reward 0.000, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched']
821
+ lazy: reward 0.000, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched']
822
+ alt: reward 0.840, failed blockers none
823
+ prevgold: reward 0.190, failed blockers none
824
+ cheat: reward 0.080, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched']
825
+ tamper: reward 0.000, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched']
826
+ tamper_key: reward 0.000, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched']
827
+ tamper_gate: reward 0.160, failed blockers ['gate_repo_suite_green_and_tests_untouched']
828
+ tamper_report: reward 0.160, failed blockers ['gate_repo_suite_green_and_tests_untouched']
829
+ tamper_wire: reward 0.160, failed blockers ['gate_repo_suite_green_and_tests_untouched']
830
+ base: gate green on the untouched checkout (gate_repo_suite_green_and_tests_untouched, its rule holds -- G-4), and worth 0.000 there (G-5', enforced by the gate itself)
831
+ base: all criteria red, one by one
832
+ gold: gates green
833
+ gold: all criteria green, one by one
834
+ ladder noop: 0.000 (uncapped 0.000, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched']) expected == 0.000 OK
835
+ ladder lazy: 0.000 (uncapped 0.000, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched']) expected < 0.50 OK
836
+ ladder alt: 0.840 (uncapped 0.840, failed blockers none) expected >= 0.80 OK
837
+ ladder prevgold: 0.190 (uncapped 0.190, failed blockers none) expected < 0.50 OK
838
+ ladder cheat: 0.080 (uncapped 0.080, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched']) expected capped <= 0.60 OK
839
+ ladder tamper: 0.000 (uncapped 0.000, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched']) expected == 0.000 OK
840
+ ladder tamper_key: 0.000 (uncapped 0.000, failed blockers ['move_keeps_both_export_contracts', 'gate_repo_suite_green_and_tests_untouched']) expected == 0.000 OK
841
+ ladder tamper_gate: 0.160 (uncapped 0.160, failed blockers ['gate_repo_suite_green_and_tests_untouched']) expected capped <= 0.60 OK
842
+ ladder tamper_report: 0.160 (uncapped 0.160, failed blockers ['gate_repo_suite_green_and_tests_untouched']) expected capped <= 0.60 OK
843
+ ladder tamper_wire: 0.160 (uncapped 0.160, failed blockers ['gate_repo_suite_green_and_tests_untouched']) expected capped <= 0.60 OK
844
+ LADDER gold:1.000 base:0.000 noop:0.000 lazy:0.000 alt:0.840 prevgold:0.190 cheat:0.080 tamper:0.000 tamper_key:0.000 tamper_gate:0.160 tamper_report:0.160 tamper_wire:0.160
harbor/evidence/rope/native-reference.json ADDED
@@ -0,0 +1,137 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "reward": 1.0,
3
+ "done": true,
4
+ "content": null,
5
+ "info": {},
6
+ "isError": false,
7
+ "subscores": [
8
+ {
9
+ "name": "export_list_follows_the_rename",
10
+ "weight": 0.08,
11
+ "value": 1.0,
12
+ "children": null,
13
+ "info": {
14
+ "exit_code": 0,
15
+ "stdout": "PASS: the defining module's export list\nPASS: an export list written as a tuple over several lines\nPASS: the export list of a package that re-exports the name\nPASS: an export list naming a module that is being renamed\nPASS: an export list extended in place\nPASS: prose and an unrelated list of the same word\nPASS: another module that exports a name of its own\nPASS: an export list built through a variable\nPASS: an export list added to another list\nPASS: an export list written as one string of names\nPASS: an export list written as a block of names\nPASS: export_list_follows_the_rename (11 scenarios)\n",
16
+ "stderr": "",
17
+ "_parameters": {
18
+ "command": "bash /hud/grader/run_grading.sh export_list_follows_the_rename 600",
19
+ "cwd": "/workspace/repo",
20
+ "timeout_seconds": 600
21
+ }
22
+ }
23
+ },
24
+ {
25
+ "name": "type_constructor_names_follow_the_rename",
26
+ "weight": 0.08,
27
+ "value": 1.0,
28
+ "children": null,
29
+ "info": {
30
+ "exit_code": 0,
31
+ "stdout": "PASS: the name a new type is given\nPASS: a new type built from a directly imported constructor\nPASS: the bound of a type variable\nPASS: a type whose name is spelled like something else\nPASS: a constraint of a type variable\nPASS: a new type whose name is handed over by keyword\nPASS: type_constructor_names_follow_the_rename (6 scenarios)\n",
32
+ "stderr": "",
33
+ "_parameters": {
34
+ "command": "bash /hud/grader/run_grading.sh type_constructor_names_follow_the_rename 600",
35
+ "cwd": "/workspace/repo",
36
+ "timeout_seconds": 600
37
+ }
38
+ }
39
+ },
40
+ {
41
+ "name": "declared_attribute_names_follow_the_rename",
42
+ "weight": 0.08,
43
+ "value": 1.0,
44
+ "children": null,
45
+ "info": {
46
+ "exit_code": 0,
47
+ "stdout": "PASS: a slots tuple follows the attribute\nPASS: a slots list follows the attribute\nPASS: the positional attribute names a class declares for matching\nPASS: declared_attribute_names_follow_the_rename (3 scenarios)\n",
48
+ "stderr": "",
49
+ "_parameters": {
50
+ "command": "bash /hud/grader/run_grading.sh declared_attribute_names_follow_the_rename 600",
51
+ "cwd": "/workspace/repo",
52
+ "timeout_seconds": 600
53
+ }
54
+ }
55
+ },
56
+ {
57
+ "name": "string_annotations_follow_and_data_stays",
58
+ "weight": 0.22,
59
+ "value": 1.0,
60
+ "children": null,
61
+ "info": {
62
+ "exit_code": 0,
63
+ "stdout": "PASS: a forward reference in a signature\nPASS: a forward reference inside a generic\nPASS: a literal type beside a forward reference\nPASS: the metadata of an annotated type\nPASS: a class body with a literal field and a forward reference\nPASS: string_annotations_follow_and_data_stays (5 scenarios)\n",
64
+ "stderr": "",
65
+ "_parameters": {
66
+ "command": "bash /hud/grader/run_grading.sh string_annotations_follow_and_data_stays 600",
67
+ "cwd": "/workspace/repo",
68
+ "timeout_seconds": 600
69
+ }
70
+ }
71
+ },
72
+ {
73
+ "name": "move_keeps_both_export_contracts",
74
+ "weight": 0.08,
75
+ "value": 1.0,
76
+ "children": null,
77
+ "info": {
78
+ "exit_code": 0,
79
+ "stdout": "PASS: the module left behind stops exporting the name\nPASS: the module arrived in starts exporting the name\nPASS: a module with no export list is not given one\nPASS: move_keeps_both_export_contracts (3 scenarios)\n",
80
+ "stderr": "",
81
+ "_parameters": {
82
+ "command": "bash /hud/grader/run_grading.sh move_keeps_both_export_contracts 600",
83
+ "cwd": "/workspace/repo",
84
+ "timeout_seconds": 600
85
+ }
86
+ }
87
+ },
88
+ {
89
+ "name": "move_destination_list_however_built_gains_the_name",
90
+ "weight": 0.22,
91
+ "value": 1.0,
92
+ "children": null,
93
+ "info": {
94
+ "exit_code": 0,
95
+ "stdout": "PASS: the list the destination publishes is built through a variable\nPASS: the list the destination publishes is chosen by a condition\nPASS: the list the destination publishes is a sorted copy\nPASS: the list the destination publishes is one string of names\nPASS: the generated import does not carry the export list across\nPASS: move_destination_list_however_built_gains_the_name (5 scenarios)\n",
96
+ "stderr": "",
97
+ "_parameters": {
98
+ "command": "bash /hud/grader/run_grading.sh move_destination_list_however_built_gains_the_name 600",
99
+ "cwd": "/workspace/repo",
100
+ "timeout_seconds": 600
101
+ }
102
+ }
103
+ },
104
+ {
105
+ "name": "move_source_list_however_built_loses_the_name",
106
+ "weight": 0.21,
107
+ "value": 1.0,
108
+ "children": null,
109
+ "info": {
110
+ "exit_code": 0,
111
+ "stdout": "PASS: a list written as one string of names\nPASS: a name put on the list at its front\nPASS: a name appended to the list\nPASS: a tuple of two names\nPASS: a tuple of names held in a variable\nPASS: move_source_list_however_built_loses_the_name (5 scenarios)\n",
112
+ "stderr": "",
113
+ "_parameters": {
114
+ "command": "bash /hud/grader/run_grading.sh move_source_list_however_built_loses_the_name 600",
115
+ "cwd": "/workspace/repo",
116
+ "timeout_seconds": 600
117
+ }
118
+ }
119
+ },
120
+ {
121
+ "name": "gate_repo_suite_green_and_tests_untouched",
122
+ "weight": 0.03,
123
+ "value": 1.0,
124
+ "children": null,
125
+ "info": {
126
+ "exit_code": 0,
127
+ "stdout": "PASS: every shipped test file is byte for byte what it was\nPASS: the repository's own tests pass\n",
128
+ "stderr": "",
129
+ "_parameters": {
130
+ "command": "CORE_GREEN=1 bash /hud/grader/run_grading.sh gate_repo_suite_green_and_tests_untouched 900",
131
+ "cwd": "/workspace/repo",
132
+ "timeout_seconds": 900
133
+ }
134
+ }
135
+ }
136
+ ]
137
+ }
harbor/evidence/rope/reports/noop.json ADDED
@@ -0,0 +1,281 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "revision": "coding-rubric-v2",
3
+ "task_id": "rope_rename_all_reexport_owners_contract",
4
+ "grader_version": "0.6.15",
5
+ "commands": [
6
+ {
7
+ "name": "export_list_follows_the_rename",
8
+ "weight": 0.08,
9
+ "value": 0.0,
10
+ "children": null,
11
+ "info": {
12
+ "exit_code": 1,
13
+ "stdout": "FAIL: the defining module's export list\n mod.py is not what it has to be\n expected mod.py:\n | def new_func():\n | pass\n | \n | \n | __all__ = [\"new_func\"]\n got:\n | def new_func():\n | pass\n | \n | \n | __all__ = [\"a_func\"]\nFAIL: an export list written as a tuple over several lines\n mod.py is not what it has to be\n expected mod.py:\n | def new_func():\n | pass\n | \n | \n | def other():\n | pass\n | \n | \n | __all__ = (\n | 'new_func',\n | 'other',\n | )\n got:\n | def new_func():\n | pass\n | \n | \n | def other():\n | pass\n | \n | \n | __all__ = (\n | 'a_func',\n | 'other',\n | )\nFAIL: the export list of a package that re-exports the name\n pkg/__init__.py is not what it has to be\n expected pkg/__init__.py:\n | from pkg.core import new_func\n | \n | __all__ = [\"new_func\"]\n got:\n | from pkg.core import new_func\n | \n | __all__ = [\"a_func\"]\nFAIL: an export list naming a module that is being renamed\n pkg/__init__.py is not what it has to be\n expected pkg/__init__.py:\n | from pkg import base\n | \n | __all__ = [\"base\"]\n got:\n | from pkg import base\n | \n | __all__ = [\"core\"]\nFAIL: an export list extended in place\n mod.py is not what it has to be\n expected mod.py:\n | def new_func():\n | pass\n | \n | \n | __all__ = []\n | __all__ += [\"new_func\"]\n got:\n | def new_func():\n | pass\n | \n | \n | __all__ = []\n | __all__ += [\"a_func\"]\nFAIL: prose and an unrelated list of the same word\n mod.py is not what it has to be\n expected mod.py:\n | def new_func():\n | \"\"\"a_func is the entry point.\n | \n | Call a_func early.\n | \"\"\"\n | # a_func is also mentioned here\n | pass\n | \n | \n | NAMES = [\"a_func\"]\n | __all__ = [\"new_func\"]\n got:\n | def new_func():\n | \"\"\"a_func is the entry point.\n | \n | Call a_func early.\n | \"\"\"\n | # a_func is also mentioned here\n | pass\n | \n | \n | NAMES = [\"a_func\"]\n | __all__ = [\"a_func\"]\nFAIL: another module that exports a name of its own\n first.py is not what it has to be\n expected first.py:\n | def new_func():\n | pass\n | \n | \n | __all__ = [\"new_func\"]\n got:\n | def new_func():\n | pass\n | \n | \n | __all__ = [\"a_func\"]\nFAIL: an export list built through a variable\n mod.py is not what it has to be\n expected mod.py:\n | def new_func():\n | pass\n | \n | \n | exported = \"new_func\"\n | label = \"a_func\"\n | __all__ = [exported]\n got:\n | def new_func():\n | pass\n | \n | \n | exported = \"a_func\"\n | label = \"a_func\"\n | __all__ = [exported]\nFAIL: an export list added to another list\n mod.py is not what it has to be\n expected mod.py:\n | def new_func():\n | pass\n | \n | \n | def other():\n | pass\n | \n | \n | extra = \"new_func\"\n | __all__ = [\"other\"] + [extra]\n got:\n | def new_func():\n | pass\n | \n | \n | def other():\n | pass\n | \n | \n | extra = \"a_func\"\n | __all__ = [\"other\"] + [extra]\nFAIL: an export list written as one string of names\n mod.py publishes ['a_func', 'other'], not ['new_func', 'other']\n expected mod.py:\n | __all__ == ['new_func', 'other']\n got:\n | def new_func():\n | pass\n | \n | \n | def other():\n | pass\n | \n | \n | WORDS = \"a_func other\".split()\n | __all__ = \"a_func other\".split()\nFAIL: an export list written as a block of names\n mod.py publishes ['a_func', 'other'], not ['new_func', 'other']\n expected mod.py:\n | __all__ == ['new_func', 'other']\n got:\n | def new_func():\n | pass\n | \n | \n | def other():\n | pass\n | \n | \n | __all__ = \"\"\"\n | a_func\n | other\n | \"\"\".split()\nFAIL: export_list_follows_the_rename (11 of 11 scenarios)\n",
14
+ "stderr": "",
15
+ "_parameters": {
16
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh export_list_follows_the_rename 600'",
17
+ "cwd": "/workspace/repo",
18
+ "timeout_seconds": 600
19
+ }
20
+ }
21
+ },
22
+ {
23
+ "name": "type_constructor_names_follow_the_rename",
24
+ "weight": 0.08,
25
+ "value": 0.0,
26
+ "children": null,
27
+ "info": {
28
+ "exit_code": 1,
29
+ "stdout": "FAIL: the name a new type is given\n mod.py is not what it has to be\n expected mod.py:\n | import typing\n | \n | LABEL = \"Number\"\n | Count = typing.NewType(\"Count\", int)\n | \n | \n | def scale(value: Count) -> Count:\n | \"\"\"Number is a count of things.\"\"\"\n | return value\n got:\n | import typing\n | \n | LABEL = \"Number\"\n | Count = typing.NewType(\"Number\", int)\n | \n | \n | def scale(value: Count) -> Count:\n | \"\"\"Number is a count of things.\"\"\"\n | return value\nFAIL: a new type built from a directly imported constructor\n mod.py is not what it has to be\n expected mod.py:\n | from typing import NewType\n | \n | AccountId = NewType(\"AccountId\", int)\n got:\n | from typing import NewType\n | \n | AccountId = NewType(\"UserId\", int)\nFAIL: the bound of a type variable\n mod.py is not what it has to be\n expected mod.py:\n | from typing import TypeVar\n | \n | \n | class Figure:\n | pass\n | \n | \n | T = TypeVar(\"T\", bound=\"Figure\")\n got:\n | from typing import TypeVar\n | \n | \n | class Figure:\n | pass\n | \n | \n | T = TypeVar(\"T\", bound=\"Shape\")\nPASS: a type whose name is spelled like something else\nFAIL: a constraint of a type variable\n mod.py is not what it has to be\n expected mod.py:\n | from typing import TypeVar\n | \n | \n | class Figure:\n | pass\n | \n | \n | class Circle(Figure):\n | pass\n | \n | \n | T = TypeVar(\"T\", \"Circle\", \"Figure\")\n got:\n | from typing import TypeVar\n | \n | \n | class Figure:\n | pass\n | \n | \n | class Circle(Figure):\n | pass\n | \n | \n | T = TypeVar(\"T\", \"Circle\", \"Shape\")\nFAIL: a new type whose name is handed over by keyword\n mod.py is not what it has to be\n expected mod.py:\n | from typing import NewType\n | \n | Count = NewType(name=\"Count\", tp=int)\n got:\n | from typing import NewType\n | \n | Count = NewType(name=\"Number\", tp=int)\nFAIL: type_constructor_names_follow_the_rename (5 of 6 scenarios)\n",
30
+ "stderr": "",
31
+ "_parameters": {
32
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh type_constructor_names_follow_the_rename 600'",
33
+ "cwd": "/workspace/repo",
34
+ "timeout_seconds": 600
35
+ }
36
+ }
37
+ },
38
+ {
39
+ "name": "declared_attribute_names_follow_the_rename",
40
+ "weight": 0.08,
41
+ "value": 0.0,
42
+ "children": null,
43
+ "info": {
44
+ "exit_code": 1,
45
+ "stdout": "FAIL: a slots tuple follows the attribute\n mod.py is not what it has to be\n expected mod.py:\n | class Point:\n | __slots__ = (\"sideways\",)\n | \n | def __init__(self):\n | self.sideways = 1\n | \n | def get(self):\n | return self.sideways\n | \n | \n | class Other:\n | __slots__ = (\"across\",)\n | \n | def __init__(self):\n | self.across = 2\n got:\n | class Point:\n | __slots__ = (\"across\",)\n | \n | def __init__(self):\n | self.sideways = 1\n | \n | def get(self):\n | return self.sideways\n | \n | \n | class Other:\n | __slots__ = (\"across\",)\n | \n | def __init__(self):\n | self.across = 2\nFAIL: a slots list follows the attribute\n mod.py is not what it has to be\n expected mod.py:\n | class Point:\n | __slots__ = [\"sideways\", \"down\"]\n | \n | def __init__(self):\n | self.sideways = 1\n | self.down = 2\n got:\n | class Point:\n | __slots__ = [\"across\", \"down\"]\n | \n | def __init__(self):\n | self.sideways = 1\n | self.down = 2\nFAIL: the positional attribute names a class declares for matching\n mod.py is not what it has to be\n expected mod.py:\n | class Point:\n | __slots__ = (\"sideways\", \"down\")\n | __match_args__ = (\"sideways\", \"down\")\n | \n | def __init__(self):\n | self.sideways = 1\n | self.down = 2\n | \n | \n | class Other:\n | __match_args__ = (\"across\",)\n | \n | def __init__(self):\n | self.across = 3\n got:\n | class Point:\n | __slots__ = (\"across\", \"down\")\n | __match_args__ = (\"across\", \"down\")\n | \n | def __init__(self):\n | self.sideways = 1\n | self.down = 2\n | \n | \n | class Other:\n | __match_args__ = (\"across\",)\n | \n | def __init__(self):\n | self.across = 3\nFAIL: declared_attribute_names_follow_the_rename (3 of 3 scenarios)\n",
46
+ "stderr": "",
47
+ "_parameters": {
48
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh declared_attribute_names_follow_the_rename 600'",
49
+ "cwd": "/workspace/repo",
50
+ "timeout_seconds": 600
51
+ }
52
+ }
53
+ },
54
+ {
55
+ "name": "string_annotations_follow_and_data_stays",
56
+ "weight": 0.22,
57
+ "value": 0.0,
58
+ "children": null,
59
+ "info": {
60
+ "exit_code": 1,
61
+ "stdout": "FAIL: a forward reference in a signature\n mod.py is not what it has to be\n expected mod.py:\n | class Figure:\n | \"\"\"Shape is a shape.\"\"\"\n | \n | \n | NAMES = [\"Shape\"]\n | \n | \n | def draw(what: \"Figure\") -> \"Figure\":\n | return what\n got:\n | class Figure:\n | \"\"\"Shape is a shape.\"\"\"\n | \n | \n | NAMES = [\"Shape\"]\n | \n | \n | def draw(what: \"Shape\") -> \"Shape\":\n | return what\nFAIL: a forward reference inside a generic\n mod.py is not what it has to be\n expected mod.py:\n | from typing import List, Optional\n | \n | \n | class Figure:\n | pass\n | \n | \n | corner: Optional[\"Figure\"] = None\n | \n | \n | def each(items: List[\"Figure\"]):\n | return items\n got:\n | from typing import List, Optional\n | \n | \n | class Figure:\n | pass\n | \n | \n | corner: Optional[\"Shape\"] = None\n | \n | \n | def each(items: List[\"Shape\"]):\n | return items\nFAIL: a literal type beside a forward reference\n mod.py is not what it has to be\n expected mod.py:\n | from typing import Literal\n | \n | \n | class Figure:\n | pass\n | \n | \n | def draw(what: \"Figure\", kind: Literal[\"Shape\", \"Circle\"]) -> \"Figure\":\n | return what\n got:\n | from typing import Literal\n | \n | \n | class Figure:\n | pass\n | \n | \n | def draw(what: \"Shape\", kind: Literal[\"Shape\", \"Circle\"]) -> \"Shape\":\n | return what\nFAIL: the metadata of an annotated type\n mod.py is not what it has to be\n expected mod.py:\n | from typing import Annotated\n | \n | \n | class Figure:\n | pass\n | \n | \n | def draw(what: Annotated[\"Figure\", \"Shape\"]):\n | return what\n got:\n | from typing import Annotated\n | \n | \n | class Figure:\n | pass\n | \n | \n | def draw(what: Annotated[\"Shape\", \"Shape\"]):\n | return what\nFAIL: a class body with a literal field and a forward reference\n mod.py is not what it has to be\n expected mod.py:\n | from typing import Literal\n | \n | \n | class Figure:\n | pass\n | \n | \n | class Box:\n | kind: Literal[\"Shape\"] = \"Shape\"\n | item: \"Figure\"\n got:\n | from typing import Literal\n | \n | \n | class Figure:\n | pass\n | \n | \n | class Box:\n | kind: Literal[\"Shape\"] = \"Shape\"\n | item: \"Shape\"\nFAIL: string_annotations_follow_and_data_stays (5 of 5 scenarios)\n",
62
+ "stderr": "",
63
+ "_parameters": {
64
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh string_annotations_follow_and_data_stays 600'",
65
+ "cwd": "/workspace/repo",
66
+ "timeout_seconds": 600
67
+ }
68
+ }
69
+ },
70
+ {
71
+ "name": "move_keeps_both_export_contracts",
72
+ "weight": 0.08,
73
+ "value": 0.0,
74
+ "children": null,
75
+ "info": {
76
+ "exit_code": 1,
77
+ "stdout": "FAIL: the module left behind stops exporting the name\n pkg/a.py publishes ['a_func'], not []\n expected pkg/a.py:\n | __all__ == []\n got:\n | __all__ = [\"a_func\"]\n pkg/a.py still contains 'a_func'\n expected pkg/a.py:\n | no a_func\n got:\n | __all__ = [\"a_func\"]\nFAIL: the module arrived in starts exporting the name\n pkg/b.py publishes ['other'], not ['a_func', 'other']\n expected pkg/b.py:\n | __all__ == ['a_func', 'other']\n got:\n | from pkg.a import __all__\n | \n | \n | def a_func():\n | pass\n | def other():\n | pass\n | \n | \n | __all__ = [\"other\"]\n pkg/a.py still contains 'a_func'\n expected pkg/a.py:\n | no a_func\n got:\n | __all__ = [\"a_func\"]\nPASS: a module with no export list is not given one\nFAIL: move_keeps_both_export_contracts (2 of 3 scenarios)\n",
78
+ "stderr": "",
79
+ "_parameters": {
80
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh move_keeps_both_export_contracts 600'",
81
+ "cwd": "/workspace/repo",
82
+ "timeout_seconds": 600
83
+ }
84
+ }
85
+ },
86
+ {
87
+ "name": "move_destination_list_however_built_gains_the_name",
88
+ "weight": 0.22,
89
+ "value": 0.0,
90
+ "children": null,
91
+ "info": {
92
+ "exit_code": 1,
93
+ "stdout": "FAIL: the list the destination publishes is built through a variable\n pkg/a.py publishes ['a_func'], not []\n expected pkg/a.py:\n | __all__ == []\n got:\n | __all__ = [\"a_func\"]\n pkg/b.py publishes ['other'], not ['a_func', 'other']\n expected pkg/b.py:\n | __all__ == ['a_func', 'other']\n got:\n | from pkg.a import __all__\n | \n | \n | def a_func():\n | pass\n | def other():\n | pass\n | \n | \n | _names = [\"other\"]\n | __all__ = _names\nFAIL: the list the destination publishes is chosen by a condition\n pkg/a.py publishes ['a_func'], not []\n expected pkg/a.py:\n | __all__ == []\n got:\n | __all__ = [\"a_func\"]\n pkg/b.py publishes ['other'], not ['a_func', 'other']\n expected pkg/b.py:\n | __all__ == ['a_func', 'other']\n got:\n | from pkg.a import __all__\n | \n | \n | def a_func():\n | pass\n | def other():\n | pass\n | \n | \n | FLAG = True\n | __all__ = [\"other\"] if FLAG else []\nFAIL: the list the destination publishes is a sorted copy\n pkg/a.py publishes ['a_func'], not []\n expected pkg/a.py:\n | __all__ == []\n got:\n | __all__ = [\"a_func\"]\n pkg/b.py publishes ['other'], not ['a_func', 'other']\n expected pkg/b.py:\n | __all__ == ['a_func', 'other']\n got:\n | from pkg.a import __all__\n | \n | \n | def a_func():\n | pass\n | def other():\n | pass\n | \n | \n | __all__ = sorted([\"other\"])\nFAIL: the list the destination publishes is one string of names\n pkg/a.py publishes ['a_func'], not []\n expected pkg/a.py:\n | __all__ == []\n got:\n | __all__ = [\"a_func\"]\n pkg/b.py publishes ['other'], not ['a_func', 'other']\n expected pkg/b.py:\n | __all__ == ['a_func', 'other']\n got:\n | from pkg.a import __all__\n | \n | \n | def a_func():\n | pass\n | def other():\n | pass\n | \n | \n | __all__ = \"other\".split()\nFAIL: the generated import does not carry the export list across\n pkg/b.py still contains '__all__'\n expected pkg/b.py:\n | no __all__\n got:\n | from pkg.a import other, __all__\n | \n | \n | def a_func():\n | pass\nFAIL: move_destination_list_however_built_gains_the_name (5 of 5 scenarios)\n",
94
+ "stderr": "",
95
+ "_parameters": {
96
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh move_destination_list_however_built_gains_the_name 600'",
97
+ "cwd": "/workspace/repo",
98
+ "timeout_seconds": 600
99
+ }
100
+ }
101
+ },
102
+ {
103
+ "name": "move_source_list_however_built_loses_the_name",
104
+ "weight": 0.21,
105
+ "value": 0.0,
106
+ "children": null,
107
+ "info": {
108
+ "exit_code": 1,
109
+ "stdout": "FAIL: a list written as one string of names\n pkg/a.py publishes ['a_func', 'other'], not ['other']\n expected pkg/a.py:\n | __all__ == ['other']\n got:\n | def other():\n | pass\n | \n | \n | __all__ = \"a_func other\".split()\nFAIL: a name put on the list at its front\n pkg/a.py publishes ['a_func', 'other'], not ['other']\n expected pkg/a.py:\n | __all__ == ['other']\n got:\n | def other():\n | pass\n | \n | \n | __all__ = [\"other\"]\n | __all__.insert(0, \"a_func\")\nFAIL: a name appended to the list\n pkg/a.py publishes ['a_func', 'other'], not ['other']\n expected pkg/a.py:\n | __all__ == ['other']\n got:\n | def other():\n | pass\n | \n | \n | __all__ = [\"other\"]\n | __all__.append(\"a_func\")\nFAIL: a tuple of two names\n pkg/a.py publishes ['a_func', 'other'], not ['other']\n expected pkg/a.py:\n | __all__ == ['other']\n got:\n | def other():\n | pass\n | \n | \n | __all__ = (\"a_func\", \"other\")\nFAIL: a tuple of names held in a variable\n pkg/a.py publishes ['a_func', 'other'], not ['other']\n expected pkg/a.py:\n | __all__ == ['other']\n got:\n | def other():\n | pass\n | \n | \n | _names = (\"a_func\", \"other\")\n | __all__ = _names\nFAIL: move_source_list_however_built_loses_the_name (5 of 5 scenarios)\n",
110
+ "stderr": "",
111
+ "_parameters": {
112
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh move_source_list_however_built_loses_the_name 600'",
113
+ "cwd": "/workspace/repo",
114
+ "timeout_seconds": 600
115
+ }
116
+ }
117
+ },
118
+ {
119
+ "name": "gate_repo_suite_green_and_tests_untouched",
120
+ "weight": 0.03,
121
+ "value": 0.0,
122
+ "children": null,
123
+ "info": {
124
+ "exit_code": 1,
125
+ "stdout": "RULE HOLDS: every shipped test file is byte for byte what it was\nRULE HOLDS: the repository's own tests pass\nFAIL: not paid -- no scored behaviour was fixed, and this gate does not pay for an empty change\n",
126
+ "stderr": "",
127
+ "_parameters": {
128
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=0 bash /hud/grader/run_grading.sh gate_repo_suite_green_and_tests_untouched 900'",
129
+ "cwd": "/workspace/repo",
130
+ "timeout_seconds": 900
131
+ }
132
+ }
133
+ }
134
+ ],
135
+ "status": "graded",
136
+ "patch_sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
137
+ "result": {
138
+ "reward": 0.0,
139
+ "done": true,
140
+ "content": "Blocker criteria failed (gate_repo_suite_green_and_tests_untouched, move_keeps_both_export_contracts); cap 0.60, reward 0.000 (uncapped 0.000).",
141
+ "info": {
142
+ "uncapped_reward": 0.0,
143
+ "failed_blockers": [
144
+ "gate_repo_suite_green_and_tests_untouched",
145
+ "move_keeps_both_export_contracts"
146
+ ],
147
+ "blocker_cap": 0.6
148
+ },
149
+ "isError": false,
150
+ "subscores": [
151
+ {
152
+ "name": "export_list_follows_the_rename",
153
+ "weight": 0.08,
154
+ "value": 0.0,
155
+ "children": null,
156
+ "info": {
157
+ "exit_code": 1,
158
+ "stdout": "FAIL: the defining module's export list\n mod.py is not what it has to be\n expected mod.py:\n | def new_func():\n | pass\n | \n | \n | __all__ = [\"new_func\"]\n got:\n | def new_func():\n | pass\n | \n | \n | __all__ = [\"a_func\"]\nFAIL: an export list written as a tuple over several lines\n mod.py is not what it has to be\n expected mod.py:\n | def new_func():\n | pass\n | \n | \n | def other():\n | pass\n | \n | \n | __all__ = (\n | 'new_func',\n | 'other',\n | )\n got:\n | def new_func():\n | pass\n | \n | \n | def other():\n | pass\n | \n | \n | __all__ = (\n | 'a_func',\n | 'other',\n | )\nFAIL: the export list of a package that re-exports the name\n pkg/__init__.py is not what it has to be\n expected pkg/__init__.py:\n | from pkg.core import new_func\n | \n | __all__ = [\"new_func\"]\n got:\n | from pkg.core import new_func\n | \n | __all__ = [\"a_func\"]\nFAIL: an export list naming a module that is being renamed\n pkg/__init__.py is not what it has to be\n expected pkg/__init__.py:\n | from pkg import base\n | \n | __all__ = [\"base\"]\n got:\n | from pkg import base\n | \n | __all__ = [\"core\"]\nFAIL: an export list extended in place\n mod.py is not what it has to be\n expected mod.py:\n | def new_func():\n | pass\n | \n | \n | __all__ = []\n | __all__ += [\"new_func\"]\n got:\n | def new_func():\n | pass\n | \n | \n | __all__ = []\n | __all__ += [\"a_func\"]\nFAIL: prose and an unrelated list of the same word\n mod.py is not what it has to be\n expected mod.py:\n | def new_func():\n | \"\"\"a_func is the entry point.\n | \n | Call a_func early.\n | \"\"\"\n | # a_func is also mentioned here\n | pass\n | \n | \n | NAMES = [\"a_func\"]\n | __all__ = [\"new_func\"]\n got:\n | def new_func():\n | \"\"\"a_func is the entry point.\n | \n | Call a_func early.\n | \"\"\"\n | # a_func is also mentioned here\n | pass\n | \n | \n | NAMES = [\"a_func\"]\n | __all__ = [\"a_func\"]\nFAIL: another module that exports a name of its own\n first.py is not what it has to be\n expected first.py:\n | def new_func():\n | pass\n | \n | \n | __all__ = [\"new_func\"]\n got:\n | def new_func():\n | pass\n | \n | \n | __all__ = [\"a_func\"]\nFAIL: an export list built through a variable\n mod.py is not what it has to be\n expected mod.py:\n | def new_func():\n | pass\n | \n | \n | exported = \"new_func\"\n | label = \"a_func\"\n | __all__ = [exported]\n got:\n | def new_func():\n | pass\n | \n | \n | exported = \"a_func\"\n | label = \"a_func\"\n | __all__ = [exported]\nFAIL: an export list added to another list\n mod.py is not what it has to be\n expected mod.py:\n | def new_func():\n | pass\n | \n | \n | def other():\n | pass\n | \n | \n | extra = \"new_func\"\n | __all__ = [\"other\"] + [extra]\n got:\n | def new_func():\n | pass\n | \n | \n | def other():\n | pass\n | \n | \n | extra = \"a_func\"\n | __all__ = [\"other\"] + [extra]\nFAIL: an export list written as one string of names\n mod.py publishes ['a_func', 'other'], not ['new_func', 'other']\n expected mod.py:\n | __all__ == ['new_func', 'other']\n got:\n | def new_func():\n | pass\n | \n | \n | def other():\n | pass\n | \n | \n | WORDS = \"a_func other\".split()\n | __all__ = \"a_func other\".split()\nFAIL: an export list written as a block of names\n mod.py publishes ['a_func', 'other'], not ['new_func', 'other']\n expected mod.py:\n | __all__ == ['new_func', 'other']\n got:\n | def new_func():\n | pass\n | \n | \n | def other():\n | pass\n | \n | \n | __all__ = \"\"\"\n | a_func\n | other\n | \"\"\".split()\nFAIL: export_list_follows_the_rename (11 of 11 scenarios)\n",
159
+ "stderr": "",
160
+ "_parameters": {
161
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh export_list_follows_the_rename 600'",
162
+ "cwd": "/workspace/repo",
163
+ "timeout_seconds": 600
164
+ }
165
+ }
166
+ },
167
+ {
168
+ "name": "type_constructor_names_follow_the_rename",
169
+ "weight": 0.08,
170
+ "value": 0.0,
171
+ "children": null,
172
+ "info": {
173
+ "exit_code": 1,
174
+ "stdout": "FAIL: the name a new type is given\n mod.py is not what it has to be\n expected mod.py:\n | import typing\n | \n | LABEL = \"Number\"\n | Count = typing.NewType(\"Count\", int)\n | \n | \n | def scale(value: Count) -> Count:\n | \"\"\"Number is a count of things.\"\"\"\n | return value\n got:\n | import typing\n | \n | LABEL = \"Number\"\n | Count = typing.NewType(\"Number\", int)\n | \n | \n | def scale(value: Count) -> Count:\n | \"\"\"Number is a count of things.\"\"\"\n | return value\nFAIL: a new type built from a directly imported constructor\n mod.py is not what it has to be\n expected mod.py:\n | from typing import NewType\n | \n | AccountId = NewType(\"AccountId\", int)\n got:\n | from typing import NewType\n | \n | AccountId = NewType(\"UserId\", int)\nFAIL: the bound of a type variable\n mod.py is not what it has to be\n expected mod.py:\n | from typing import TypeVar\n | \n | \n | class Figure:\n | pass\n | \n | \n | T = TypeVar(\"T\", bound=\"Figure\")\n got:\n | from typing import TypeVar\n | \n | \n | class Figure:\n | pass\n | \n | \n | T = TypeVar(\"T\", bound=\"Shape\")\nPASS: a type whose name is spelled like something else\nFAIL: a constraint of a type variable\n mod.py is not what it has to be\n expected mod.py:\n | from typing import TypeVar\n | \n | \n | class Figure:\n | pass\n | \n | \n | class Circle(Figure):\n | pass\n | \n | \n | T = TypeVar(\"T\", \"Circle\", \"Figure\")\n got:\n | from typing import TypeVar\n | \n | \n | class Figure:\n | pass\n | \n | \n | class Circle(Figure):\n | pass\n | \n | \n | T = TypeVar(\"T\", \"Circle\", \"Shape\")\nFAIL: a new type whose name is handed over by keyword\n mod.py is not what it has to be\n expected mod.py:\n | from typing import NewType\n | \n | Count = NewType(name=\"Count\", tp=int)\n got:\n | from typing import NewType\n | \n | Count = NewType(name=\"Number\", tp=int)\nFAIL: type_constructor_names_follow_the_rename (5 of 6 scenarios)\n",
175
+ "stderr": "",
176
+ "_parameters": {
177
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh type_constructor_names_follow_the_rename 600'",
178
+ "cwd": "/workspace/repo",
179
+ "timeout_seconds": 600
180
+ }
181
+ }
182
+ },
183
+ {
184
+ "name": "declared_attribute_names_follow_the_rename",
185
+ "weight": 0.08,
186
+ "value": 0.0,
187
+ "children": null,
188
+ "info": {
189
+ "exit_code": 1,
190
+ "stdout": "FAIL: a slots tuple follows the attribute\n mod.py is not what it has to be\n expected mod.py:\n | class Point:\n | __slots__ = (\"sideways\",)\n | \n | def __init__(self):\n | self.sideways = 1\n | \n | def get(self):\n | return self.sideways\n | \n | \n | class Other:\n | __slots__ = (\"across\",)\n | \n | def __init__(self):\n | self.across = 2\n got:\n | class Point:\n | __slots__ = (\"across\",)\n | \n | def __init__(self):\n | self.sideways = 1\n | \n | def get(self):\n | return self.sideways\n | \n | \n | class Other:\n | __slots__ = (\"across\",)\n | \n | def __init__(self):\n | self.across = 2\nFAIL: a slots list follows the attribute\n mod.py is not what it has to be\n expected mod.py:\n | class Point:\n | __slots__ = [\"sideways\", \"down\"]\n | \n | def __init__(self):\n | self.sideways = 1\n | self.down = 2\n got:\n | class Point:\n | __slots__ = [\"across\", \"down\"]\n | \n | def __init__(self):\n | self.sideways = 1\n | self.down = 2\nFAIL: the positional attribute names a class declares for matching\n mod.py is not what it has to be\n expected mod.py:\n | class Point:\n | __slots__ = (\"sideways\", \"down\")\n | __match_args__ = (\"sideways\", \"down\")\n | \n | def __init__(self):\n | self.sideways = 1\n | self.down = 2\n | \n | \n | class Other:\n | __match_args__ = (\"across\",)\n | \n | def __init__(self):\n | self.across = 3\n got:\n | class Point:\n | __slots__ = (\"across\", \"down\")\n | __match_args__ = (\"across\", \"down\")\n | \n | def __init__(self):\n | self.sideways = 1\n | self.down = 2\n | \n | \n | class Other:\n | __match_args__ = (\"across\",)\n | \n | def __init__(self):\n | self.across = 3\nFAIL: declared_attribute_names_follow_the_rename (3 of 3 scenarios)\n",
191
+ "stderr": "",
192
+ "_parameters": {
193
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh declared_attribute_names_follow_the_rename 600'",
194
+ "cwd": "/workspace/repo",
195
+ "timeout_seconds": 600
196
+ }
197
+ }
198
+ },
199
+ {
200
+ "name": "string_annotations_follow_and_data_stays",
201
+ "weight": 0.22,
202
+ "value": 0.0,
203
+ "children": null,
204
+ "info": {
205
+ "exit_code": 1,
206
+ "stdout": "FAIL: a forward reference in a signature\n mod.py is not what it has to be\n expected mod.py:\n | class Figure:\n | \"\"\"Shape is a shape.\"\"\"\n | \n | \n | NAMES = [\"Shape\"]\n | \n | \n | def draw(what: \"Figure\") -> \"Figure\":\n | return what\n got:\n | class Figure:\n | \"\"\"Shape is a shape.\"\"\"\n | \n | \n | NAMES = [\"Shape\"]\n | \n | \n | def draw(what: \"Shape\") -> \"Shape\":\n | return what\nFAIL: a forward reference inside a generic\n mod.py is not what it has to be\n expected mod.py:\n | from typing import List, Optional\n | \n | \n | class Figure:\n | pass\n | \n | \n | corner: Optional[\"Figure\"] = None\n | \n | \n | def each(items: List[\"Figure\"]):\n | return items\n got:\n | from typing import List, Optional\n | \n | \n | class Figure:\n | pass\n | \n | \n | corner: Optional[\"Shape\"] = None\n | \n | \n | def each(items: List[\"Shape\"]):\n | return items\nFAIL: a literal type beside a forward reference\n mod.py is not what it has to be\n expected mod.py:\n | from typing import Literal\n | \n | \n | class Figure:\n | pass\n | \n | \n | def draw(what: \"Figure\", kind: Literal[\"Shape\", \"Circle\"]) -> \"Figure\":\n | return what\n got:\n | from typing import Literal\n | \n | \n | class Figure:\n | pass\n | \n | \n | def draw(what: \"Shape\", kind: Literal[\"Shape\", \"Circle\"]) -> \"Shape\":\n | return what\nFAIL: the metadata of an annotated type\n mod.py is not what it has to be\n expected mod.py:\n | from typing import Annotated\n | \n | \n | class Figure:\n | pass\n | \n | \n | def draw(what: Annotated[\"Figure\", \"Shape\"]):\n | return what\n got:\n | from typing import Annotated\n | \n | \n | class Figure:\n | pass\n | \n | \n | def draw(what: Annotated[\"Shape\", \"Shape\"]):\n | return what\nFAIL: a class body with a literal field and a forward reference\n mod.py is not what it has to be\n expected mod.py:\n | from typing import Literal\n | \n | \n | class Figure:\n | pass\n | \n | \n | class Box:\n | kind: Literal[\"Shape\"] = \"Shape\"\n | item: \"Figure\"\n got:\n | from typing import Literal\n | \n | \n | class Figure:\n | pass\n | \n | \n | class Box:\n | kind: Literal[\"Shape\"] = \"Shape\"\n | item: \"Shape\"\nFAIL: string_annotations_follow_and_data_stays (5 of 5 scenarios)\n",
207
+ "stderr": "",
208
+ "_parameters": {
209
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh string_annotations_follow_and_data_stays 600'",
210
+ "cwd": "/workspace/repo",
211
+ "timeout_seconds": 600
212
+ }
213
+ }
214
+ },
215
+ {
216
+ "name": "move_keeps_both_export_contracts",
217
+ "weight": 0.08,
218
+ "value": 0.0,
219
+ "children": null,
220
+ "info": {
221
+ "exit_code": 1,
222
+ "stdout": "FAIL: the module left behind stops exporting the name\n pkg/a.py publishes ['a_func'], not []\n expected pkg/a.py:\n | __all__ == []\n got:\n | __all__ = [\"a_func\"]\n pkg/a.py still contains 'a_func'\n expected pkg/a.py:\n | no a_func\n got:\n | __all__ = [\"a_func\"]\nFAIL: the module arrived in starts exporting the name\n pkg/b.py publishes ['other'], not ['a_func', 'other']\n expected pkg/b.py:\n | __all__ == ['a_func', 'other']\n got:\n | from pkg.a import __all__\n | \n | \n | def a_func():\n | pass\n | def other():\n | pass\n | \n | \n | __all__ = [\"other\"]\n pkg/a.py still contains 'a_func'\n expected pkg/a.py:\n | no a_func\n got:\n | __all__ = [\"a_func\"]\nPASS: a module with no export list is not given one\nFAIL: move_keeps_both_export_contracts (2 of 3 scenarios)\n",
223
+ "stderr": "",
224
+ "_parameters": {
225
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh move_keeps_both_export_contracts 600'",
226
+ "cwd": "/workspace/repo",
227
+ "timeout_seconds": 600
228
+ }
229
+ }
230
+ },
231
+ {
232
+ "name": "move_destination_list_however_built_gains_the_name",
233
+ "weight": 0.22,
234
+ "value": 0.0,
235
+ "children": null,
236
+ "info": {
237
+ "exit_code": 1,
238
+ "stdout": "FAIL: the list the destination publishes is built through a variable\n pkg/a.py publishes ['a_func'], not []\n expected pkg/a.py:\n | __all__ == []\n got:\n | __all__ = [\"a_func\"]\n pkg/b.py publishes ['other'], not ['a_func', 'other']\n expected pkg/b.py:\n | __all__ == ['a_func', 'other']\n got:\n | from pkg.a import __all__\n | \n | \n | def a_func():\n | pass\n | def other():\n | pass\n | \n | \n | _names = [\"other\"]\n | __all__ = _names\nFAIL: the list the destination publishes is chosen by a condition\n pkg/a.py publishes ['a_func'], not []\n expected pkg/a.py:\n | __all__ == []\n got:\n | __all__ = [\"a_func\"]\n pkg/b.py publishes ['other'], not ['a_func', 'other']\n expected pkg/b.py:\n | __all__ == ['a_func', 'other']\n got:\n | from pkg.a import __all__\n | \n | \n | def a_func():\n | pass\n | def other():\n | pass\n | \n | \n | FLAG = True\n | __all__ = [\"other\"] if FLAG else []\nFAIL: the list the destination publishes is a sorted copy\n pkg/a.py publishes ['a_func'], not []\n expected pkg/a.py:\n | __all__ == []\n got:\n | __all__ = [\"a_func\"]\n pkg/b.py publishes ['other'], not ['a_func', 'other']\n expected pkg/b.py:\n | __all__ == ['a_func', 'other']\n got:\n | from pkg.a import __all__\n | \n | \n | def a_func():\n | pass\n | def other():\n | pass\n | \n | \n | __all__ = sorted([\"other\"])\nFAIL: the list the destination publishes is one string of names\n pkg/a.py publishes ['a_func'], not []\n expected pkg/a.py:\n | __all__ == []\n got:\n | __all__ = [\"a_func\"]\n pkg/b.py publishes ['other'], not ['a_func', 'other']\n expected pkg/b.py:\n | __all__ == ['a_func', 'other']\n got:\n | from pkg.a import __all__\n | \n | \n | def a_func():\n | pass\n | def other():\n | pass\n | \n | \n | __all__ = \"other\".split()\nFAIL: the generated import does not carry the export list across\n pkg/b.py still contains '__all__'\n expected pkg/b.py:\n | no __all__\n got:\n | from pkg.a import other, __all__\n | \n | \n | def a_func():\n | pass\nFAIL: move_destination_list_however_built_gains_the_name (5 of 5 scenarios)\n",
239
+ "stderr": "",
240
+ "_parameters": {
241
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh move_destination_list_however_built_gains_the_name 600'",
242
+ "cwd": "/workspace/repo",
243
+ "timeout_seconds": 600
244
+ }
245
+ }
246
+ },
247
+ {
248
+ "name": "move_source_list_however_built_loses_the_name",
249
+ "weight": 0.21,
250
+ "value": 0.0,
251
+ "children": null,
252
+ "info": {
253
+ "exit_code": 1,
254
+ "stdout": "FAIL: a list written as one string of names\n pkg/a.py publishes ['a_func', 'other'], not ['other']\n expected pkg/a.py:\n | __all__ == ['other']\n got:\n | def other():\n | pass\n | \n | \n | __all__ = \"a_func other\".split()\nFAIL: a name put on the list at its front\n pkg/a.py publishes ['a_func', 'other'], not ['other']\n expected pkg/a.py:\n | __all__ == ['other']\n got:\n | def other():\n | pass\n | \n | \n | __all__ = [\"other\"]\n | __all__.insert(0, \"a_func\")\nFAIL: a name appended to the list\n pkg/a.py publishes ['a_func', 'other'], not ['other']\n expected pkg/a.py:\n | __all__ == ['other']\n got:\n | def other():\n | pass\n | \n | \n | __all__ = [\"other\"]\n | __all__.append(\"a_func\")\nFAIL: a tuple of two names\n pkg/a.py publishes ['a_func', 'other'], not ['other']\n expected pkg/a.py:\n | __all__ == ['other']\n got:\n | def other():\n | pass\n | \n | \n | __all__ = (\"a_func\", \"other\")\nFAIL: a tuple of names held in a variable\n pkg/a.py publishes ['a_func', 'other'], not ['other']\n expected pkg/a.py:\n | __all__ == ['other']\n got:\n | def other():\n | pass\n | \n | \n | _names = (\"a_func\", \"other\")\n | __all__ = _names\nFAIL: move_source_list_however_built_loses_the_name (5 of 5 scenarios)\n",
255
+ "stderr": "",
256
+ "_parameters": {
257
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh move_source_list_however_built_loses_the_name 600'",
258
+ "cwd": "/workspace/repo",
259
+ "timeout_seconds": 600
260
+ }
261
+ }
262
+ },
263
+ {
264
+ "name": "gate_repo_suite_green_and_tests_untouched",
265
+ "weight": 0.03,
266
+ "value": 0.0,
267
+ "children": null,
268
+ "info": {
269
+ "exit_code": 1,
270
+ "stdout": "RULE HOLDS: every shipped test file is byte for byte what it was\nRULE HOLDS: the repository's own tests pass\nFAIL: not paid -- no scored behaviour was fixed, and this gate does not pay for an empty change\n",
271
+ "stderr": "",
272
+ "_parameters": {
273
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=0 bash /hud/grader/run_grading.sh gate_repo_suite_green_and_tests_untouched 900'",
274
+ "cwd": "/workspace/repo",
275
+ "timeout_seconds": 900
276
+ }
277
+ }
278
+ }
279
+ ]
280
+ }
281
+ }
harbor/evidence/rope/reports/reference.json ADDED
@@ -0,0 +1,274 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "revision": "coding-rubric-v2",
3
+ "task_id": "rope_rename_all_reexport_owners_contract",
4
+ "grader_version": "0.6.15",
5
+ "commands": [
6
+ {
7
+ "name": "export_list_follows_the_rename",
8
+ "weight": 0.08,
9
+ "value": 1.0,
10
+ "children": null,
11
+ "info": {
12
+ "exit_code": 0,
13
+ "stdout": "PASS: the defining module's export list\nPASS: an export list written as a tuple over several lines\nPASS: the export list of a package that re-exports the name\nPASS: an export list naming a module that is being renamed\nPASS: an export list extended in place\nPASS: prose and an unrelated list of the same word\nPASS: another module that exports a name of its own\nPASS: an export list built through a variable\nPASS: an export list added to another list\nPASS: an export list written as one string of names\nPASS: an export list written as a block of names\nPASS: export_list_follows_the_rename (11 scenarios)\n",
14
+ "stderr": "",
15
+ "_parameters": {
16
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh export_list_follows_the_rename 600'",
17
+ "cwd": "/workspace/repo",
18
+ "timeout_seconds": 600
19
+ }
20
+ }
21
+ },
22
+ {
23
+ "name": "type_constructor_names_follow_the_rename",
24
+ "weight": 0.08,
25
+ "value": 1.0,
26
+ "children": null,
27
+ "info": {
28
+ "exit_code": 0,
29
+ "stdout": "PASS: the name a new type is given\nPASS: a new type built from a directly imported constructor\nPASS: the bound of a type variable\nPASS: a type whose name is spelled like something else\nPASS: a constraint of a type variable\nPASS: a new type whose name is handed over by keyword\nPASS: type_constructor_names_follow_the_rename (6 scenarios)\n",
30
+ "stderr": "",
31
+ "_parameters": {
32
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh type_constructor_names_follow_the_rename 600'",
33
+ "cwd": "/workspace/repo",
34
+ "timeout_seconds": 600
35
+ }
36
+ }
37
+ },
38
+ {
39
+ "name": "declared_attribute_names_follow_the_rename",
40
+ "weight": 0.08,
41
+ "value": 1.0,
42
+ "children": null,
43
+ "info": {
44
+ "exit_code": 0,
45
+ "stdout": "PASS: a slots tuple follows the attribute\nPASS: a slots list follows the attribute\nPASS: the positional attribute names a class declares for matching\nPASS: declared_attribute_names_follow_the_rename (3 scenarios)\n",
46
+ "stderr": "",
47
+ "_parameters": {
48
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh declared_attribute_names_follow_the_rename 600'",
49
+ "cwd": "/workspace/repo",
50
+ "timeout_seconds": 600
51
+ }
52
+ }
53
+ },
54
+ {
55
+ "name": "string_annotations_follow_and_data_stays",
56
+ "weight": 0.22,
57
+ "value": 1.0,
58
+ "children": null,
59
+ "info": {
60
+ "exit_code": 0,
61
+ "stdout": "PASS: a forward reference in a signature\nPASS: a forward reference inside a generic\nPASS: a literal type beside a forward reference\nPASS: the metadata of an annotated type\nPASS: a class body with a literal field and a forward reference\nPASS: string_annotations_follow_and_data_stays (5 scenarios)\n",
62
+ "stderr": "",
63
+ "_parameters": {
64
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh string_annotations_follow_and_data_stays 600'",
65
+ "cwd": "/workspace/repo",
66
+ "timeout_seconds": 600
67
+ }
68
+ }
69
+ },
70
+ {
71
+ "name": "move_keeps_both_export_contracts",
72
+ "weight": 0.08,
73
+ "value": 1.0,
74
+ "children": null,
75
+ "info": {
76
+ "exit_code": 0,
77
+ "stdout": "PASS: the module left behind stops exporting the name\nPASS: the module arrived in starts exporting the name\nPASS: a module with no export list is not given one\nPASS: move_keeps_both_export_contracts (3 scenarios)\n",
78
+ "stderr": "",
79
+ "_parameters": {
80
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh move_keeps_both_export_contracts 600'",
81
+ "cwd": "/workspace/repo",
82
+ "timeout_seconds": 600
83
+ }
84
+ }
85
+ },
86
+ {
87
+ "name": "move_destination_list_however_built_gains_the_name",
88
+ "weight": 0.22,
89
+ "value": 1.0,
90
+ "children": null,
91
+ "info": {
92
+ "exit_code": 0,
93
+ "stdout": "PASS: the list the destination publishes is built through a variable\nPASS: the list the destination publishes is chosen by a condition\nPASS: the list the destination publishes is a sorted copy\nPASS: the list the destination publishes is one string of names\nPASS: the generated import does not carry the export list across\nPASS: move_destination_list_however_built_gains_the_name (5 scenarios)\n",
94
+ "stderr": "",
95
+ "_parameters": {
96
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh move_destination_list_however_built_gains_the_name 600'",
97
+ "cwd": "/workspace/repo",
98
+ "timeout_seconds": 600
99
+ }
100
+ }
101
+ },
102
+ {
103
+ "name": "move_source_list_however_built_loses_the_name",
104
+ "weight": 0.21,
105
+ "value": 1.0,
106
+ "children": null,
107
+ "info": {
108
+ "exit_code": 0,
109
+ "stdout": "PASS: a list written as one string of names\nPASS: a name put on the list at its front\nPASS: a name appended to the list\nPASS: a tuple of two names\nPASS: a tuple of names held in a variable\nPASS: move_source_list_however_built_loses_the_name (5 scenarios)\n",
110
+ "stderr": "",
111
+ "_parameters": {
112
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh move_source_list_however_built_loses_the_name 600'",
113
+ "cwd": "/workspace/repo",
114
+ "timeout_seconds": 600
115
+ }
116
+ }
117
+ },
118
+ {
119
+ "name": "gate_repo_suite_green_and_tests_untouched",
120
+ "weight": 0.03,
121
+ "value": 1.0,
122
+ "children": null,
123
+ "info": {
124
+ "exit_code": 0,
125
+ "stdout": "PASS: every shipped test file is byte for byte what it was\nPASS: the repository's own tests pass\n",
126
+ "stderr": "",
127
+ "_parameters": {
128
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh gate_repo_suite_green_and_tests_untouched 900'",
129
+ "cwd": "/workspace/repo",
130
+ "timeout_seconds": 900
131
+ }
132
+ }
133
+ }
134
+ ],
135
+ "status": "graded",
136
+ "patch_sha256": "0d2bb7844e4fbbf9603570156b1857e77c12abca0eaf486a93f5e4118f01b9dc",
137
+ "result": {
138
+ "reward": 1.0,
139
+ "done": true,
140
+ "content": null,
141
+ "info": {},
142
+ "isError": false,
143
+ "subscores": [
144
+ {
145
+ "name": "export_list_follows_the_rename",
146
+ "weight": 0.08,
147
+ "value": 1.0,
148
+ "children": null,
149
+ "info": {
150
+ "exit_code": 0,
151
+ "stdout": "PASS: the defining module's export list\nPASS: an export list written as a tuple over several lines\nPASS: the export list of a package that re-exports the name\nPASS: an export list naming a module that is being renamed\nPASS: an export list extended in place\nPASS: prose and an unrelated list of the same word\nPASS: another module that exports a name of its own\nPASS: an export list built through a variable\nPASS: an export list added to another list\nPASS: an export list written as one string of names\nPASS: an export list written as a block of names\nPASS: export_list_follows_the_rename (11 scenarios)\n",
152
+ "stderr": "",
153
+ "_parameters": {
154
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh export_list_follows_the_rename 600'",
155
+ "cwd": "/workspace/repo",
156
+ "timeout_seconds": 600
157
+ }
158
+ }
159
+ },
160
+ {
161
+ "name": "type_constructor_names_follow_the_rename",
162
+ "weight": 0.08,
163
+ "value": 1.0,
164
+ "children": null,
165
+ "info": {
166
+ "exit_code": 0,
167
+ "stdout": "PASS: the name a new type is given\nPASS: a new type built from a directly imported constructor\nPASS: the bound of a type variable\nPASS: a type whose name is spelled like something else\nPASS: a constraint of a type variable\nPASS: a new type whose name is handed over by keyword\nPASS: type_constructor_names_follow_the_rename (6 scenarios)\n",
168
+ "stderr": "",
169
+ "_parameters": {
170
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh type_constructor_names_follow_the_rename 600'",
171
+ "cwd": "/workspace/repo",
172
+ "timeout_seconds": 600
173
+ }
174
+ }
175
+ },
176
+ {
177
+ "name": "declared_attribute_names_follow_the_rename",
178
+ "weight": 0.08,
179
+ "value": 1.0,
180
+ "children": null,
181
+ "info": {
182
+ "exit_code": 0,
183
+ "stdout": "PASS: a slots tuple follows the attribute\nPASS: a slots list follows the attribute\nPASS: the positional attribute names a class declares for matching\nPASS: declared_attribute_names_follow_the_rename (3 scenarios)\n",
184
+ "stderr": "",
185
+ "_parameters": {
186
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh declared_attribute_names_follow_the_rename 600'",
187
+ "cwd": "/workspace/repo",
188
+ "timeout_seconds": 600
189
+ }
190
+ }
191
+ },
192
+ {
193
+ "name": "string_annotations_follow_and_data_stays",
194
+ "weight": 0.22,
195
+ "value": 1.0,
196
+ "children": null,
197
+ "info": {
198
+ "exit_code": 0,
199
+ "stdout": "PASS: a forward reference in a signature\nPASS: a forward reference inside a generic\nPASS: a literal type beside a forward reference\nPASS: the metadata of an annotated type\nPASS: a class body with a literal field and a forward reference\nPASS: string_annotations_follow_and_data_stays (5 scenarios)\n",
200
+ "stderr": "",
201
+ "_parameters": {
202
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh string_annotations_follow_and_data_stays 600'",
203
+ "cwd": "/workspace/repo",
204
+ "timeout_seconds": 600
205
+ }
206
+ }
207
+ },
208
+ {
209
+ "name": "move_keeps_both_export_contracts",
210
+ "weight": 0.08,
211
+ "value": 1.0,
212
+ "children": null,
213
+ "info": {
214
+ "exit_code": 0,
215
+ "stdout": "PASS: the module left behind stops exporting the name\nPASS: the module arrived in starts exporting the name\nPASS: a module with no export list is not given one\nPASS: move_keeps_both_export_contracts (3 scenarios)\n",
216
+ "stderr": "",
217
+ "_parameters": {
218
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh move_keeps_both_export_contracts 600'",
219
+ "cwd": "/workspace/repo",
220
+ "timeout_seconds": 600
221
+ }
222
+ }
223
+ },
224
+ {
225
+ "name": "move_destination_list_however_built_gains_the_name",
226
+ "weight": 0.22,
227
+ "value": 1.0,
228
+ "children": null,
229
+ "info": {
230
+ "exit_code": 0,
231
+ "stdout": "PASS: the list the destination publishes is built through a variable\nPASS: the list the destination publishes is chosen by a condition\nPASS: the list the destination publishes is a sorted copy\nPASS: the list the destination publishes is one string of names\nPASS: the generated import does not carry the export list across\nPASS: move_destination_list_however_built_gains_the_name (5 scenarios)\n",
232
+ "stderr": "",
233
+ "_parameters": {
234
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh move_destination_list_however_built_gains_the_name 600'",
235
+ "cwd": "/workspace/repo",
236
+ "timeout_seconds": 600
237
+ }
238
+ }
239
+ },
240
+ {
241
+ "name": "move_source_list_however_built_loses_the_name",
242
+ "weight": 0.21,
243
+ "value": 1.0,
244
+ "children": null,
245
+ "info": {
246
+ "exit_code": 0,
247
+ "stdout": "PASS: a list written as one string of names\nPASS: a name put on the list at its front\nPASS: a name appended to the list\nPASS: a tuple of two names\nPASS: a tuple of names held in a variable\nPASS: move_source_list_however_built_loses_the_name (5 scenarios)\n",
248
+ "stderr": "",
249
+ "_parameters": {
250
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'bash /hud/grader/run_grading.sh move_source_list_however_built_loses_the_name 600'",
251
+ "cwd": "/workspace/repo",
252
+ "timeout_seconds": 600
253
+ }
254
+ }
255
+ },
256
+ {
257
+ "name": "gate_repo_suite_green_and_tests_untouched",
258
+ "weight": 0.03,
259
+ "value": 1.0,
260
+ "children": null,
261
+ "info": {
262
+ "exit_code": 0,
263
+ "stdout": "PASS: every shipped test file is byte for byte what it was\nPASS: the repository's own tests pass\n",
264
+ "stderr": "",
265
+ "_parameters": {
266
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc 'CORE_GREEN=1 bash /hud/grader/run_grading.sh gate_repo_suite_green_and_tests_untouched 900'",
267
+ "cwd": "/workspace/repo",
268
+ "timeout_seconds": 900
269
+ }
270
+ }
271
+ }
272
+ ]
273
+ }
274
+ }
harbor/evidence/rope/summary.json ADDED
@@ -0,0 +1,149 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "name": "rope",
3
+ "measure": {
4
+ "ok": true,
5
+ "hud": "0.6.15",
6
+ "path": "/opt/agentvenv/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games",
7
+ "handed": [
8
+ "PIP_DISABLE_PIP_VERSION_CHECK",
9
+ "PYTHONDONTWRITEBYTECODE"
10
+ ],
11
+ "repo_dir": "/workspace/repo",
12
+ "python_usr_local": true,
13
+ "seconds": 4
14
+ },
15
+ "parity": {
16
+ "ok": true,
17
+ "reward": 1.0,
18
+ "criteria": 8,
19
+ "unmet": [],
20
+ "info": null,
21
+ "seconds": 30
22
+ },
23
+ "task_id": "rope_rename_all_reexport_owners_contract",
24
+ "image": "ec-swe-rope:source-v3",
25
+ "build": {
26
+ "ok": true,
27
+ "image_id": "sha256:e33bc697f20f1281afeb4f9862caa9dc697b1c045eb68e0d5425565a1d7196e5",
28
+ "ladder": {
29
+ "gold": 1.0,
30
+ "base": 0.0,
31
+ "noop": 0.0,
32
+ "lazy": 0.0,
33
+ "alt": 0.84,
34
+ "prevgold": 0.19,
35
+ "cheat": 0.08,
36
+ "tamper": 0.0,
37
+ "tamper_key": 0.0,
38
+ "tamper_gate": 0.16,
39
+ "tamper_report": 0.16,
40
+ "tamper_wire": 0.16
41
+ },
42
+ "source_digest": "d7a94af16d5e99d1",
43
+ "source": "edited",
44
+ "seconds": 362
45
+ },
46
+ "prepare": {
47
+ "ok": true,
48
+ "bundle": "rope-r5",
49
+ "converter": "b8bba68767da888f",
50
+ "pinned_files": 25,
51
+ "criteria": 8,
52
+ "seconds": 1
53
+ },
54
+ "qualified": false,
55
+ "controls": {
56
+ "ok": false,
57
+ "checks": {
58
+ "noop_is_zero": true,
59
+ "reference_is_one": true,
60
+ "reference_equals_native": true,
61
+ "agent_is_isolated": true
62
+ },
63
+ "results": {
64
+ "noop": {
65
+ "run": "rope-r5-control-noop-1791900129",
66
+ "reward": 0.0,
67
+ "stop": "completed",
68
+ "error": null,
69
+ "seconds": 130,
70
+ "probe": false,
71
+ "status": "graded",
72
+ "verifier_error": null,
73
+ "exit_codes": [
74
+ 1
75
+ ],
76
+ "attempts": 1
77
+ },
78
+ "reference": {
79
+ "run": "rope-r5-control-reference-1791900260",
80
+ "reward": 1.0,
81
+ "stop": "completed",
82
+ "error": null,
83
+ "seconds": 98,
84
+ "probe": true,
85
+ "status": "graded",
86
+ "verifier_error": null,
87
+ "exit_codes": [
88
+ 0
89
+ ],
90
+ "subscores": {
91
+ "export_list_follows_the_rename": [
92
+ 1.0,
93
+ 0.08
94
+ ],
95
+ "type_constructor_names_follow_the_rename": [
96
+ 1.0,
97
+ 0.08
98
+ ],
99
+ "declared_attribute_names_follow_the_rename": [
100
+ 1.0,
101
+ 0.08
102
+ ],
103
+ "string_annotations_follow_and_data_stays": [
104
+ 1.0,
105
+ 0.22
106
+ ],
107
+ "move_keeps_both_export_contracts": [
108
+ 1.0,
109
+ 0.08
110
+ ],
111
+ "move_destination_list_however_built_gains_the_name": [
112
+ 1.0,
113
+ 0.22
114
+ ],
115
+ "move_source_list_however_built_loses_the_name": [
116
+ 1.0,
117
+ 0.21
118
+ ],
119
+ "gate_repo_suite_green_and_tests_untouched": [
120
+ 1.0,
121
+ 0.03
122
+ ]
123
+ },
124
+ "attempts": 1
125
+ }
126
+ },
127
+ "bundle": "rope-r5",
128
+ "complete": false,
129
+ "seconds": 228
130
+ },
131
+ "leak": {
132
+ "scan_finished": true,
133
+ "hits_outside_checkout": [],
134
+ "other_files_holding_only_upstream_lines": 0,
135
+ "library_files_sharing_a_line": 0,
136
+ "most_lines_shared_by_one_library_file": 0,
137
+ "private_paths_absent": true,
138
+ "public_lines_shared_with_patch_and_graders": [
139
+ 3,
140
+ 0
141
+ ],
142
+ "private_lines_only_in_agent_checkout": [
143
+ 0,
144
+ 0
145
+ ],
146
+ "ok": true,
147
+ "seconds": 18
148
+ }
149
+ }
harbor/evidence/zod/agent-image-scan.txt ADDED
@@ -0,0 +1,36 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ needles: 1582
2
+ 2 matching line(s): /workspace/repo/packages/zod/src/v4/core/tests/compile.test.ts
3
+ 1 matching line(s): /workspace/repo/packages/zod/src/v4/core/json-schema-processors.ts
4
+ 2 matching line(s): /workspace/repo/packages/zod/src/v4/classic/tests/record.test.ts
5
+ 234 matching line(s): /workspace/repo/packages/zod/src/v4/classic/tests/from-json-schema.test.ts
6
+ 9 matching line(s): /workspace/repo/packages/zod/src/v4/classic/tests/to-json-schema-methods.test.ts
7
+ 1 matching line(s): /workspace/repo/packages/zod/src/v4/classic/tests/catch.test.ts
8
+ 571 matching line(s): /workspace/repo/packages/zod/src/v4/classic/tests/to-json-schema.test.ts
9
+ 2 matching line(s): /workspace/repo/packages/zod/src/v4/classic/tests/datetime.test.ts
10
+ 3 matching line(s): /workspace/repo/packages/docs/content/json-schema.mdx
11
+ 82 matching line(s): /workspace/repo/node_modules/.pnpm/zod@4.0.8/node_modules/zod/src/v4/classic/tests/to-json-schema.test.ts
12
+ 3 matching line(s): /workspace/repo/node_modules/.pnpm/@seriousme+openapi-schema-validator@2.9.0/node_modules/@seriousme/openapi-schema-validator/README.md
13
+ 2 matching line(s): /workspace/repo/node_modules/.pnpm/@seriousme+openapi-schema-validator@2.9.0/node_modules/@seriousme/openapi-schema-validator/UPGRADING.md
14
+ 1 matching line(s): /workspace/repo/node_modules/.pnpm/zod@4.4.3/node_modules/zod/src/v4/classic/tests/record.test.ts
15
+ 74 matching line(s): /workspace/repo/node_modules/.pnpm/zod@4.4.3/node_modules/zod/src/v4/classic/tests/from-json-schema.test.ts
16
+ 9 matching line(s): /workspace/repo/node_modules/.pnpm/zod@4.4.3/node_modules/zod/src/v4/classic/tests/to-json-schema-methods.test.ts
17
+ 176 matching line(s): /workspace/repo/node_modules/.pnpm/zod@4.4.3/node_modules/zod/src/v4/classic/tests/to-json-schema.test.ts
18
+ 3 matching line(s): /tmp/agent-home/.local/share/pnpm/store/v11/files/70/cb2bcdec2238b686581c1875801ebbe4655e31e481abb02808b641794cf61202fa15dc6d132007920e5514a5b30eca9631f1f497dc5bd161bb30e306db1242
19
+ 82 matching line(s): /tmp/agent-home/.local/share/pnpm/store/v11/files/8b/8b12266aa4f1770c38b9315660998b4ec629d6dc619baf4a6d546195109f73e2d04bd95ee6969b2f9b1b2265f28162d26e962ae076d3c19ebefa0116f337a7
20
+ 74 matching line(s): /tmp/agent-home/.local/share/pnpm/store/v11/files/32/6254f362a42af3d2190672411f230955afe95289cec7e3faa916c4321e1dcc9e1fc392d30878ccba466469557186aed95195422285205dfe5c9058384aebd8
21
+ 176 matching line(s): /tmp/agent-home/.local/share/pnpm/store/v11/files/0c/f56b6dbef29f709b57525b1d28ee2c4b4d0fba92e84218ff26813643513b3de6f18aaa311f93bd2b37e4a0b803d7fe2edec9ca8b8450bbd4af0c1d5ade13b7
22
+ 9 matching line(s): /tmp/agent-home/.local/share/pnpm/store/v11/files/ba/92c366de0fa10d4e1eb680244d2729bd9db73730528ac46e5eaf0edc5b586a958196da3e5fb34d860984ee358eb69f9f997fa8d57926cb81804b3ceec53f76
23
+ 1 matching line(s): /tmp/agent-home/.local/share/pnpm/store/v11/files/6b/27923e8875d5efbcf5fcc377fc75e63098b6e0d7de4a4d73391a9605a0fba28d55179223b21fa094f2cabda5a055399c8f3638268f22e8dc3f6db2685cd730
24
+ 2 matching line(s): /tmp/agent-home/.local/share/pnpm/store/v11/files/af/cef11e126bb20cd74708e91498bcd10cbe0d17c183f370ebd213a51f8cf2a016d6b14d8f86015c3b1d7286b311f95ebbe8c584ba64473485e54cd4fe2fb46f
25
+ scan finished
26
+ absent: /hud
27
+ absent: /app
28
+ absent: /tests
29
+ present: /opt/task-tools/baseline.git
30
+ reference-patch lines in the agent's tracked files: 1, of which the pristine checkout lacks: 0
31
+ grader lines in the agent's tracked files: 751, of which the pristine checkout lacks: 0
32
+ reference-patch lines in total: 43, grader lines in total: 1531
33
+ private lines in 7 other files outside the checkout: 221, of which upstream lacks: 0
34
+ --- private lines only the agent's checkout holds (expect none)
35
+ --- the agent's checkout: uncommitted changes (expect none), then its history
36
+ 818c759 baseline
harbor/evidence/zod/native-reference.json ADDED
@@ -0,0 +1,204 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "reward": 1.0,
3
+ "done": true,
4
+ "content": null,
5
+ "info": {
6
+ "blocker_policy": "weight",
7
+ "failed_blockers": []
8
+ },
9
+ "isError": false,
10
+ "subscores": [
11
+ {
12
+ "name": "g1_catch_value_degrades",
13
+ "weight": 0.04,
14
+ "value": 1.0,
15
+ "children": null,
16
+ "info": {
17
+ "exit_code": 0,
18
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g1_catch_value_degrades: PASS\n",
19
+ "stderr": "",
20
+ "_parameters": {
21
+ "command": "/bin/bash /hud/grader/run_grading.sh g1_catch_value_degrades",
22
+ "cwd": "/workspace/repo",
23
+ "timeout_seconds": 600
24
+ }
25
+ }
26
+ },
27
+ {
28
+ "name": "g6_unencodable_default_degrades",
29
+ "weight": 0.04,
30
+ "value": 1.0,
31
+ "children": null,
32
+ "info": {
33
+ "exit_code": 0,
34
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g6_unencodable_default_degrades: PASS\n",
35
+ "stderr": "",
36
+ "_parameters": {
37
+ "command": "/bin/bash /hud/grader/run_grading.sh g6_unencodable_default_degrades",
38
+ "cwd": "/workspace/repo",
39
+ "timeout_seconds": 600
40
+ }
41
+ }
42
+ },
43
+ {
44
+ "name": "g5_default_value_conforms",
45
+ "weight": 0.11,
46
+ "value": 1.0,
47
+ "children": null,
48
+ "info": {
49
+ "exit_code": 0,
50
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g5_default_value_conforms: PASS\n",
51
+ "stderr": "",
52
+ "_parameters": {
53
+ "command": "/bin/bash /hud/grader/run_grading.sh g5_default_value_conforms",
54
+ "cwd": "/workspace/repo",
55
+ "timeout_seconds": 600
56
+ }
57
+ }
58
+ },
59
+ {
60
+ "name": "g2_empty_positional_list",
61
+ "weight": 0.09,
62
+ "value": 1.0,
63
+ "children": null,
64
+ "info": {
65
+ "exit_code": 0,
66
+ "stdout": "VITEST passes=4 failures=0 pending=0 todo=0 tests=4 expected=4\nCRITERION g2_empty_positional_list: PASS\n",
67
+ "stderr": "",
68
+ "_parameters": {
69
+ "command": "/bin/bash /hud/grader/run_grading.sh g2_empty_positional_list",
70
+ "cwd": "/workspace/repo",
71
+ "timeout_seconds": 600
72
+ }
73
+ }
74
+ },
75
+ {
76
+ "name": "g2_empty_tuple_rest_element",
77
+ "weight": 0.05,
78
+ "value": 1.0,
79
+ "children": null,
80
+ "info": {
81
+ "exit_code": 0,
82
+ "stdout": "VITEST passes=2 failures=0 pending=0 todo=0 tests=2 expected=2\nCRITERION g2_empty_tuple_rest_element: PASS\n",
83
+ "stderr": "",
84
+ "_parameters": {
85
+ "command": "/bin/bash /hud/grader/run_grading.sh g2_empty_tuple_rest_element",
86
+ "cwd": "/workspace/repo",
87
+ "timeout_seconds": 600
88
+ }
89
+ }
90
+ },
91
+ {
92
+ "name": "g3_pattern_keyed_record_openapi",
93
+ "weight": 0.11,
94
+ "value": 1.0,
95
+ "children": null,
96
+ "info": {
97
+ "exit_code": 0,
98
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g3_pattern_keyed_record_openapi: PASS\n",
99
+ "stderr": "",
100
+ "_parameters": {
101
+ "command": "/bin/bash /hud/grader/run_grading.sh g3_pattern_keyed_record_openapi",
102
+ "cwd": "/workspace/repo",
103
+ "timeout_seconds": 600
104
+ }
105
+ }
106
+ },
107
+ {
108
+ "name": "g4_metadata_examples_openapi",
109
+ "weight": 0.09,
110
+ "value": 1.0,
111
+ "children": null,
112
+ "info": {
113
+ "exit_code": 0,
114
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g4_metadata_examples_openapi: PASS\n",
115
+ "stderr": "",
116
+ "_parameters": {
117
+ "command": "/bin/bash /hud/grader/run_grading.sh g4_metadata_examples_openapi",
118
+ "cwd": "/workspace/repo",
119
+ "timeout_seconds": 600
120
+ }
121
+ }
122
+ },
123
+ {
124
+ "name": "g7_null_literal_openapi",
125
+ "weight": 0.09,
126
+ "value": 1.0,
127
+ "children": null,
128
+ "info": {
129
+ "exit_code": 0,
130
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g7_null_literal_openapi: PASS\n",
131
+ "stderr": "",
132
+ "_parameters": {
133
+ "command": "/bin/bash /hud/grader/run_grading.sh g7_null_literal_openapi",
134
+ "cwd": "/workspace/repo",
135
+ "timeout_seconds": 600
136
+ }
137
+ }
138
+ },
139
+ {
140
+ "name": "g8_empty_union_accepts_nothing",
141
+ "weight": 0.09,
142
+ "value": 1.0,
143
+ "children": null,
144
+ "info": {
145
+ "exit_code": 0,
146
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g8_empty_union_accepts_nothing: PASS\n",
147
+ "stderr": "",
148
+ "_parameters": {
149
+ "command": "/bin/bash /hud/grader/run_grading.sh g8_empty_union_accepts_nothing",
150
+ "cwd": "/workspace/repo",
151
+ "timeout_seconds": 600
152
+ }
153
+ }
154
+ },
155
+ {
156
+ "name": "g9_enum_members_unique",
157
+ "weight": 0.09,
158
+ "value": 1.0,
159
+ "children": null,
160
+ "info": {
161
+ "exit_code": 0,
162
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g9_enum_members_unique: PASS\n",
163
+ "stderr": "",
164
+ "_parameters": {
165
+ "command": "/bin/bash /hud/grader/run_grading.sh g9_enum_members_unique",
166
+ "cwd": "/workspace/repo",
167
+ "timeout_seconds": 600
168
+ }
169
+ }
170
+ },
171
+ {
172
+ "name": "d1_established_behavior",
173
+ "weight": 0.1,
174
+ "value": 1.0,
175
+ "children": null,
176
+ "info": {
177
+ "exit_code": 0,
178
+ "stdout": "VITEST passes=22 failures=0 pending=0 todo=0 tests=22 expected=22\nCRITERION d1_established_behavior: PASS\n",
179
+ "stderr": "",
180
+ "_parameters": {
181
+ "command": "/bin/bash /hud/grader/run_grading.sh d1_established_behavior",
182
+ "cwd": "/workspace/repo",
183
+ "timeout_seconds": 900
184
+ }
185
+ }
186
+ },
187
+ {
188
+ "name": "preservation_converter_suites",
189
+ "weight": 0.10000000000000009,
190
+ "value": 1.0,
191
+ "children": null,
192
+ "info": {
193
+ "exit_code": 0,
194
+ "stdout": "VITEST passes=734 failures=0 pending=0 todo=0 tests=734 expected=734\nCRITERION preservation_converter_suites: PASS\n",
195
+ "stderr": "",
196
+ "_parameters": {
197
+ "command": "/bin/bash /hud/grader/run_grading.sh preservation_converter_suites",
198
+ "cwd": "/workspace/repo",
199
+ "timeout_seconds": 900
200
+ }
201
+ }
202
+ }
203
+ ]
204
+ }
harbor/evidence/zod/reports/noop.json ADDED
@@ -0,0 +1,108 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "revision": "coding-rubric-v2",
3
+ "task_id": "zod_json_schema_target_legality",
4
+ "grader_version": "0.6.17",
5
+ "commands": [],
6
+ "status": "empty_patch",
7
+ "patch_sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
8
+ "result": {
9
+ "reward": 0.0,
10
+ "done": true,
11
+ "content": "Empty diff: no change to grade.",
12
+ "info": {
13
+ "failed_blockers": [
14
+ "g1_catch_value_degrades",
15
+ "d1_established_behavior",
16
+ "preservation_converter_suites"
17
+ ],
18
+ "blocker_policy": "weight"
19
+ },
20
+ "isError": false,
21
+ "subscores": [
22
+ {
23
+ "name": "g1_catch_value_degrades",
24
+ "weight": 0.04,
25
+ "value": 0.0,
26
+ "children": null,
27
+ "info": null
28
+ },
29
+ {
30
+ "name": "g6_unencodable_default_degrades",
31
+ "weight": 0.04,
32
+ "value": 0.0,
33
+ "children": null,
34
+ "info": null
35
+ },
36
+ {
37
+ "name": "g5_default_value_conforms",
38
+ "weight": 0.11,
39
+ "value": 0.0,
40
+ "children": null,
41
+ "info": null
42
+ },
43
+ {
44
+ "name": "g2_empty_positional_list",
45
+ "weight": 0.09,
46
+ "value": 0.0,
47
+ "children": null,
48
+ "info": null
49
+ },
50
+ {
51
+ "name": "g2_empty_tuple_rest_element",
52
+ "weight": 0.05,
53
+ "value": 0.0,
54
+ "children": null,
55
+ "info": null
56
+ },
57
+ {
58
+ "name": "g3_pattern_keyed_record_openapi",
59
+ "weight": 0.11,
60
+ "value": 0.0,
61
+ "children": null,
62
+ "info": null
63
+ },
64
+ {
65
+ "name": "g4_metadata_examples_openapi",
66
+ "weight": 0.09,
67
+ "value": 0.0,
68
+ "children": null,
69
+ "info": null
70
+ },
71
+ {
72
+ "name": "g7_null_literal_openapi",
73
+ "weight": 0.09,
74
+ "value": 0.0,
75
+ "children": null,
76
+ "info": null
77
+ },
78
+ {
79
+ "name": "g8_empty_union_accepts_nothing",
80
+ "weight": 0.09,
81
+ "value": 0.0,
82
+ "children": null,
83
+ "info": null
84
+ },
85
+ {
86
+ "name": "g9_enum_members_unique",
87
+ "weight": 0.09,
88
+ "value": 0.0,
89
+ "children": null,
90
+ "info": null
91
+ },
92
+ {
93
+ "name": "d1_established_behavior",
94
+ "weight": 0.1,
95
+ "value": 0.0,
96
+ "children": null,
97
+ "info": null
98
+ },
99
+ {
100
+ "name": "preservation_converter_suites",
101
+ "weight": 0.1,
102
+ "value": 0.0,
103
+ "children": null,
104
+ "info": null
105
+ }
106
+ ]
107
+ }
108
+ }
harbor/evidence/zod/reports/reference.json ADDED
@@ -0,0 +1,405 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "revision": "coding-rubric-v2",
3
+ "task_id": "zod_json_schema_target_legality",
4
+ "grader_version": "0.6.17",
5
+ "commands": [
6
+ {
7
+ "name": "g1_catch_value_degrades",
8
+ "weight": 0.04,
9
+ "value": 1.0,
10
+ "children": null,
11
+ "info": {
12
+ "exit_code": 0,
13
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g1_catch_value_degrades: PASS\n",
14
+ "stderr": "",
15
+ "_parameters": {
16
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g1_catch_value_degrades'",
17
+ "cwd": "/workspace/repo",
18
+ "timeout_seconds": 600
19
+ }
20
+ }
21
+ },
22
+ {
23
+ "name": "g6_unencodable_default_degrades",
24
+ "weight": 0.04,
25
+ "value": 1.0,
26
+ "children": null,
27
+ "info": {
28
+ "exit_code": 0,
29
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g6_unencodable_default_degrades: PASS\n",
30
+ "stderr": "",
31
+ "_parameters": {
32
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g6_unencodable_default_degrades'",
33
+ "cwd": "/workspace/repo",
34
+ "timeout_seconds": 600
35
+ }
36
+ }
37
+ },
38
+ {
39
+ "name": "g5_default_value_conforms",
40
+ "weight": 0.11,
41
+ "value": 1.0,
42
+ "children": null,
43
+ "info": {
44
+ "exit_code": 0,
45
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g5_default_value_conforms: PASS\n",
46
+ "stderr": "",
47
+ "_parameters": {
48
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g5_default_value_conforms'",
49
+ "cwd": "/workspace/repo",
50
+ "timeout_seconds": 600
51
+ }
52
+ }
53
+ },
54
+ {
55
+ "name": "g2_empty_positional_list",
56
+ "weight": 0.09,
57
+ "value": 1.0,
58
+ "children": null,
59
+ "info": {
60
+ "exit_code": 0,
61
+ "stdout": "VITEST passes=4 failures=0 pending=0 todo=0 tests=4 expected=4\nCRITERION g2_empty_positional_list: PASS\n",
62
+ "stderr": "",
63
+ "_parameters": {
64
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g2_empty_positional_list'",
65
+ "cwd": "/workspace/repo",
66
+ "timeout_seconds": 600
67
+ }
68
+ }
69
+ },
70
+ {
71
+ "name": "g2_empty_tuple_rest_element",
72
+ "weight": 0.05,
73
+ "value": 1.0,
74
+ "children": null,
75
+ "info": {
76
+ "exit_code": 0,
77
+ "stdout": "VITEST passes=2 failures=0 pending=0 todo=0 tests=2 expected=2\nCRITERION g2_empty_tuple_rest_element: PASS\n",
78
+ "stderr": "",
79
+ "_parameters": {
80
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g2_empty_tuple_rest_element'",
81
+ "cwd": "/workspace/repo",
82
+ "timeout_seconds": 600
83
+ }
84
+ }
85
+ },
86
+ {
87
+ "name": "g3_pattern_keyed_record_openapi",
88
+ "weight": 0.11,
89
+ "value": 1.0,
90
+ "children": null,
91
+ "info": {
92
+ "exit_code": 0,
93
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g3_pattern_keyed_record_openapi: PASS\n",
94
+ "stderr": "",
95
+ "_parameters": {
96
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g3_pattern_keyed_record_openapi'",
97
+ "cwd": "/workspace/repo",
98
+ "timeout_seconds": 600
99
+ }
100
+ }
101
+ },
102
+ {
103
+ "name": "g4_metadata_examples_openapi",
104
+ "weight": 0.09,
105
+ "value": 1.0,
106
+ "children": null,
107
+ "info": {
108
+ "exit_code": 0,
109
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g4_metadata_examples_openapi: PASS\n",
110
+ "stderr": "",
111
+ "_parameters": {
112
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g4_metadata_examples_openapi'",
113
+ "cwd": "/workspace/repo",
114
+ "timeout_seconds": 600
115
+ }
116
+ }
117
+ },
118
+ {
119
+ "name": "g7_null_literal_openapi",
120
+ "weight": 0.09,
121
+ "value": 1.0,
122
+ "children": null,
123
+ "info": {
124
+ "exit_code": 0,
125
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g7_null_literal_openapi: PASS\n",
126
+ "stderr": "",
127
+ "_parameters": {
128
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g7_null_literal_openapi'",
129
+ "cwd": "/workspace/repo",
130
+ "timeout_seconds": 600
131
+ }
132
+ }
133
+ },
134
+ {
135
+ "name": "g8_empty_union_accepts_nothing",
136
+ "weight": 0.09,
137
+ "value": 1.0,
138
+ "children": null,
139
+ "info": {
140
+ "exit_code": 0,
141
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g8_empty_union_accepts_nothing: PASS\n",
142
+ "stderr": "",
143
+ "_parameters": {
144
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g8_empty_union_accepts_nothing'",
145
+ "cwd": "/workspace/repo",
146
+ "timeout_seconds": 600
147
+ }
148
+ }
149
+ },
150
+ {
151
+ "name": "g9_enum_members_unique",
152
+ "weight": 0.09,
153
+ "value": 1.0,
154
+ "children": null,
155
+ "info": {
156
+ "exit_code": 0,
157
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g9_enum_members_unique: PASS\n",
158
+ "stderr": "",
159
+ "_parameters": {
160
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g9_enum_members_unique'",
161
+ "cwd": "/workspace/repo",
162
+ "timeout_seconds": 600
163
+ }
164
+ }
165
+ },
166
+ {
167
+ "name": "d1_established_behavior",
168
+ "weight": 0.1,
169
+ "value": 1.0,
170
+ "children": null,
171
+ "info": {
172
+ "exit_code": 0,
173
+ "stdout": "VITEST passes=22 failures=0 pending=0 todo=0 tests=22 expected=22\nCRITERION d1_established_behavior: PASS\n",
174
+ "stderr": "",
175
+ "_parameters": {
176
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh d1_established_behavior'",
177
+ "cwd": "/workspace/repo",
178
+ "timeout_seconds": 900
179
+ }
180
+ }
181
+ },
182
+ {
183
+ "name": "preservation_converter_suites",
184
+ "weight": 0.10000000000000009,
185
+ "value": 1.0,
186
+ "children": null,
187
+ "info": {
188
+ "exit_code": 0,
189
+ "stdout": "VITEST passes=734 failures=0 pending=0 todo=0 tests=734 expected=734\nCRITERION preservation_converter_suites: PASS\n",
190
+ "stderr": "",
191
+ "_parameters": {
192
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh preservation_converter_suites'",
193
+ "cwd": "/workspace/repo",
194
+ "timeout_seconds": 900
195
+ }
196
+ }
197
+ }
198
+ ],
199
+ "status": "graded",
200
+ "patch_sha256": "4cbdcd45459e6ca72da3fe41ef8cd70b715d5aa61f7af94c4e1183b2e299a182",
201
+ "result": {
202
+ "reward": 1.0,
203
+ "done": true,
204
+ "content": null,
205
+ "info": {
206
+ "blocker_policy": "weight",
207
+ "failed_blockers": []
208
+ },
209
+ "isError": false,
210
+ "subscores": [
211
+ {
212
+ "name": "g1_catch_value_degrades",
213
+ "weight": 0.04,
214
+ "value": 1.0,
215
+ "children": null,
216
+ "info": {
217
+ "exit_code": 0,
218
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g1_catch_value_degrades: PASS\n",
219
+ "stderr": "",
220
+ "_parameters": {
221
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g1_catch_value_degrades'",
222
+ "cwd": "/workspace/repo",
223
+ "timeout_seconds": 600
224
+ }
225
+ }
226
+ },
227
+ {
228
+ "name": "g6_unencodable_default_degrades",
229
+ "weight": 0.04,
230
+ "value": 1.0,
231
+ "children": null,
232
+ "info": {
233
+ "exit_code": 0,
234
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g6_unencodable_default_degrades: PASS\n",
235
+ "stderr": "",
236
+ "_parameters": {
237
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g6_unencodable_default_degrades'",
238
+ "cwd": "/workspace/repo",
239
+ "timeout_seconds": 600
240
+ }
241
+ }
242
+ },
243
+ {
244
+ "name": "g5_default_value_conforms",
245
+ "weight": 0.11,
246
+ "value": 1.0,
247
+ "children": null,
248
+ "info": {
249
+ "exit_code": 0,
250
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g5_default_value_conforms: PASS\n",
251
+ "stderr": "",
252
+ "_parameters": {
253
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g5_default_value_conforms'",
254
+ "cwd": "/workspace/repo",
255
+ "timeout_seconds": 600
256
+ }
257
+ }
258
+ },
259
+ {
260
+ "name": "g2_empty_positional_list",
261
+ "weight": 0.09,
262
+ "value": 1.0,
263
+ "children": null,
264
+ "info": {
265
+ "exit_code": 0,
266
+ "stdout": "VITEST passes=4 failures=0 pending=0 todo=0 tests=4 expected=4\nCRITERION g2_empty_positional_list: PASS\n",
267
+ "stderr": "",
268
+ "_parameters": {
269
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g2_empty_positional_list'",
270
+ "cwd": "/workspace/repo",
271
+ "timeout_seconds": 600
272
+ }
273
+ }
274
+ },
275
+ {
276
+ "name": "g2_empty_tuple_rest_element",
277
+ "weight": 0.05,
278
+ "value": 1.0,
279
+ "children": null,
280
+ "info": {
281
+ "exit_code": 0,
282
+ "stdout": "VITEST passes=2 failures=0 pending=0 todo=0 tests=2 expected=2\nCRITERION g2_empty_tuple_rest_element: PASS\n",
283
+ "stderr": "",
284
+ "_parameters": {
285
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g2_empty_tuple_rest_element'",
286
+ "cwd": "/workspace/repo",
287
+ "timeout_seconds": 600
288
+ }
289
+ }
290
+ },
291
+ {
292
+ "name": "g3_pattern_keyed_record_openapi",
293
+ "weight": 0.11,
294
+ "value": 1.0,
295
+ "children": null,
296
+ "info": {
297
+ "exit_code": 0,
298
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g3_pattern_keyed_record_openapi: PASS\n",
299
+ "stderr": "",
300
+ "_parameters": {
301
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g3_pattern_keyed_record_openapi'",
302
+ "cwd": "/workspace/repo",
303
+ "timeout_seconds": 600
304
+ }
305
+ }
306
+ },
307
+ {
308
+ "name": "g4_metadata_examples_openapi",
309
+ "weight": 0.09,
310
+ "value": 1.0,
311
+ "children": null,
312
+ "info": {
313
+ "exit_code": 0,
314
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g4_metadata_examples_openapi: PASS\n",
315
+ "stderr": "",
316
+ "_parameters": {
317
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g4_metadata_examples_openapi'",
318
+ "cwd": "/workspace/repo",
319
+ "timeout_seconds": 600
320
+ }
321
+ }
322
+ },
323
+ {
324
+ "name": "g7_null_literal_openapi",
325
+ "weight": 0.09,
326
+ "value": 1.0,
327
+ "children": null,
328
+ "info": {
329
+ "exit_code": 0,
330
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g7_null_literal_openapi: PASS\n",
331
+ "stderr": "",
332
+ "_parameters": {
333
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g7_null_literal_openapi'",
334
+ "cwd": "/workspace/repo",
335
+ "timeout_seconds": 600
336
+ }
337
+ }
338
+ },
339
+ {
340
+ "name": "g8_empty_union_accepts_nothing",
341
+ "weight": 0.09,
342
+ "value": 1.0,
343
+ "children": null,
344
+ "info": {
345
+ "exit_code": 0,
346
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g8_empty_union_accepts_nothing: PASS\n",
347
+ "stderr": "",
348
+ "_parameters": {
349
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g8_empty_union_accepts_nothing'",
350
+ "cwd": "/workspace/repo",
351
+ "timeout_seconds": 600
352
+ }
353
+ }
354
+ },
355
+ {
356
+ "name": "g9_enum_members_unique",
357
+ "weight": 0.09,
358
+ "value": 1.0,
359
+ "children": null,
360
+ "info": {
361
+ "exit_code": 0,
362
+ "stdout": "VITEST passes=6 failures=0 pending=0 todo=0 tests=6 expected=6\nCRITERION g9_enum_members_unique: PASS\n",
363
+ "stderr": "",
364
+ "_parameters": {
365
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh g9_enum_members_unique'",
366
+ "cwd": "/workspace/repo",
367
+ "timeout_seconds": 600
368
+ }
369
+ }
370
+ },
371
+ {
372
+ "name": "d1_established_behavior",
373
+ "weight": 0.1,
374
+ "value": 1.0,
375
+ "children": null,
376
+ "info": {
377
+ "exit_code": 0,
378
+ "stdout": "VITEST passes=22 failures=0 pending=0 todo=0 tests=22 expected=22\nCRITERION d1_established_behavior: PASS\n",
379
+ "stderr": "",
380
+ "_parameters": {
381
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh d1_established_behavior'",
382
+ "cwd": "/workspace/repo",
383
+ "timeout_seconds": 900
384
+ }
385
+ }
386
+ },
387
+ {
388
+ "name": "preservation_converter_suites",
389
+ "weight": 0.10000000000000009,
390
+ "value": 1.0,
391
+ "children": null,
392
+ "info": {
393
+ "exit_code": 0,
394
+ "stdout": "VITEST passes=734 failures=0 pending=0 todo=0 tests=734 expected=734\nCRITERION preservation_converter_suites: PASS\n",
395
+ "stderr": "",
396
+ "_parameters": {
397
+ "command": "setpriv --reuid 1000 --regid 1000 --clear-groups --no-new-privs env HOME=/tmp/agent-home bash -lc '/bin/bash /hud/grader/run_grading.sh preservation_converter_suites'",
398
+ "cwd": "/workspace/repo",
399
+ "timeout_seconds": 900
400
+ }
401
+ }
402
+ }
403
+ ]
404
+ }
405
+ }
harbor/evidence/zod/summary.json ADDED
@@ -0,0 +1,150 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "name": "zod",
3
+ "task_id": "zod_json_schema_target_legality",
4
+ "image": "ec-swe-zod:source-v7",
5
+ "build": {
6
+ "ok": true,
7
+ "image_id": "sha256:6c7eb55e9901704ab8e6b81e924c3c9ba35bfef05b814c6487399dc494123852",
8
+ "ladder": {},
9
+ "seconds": 0
10
+ },
11
+ "qualified": false,
12
+ "measure": {
13
+ "ok": true,
14
+ "hud": "0.6.17",
15
+ "path": "/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games",
16
+ "handed": [],
17
+ "repo_dir": "/workspace/repo",
18
+ "python_usr_local": false,
19
+ "seconds": 7,
20
+ "reused": true
21
+ },
22
+ "parity": {
23
+ "ok": true,
24
+ "reward": 1.0,
25
+ "criteria": 12,
26
+ "unmet": [],
27
+ "info": {
28
+ "blocker_policy": "weight",
29
+ "failed_blockers": []
30
+ },
31
+ "seconds": 578,
32
+ "reused": true
33
+ },
34
+ "prepare": {
35
+ "ok": true,
36
+ "bundle": "zod-r4",
37
+ "converter": "b8bba68767da888f",
38
+ "pinned_files": 26,
39
+ "criteria": 12,
40
+ "seconds": 3
41
+ },
42
+ "controls": {
43
+ "ok": false,
44
+ "checks": {
45
+ "noop_is_zero": true,
46
+ "reference_is_one": true,
47
+ "reference_equals_native": true,
48
+ "agent_is_isolated": true
49
+ },
50
+ "results": {
51
+ "noop": {
52
+ "run": "zod-r4-control-noop-1791892270",
53
+ "reward": 0.0,
54
+ "stop": "completed",
55
+ "error": null,
56
+ "seconds": 1299,
57
+ "probe": false,
58
+ "status": "empty_patch",
59
+ "verifier_error": null,
60
+ "exit_codes": [],
61
+ "attempts": 1
62
+ },
63
+ "reference": {
64
+ "run": "zod-r4-control-reference-1791892270",
65
+ "reward": 1.0,
66
+ "stop": "completed",
67
+ "error": null,
68
+ "seconds": 1383,
69
+ "probe": true,
70
+ "status": "graded",
71
+ "verifier_error": null,
72
+ "exit_codes": [
73
+ 0
74
+ ],
75
+ "subscores": {
76
+ "g1_catch_value_degrades": [
77
+ 1.0,
78
+ 0.04
79
+ ],
80
+ "g6_unencodable_default_degrades": [
81
+ 1.0,
82
+ 0.04
83
+ ],
84
+ "g5_default_value_conforms": [
85
+ 1.0,
86
+ 0.11
87
+ ],
88
+ "g2_empty_positional_list": [
89
+ 1.0,
90
+ 0.09
91
+ ],
92
+ "g2_empty_tuple_rest_element": [
93
+ 1.0,
94
+ 0.05
95
+ ],
96
+ "g3_pattern_keyed_record_openapi": [
97
+ 1.0,
98
+ 0.11
99
+ ],
100
+ "g4_metadata_examples_openapi": [
101
+ 1.0,
102
+ 0.09
103
+ ],
104
+ "g7_null_literal_openapi": [
105
+ 1.0,
106
+ 0.09
107
+ ],
108
+ "g8_empty_union_accepts_nothing": [
109
+ 1.0,
110
+ 0.09
111
+ ],
112
+ "g9_enum_members_unique": [
113
+ 1.0,
114
+ 0.09
115
+ ],
116
+ "d1_established_behavior": [
117
+ 1.0,
118
+ 0.1
119
+ ],
120
+ "preservation_converter_suites": [
121
+ 1.0,
122
+ 0.10000000000000009
123
+ ]
124
+ },
125
+ "attempts": 1
126
+ }
127
+ },
128
+ "bundle": "zod-r4",
129
+ "complete": false,
130
+ "seconds": 1383
131
+ },
132
+ "leak": {
133
+ "scan_finished": true,
134
+ "hits_outside_checkout": [],
135
+ "other_files_holding_only_upstream_lines": 7,
136
+ "library_files_sharing_a_line": 0,
137
+ "most_lines_shared_by_one_library_file": 0,
138
+ "private_paths_absent": true,
139
+ "public_lines_shared_with_patch_and_graders": [
140
+ 1,
141
+ 751
142
+ ],
143
+ "private_lines_only_in_agent_checkout": [
144
+ 0,
145
+ 0
146
+ ],
147
+ "ok": true,
148
+ "seconds": 88
149
+ }
150
+ }
harbor/manifest.json ADDED
@@ -0,0 +1,527 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "schema_version": 1,
3
+ "created": "2026-10-13",
4
+ "contains": "reference solutions and hidden graders; keep away from evaluated models",
5
+ "package_revision": "coding-rubric-v2",
6
+ "runtime": {
7
+ "python": "3.12",
8
+ "harbor": "0.23.0",
9
+ "platform": "linux/amd64"
10
+ },
11
+ "qualified_with": "stock Harbor 0.23.0 (oracle and nop agents) on Docker",
12
+ "tasks": [
13
+ {
14
+ "task_id": "coredns_rewrite_svcb_opt",
15
+ "name": "coredns",
16
+ "dataset_instance_id": "coredns__coredns-coredns__4097",
17
+ "repository": "coredns/coredns",
18
+ "language": "Go",
19
+ "source_folder": "coredns-v4",
20
+ "dockerfile": "Dockerfile.hud",
21
+ "source_image": "ec-swe-coredns:source-v4",
22
+ "source_image_id_at_qualification": "sha256:5f122f58a039aefe65ccf2fd057eceb288c09278edde20f2ff0f2598f52c22e9",
23
+ "grader_version": "0.6.18",
24
+ "criteria": 7,
25
+ "reward_rule": "authored",
26
+ "blocker_cap": null,
27
+ "author_calibration": {},
28
+ "provenance": {
29
+ "repository": "coredns/coredns",
30
+ "environment_id": "26a880f2-79fd-403a-8189-570cff511312",
31
+ "build": 4,
32
+ "build_id": "0f706606-696c-411a-b95a-727766f336ed",
33
+ "hosted_task": "coredns__4097",
34
+ "task_version": 1,
35
+ "source_archive_sha256": "f3e54c704918dc7b5043354e24681e708f15164f4069f857d4abf9de0faf796d",
36
+ "hosted_revision_argument": "not recorded; the scenario does not read it"
37
+ },
38
+ "checks_on_shipped_files": "all",
39
+ "further_checks": "broken fix 0; missing grader file: no reward; planted score 0; author's patches: none supplied"
40
+ },
41
+ {
42
+ "task_id": "epicyon_deleted_post_announce_cache_contract",
43
+ "name": "epicyon",
44
+ "dataset_instance_id": "bashrc2__epicyon-epicyon_deleted_post_announce_cache_contract-1c066303",
45
+ "repository": "bashrc2/epicyon",
46
+ "language": "Python",
47
+ "source_folder": "epicyon-v7",
48
+ "dockerfile": "Dockerfile.hud",
49
+ "source_image": "ec-swe-epicyon:source-v7",
50
+ "source_image_id_at_qualification": "sha256:74752fd4e8ebf481d6f0c01fd9b7e542c539f850bf9eed8503f41aaeabd7d99d",
51
+ "grader_version": "0.6.15",
52
+ "criteria": 11,
53
+ "reward_rule": "weighted_cap",
54
+ "blocker_cap": 0.6,
55
+ "author_calibration": {
56
+ "gold": 1.0,
57
+ "base": 0.0,
58
+ "noop": 0.0,
59
+ "lazy": 0.085,
60
+ "alt": 1.0,
61
+ "cheat": 0.6
62
+ },
63
+ "provenance": {
64
+ "repository": "bashrc2/epicyon",
65
+ "environment_id": "c29bfa96-5ecd-4ebd-9741-1f74147966c2",
66
+ "build": 7,
67
+ "build_id": "dd339e97-119f-4162-be02-d283a0784ff5",
68
+ "hosted_task": "epicyon_deleted_post_announce_cache_contract-1c066303",
69
+ "task_version": 1,
70
+ "source_archive_sha256": "f8c5e69a0a61ee283feb452cc2ed4e0645fe4ceff039b772af6119581f7151fb",
71
+ "hosted_revision_argument": "not recorded; the scenario does not read it"
72
+ },
73
+ "source_edited": {
74
+ "changed": [
75
+ "env.py",
76
+ "pyproject.toml"
77
+ ],
78
+ "removed": [],
79
+ "what": "the environment name was changed to a neutral one (ec-swe-epicyon-deleted-post-announce-cache)"
80
+ },
81
+ "checks_on_shipped_files": "reference, empty change, image scan",
82
+ "further_checks": "not yet; on the preceding build, with stock Harbor: broken fix 0; missing grader file: no reward; planted score 0; author's patches: 4 of 4"
83
+ },
84
+ {
85
+ "task_id": "rope_rename_all_reexport_owners_contract",
86
+ "name": "rope",
87
+ "dataset_instance_id": "python-rope__rope-rope_rename_all_reexport_owners_contract-1c066303",
88
+ "repository": "python-rope/rope",
89
+ "language": "Python",
90
+ "source_folder": "rope-v3",
91
+ "dockerfile": "Dockerfile.hud",
92
+ "source_image": "ec-swe-rope:source-v3",
93
+ "source_image_id_at_qualification": "sha256:e33bc697f20f1281afeb4f9862caa9dc697b1c045eb68e0d5425565a1d7196e5",
94
+ "grader_version": "0.6.15",
95
+ "criteria": 8,
96
+ "reward_rule": "weighted_cap",
97
+ "blocker_cap": 0.6,
98
+ "author_calibration": {
99
+ "gold": 1.0,
100
+ "base": 0.0,
101
+ "noop": 0.0,
102
+ "lazy": 0.0,
103
+ "alt": 0.84,
104
+ "prevgold": 0.19,
105
+ "cheat": 0.08,
106
+ "tamper": 0.0,
107
+ "tamper_key": 0.0,
108
+ "tamper_gate": 0.16,
109
+ "tamper_report": 0.16,
110
+ "tamper_wire": 0.16
111
+ },
112
+ "provenance": {
113
+ "repository": "python-rope/rope",
114
+ "environment_id": "98a7b668-7394-4dc8-a222-d1759208e2c0",
115
+ "build": 3,
116
+ "build_id": "2eef5e21-3eec-45df-aaee-043567b1bdf1",
117
+ "hosted_task": "rope_rename_all_reexport_owners_contract-1c066303",
118
+ "task_version": 1,
119
+ "source_archive_sha256": "09367f6384cda46d917e9ff0e0a3968e6d85ffbbc6c767c1825f6b69d97dffc3",
120
+ "hosted_revision_argument": "not recorded; the scenario does not read it"
121
+ },
122
+ "source_edited": {
123
+ "changed": [
124
+ "env.py",
125
+ "pyproject.toml"
126
+ ],
127
+ "removed": [],
128
+ "what": "the environment name was changed to a neutral one (ec-swe-rope-rename-all-reexport-owners)"
129
+ },
130
+ "checks_on_shipped_files": "reference, empty change, image scan",
131
+ "further_checks": "not yet; on the preceding build, with stock Harbor: broken fix 0; missing grader file: no reward; planted score 0; author's patches: 10 of 10"
132
+ },
133
+ {
134
+ "task_id": "zod_json_schema_target_legality",
135
+ "name": "zod",
136
+ "dataset_instance_id": "colinhacks__zod-zod-json-schema-target-legality",
137
+ "repository": "colinhacks/zod",
138
+ "language": "TypeScript",
139
+ "source_folder": "zod-v7",
140
+ "dockerfile": "Dockerfile.hud",
141
+ "source_image": "ec-swe-zod:source-v7",
142
+ "source_image_id_at_qualification": "sha256:6c7eb55e9901704ab8e6b81e924c3c9ba35bfef05b814c6487399dc494123852",
143
+ "grader_version": "0.6.17",
144
+ "criteria": 12,
145
+ "reward_rule": "authored",
146
+ "blocker_cap": null,
147
+ "author_calibration": {},
148
+ "provenance": {
149
+ "repository": "colinhacks/zod",
150
+ "environment_id": "130424c5-8a1d-4cb7-b5b0-ffa04b564d03",
151
+ "build": 7,
152
+ "build_id": "af9abdd0-1f19-4d21-80da-d60924ccc128",
153
+ "hosted_task": "zod-json-schema-target-legality",
154
+ "task_version": 1,
155
+ "source_archive_sha256": "feb1e6acfc057e95a3a89532cb7f322f2c08f6bfea65556d66a04ceca877a5bc",
156
+ "hosted_revision_argument": "not recorded; the scenario does not read it"
157
+ },
158
+ "checks_on_shipped_files": "reference, empty change, image scan",
159
+ "further_checks": "not yet; on an earlier build, with a different launcher: broken fix 0; missing grader file: no reward. Planted score: not run; author's patches: none supplied"
160
+ }
161
+ ],
162
+ "unpackaged": [
163
+ {
164
+ "source_edited": {
165
+ "changed": [
166
+ "env.py",
167
+ "tasks.py"
168
+ ],
169
+ "removed": [],
170
+ "what": "the environment name was changed to a neutral one (ec-swe-click)"
171
+ },
172
+ "task_id": "click",
173
+ "name": "click",
174
+ "dataset_instance_id": "pallets__click-click-help-defaults",
175
+ "repository": "pallets/click",
176
+ "source_folder": "click-v9",
177
+ "dockerfile": "Dockerfile.hud",
178
+ "source_image": "ec-swe-click:source-v9",
179
+ "package": null,
180
+ "why_no_package": "one criterion is judged by a model"
181
+ },
182
+ {
183
+ "source_edited": {
184
+ "changed": [
185
+ "env.py",
186
+ "tasks.py"
187
+ ],
188
+ "removed": [],
189
+ "what": "the environment name was changed to a neutral one (ec-swe-sequelize)"
190
+ },
191
+ "task_id": "sequelize",
192
+ "name": "sequelize",
193
+ "dataset_instance_id": "sequelize__sequelize-sequelize-bulkcreate-ignore-duplicates",
194
+ "repository": "sequelize/sequelize",
195
+ "source_folder": "sequelize-v27",
196
+ "dockerfile": "Dockerfile.hud",
197
+ "source_image": "ec-swe-sequelize:source-v27",
198
+ "package": null,
199
+ "why_no_package": "one criterion is judged by a model"
200
+ },
201
+ {
202
+ "source_edited": {
203
+ "changed": [
204
+ "env.py"
205
+ ],
206
+ "removed": [],
207
+ "what": "the environment name was changed to a neutral one (ec-swe-hooks2675-v2)"
208
+ },
209
+ "task_id": "hooks",
210
+ "name": "hooks",
211
+ "dataset_instance_id": "alibaba__hooks-ahooks_request_cache_races",
212
+ "repository": "alibaba/hooks",
213
+ "source_folder": "hooks-v4",
214
+ "dockerfile": "Dockerfile.hud",
215
+ "source_image": "ec-swe-hooks:source-v4",
216
+ "package": null,
217
+ "why_no_package": "one criterion is judged by a model"
218
+ },
219
+ {
220
+ "source_edited": {
221
+ "changed": [
222
+ "preflight.sh",
223
+ "tasks.py"
224
+ ],
225
+ "removed": [
226
+ ".hud/config.json",
227
+ "task/grader/maintainer_review.judge.json.as-submitted-2026-09-18",
228
+ "tasks.py.bak-2026-09-20"
229
+ ],
230
+ "what": "comments that recorded internal review history were shortened in two files, and three files the image build does not read were removed; tasks.py is the same program"
231
+ },
232
+ "task_id": "druid",
233
+ "name": "druid",
234
+ "dataset_instance_id": "alibaba__druid-druid_lenient_script",
235
+ "repository": "alibaba/druid",
236
+ "source_folder": "druid-v9",
237
+ "dockerfile": "Dockerfile.hud",
238
+ "source_image": "ec-swe-druid:source-v9",
239
+ "package": null,
240
+ "why_no_package": "one criterion is judged by a model"
241
+ },
242
+ {
243
+ "source_edited": {
244
+ "changed": [
245
+ "env.py",
246
+ "pyproject.toml"
247
+ ],
248
+ "removed": [],
249
+ "what": "the environment name was changed to a neutral one (ec-swe-sickchill-episode-rename-sidecars)"
250
+ },
251
+ "task_id": "sickchill",
252
+ "name": "sickchill",
253
+ "dataset_instance_id": "SickChill__SickChill-sickchill_episode_metadata_files_contract-2e2a49e4",
254
+ "repository": "SickChill/SickChill",
255
+ "source_folder": "sickchill-v7",
256
+ "dockerfile": "Dockerfile.hud",
257
+ "source_image": "ec-swe-sickchill:source-v7",
258
+ "package": null,
259
+ "why_no_package": "its gate runs repository tests that fetch from pypi.org, so it cannot pass offline"
260
+ },
261
+ {
262
+ "task_id": "mikro-orm",
263
+ "name": "mikro-orm",
264
+ "dataset_instance_id": "mikro-orm__mikro-orm-mikro-orm-pessimistic-locking",
265
+ "repository": "mikro-orm/mikro-orm",
266
+ "source_folder": "mikro-orm-v7",
267
+ "dockerfile": "Dockerfile.hud",
268
+ "source_image": "ec-swe-mikro-orm:source-v7",
269
+ "package": null,
270
+ "why_no_package": "its grader starts database servers under their own accounts, which needs root; the packaged verifier runs graders unprivileged"
271
+ },
272
+ {
273
+ "source_edited": {
274
+ "changed": [
275
+ "env.py",
276
+ "pyproject.toml"
277
+ ],
278
+ "removed": [],
279
+ "what": "the environment name was changed to a neutral one (ec-swe-babylonjs-scene-remove-owner-refs)"
280
+ },
281
+ "task_id": "babylonjs",
282
+ "name": "babylonjs",
283
+ "dataset_instance_id": "BabylonJS__Babylon.js-babylonjs_scene_remove_owner_refs_contract-382616f8",
284
+ "repository": "BabylonJS/Babylon.js",
285
+ "source_folder": "babylonjs-v8",
286
+ "dockerfile": "Dockerfile.hud",
287
+ "source_image": "ec-swe-babylonjs:source-v8",
288
+ "package": null,
289
+ "why_no_package": "too heavy for the qualification host: its setup's ownership change of a very large dependency tree exceeded its ten-minute limit twice, and on a third try grading the reference fix had not finished after two hours"
290
+ },
291
+ {
292
+ "task_id": "aioftp",
293
+ "name": "aioftp",
294
+ "dataset_instance_id": "aio-libs__aioftp-aioftp-stream-abort-desynchronization",
295
+ "repository": "aio-libs/aioftp",
296
+ "source_folder": "aioftp-v11",
297
+ "dockerfile": "Dockerfile.hud",
298
+ "source_image": "ec-swe-aioftp:source-v11",
299
+ "package": null,
300
+ "why_no_package": "different task template; not converted yet"
301
+ },
302
+ {
303
+ "task_id": "apscheduler",
304
+ "name": "apscheduler",
305
+ "dataset_instance_id": "agronholm__apscheduler-apscheduler-expired-job-lease",
306
+ "repository": "agronholm/apscheduler",
307
+ "source_folder": "apscheduler-v17",
308
+ "dockerfile": "Dockerfile.hud",
309
+ "source_image": "ec-swe-apscheduler:source-v17",
310
+ "package": null,
311
+ "why_no_package": "different task template; not converted yet"
312
+ }
313
+ ],
314
+ "being_rechecked": [
315
+ {
316
+ "task_id": "badger",
317
+ "name": "badger",
318
+ "dataset_instance_id": "dgraph-io__badger-journal_recovery_after_unclean_stop",
319
+ "repository": "dgraph-io/badger",
320
+ "source_folder": "badger-v2",
321
+ "dockerfile": "Dockerfile.hud",
322
+ "source_edited": {
323
+ "changed": [
324
+ "env.py",
325
+ "pyproject.toml",
326
+ "tasks.py"
327
+ ],
328
+ "removed": [],
329
+ "what": "the environment name was changed to a neutral one (ec-swe-badger-journal)"
330
+ },
331
+ "package": null,
332
+ "why_no_package": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them"
333
+ },
334
+ {
335
+ "task_id": "bazel-remote",
336
+ "name": "bazel-remote",
337
+ "dataset_instance_id": "buchgr__bazel-remote-bazel_remote_disk_eviction_accounting_contract-afe5ea56",
338
+ "repository": "buchgr/bazel-remote",
339
+ "source_folder": "bazel-remote-v2",
340
+ "dockerfile": "Dockerfile.hud",
341
+ "source_edited": {
342
+ "changed": [
343
+ "env.py",
344
+ "pyproject.toml"
345
+ ],
346
+ "removed": [],
347
+ "what": "the environment name was changed to a neutral one (ec-swe-bazel-remote-disk-eviction-accounting)"
348
+ },
349
+ "package": null,
350
+ "why_no_package": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them"
351
+ },
352
+ {
353
+ "task_id": "celery",
354
+ "name": "celery",
355
+ "dataset_instance_id": "celery__celery-celery_retry_expires_countdown_contract",
356
+ "repository": "celery/celery",
357
+ "source_folder": "celery-v12",
358
+ "dockerfile": "Dockerfile.hud",
359
+ "source_edited": {
360
+ "changed": [
361
+ "env.py",
362
+ "pyproject.toml"
363
+ ],
364
+ "removed": [],
365
+ "what": "the environment name was changed to a neutral one (ec-swe-celery-retry-expires-countdown)"
366
+ },
367
+ "package": null,
368
+ "why_no_package": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them"
369
+ },
370
+ {
371
+ "task_id": "geode",
372
+ "name": "geode",
373
+ "dataset_instance_id": "apache__geode-geode_oql_index_null_semantics_contract-1c066303",
374
+ "repository": "apache/geode",
375
+ "source_folder": "geode-v3",
376
+ "dockerfile": "Dockerfile.hud",
377
+ "source_edited": {
378
+ "changed": [
379
+ "env.py",
380
+ "pyproject.toml"
381
+ ],
382
+ "removed": [],
383
+ "what": "the environment name was changed to a neutral one (ec-swe-geode-oql-index-null-semantics)"
384
+ },
385
+ "package": null,
386
+ "why_no_package": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them"
387
+ },
388
+ {
389
+ "task_id": "kratos",
390
+ "name": "kratos",
391
+ "dataset_instance_id": "ory__kratos-kratos_cleanup_stale_flows_courier_contract",
392
+ "repository": "ory/kratos",
393
+ "source_folder": "kratos-v10",
394
+ "dockerfile": "Dockerfile.hud",
395
+ "source_edited": {
396
+ "changed": [
397
+ "env.py",
398
+ "pyproject.toml"
399
+ ],
400
+ "removed": [],
401
+ "what": "the environment name was changed to a neutral one (ec-swe-kratos-cleanup-stale-flows-courier)"
402
+ },
403
+ "package": null,
404
+ "why_no_package": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them"
405
+ },
406
+ {
407
+ "task_id": "microblogpub",
408
+ "name": "microblogpub",
409
+ "dataset_instance_id": "tsileo__microblog.pub-microblogpub_deleted_object_resurrect_lookup_contract-382616f8",
410
+ "repository": "tsileo/microblog.pub",
411
+ "source_folder": "microblogpub-v4",
412
+ "dockerfile": "Dockerfile.hud",
413
+ "source_edited": {
414
+ "changed": [
415
+ "env.py",
416
+ "pyproject.toml"
417
+ ],
418
+ "removed": [],
419
+ "what": "the environment name was changed to a neutral one (ec-swe-microblogpub-deleted-object-resurrect-lookup)"
420
+ },
421
+ "package": null,
422
+ "why_no_package": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them"
423
+ },
424
+ {
425
+ "task_id": "open-xml-sdk",
426
+ "name": "open-xml-sdk",
427
+ "dataset_instance_id": "dotnet__Open-XML-SDK-open_xml_sdk_deletepart_refs_contract-1c066303",
428
+ "repository": "dotnet/Open-XML-SDK",
429
+ "source_folder": "open-xml-sdk-v5",
430
+ "dockerfile": "Dockerfile.hud",
431
+ "source_edited": {
432
+ "changed": [
433
+ "env.py",
434
+ "pyproject.toml"
435
+ ],
436
+ "removed": [],
437
+ "what": "the environment name was changed to a neutral one (ec-swe-open-xml-sdk-deletepart-refs)"
438
+ },
439
+ "package": null,
440
+ "why_no_package": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them"
441
+ },
442
+ {
443
+ "task_id": "openfire",
444
+ "name": "openfire",
445
+ "dataset_instance_id": "igniterealtime__Openfire-openfire_userdeleting_last_owner_contract-0163de9c",
446
+ "repository": "igniterealtime/Openfire",
447
+ "source_folder": "openfire-v9",
448
+ "dockerfile": "Dockerfile.hud",
449
+ "source_edited": {
450
+ "changed": [
451
+ "env.py",
452
+ "pyproject.toml"
453
+ ],
454
+ "removed": [],
455
+ "what": "the environment name was changed to a neutral one (ec-swe-openfire-userdeleting-last-owner)"
456
+ },
457
+ "package": null,
458
+ "why_no_package": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them"
459
+ },
460
+ {
461
+ "task_id": "terser",
462
+ "name": "terser",
463
+ "dataset_instance_id": "terser__terser-retained_top_level_names_keep_their_values",
464
+ "repository": "terser/terser",
465
+ "source_folder": "terser-v3",
466
+ "dockerfile": "Dockerfile.hud",
467
+ "source_edited": {
468
+ "changed": [
469
+ "env.py",
470
+ "tasks.py"
471
+ ],
472
+ "removed": [],
473
+ "what": "the environment name was changed to a neutral one (ec-swe-terser)"
474
+ },
475
+ "package": null,
476
+ "why_no_package": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them"
477
+ },
478
+ {
479
+ "task_id": "umya",
480
+ "name": "umya",
481
+ "dataset_instance_id": "MathNya__umya-spreadsheet-umya_structural_edit_reference_owners_contract",
482
+ "repository": "MathNya/umya-spreadsheet",
483
+ "source_folder": "umya-v4",
484
+ "dockerfile": "Dockerfile.hud",
485
+ "source_edited": {
486
+ "changed": [
487
+ "env.py",
488
+ "pyproject.toml"
489
+ ],
490
+ "removed": [],
491
+ "what": "the environment name was changed to a neutral one (ec-swe-umya-structural-edit-reference-owners)"
492
+ },
493
+ "package": null,
494
+ "why_no_package": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them"
495
+ },
496
+ {
497
+ "task_id": "zettlr",
498
+ "name": "zettlr",
499
+ "dataset_instance_id": "Zettlr__Zettlr-zettlr_clickable_keywords",
500
+ "repository": "Zettlr/Zettlr",
501
+ "source_folder": "zettlr-v32",
502
+ "dockerfile": "Dockerfile.hud",
503
+ "source_edited": {
504
+ "changed": [
505
+ "env.py"
506
+ ],
507
+ "removed": [],
508
+ "what": "the environment name was changed to a neutral one (ec-swe-zettir-v1)"
509
+ },
510
+ "package": null,
511
+ "why_no_package": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them"
512
+ }
513
+ ],
514
+ "not_included": {
515
+ "badger": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them",
516
+ "bazel-remote": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them",
517
+ "celery": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them",
518
+ "geode": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them",
519
+ "kratos": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them",
520
+ "microblogpub": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them",
521
+ "open-xml-sdk": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them",
522
+ "openfire": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them",
523
+ "terser": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them",
524
+ "umya": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them",
525
+ "zettlr": "its build files were given a neutral environment name; the package is being rebuilt and re-checked on them"
526
+ }
527
+ }
harbor/run_checks.py ADDED
@@ -0,0 +1,153 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """Run the scripted checks on these tasks with Harbor's own agents.
2
+
3
+ python run_checks.py --task <task id> --output checks-001
4
+ python run_checks.py --task <task id> --case noop --output smoke-001
5
+ python run_checks.py --output all-checks-001 # every task, every case
6
+
7
+ Needs the `harbor` command (pip install harbor==0.23.0) and Docker, on Linux,
8
+ macOS or WSL, and the task's source image (build_images.py). No model is
9
+ called. Each case is one `harbor run` on a copy of the task:
10
+
11
+ noop Harbor's nop agent changes nothing -> reward 0
12
+ reference Harbor's oracle agent applies the reference fix -> reward 1
13
+ (it first checks, from inside the agent's container, that it is
14
+ an unprivileged user, sees no grading files and gets no traffic out)
15
+ broken the reference fix plus a syntax error -> reward 0, graded
16
+ infra a grader file is removed from the verifier -> no reward at all
17
+ tamper the "agent" keeps writing itself a full score -> reward 0
18
+
19
+ Results go to <output>/summary.json; the script exits 0 only if every case
20
+ gave what is expected. Every run needs a new output directory name.
21
+ """
22
+
23
+ from __future__ import annotations
24
+
25
+ import argparse
26
+ import json
27
+ import re
28
+ import shlex
29
+ import shutil
30
+ import subprocess
31
+ import sys
32
+ import time
33
+ from pathlib import Path
34
+
35
+ CASES = ["noop", "reference", "broken", "infra", "tamper"]
36
+ EXPECTED = {"noop": 0.0, "reference": 1.0, "broken": 0.0, "infra": None, "tamper": 0.0}
37
+ PROBE = r"""/opt/task-tools/python -c 'import os,socket; from pathlib import Path
38
+ assert os.getuid()==1000, "the agent is not uid 1000"
39
+ private=("/hud", "/app/tasks.py", "/tests", "/var/run/docker.sock")
40
+ assert not any(Path(p).exists() for p in private), "a private path is visible"
41
+ data=b""
42
+ try:
43
+ s=socket.create_connection(("1.1.1.1",443),timeout=4); s.settimeout(4)
44
+ s.sendall(b"GET / HTTP/1.0\r\n\r\n"); data=s.recv(16)
45
+ except OSError:
46
+ pass
47
+ assert not data, "the network is reachable"
48
+ print("agent isolation probe passed")'
49
+ """
50
+ PLANT = """#!/bin/bash
51
+ mkdir -p /logs/verifier 2>/dev/null
52
+ ( while true; do
53
+ echo 1 > /logs/verifier/reward.txt 2>/dev/null
54
+ echo '{"reward": 1}' > /logs/verifier/reward.json 2>/dev/null
55
+ sleep 0.2
56
+ done ) > /dev/null 2>&1 &
57
+ sleep 2
58
+ exit 0
59
+ """
60
+ SOURCE_SUFFIXES = (".py", ".go", ".java", ".rs", ".cs", ".ts", ".tsx", ".js", ".mjs", ".cjs")
61
+ TEST_PATH = re.compile(
62
+ r"/(tests?|__tests__|specs?|testing)/"
63
+ r"|/test[^/]*$|[._-](test|spec)\.[a-z]+$|_test\.go$|Tests?\.(java|cs)$|/[^/]*tests?\.py$",
64
+ re.IGNORECASE,
65
+ )
66
+
67
+
68
+ def variant_for(case: str, package: Path, scratch: Path) -> tuple[Path, str]:
69
+ """Copy the task and change what this case submits; return the copy and the agent."""
70
+ variant = scratch / case / package.name
71
+ shutil.copytree(package, variant)
72
+ solve = variant / "solution/solve.sh"
73
+ if case == "noop":
74
+ return variant, "nop"
75
+ if case == "reference":
76
+ marker = "cd /workspace/repo\n"
77
+ text = solve.read_text()
78
+ solve.write_text(text.replace(marker, marker + PROBE, 1), newline="\n")
79
+ elif case == "broken":
80
+ patch = (variant / "solution/reference.patch").read_text()
81
+ paths = re.findall(r"^\+\+\+ b/(\S+)", patch, flags=re.MULTILINE)
82
+ target = next(p for p in paths if p.endswith(SOURCE_SUFFIXES) and not TEST_PATH.search(f"/{p}"))
83
+ with solve.open("a", newline="\n") as handle:
84
+ handle.write(f"printf '\\nBROKEN SYNTAX !\\n' >> {shlex.quote(target)}\n")
85
+ elif case == "infra":
86
+ config = json.loads((variant / "tests/config.json").read_text())
87
+ pinned = sorted(f for f in config["verifier_files"] if f.startswith("/hud/grader/"))
88
+ script = variant / "tests/test.sh"
89
+ lines = script.read_text().splitlines()
90
+ lines.insert(len(lines) - 1, f"rm {shlex.quote(pinned[0])}")
91
+ script.write_text("\n".join(lines) + "\n", newline="\n")
92
+ elif case == "tamper":
93
+ solve.write_text(PLANT, newline="\n")
94
+ return variant, "oracle"
95
+
96
+
97
+ def main() -> None:
98
+ parser = argparse.ArgumentParser(description=__doc__, formatter_class=argparse.RawDescriptionHelpFormatter)
99
+ parser.add_argument("--output", required=True)
100
+ parser.add_argument("--task", action="append", default=[])
101
+ parser.add_argument("--case", action="append", choices=CASES)
102
+ args = parser.parse_args()
103
+ root = Path(__file__).resolve().parent
104
+ if shutil.which("harbor") is None:
105
+ raise SystemExit("The harbor command is not on PATH: pip install harbor==0.23.0")
106
+ output = root / args.output
107
+ if Path(args.output).name != args.output:
108
+ raise SystemExit("--output must be a new directory name within the bundle")
109
+ output.mkdir(exist_ok=False)
110
+ known = json.loads((root / "tasks/manifest.json").read_text())["tasks"]
111
+ unknown = [name for name in args.task if name not in known]
112
+ if unknown:
113
+ raise SystemExit("Unknown task: " + ", ".join(unknown))
114
+ summary = []
115
+ for task in args.task or known:
116
+ for case in args.case or CASES:
117
+ variant, agent = variant_for(case, root / "tasks" / task, output / "variants" / task)
118
+ job = f"{task[:40]}-{case}"
119
+ started = time.time()
120
+ log = output / f"{job}.log"
121
+ with log.open("wb") as handle:
122
+ subprocess.run(
123
+ ["harbor", "run", "-p", str(variant), "-a", agent, "--jobs-dir", str(output / "jobs"),
124
+ "--job-name", job, "-n", "1"],
125
+ stdout=handle, stderr=subprocess.STDOUT,
126
+ )
127
+ results = sorted((output / "jobs" / job).glob("*/result.json"))
128
+ reward, error, probe = None, "Harbor wrote no trial result", None
129
+ if results:
130
+ data = json.loads(results[0].read_text())
131
+ failure = data.get("exception_info")
132
+ error = f"{failure.get('exception_type')}: {failure.get('exception_message')}"[:300] if failure else None
133
+ if failure is None:
134
+ reward = ((data.get("verifier_result") or {}).get("rewards") or {}).get("reward")
135
+ agent_dir = results[0].parent / "agent"
136
+ said = "".join(f.read_text(errors="replace") for f in agent_dir.rglob("*") if f.is_file()) if agent_dir.is_dir() else ""
137
+ probe = "agent isolation probe passed" in said
138
+ ok = reward == EXPECTED[case] and (error is None) == (case != "infra")
139
+ if case == "reference":
140
+ ok = ok and bool(probe)
141
+ row = {"task": task, "case": case, "reward": reward, "expected": EXPECTED[case], "ok": ok,
142
+ "error": error, "seconds": round(time.time() - started)}
143
+ if case == "reference":
144
+ row["agent_isolated"] = probe
145
+ summary.append(row)
146
+ (output / "summary.json").write_text(json.dumps(summary, indent=2) + "\n")
147
+ print(json.dumps(row), flush=True)
148
+ shutil.rmtree(output / "variants", ignore_errors=True)
149
+ sys.exit(0 if summary and all(row["ok"] for row in summary) else 1)
150
+
151
+
152
+ if __name__ == "__main__":
153
+ main()
harbor/sources/aioftp-v11/.dockerignore ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .venv/
2
+ __pycache__
3
+ *.pyc
4
+ .pytest_cache/
5
+ .ruff_cache/
6
+ .hud/
7
+ .git/
8
+ .github/
9
+ tests/
10
+ !grading/baseline/tests/
11
+ !grading/baseline/tests/**
12
+ grading/adversarial/
13
+ artifact-manifest.json
14
+ scaffold-manifest.json
harbor/sources/aioftp-v11/.gitignore ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
 
1
+ .venv/
2
+ __pycache__/
3
+ *.pyc
4
+ .pytest_cache/
5
+ .ruff_cache/
6
+ .hud/
7
+ dist/
8
+ build/
9
+ *.egg-info/
harbor/sources/aioftp-v11/Dockerfile.hud ADDED
@@ -0,0 +1,126 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # syntax=docker/dockerfile:1
2
+ # Stage `runtime-contract` is the credential-free, source-free runtime the graders, the
3
+ # repository-native commands, and the agent prompt's tools run on. `validate-helper.py
4
+ # runtime-preflight` builds only this target (no BuildKit secret) and probes every declared
5
+ # executable and service here; the final `runtime` stage derives from it unchanged, so what the
6
+ # probe proves is what the served image carries. Keep credentials and the private clone out of it.
7
+ FROM ubuntu:24.04@sha256:224a1869083a311ef3f13648a154ba79832fbef6364d31493642ca03082da254 AS runtime-contract
8
+
9
+ # Resolve uv once by immutable OCI digest. Independent local and HUD builds therefore copy the
10
+ # same binary instead of asking PyPI for whatever version happens to be current.
11
+ COPY --from=ghcr.io/astral-sh/uv:0.12.3@sha256:2d890623d310b57771ce840f0da5eed5fc6d657da05ffaa45d82797b53fa3abc /uv /uvx /bin/
12
+
13
+ # Every apt package resolves against one dated Ubuntu snapshot. The image has no CA bundle yet,
14
+ # so the first index fetch skips TLS peer checks only to install ca-certificates; apt still
15
+ # verifies every index against the archive's signing keys, and every later fetch uses TLS.
16
+ RUN echo 'APT::Snapshot "20260915T000000Z";' > /etc/apt/apt.conf.d/50snapshot \
17
+ && apt-get -o Acquire::https::Verify-Peer=false update -y \
18
+ && apt-get -o Acquire::https::Verify-Peer=false install -y --no-install-recommends ca-certificates \
19
+ && apt-get update -y \
20
+ && apt-get install -y --no-install-recommends \
21
+ bash \
22
+ build-essential \
23
+ curl \
24
+ git \
25
+ gnupg \
26
+ libpq5 \
27
+ openssl \
28
+ python-is-python3 \
29
+ python3 \
30
+ python3-dev \
31
+ python3-pip \
32
+ python3-venv \
33
+ python3-wheel \
34
+ rsync \
35
+ util-linux \
36
+ sqlite3 \
37
+ vim \
38
+ wget \
39
+ && rm -rf /var/lib/apt/lists/* \
40
+ && update-ca-certificates
41
+
42
+ # Repository runtime: CPython 3.11.15 (uv-managed, hash-verified download) with the repository's
43
+ # `dev` extra from a fully hashed lock. The editable path and the dist-info record stand in for
44
+ # `pip install -e .[dev]` of the workspace cloned below, so `pytest` from the repository root, the
45
+ # native test command, and the hidden probes all import `aioftp` from the tree being worked on.
46
+ # `aioftp_ipv6_loopback` is a pytest11 plugin that skips only the suite's `::1` nodes, and only
47
+ # where IPv6 loopback cannot be bound (HUD's sandbox has none); with `::1` available it is inert.
48
+ # `pytest-timeout` fails one hung test after PYTEST_TIMEOUT seconds with its traceback (default
49
+ # `signal` method; the rest of the run continues) instead of the whole shell call expiring with no
50
+ # output. Only the agent shell inherits the variable: the grader runs pytest with a clean
51
+ # environment and the pristine settings, where the plugin has no timeout and is inert.
52
+ ENV UV_PYTHON_INSTALL_DIR=/opt/uv-python \
53
+ PYTEST_TIMEOUT=30
54
+ COPY ./runtime/aioftp-dev-requirements.txt /opt/aioftp-runtime/requirements.txt
55
+ COPY ./runtime/aioftp_ipv6_loopback.py /opt/aioftp-runtime/aioftp_ipv6_loopback.py
56
+ RUN uv python install --no-bin 3.11.15 \
57
+ && uv venv --python 3.11.15 /opt/aioftp-venv \
58
+ && uv pip install --python /opt/aioftp-venv/bin/python --no-cache --require-hashes --no-deps -r /opt/aioftp-runtime/requirements.txt \
59
+ && site="$(/opt/aioftp-venv/bin/python -c 'import sysconfig; print(sysconfig.get_paths()["purelib"])')" \
60
+ && mkdir -p "$site/aioftp-0.28.3.dist-info" \
61
+ && printf 'Metadata-Version: 2.1\nName: aioftp\nVersion: 0.28.3\n' > "$site/aioftp-0.28.3.dist-info/METADATA" \
62
+ && printf 'uv\n' > "$site/aioftp-0.28.3.dist-info/INSTALLER" \
63
+ && : > "$site/aioftp-0.28.3.dist-info/RECORD" \
64
+ && echo /home/ubuntu/aioftp/src > "$site/__editable__.aioftp-0.28.3.pth" \
65
+ && cp /opt/aioftp-runtime/aioftp_ipv6_loopback.py "$site/aioftp_ipv6_loopback.py" \
66
+ && mkdir -p "$site/aioftp_ipv6_loopback-1.0.dist-info" \
67
+ && printf 'Metadata-Version: 2.1\nName: aioftp-ipv6-loopback\nVersion: 1.0\n' > "$site/aioftp_ipv6_loopback-1.0.dist-info/METADATA" \
68
+ && printf '[pytest11]\naioftp_ipv6_loopback = aioftp_ipv6_loopback\n' > "$site/aioftp_ipv6_loopback-1.0.dist-info/entry_points.txt" \
69
+ && : > "$site/aioftp_ipv6_loopback-1.0.dist-info/RECORD" \
70
+ && chmod -R a+rX /opt/uv-python /opt/aioftp-venv /opt/aioftp-runtime
71
+
72
+ # Grader and HUD server virtualenv, from the package lock (Python 3.12 from the snapshot).
73
+ COPY ./pyproject.toml ./uv.lock /hud/
74
+ WORKDIR /hud
75
+ ENV RUST_LOG=warn \
76
+ PYTHONPATH=/hud/.venv/lib/python3.12/site-packages:/hud \
77
+ PATH=/hud/.venv/bin:/opt/aioftp-venv/bin:$PATH \
78
+ AIOFTP_REPO_PYTHON=/opt/aioftp-venv/bin/python
79
+ RUN uv venv --python /usr/bin/python3 /hud/.venv \
80
+ && uv sync --frozen --no-install-project --no-cache --python /hud/.venv/bin/python
81
+
82
+ FROM runtime-contract AS setup
83
+
84
+ ARG REPO_URL="https://github.com/aio-libs/aioftp"
85
+ ARG BASE_COMMIT="4c18bdec8eb8f2e12a226fc513d07b92b5014167"
86
+ ARG FOLDER_NAME="aioftp"
87
+
88
+ ENV FOLDER_NAME=${FOLDER_NAME} \
89
+ REPO_URL=${REPO_URL} \
90
+ BASE_COMMIT=${BASE_COMMIT} \
91
+ HOME=/home/ubuntu \
92
+ PROJECT_DIR=/home/ubuntu/${FOLDER_NAME} \
93
+ PATCHES_DIR=/hud/patches
94
+
95
+ # The base repository is public (the upstream itself, or the published base), so the pinned
96
+ # commit is fetched by SHA with no credential and no other ref: the image never holds a branch
97
+ # that could reach the gold, and no BuildKit secret is mounted anywhere in this Dockerfile.
98
+ USER ubuntu
99
+ RUN git init -q /home/ubuntu/${FOLDER_NAME} && \
100
+ cd /home/ubuntu/${FOLDER_NAME} && \
101
+ git fetch -q --depth 1 --no-tags ${REPO_URL} ${BASE_COMMIT} && \
102
+ git checkout -q --detach ${BASE_COMMIT} && \
103
+ rm -f .git/FETCH_HEAD
104
+
105
+ USER root
106
+ RUN chown -R ubuntu:ubuntu /home/ubuntu/${FOLDER_NAME} \
107
+ && mkdir -p /hud/patches \
108
+ && chown -R root:root /home/ubuntu/${FOLDER_NAME}/.git \
109
+ && chmod -R 700 /home/ubuntu/${FOLDER_NAME}/.git
110
+
111
+ FROM setup AS runtime
112
+
113
+ USER root
114
+ WORKDIR /hud
115
+ COPY ./env.py /hud/env.py
116
+ COPY ./grading /hud/grading
117
+ COPY ./tasks.py /hud/tasks.py
118
+ COPY ./task /hud/task
119
+ COPY ./gold.diff /hud/gold.diff
120
+ RUN chmod -R 700 /hud \
121
+ && chown -R root:root /hud
122
+ RUN chmod 700 /root
123
+
124
+ ENV PROBLEM_ID=""
125
+ EXPOSE 8765
126
+ CMD ["hud", "serve", "env:env", "--host", "0.0.0.0", "--port", "8765"]
harbor/sources/aioftp-v11/env.py ADDED
@@ -0,0 +1,700 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """Coding environment (HUD v6) for aioftp_stream_abort_desynchronization.
2
+
3
+ The environment publishes one ssh capability (a UID-walled Workspace); the agent's
4
+ harness brings its own bash/file tools. A task is a @env.template async
5
+ generator: yield a prompt, then yield a reward.
6
+
7
+ Grading entry point contract: this module must never import the grader chain
8
+ (``grading.*``) at module import time. The chain is resolved lazily inside
9
+ ``run_grading`` so that a missing or corrupted grader module degrades to a
10
+ fail-closed JSON result instead of aborting the import and emitting no output
11
+ at all. Prompt 05 populates the grader behind ``GRADER_ENTRY_POINT``; it must
12
+ not add a module-level ``grading`` import here.
13
+ """
14
+
15
+ import asyncio
16
+ import base64
17
+ import datetime
18
+ import gzip
19
+ import hashlib
20
+ import importlib
21
+ import inspect
22
+ import json
23
+ import logging
24
+ import os
25
+ import shutil
26
+ import stat
27
+ import subprocess
28
+ import sys
29
+ import tempfile
30
+ import time
31
+ import traceback
32
+ from pathlib import Path
33
+
34
+ from hud.environment import Environment, Workspace
35
+ from hud.graders import EvaluationResult
36
+
37
+ logger = logging.getLogger(__name__)
38
+
39
+ TASK_ID = "aioftp_stream_abort_desynchronization"
40
+ TASK_SLUG = "aioftp-stream-abort-desynchronization"
41
+ HUD_ENV_NAME = "aioftp-stream-abort-desynchronization"
42
+ FOLDER_NAME = os.environ.get("FOLDER_NAME", "aioftp")
43
+ REPO_URL = os.environ.get("REPO_URL", "https://github.com/aio-libs/aioftp")
44
+ BASE_COMMIT_SHA = "4c18bdec8eb8f2e12a226fc513d07b92b5014167"
45
+ BASE_TREE_SHA = "cb1a5e0d57a012eea1e9bddbb9e1946d167c2f50"
46
+
47
+ _explicit_dir = os.environ.get("PROJECT_DIR")
48
+ if _explicit_dir:
49
+ PROJECT_DIR = _explicit_dir
50
+ PATCHES_DIR = os.environ.get("PATCHES_DIR", "/hud/patches")
51
+ _LOCAL_SUBSTRATE = False
52
+ else:
53
+ _LOCAL_ROOT = Path(tempfile.gettempdir()) / f"hud-{FOLDER_NAME}"
54
+ PROJECT_DIR = str(_LOCAL_ROOT / f"{FOLDER_NAME}-{os.getpid()}")
55
+ PATCHES_DIR = str(_LOCAL_ROOT / f"patches-{os.getpid()}")
56
+ _LOCAL_SUBSTRATE = True
57
+
58
+ env = Environment(name="aioftp-stream-abort-desynchronization")
59
+
60
+
61
+ class UidWallWorkspace(Workspace):
62
+ """Workspace that drops the agent shell to UID 1000 (ubuntu) when running as root.
63
+
64
+ Maintains full signature compatibility with Workspace.shell_argv.
65
+ """
66
+
67
+ def shell_argv(self, command=None, *, cwd=None, env=None, tty: bool = False, **kwargs):
68
+ super_kwargs = {"cwd": cwd, "env": env, "tty": tty}
69
+ sig = inspect.signature(super().shell_argv)
70
+ if "kwargs" in sig.parameters:
71
+ super_kwargs.update(kwargs)
72
+ else:
73
+ for k, v in kwargs.items():
74
+ if k in sig.parameters:
75
+ super_kwargs[k] = v
76
+ argv = super().shell_argv(command, **super_kwargs)
77
+ if sys.platform != "win32" and hasattr(os, "geteuid") and os.geteuid() == 0:
78
+ argv = ["setpriv", "--reuid", "1000", "--regid", "1000", "--clear-groups", "--", *argv]
79
+ return argv
80
+
81
+
82
+ _ws = UidWallWorkspace(
83
+ PROJECT_DIR,
84
+ guest_path=PROJECT_DIR,
85
+ network=True,
86
+ env={"HOME": "/home/ubuntu"},
87
+ )
88
+
89
+
90
+ async def _git_step(args: list[str], cwd: str | None, label: str) -> None:
91
+ proc = await asyncio.create_subprocess_exec(
92
+ "git", *args,
93
+ cwd=cwd,
94
+ stdout=asyncio.subprocess.PIPE,
95
+ stderr=asyncio.subprocess.PIPE,
96
+ )
97
+ _, stderr = await proc.communicate()
98
+ if proc.returncode != 0:
99
+ raise RuntimeError(f"{label} failed: {stderr.decode(errors='replace')}")
100
+
101
+
102
+ async def _ensure_repo() -> None:
103
+ """Local-substrate fallback: the same single-commit, credential-free fetch the image performs."""
104
+ if (Path(PROJECT_DIR) / ".git").exists():
105
+ return
106
+ Path(PROJECT_DIR).parent.mkdir(parents=True, exist_ok=True)
107
+ logger.info("Fetching %s@%s into %s", REPO_URL, BASE_COMMIT_SHA, PROJECT_DIR)
108
+ await _git_step(["init", "-q", PROJECT_DIR], None, "git init")
109
+ await _git_step(
110
+ ["-c", f"safe.directory={PROJECT_DIR}", "fetch", "-q", "--depth", "1", "--no-tags", REPO_URL, BASE_COMMIT_SHA],
111
+ PROJECT_DIR, f"git fetch {REPO_URL} {BASE_COMMIT_SHA}",
112
+ )
113
+ await _git_step(
114
+ ["-c", f"safe.directory={PROJECT_DIR}", "checkout", "-q", "--detach", BASE_COMMIT_SHA],
115
+ PROJECT_DIR, f"git checkout {BASE_COMMIT_SHA}",
116
+ )
117
+ (Path(PROJECT_DIR) / ".git" / "FETCH_HEAD").unlink(missing_ok=True)
118
+
119
+
120
+ @env.initialize
121
+ async def _up() -> None:
122
+ await _ensure_repo()
123
+ await _ws.start()
124
+ env.add_capability(_ws.capability("shell"))
125
+
126
+
127
+ @env.shutdown
128
+ async def _down() -> None:
129
+ await _ws.stop()
130
+ if _LOCAL_SUBSTRATE:
131
+ shutil.rmtree(PROJECT_DIR, ignore_errors=True)
132
+ shutil.rmtree(PATCHES_DIR, ignore_errors=True)
133
+
134
+
135
+ def make_prompt(description: str) -> str:
136
+ return f"""You are working in a coding repository located at {PROJECT_DIR}.
137
+
138
+ Use the tools provided to complete the following task:
139
+
140
+ {description}
141
+ """
142
+
143
+
144
+ # Grading entry point. Resolved lazily by ``run_grading``; never imported at module
145
+ # import time. Prompt 05 implements ``grade_repository`` in ``grading/runner.py``.
146
+ GRADER_ENTRY_POINT = ("grading.runner", "grade_repository")
147
+
148
+ FAIL_CLOSED_LIST_KEYS = ("caps", "families", "subscores", "checks", "blockers")
149
+
150
+
151
+
152
+ # --- Workspace snapshot ---------------------------------------------------------------------
153
+ # Captured around the grader, never inside ``grading/**`` (so the grader scale id is untouched):
154
+ # the agent's final workspace as a binary-safe git patch against the pinned base commit, attached
155
+ # to the grade envelope's ``info["workspace_snapshot"]``. Prompt 08 decodes it beside the trace
156
+ # export and Prompt 11 reconstructs the candidate from it instead of replaying the trajectory.
157
+ #
158
+ # Isolation: the env process runs as root against the root-owned ``.git`` through a scratch index
159
+ # and a scratch object directory (the real object store is read-only through alternates), so the
160
+ # agent's tree, the real index and the real objects are never written. Completeness: when the
161
+ # agent edited an ignore file the capture re-adds with ``--force`` (complete beats compact), and
162
+ # configured content filters are reported so diagnosis never trusts transformed bytes. Safety:
163
+ # the capture runs after the grader, under one deadline, streams the diff to disk and reads it
164
+ # only under the size cap; a capture failure degrades to ``unavailable`` and never touches the grade.
165
+
166
+ WORKSPACE_SNAPSHOT_SCHEMA_VERSION = 2
167
+ WORKSPACE_SNAPSHOT_MAX_BYTES_ENV = "HUD_WORKSPACE_SNAPSHOT_MAX_BYTES" # raw patch bytes; 0 disables
168
+ WORKSPACE_SNAPSHOT_DEADLINE_ENV = "HUD_WORKSPACE_SNAPSHOT_DEADLINE_SECONDS" # whole capture
169
+ WORKSPACE_SNAPSHOT_DEFAULT_MAX_BYTES = 4 * 1024 * 1024
170
+ WORKSPACE_SNAPSHOT_DEFAULT_DEADLINE = 120.0
171
+ WORKSPACE_SNAPSHOT_EXCLUDED_DIRS = ("node_modules", ".venv", ".hud", ".tmp", ".cache", "dist", "build", "cdk.out")
172
+ # Prompt 11's forbidden path parts, refused here too so they never enter the grade event.
173
+ WORKSPACE_SNAPSHOT_PROTECTED_NAMES = (".env", ".hud", "gold.diff", "grading", "mcp_server")
174
+ WORKSPACE_SNAPSHOT_IGNORE_FILES = (".gitignore", ".gitattributes")
175
+ WORKSPACE_SNAPSHOT_MAX_LISTED_FILES = 2000
176
+ WORKSPACE_SNAPSHOT_GIT_TIMEOUT = 60
177
+ WORKSPACE_SNAPSHOT_ENCODING = "gzip+base64"
178
+
179
+
180
+ def _snapshot_limit(name: str, default, cast):
181
+ try:
182
+ return cast(os.environ.get(name, default))
183
+ except (TypeError, ValueError):
184
+ return cast(default)
185
+
186
+
187
+ def _snapshot_payload(base_commit_sha: str, max_bytes: int | None, **fields) -> dict:
188
+ payload = {
189
+ "schema_version": WORKSPACE_SNAPSHOT_SCHEMA_VERSION,
190
+ "status": "unavailable",
191
+ "reason": None,
192
+ "base_commit_sha": base_commit_sha,
193
+ "head_commit_sha": None,
194
+ "patch_sha256": None,
195
+ "patch_size": None,
196
+ "changed_files": [],
197
+ "changed_file_count": None,
198
+ "changed_files_truncated": False,
199
+ "ignore_rules_modified": None,
200
+ "ignored_entry_count": None,
201
+ "capture_mode": None,
202
+ "filtered": None,
203
+ "content_filters": {"configured": [], "attributes_declared": False},
204
+ "captured_after_grading": True,
205
+ "excluded_dirs": list(WORKSPACE_SNAPSHOT_EXCLUDED_DIRS),
206
+ "protected_names": list(WORKSPACE_SNAPSHOT_PROTECTED_NAMES),
207
+ "encoding": WORKSPACE_SNAPSHOT_ENCODING,
208
+ "max_bytes": max_bytes,
209
+ "deadline_seconds": None,
210
+ "elapsed_seconds": None,
211
+ "captured_at_utc": datetime.datetime.now(datetime.UTC).strftime("%Y-%m-%dT%H:%M:%SZ"),
212
+ }
213
+ payload.update(fields)
214
+ return payload
215
+
216
+
217
+ def _snapshot_pathspec_excludes() -> list[str]:
218
+ names = (*WORKSPACE_SNAPSHOT_EXCLUDED_DIRS, *WORKSPACE_SNAPSHOT_PROTECTED_NAMES)
219
+ specs: list[str] = []
220
+ for name in names:
221
+ specs.extend((f":(exclude){name}", f":(exclude,glob)**/{name}", f":(exclude,glob)**/{name}/**"))
222
+ return specs
223
+
224
+
225
+ def capture_workspace_snapshot(
226
+ project_dir: str, base_commit_sha: str, max_bytes: int | None = None, deadline_seconds: float | None = None,
227
+ ) -> dict:
228
+ """The agent's final workspace as a ``git diff --binary`` against ``base_commit_sha``.
229
+
230
+ Status is ``captured`` (body in ``patch_b64``), ``empty`` (no change), ``too_large`` (hash and
231
+ listing only) or ``unavailable`` (reason only). Never raises.
232
+ """
233
+ if max_bytes is None:
234
+ max_bytes = _snapshot_limit(WORKSPACE_SNAPSHOT_MAX_BYTES_ENV, WORKSPACE_SNAPSHOT_DEFAULT_MAX_BYTES, int)
235
+ if deadline_seconds is None:
236
+ deadline_seconds = _snapshot_limit(WORKSPACE_SNAPSHOT_DEADLINE_ENV, WORKSPACE_SNAPSHOT_DEFAULT_DEADLINE, float)
237
+ started = time.monotonic()
238
+
239
+ def finish(payload: dict) -> dict:
240
+ payload["deadline_seconds"] = deadline_seconds
241
+ payload["elapsed_seconds"] = round(time.monotonic() - started, 3)
242
+ return payload
243
+
244
+ try:
245
+ project = Path(project_dir)
246
+ git_dir = project / ".git"
247
+ if not git_dir.exists():
248
+ return finish(_snapshot_payload(base_commit_sha, max_bytes, reason="not_a_git_repository"))
249
+ if max_bytes <= 0:
250
+ return finish(_snapshot_payload(base_commit_sha, max_bytes, reason="disabled"))
251
+ with tempfile.TemporaryDirectory(prefix="hud-workspace-snapshot-") as scratch_name:
252
+ scratch = Path(scratch_name)
253
+ objects = scratch / "objects"
254
+ objects.mkdir()
255
+ # Heavy runtime trees and protected names are excluded through a scratch excludes
256
+ # file, which layers under the repository's own ignore rules.
257
+ excludes_file = scratch / "excludes"
258
+ excludes_file.write_text(
259
+ "".join(f"{name}/\n" for name in WORKSPACE_SNAPSHOT_EXCLUDED_DIRS)
260
+ + "".join(f"{name}\n" for name in WORKSPACE_SNAPSHOT_PROTECTED_NAMES),
261
+ encoding="utf-8",
262
+ )
263
+ env = {
264
+ **os.environ,
265
+ "GIT_INDEX_FILE": str(scratch / "index"),
266
+ "GIT_DIR": str(git_dir),
267
+ "GIT_WORK_TREE": str(project),
268
+ "GIT_OBJECT_DIRECTORY": str(objects),
269
+ "GIT_ALTERNATE_OBJECT_DIRECTORIES": str(git_dir / "objects"),
270
+ "HOME": scratch_name,
271
+ "GIT_CONFIG_NOSYSTEM": "1",
272
+ "GIT_TERMINAL_PROMPT": "0",
273
+ }
274
+ base_argv = [
275
+ "git", "-c", f"safe.directory={project}", "-c", "core.quotePath=false",
276
+ "-c", f"core.excludesFile={excludes_file}",
277
+ ]
278
+
279
+ def git(*args: str, ok_codes: tuple = (0,), stdout=subprocess.PIPE) -> bytes:
280
+ remaining = deadline_seconds - (time.monotonic() - started)
281
+ if remaining <= 0:
282
+ raise TimeoutError(f"snapshot deadline of {deadline_seconds:g}s exhausted before git {args[0]}")
283
+ completed = subprocess.run(
284
+ [*base_argv, *args], cwd=str(project), env=env, stdout=stdout, stderr=subprocess.PIPE,
285
+ check=False, timeout=min(WORKSPACE_SNAPSHOT_GIT_TIMEOUT, remaining),
286
+ )
287
+ if completed.returncode not in ok_codes:
288
+ detail = completed.stderr.decode("utf-8", errors="replace").strip()[-200:]
289
+ raise RuntimeError(f"git {args[0]} exited {completed.returncode}: {detail}")
290
+ return completed.stdout or b""
291
+
292
+ def name_status() -> list[dict]:
293
+ listing = git("diff", "--cached", "--name-status", "-z", "--no-renames", base_commit_sha, "--")
294
+ fields = [entry.decode("utf-8", errors="replace") for entry in listing.split(b"\0") if entry]
295
+ rows = [{"path": fields[i + 1], "status": fields[i][:1]} for i in range(0, len(fields) - 1, 2)]
296
+ rows.sort(key=lambda item: item["path"])
297
+ return rows
298
+
299
+ head = git("rev-parse", "HEAD").decode("utf-8", errors="replace").strip()
300
+ git("read-tree", base_commit_sha)
301
+ git("add", "-A", "--ignore-errors", "--", ".")
302
+ changed = name_status()
303
+ ignore_rules_modified = any(item["path"].rsplit("/", 1)[-1] in WORKSPACE_SNAPSHOT_IGNORE_FILES for item in changed)
304
+ capture_mode = "standard"
305
+ if ignore_rules_modified:
306
+ # Agent-edited ignore rules can hide files the grader saw: re-add everything the
307
+ # pathspec excludes do not name, ignore rules notwithstanding.
308
+ git("add", "-A", "--force", "--ignore-errors", "--", ".", *_snapshot_pathspec_excludes())
309
+ changed = name_status()
310
+ capture_mode = "forced"
311
+
312
+ config_out = git("config", "--get-regexp", r"^filter\..*\.(clean|smudge|process)$", ok_codes=(0, 1))
313
+ configured = sorted({line.split()[0] for line in config_out.decode("utf-8", errors="replace").splitlines() if line.strip()})
314
+ attribute_paths = [
315
+ entry.decode("utf-8", errors="replace")
316
+ for entry in git("ls-files", "-z", "--cached", "--", ".gitattributes", "*/.gitattributes").split(b"\0") if entry
317
+ ]
318
+ attributes_declared = False
319
+ for rel in [*attribute_paths, ".git/info/attributes"]:
320
+ candidate = project / rel
321
+ if candidate.is_file() and "filter=" in candidate.read_text(encoding="utf-8", errors="replace"):
322
+ attributes_declared = True
323
+ break
324
+ filtered = bool(configured) and attributes_declared
325
+
326
+ diff_path = scratch / "snapshot.diff"
327
+ with diff_path.open("wb") as handle:
328
+ git("diff", "--cached", "--binary", "--full-index", "--no-ext-diff", "--no-renames", base_commit_sha, "--", stdout=handle)
329
+ size = diff_path.stat().st_size
330
+ digest = hashlib.sha256()
331
+ with diff_path.open("rb") as handle:
332
+ while chunk := handle.read(1 << 20):
333
+ digest.update(chunk)
334
+ ignored = git("ls-files", "-z", "--others", "--ignored", "--exclude-standard", "--directory")
335
+ patch = diff_path.read_bytes() if 0 < size <= max_bytes else b""
336
+
337
+ payload = _snapshot_payload(
338
+ base_commit_sha, max_bytes,
339
+ head_commit_sha=head,
340
+ patch_sha256=digest.hexdigest(),
341
+ patch_size=size,
342
+ changed_files=changed[:WORKSPACE_SNAPSHOT_MAX_LISTED_FILES],
343
+ changed_file_count=len(changed),
344
+ changed_files_truncated=len(changed) > WORKSPACE_SNAPSHOT_MAX_LISTED_FILES,
345
+ ignore_rules_modified=ignore_rules_modified,
346
+ ignored_entry_count=sum(1 for entry in ignored.split(b"\0") if entry),
347
+ capture_mode=capture_mode,
348
+ filtered=filtered,
349
+ content_filters={"configured": configured, "attributes_declared": attributes_declared},
350
+ )
351
+ if size == 0:
352
+ payload["status"] = "empty"
353
+ elif size > max_bytes:
354
+ payload.update(status="too_large", reason=f"patch of {size} bytes exceeds max_bytes {max_bytes}")
355
+ else:
356
+ payload.update(status="captured", patch_b64=base64.b64encode(gzip.compress(patch, 6)).decode("ascii"))
357
+ return finish(payload)
358
+ except Exception as exc: # noqa: BLE001 - a snapshot failure must never change the grade
359
+ logger.warning("workspace snapshot unavailable: %s: %s", type(exc).__name__, exc)
360
+ return finish(_snapshot_payload(base_commit_sha, max_bytes, reason=f"{type(exc).__name__}: {str(exc)[:200]}"))
361
+
362
+
363
+ def _attach_workspace_snapshot(result: EvaluationResult, snapshot: dict) -> EvaluationResult:
364
+ """Return ``result`` with ``info["workspace_snapshot"]`` set; the grader's own info is kept.
365
+
366
+ Runs outside the fail-closed grading guards, so it must never raise: on any failure the
367
+ grader's result is returned exactly as it was.
368
+ """
369
+ try:
370
+ existing = getattr(result, "info", None)
371
+ info = dict(existing) if isinstance(existing, dict) else {}
372
+ info["workspace_snapshot"] = snapshot
373
+ try:
374
+ return result.model_copy(update={"info": info})
375
+ except Exception: # noqa: BLE001 - fall back to assignment on a non-pydantic result
376
+ result.info = info
377
+ return result
378
+ except Exception: # noqa: BLE001 - the snapshot is diagnostic, never grade-bearing
379
+ logger.exception("could not attach the workspace snapshot to the grade result")
380
+ return result
381
+
382
+
383
+ def fail_closed_payload(reason: str, detail: str = "", health: str = "fault:entry_point") -> dict:
384
+ """Structured, fail-closed grading result.
385
+
386
+ Emitted whenever the grader chain cannot be imported, resolved, or executed.
387
+ Every list-shaped key is present and explicitly empty so downstream readers
388
+ never have to distinguish "absent" from "empty". ``health`` is a non-healthy literal.
389
+ """
390
+ payload = {
391
+ "task_id": TASK_ID,
392
+ "reward": 0.0,
393
+ "is_error": True,
394
+ "grader_health": health,
395
+ "grader_health_reason": reason,
396
+ }
397
+ for key in FAIL_CLOSED_LIST_KEYS:
398
+ payload[key] = []
399
+ payload["blockers"] = [reason]
400
+ if detail:
401
+ payload["grader_health_detail"] = detail
402
+ return payload
403
+
404
+
405
+ # --- Served grader scale ----------------------------------------------------------------------
406
+ # The id of the scale a served grade is expressed on, computed exactly as
407
+ # delivered_tasks/scripts/hud_task_evidence.compute_grader_scale_id does over the package: every
408
+ # file under grading/ (adversarial fixtures and generated caches excluded) plus task/rubric.md.
409
+ SERVED_ROOT = Path(__file__).resolve().parent
410
+ SCALE_GENERATED_DIRECTORY_NAMES = {"__pycache__", ".pytest_cache", ".ruff_cache", ".venv"}
411
+
412
+
413
+ def served_grader_scale_id(root: Path | None = None) -> str | None:
414
+ root = root or SERVED_ROOT
415
+ try:
416
+ digest = hashlib.sha256()
417
+ sources: list[tuple[str, Path]] = []
418
+ grading_dir = root / "grading"
419
+ if grading_dir.is_dir():
420
+ for path in sorted(grading_dir.rglob("*")):
421
+ relative = path.relative_to(root)
422
+ if not path.is_file() or any(
423
+ "adversarial" in part or part in SCALE_GENERATED_DIRECTORY_NAMES for part in relative.parts
424
+ ):
425
+ continue
426
+ sources.append((relative.as_posix(), path))
427
+ rubric = root / "task" / "rubric.md"
428
+ if rubric.is_file():
429
+ sources.append(("task/rubric.md", rubric))
430
+ for relative, path in sorted(sources):
431
+ digest.update(relative.encode("utf-8"))
432
+ digest.update(b"\0")
433
+ digest.update(path.read_bytes())
434
+ digest.update(b"\0")
435
+ return digest.hexdigest()
436
+ except OSError:
437
+ return None
438
+
439
+
440
+ def _with_info(result: EvaluationResult, **fields) -> EvaluationResult:
441
+ """Return ``result`` with ``fields`` merged into its info; never raises."""
442
+ try:
443
+ existing = getattr(result, "info", None)
444
+ info = dict(existing) if isinstance(existing, dict) else {}
445
+ info.update(fields)
446
+ return result.model_copy(update={"info": info})
447
+ except Exception: # noqa: BLE001 - diagnostic enrichment never changes the grade
448
+ logger.exception("could not enrich the grade result info")
449
+ return result
450
+
451
+
452
+ def _resolve_grader():
453
+ """Import the grader chain lazily and return its callable entry point."""
454
+ module_name, attribute = GRADER_ENTRY_POINT
455
+ module = importlib.import_module(module_name)
456
+ grade = getattr(module, attribute)
457
+ if not callable(grade):
458
+ raise TypeError(f"{module_name}.{attribute} is not callable")
459
+ return grade
460
+
461
+
462
+ def _evaluation_from_payload(payload: dict) -> EvaluationResult:
463
+ """Convert a fail-closed payload into an EvaluationResult carrying the complete diagnostics.
464
+
465
+ Faults report zero raw/final scores, an error flag, a non-healthy health literal and
466
+ explicit empty lists, so every reader can reject them as measurements.
467
+ """
468
+ info = {
469
+ "raw_score": 0.0,
470
+ "final_score": 0.0,
471
+ "caps": [],
472
+ "criteria": [],
473
+ "gates_fired": [],
474
+ "gate_statuses": {},
475
+ "grader_health": payload.get("grader_health") or "fault:entry_point",
476
+ "grader_health_reason": payload.get("grader_health_reason"),
477
+ }
478
+ return EvaluationResult(
479
+ reward=0.0,
480
+ done=True,
481
+ isError=True,
482
+ content=json.dumps(payload, indent=2, sort_keys=True, default=str),
483
+ info=info,
484
+ subscores=[],
485
+ )
486
+
487
+
488
+ async def run_grading(**grader_kwargs) -> EvaluationResult:
489
+ """Run the grader chain, failing closed on any import or execution failure.
490
+
491
+ A missing or corrupted grader module must still produce a structured JSON
492
+ result with ``is_error`` true, ``reward`` 0.0, a non-healthy
493
+ ``grader_health``, and explicitly empty lists -- never an import-time crash
494
+ that leaves the container with no output.
495
+
496
+ After the grader has produced its result, the agent's final workspace is captured as a
497
+ git patch (``capture_workspace_snapshot``) and attached to that result's
498
+ ``info["workspace_snapshot"]``. The grader always runs first, so a slow or failing capture
499
+ can only degrade to ``unavailable``; it can neither delay nor change the grade.
500
+ """
501
+ outcome = await _run_grader_chain(**grader_kwargs)
502
+ project_dir = str(grader_kwargs.get("project_dir") or PROJECT_DIR)
503
+ try:
504
+ snapshot = await asyncio.to_thread(capture_workspace_snapshot, project_dir, BASE_COMMIT_SHA)
505
+ except Exception as exc: # noqa: BLE001 - the snapshot is diagnostic, never grade-bearing
506
+ logger.exception("workspace snapshot capture raised; recording it unavailable")
507
+ snapshot = _snapshot_payload(BASE_COMMIT_SHA, None, reason=f"{type(exc).__name__}: {str(exc)[:200]}")
508
+ return _attach_workspace_snapshot(outcome, snapshot)
509
+
510
+
511
+ async def _run_grader_chain(**grader_kwargs) -> EvaluationResult:
512
+ """The one shared grading function: run the grader, then attach the served scale id."""
513
+ outcome = await _grade_or_fail_closed(**grader_kwargs)
514
+ return _with_info(outcome, served_grader_scale_id=served_grader_scale_id())
515
+
516
+
517
+ async def _grade_or_fail_closed(**grader_kwargs) -> EvaluationResult:
518
+ """Resolve and run the grader, failing closed on any import or execution failure."""
519
+ try:
520
+ grade = _resolve_grader()
521
+ except Exception as exc: # noqa: BLE001 - fail closed on any resolution failure
522
+ reason = f"grader entry point {'.'.join(GRADER_ENTRY_POINT)} unavailable: {exc!r}"
523
+ logger.exception("Grader chain could not be resolved; failing closed")
524
+ return _evaluation_from_payload(fail_closed_payload(reason))
525
+
526
+ try:
527
+ result = grade(**grader_kwargs)
528
+ if inspect.isawaitable(result):
529
+ result = await result
530
+ except Exception as exc: # noqa: BLE001 - fail closed on any grading failure
531
+ reason = f"grader execution failed: {exc!r}"
532
+ logger.exception("Grader chain raised; failing closed")
533
+ return _evaluation_from_payload(
534
+ fail_closed_payload(reason, detail=traceback.format_exc(limit=5))
535
+ )
536
+
537
+ if isinstance(result, EvaluationResult):
538
+ return result
539
+ if isinstance(result, dict):
540
+ return _evaluation_from_payload({**result, "is_error": True})
541
+ reason = f"grader returned unsupported result type {type(result).__name__}"
542
+ logger.error(reason)
543
+ return _evaluation_from_payload(fail_closed_payload(reason))
544
+
545
+
546
+ TASK_PROMPT_PATH = Path(__file__).resolve().parent / "task" / "prompt.md"
547
+
548
+
549
+ def last_resort_result(exc: BaseException) -> EvaluationResult:
550
+ """The template's final guard: a fail-closed grade naming only the exception class."""
551
+ payload = fail_closed_payload(
552
+ f"unhandled {type(exc).__name__} while grading", health="fault:unhandled"
553
+ )
554
+ return _with_info(_evaluation_from_payload(payload), served_grader_scale_id=served_grader_scale_id())
555
+
556
+
557
+ async def _guarded(grading) -> EvaluationResult:
558
+ try:
559
+ return await grading
560
+ except Exception as exc: # noqa: BLE001 - the last-resort path must always yield a grade
561
+ logger.exception("grading raised past its own guards; failing closed")
562
+ return last_resort_result(exc)
563
+
564
+
565
+ @env.template(id="aioftp_stream_abort_desynchronization", description="Keep aioftp's FTP control connection in sync around transfer aborts.")
566
+ async def aioftp_stream_abort_desynchronization(
567
+ task_id: str = "aioftp_stream_abort_desynchronization",
568
+ description: str | None = None,
569
+ **kwargs,
570
+ ):
571
+ """The agent task: serve the approved prompt, then grade the agent's workspace."""
572
+ if description is None:
573
+ description = TASK_PROMPT_PATH.read_text(encoding="utf-8")
574
+ _ = yield make_prompt(description)
575
+ yield await _guarded(run_grading(task_id=task_id, project_dir=PROJECT_DIR, **kwargs))
576
+
577
+
578
+ # --- Reference variants ---------------------------------------------------------------------
579
+ # The ec-swe-benchmarks PR check needs, in the linked taskset, a job whose name contains "gold"
580
+ # with every trace at 1.0 and one whose name contains "base" with every trace at 0.0. A single-task
581
+ # HUD job is named after its template id, so each variant is its own template (``<TASK_ID>_gold``,
582
+ # ``<TASK_ID>_base``). Prompt 07 runs each once on every deployed build.
583
+ #
584
+ # Neither variant grades the agent's workspace. Only after the agent's final answer, a fresh tree is
585
+ # cloned from the root-only repository metadata (``.git`` is root:root 0700 in the image, so the
586
+ # agent cannot have changed it) into a root-only temporary directory, checked out at
587
+ # ``BASE_COMMIT_SHA`` and verified against ``BASE_TREE_SHA``. For gold, ``/hud/gold.diff`` is applied
588
+ # there, read in place and never copied. The tree is graded through the same grader entry point as
589
+ # the agent task and then removed. A patch that does not apply, or any identity mismatch, fails
590
+ # closed. No workspace snapshot is captured, so no reference content reaches the trace.
591
+
592
+ GOLD_DIFF_PATH = "/hud/gold.diff"
593
+ REFERENCE_KINDS = ("gold", "base")
594
+ REFERENCE_GIT_TIMEOUT = 600
595
+ REFERENCE_PROMPT = (
596
+ "This is a reference run of this environment. No change to the repository is needed, and no "
597
+ "files should be modified. Reply that you are done."
598
+ )
599
+
600
+
601
+ class ReferenceTreeError(RuntimeError):
602
+ """The reference tree could not be materialized exactly; the reference grade fails closed."""
603
+
604
+
605
+ def _reference_git(*args: str, cwd: Path | None = None, safe: tuple = ()) -> str:
606
+ """Run one git command for the reference tree. Its output is never echoed: it may name gold paths."""
607
+ safe_flags = [flag for directory in safe for flag in ("-c", f"safe.directory={directory}")]
608
+ completed = subprocess.run(
609
+ ["git", *safe_flags, *args],
610
+ cwd=cwd,
611
+ capture_output=True,
612
+ text=True,
613
+ check=False,
614
+ timeout=REFERENCE_GIT_TIMEOUT,
615
+ env={**os.environ, "GIT_CONFIG_GLOBAL": os.devnull, "GIT_CONFIG_NOSYSTEM": "1", "GIT_TERMINAL_PROMPT": "0"},
616
+ )
617
+ if completed.returncode != 0:
618
+ raise ReferenceTreeError(f"git {args[0]} exited {completed.returncode}")
619
+ return completed.stdout
620
+
621
+
622
+ def _require_root_only(path: Path, label: str) -> None:
623
+ """Refuse a path any other account can read, or one not owned by root when running as root."""
624
+ details = path.stat()
625
+ if stat.S_IMODE(details.st_mode) & 0o077:
626
+ raise ReferenceTreeError(f"{label} is accessible beyond its owner")
627
+ if hasattr(os, "geteuid") and os.geteuid() == 0 and details.st_uid != 0:
628
+ raise ReferenceTreeError(f"{label} is not owned by root")
629
+
630
+
631
+ def materialize_reference_tree(reference: str) -> Path:
632
+ """Build the root-only reference tree for ``reference`` and return its temporary root.
633
+
634
+ The graded tree is ``<root>/tree``; the caller removes ``<root>``.
635
+ """
636
+ if reference not in REFERENCE_KINDS:
637
+ raise ReferenceTreeError(f"unknown reference kind {reference!r}")
638
+ git_dir = Path(PROJECT_DIR) / ".git"
639
+ if not git_dir.is_dir():
640
+ raise ReferenceTreeError("repository metadata is missing")
641
+ if not _LOCAL_SUBSTRATE:
642
+ _require_root_only(git_dir, "repository metadata")
643
+ root = Path(tempfile.mkdtemp(prefix="hud-reference-"))
644
+ try:
645
+ _require_root_only(root, "reference directory")
646
+ tree = root / "tree"
647
+ _reference_git(
648
+ "clone", "--no-hardlinks", "--no-checkout", "--quiet", str(git_dir), str(tree),
649
+ safe=(str(git_dir), str(PROJECT_DIR)),
650
+ )
651
+ _reference_git("checkout", "--quiet", "--detach", BASE_COMMIT_SHA, cwd=tree)
652
+ if _reference_git("rev-parse", "HEAD^{tree}", cwd=tree).strip() != BASE_TREE_SHA:
653
+ raise ReferenceTreeError("reference tree does not match the pinned base tree")
654
+ if _reference_git("status", "--porcelain", "--untracked-files=all", cwd=tree).strip():
655
+ raise ReferenceTreeError("reference tree is not a clean checkout of the pinned base")
656
+ if reference == "gold":
657
+ patch = Path(GOLD_DIFF_PATH)
658
+ if not patch.is_file():
659
+ raise ReferenceTreeError("the gold patch is unavailable")
660
+ _reference_git("apply", "--check", "--whitespace=nowarn", str(patch), cwd=tree)
661
+ _reference_git("apply", "--whitespace=nowarn", str(patch), cwd=tree)
662
+ return root
663
+ except BaseException:
664
+ shutil.rmtree(root, ignore_errors=True)
665
+ raise
666
+
667
+
668
+ async def run_reference_grading(reference: str) -> EvaluationResult:
669
+ """Grade a fresh reference tree through the agent task's grader entry point, failing closed."""
670
+ try:
671
+ root = await asyncio.to_thread(materialize_reference_tree, reference)
672
+ except Exception as exc: # noqa: BLE001 - any materialization failure fails closed
673
+ detail = str(exc) if isinstance(exc, ReferenceTreeError) else type(exc).__name__
674
+ logger.warning("reference %s tree unavailable: %s", reference, detail)
675
+ outcome = _with_info(
676
+ _evaluation_from_payload(
677
+ fail_closed_payload(f"reference_{reference}_unavailable: {detail}", health="fault:reference_tree")
678
+ ),
679
+ served_grader_scale_id=served_grader_scale_id(),
680
+ )
681
+ else:
682
+ try:
683
+ outcome = await _run_grader_chain(task_id=TASK_ID, project_dir=str(root / "tree"))
684
+ finally:
685
+ await asyncio.to_thread(shutil.rmtree, root, ignore_errors=True)
686
+ return _attach_workspace_snapshot(outcome, _snapshot_payload(BASE_COMMIT_SHA, None, reason="reference_run"))
687
+
688
+
689
+ @env.template(id=f"{TASK_ID}_gold", description="Reference run graded on the pinned base with the gold patch.")
690
+ async def reference_gold():
691
+ """Reference variant: grades the gold tree, never the agent's workspace."""
692
+ _ = yield REFERENCE_PROMPT
693
+ yield await _guarded(run_reference_grading("gold"))
694
+
695
+
696
+ @env.template(id=f"{TASK_ID}_base", description="Reference run graded on the unchanged pinned base.")
697
+ async def reference_base():
698
+ """Reference variant: grades the unchanged base tree, never the agent's workspace."""
699
+ _ = yield REFERENCE_PROMPT
700
+ yield await _guarded(run_reference_grading("base"))
harbor/sources/aioftp-v11/gold.diff ADDED
@@ -0,0 +1,795 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ diff --git a/src/aioftp/client.py b/src/aioftp/client.py
2
+ index 9755aaf..ebb9c6e 100644
3
+ --- a/src/aioftp/client.py
4
+ +++ b/src/aioftp/client.py
5
+ @@ -97,6 +97,7 @@ class DataConnectionThrottleStreamIO(ThrottleStreamIO):
6
+ write_timeout=write_timeout,
7
+ )
8
+ self.client = client
9
+ + self.final_reply_consumed = False
10
+
11
+ async def finish(
12
+ self,
13
+ @@ -118,7 +119,18 @@ class DataConnectionThrottleStreamIO(ThrottleStreamIO):
14
+ :py:class:`str`
15
+ """
16
+ self.close()
17
+ - await self.client.command(None, expected_codes, wait_codes)
18
+ + async with self.client._control_lock():
19
+ + if self.final_reply_consumed:
20
+ + # abort already read the transfer's final reply
21
+ + return
22
+ + # from here the reply is registered as owed before anything awaits, so a
23
+ + # cancelled finish leaves it to be read by the next command instead of lost
24
+ + self.final_reply_consumed = True
25
+ + try:
26
+ + await self.client._exchange(None, expected_codes, wait_codes, claim=self)
27
+ + finally:
28
+ + if self.client._transfer_stream is self:
29
+ + self.client._transfer_stream = None
30
+
31
+ async def __aexit__(
32
+ self,
33
+ @@ -128,6 +140,15 @@ class DataConnectionThrottleStreamIO(ThrottleStreamIO):
34
+ ) -> None:
35
+ if exc is None:
36
+ await self.finish()
37
+ + elif self.client._transfer_stream is self:
38
+ + try:
39
+ + await asyncio.shield(self.client.abort())
40
+ + except Exception:
41
+ + # the exception raised inside the block is the one that propagates: an abort
42
+ + # that failed (an unexpected ABOR reply, a lost connection) must not replace it
43
+ + logger.debug("abort after an exception in the stream block failed", exc_info=True)
44
+ + finally:
45
+ + self.close()
46
+ else:
47
+ self.close()
48
+
49
+ @@ -214,6 +235,14 @@ class BaseClient:
50
+ self.path_io = path_io_factory(timeout=path_timeout)
51
+ self.encoding = encoding
52
+ self._stream: ThrottleStreamIO | None = None
53
+ + self._transfer_stream: DataConnectionThrottleStreamIO | None = None
54
+ + self._control_lock_instance: asyncio.Lock | None = None
55
+ + self._write_lock_instance: asyncio.Lock | None = None
56
+ + # replies written for but not yet read from the control connection, oldest first:
57
+ + # (expected codes, wait codes, owner) where owner is the stream entitled to read it
58
+ + self._owed_replies: collections.deque[tuple[tuple[Code, ...], tuple[Code, ...], object | None]] = (
59
+ + collections.deque()
60
+ + )
61
+ self.ssl = ssl
62
+ self.parse_list_line_custom = parse_list_line_custom
63
+ self.parse_list_line_custom_first = parse_list_line_custom_first
64
+ @@ -252,6 +281,8 @@ class BaseClient:
65
+ throttles={"_": self.throttle},
66
+ timeout=self.socket_timeout,
67
+ )
68
+ + self._transfer_stream = None
69
+ + self._owed_replies.clear()
70
+
71
+ @property
72
+ def stream(self) -> ThrottleStreamIO:
73
+ @@ -265,6 +296,20 @@ class BaseClient:
74
+ """
75
+ if self._stream is not None:
76
+ self._stream.close()
77
+ + self._transfer_stream = None
78
+ + self._owed_replies.clear()
79
+ +
80
+ + def _control_lock(self) -> asyncio.Lock:
81
+ + """Serializes readers of the control connection."""
82
+ + if self._control_lock_instance is None:
83
+ + self._control_lock_instance = asyncio.Lock()
84
+ + return self._control_lock_instance
85
+ +
86
+ + def _write_lock(self) -> asyncio.Lock:
87
+ + """Keeps the ledger of owed replies in wire order across concurrent writers."""
88
+ + if self._write_lock_instance is None:
89
+ + self._write_lock_instance = asyncio.Lock()
90
+ + return self._write_lock_instance
91
+
92
+ async def parse_line(self) -> tuple[Code, str]:
93
+ """
94
+ @@ -381,28 +426,210 @@ class BaseClient:
95
+ when logging
96
+ :type censor_after: :py:class:`None` or :py:class:`int`
97
+ """
98
+ + async with self._control_lock():
99
+ + if command and command.split(None, 1)[0].upper() != "ABOR":
100
+ + # a transfer nobody finished or aborted must not leak its reply into this exchange
101
+ + await self._settle_transfer()
102
+ + return await self._exchange(command, expected_codes, wait_codes, censor_after)
103
+ +
104
+ + async def _exchange(
105
+ + self,
106
+ + command: str | None,
107
+ + expected_codes: str | tuple[str, ...] = (),
108
+ + wait_codes: str | tuple[str, ...] = (),
109
+ + censor_after: int | None = None,
110
+ + *,
111
+ + claim: object | None = None,
112
+ + ) -> tuple[Code, list[str]] | None:
113
+ + """
114
+ + :py:func:`asyncio.coroutine`
115
+ +
116
+ + One control exchange; the caller holds the control lock. Replies owed
117
+ + from earlier exchanges are consumed before this one is read. `claim`
118
+ + names a stream whose reply may already be owed (a transfer aborted
119
+ + with `wait=False`); that reply is then read here instead of drained.
120
+ + """
121
+ expected_codes = wrap_into_codes(wrap_with_container(expected_codes))
122
+ wait_codes = wrap_into_codes(wrap_with_container(wait_codes))
123
+ - if command:
124
+ - if "\r" in command or "\n" in command:
125
+ - raise errors.InvalidCommand("Command must not contain CR/LF")
126
+ - if censor_after:
127
+ - # Censor the user's command
128
+ - raw = command[:censor_after]
129
+ - stars = "*" * len(command[censor_after:])
130
+ - logger.debug("%s%s", raw, stars)
131
+ + entry = None
132
+ + if claim is not None:
133
+ + entry = next((owed for owed in self._owed_replies if owed[2] is claim), None)
134
+ + if entry is None and (expected_codes or wait_codes):
135
+ + entry = (expected_codes, wait_codes, claim)
136
+ + if command:
137
+ + # nothing is written while replies are still owed: no pipelining behind them
138
+ + await self._drain_owed_replies()
139
+ + await self._submit(command, [entry], censor_after)
140
+ else:
141
+ - logger.debug(command)
142
+ - message = command + END_OF_LINE
143
+ - await self.stream.write(message.encode(encoding=self.encoding))
144
+ - if expected_codes or wait_codes:
145
+ + # the reply is already in flight: owed from now on, even if we are cancelled
146
+ + self._owed_replies.append(entry)
147
+ + elif command:
148
+ + await self._drain_owed_replies()
149
+ + await self._submit(command, [], censor_after)
150
+ + if entry is None:
151
+ + return None
152
+ + # another writer (an abort from a second task) may have slipped in ahead of us
153
+ + await self._drain_owed_replies(until=entry)
154
+ + code, info = await self._collect_reply()
155
+ + if expected_codes:
156
+ + self.check_codes(expected_codes, code, info)
157
+ + return code, info
158
+ +
159
+ + async def _submit(
160
+ + self,
161
+ + command: str,
162
+ + entries: list[tuple[tuple[Code, ...], tuple[Code, ...], object | None]],
163
+ + censor_after: int | None = None,
164
+ + ) -> None:
165
+ + """
166
+ + :py:func:`asyncio.coroutine`
167
+ +
168
+ + Register the replies `command` will earn and write it, as one step
169
+ + with respect to other writers, so the ledger matches the wire order.
170
+ + A failed write owes nothing.
171
+ + """
172
+ + async with self._write_lock():
173
+ + self._owed_replies.extend(entries)
174
+ + try:
175
+ + await self._write_command(command, censor_after)
176
+ + except BaseException:
177
+ + for entry in reversed(entries):
178
+ + if self._owed_replies and self._owed_replies[-1] is entry:
179
+ + self._owed_replies.pop()
180
+ + raise
181
+ +
182
+ + async def _write_command(self, command: str, censor_after: int | None = None) -> None:
183
+ + if "\r" in command or "\n" in command:
184
+ + raise errors.InvalidCommand("Command must not contain CR/LF")
185
+ + if censor_after:
186
+ + # Censor the user's command
187
+ + raw = command[:censor_after]
188
+ + stars = "*" * len(command[censor_after:])
189
+ + logger.debug("%s%s", raw, stars)
190
+ + else:
191
+ + logger.debug(command)
192
+ + message = command + END_OF_LINE
193
+ + await self.stream.write(message.encode(encoding=self.encoding))
194
+ +
195
+ + async def _collect_reply(self) -> tuple[Code, list[str]]:
196
+ + """
197
+ + :py:func:`asyncio.coroutine`
198
+ +
199
+ + Read the reply of the oldest owed exchange. The exchange leaves the
200
+ + ledger only once its reply has actually been read, so a cancelled
201
+ + reader leaves the reply owed rather than lost.
202
+ + """
203
+ + _, wait_codes, _ = self._owed_replies[0]
204
+ + code, info = await self.parse_response()
205
+ + while any(map(code.matches, wait_codes)):
206
+ code, info = await self.parse_response()
207
+ - while any(map(code.matches, wait_codes)):
208
+ - code, info = await self.parse_response()
209
+ - if expected_codes:
210
+ - self.check_codes(expected_codes, code, info)
211
+ - return code, info
212
+ - return None
213
+ + self._owed_replies.popleft()
214
+ + return code, info
215
+ +
216
+ + async def _drain_owed_replies(self, until: object | None = None) -> None:
217
+ + while self._owed_replies and self._owed_replies[0] is not until:
218
+ + await self._collect_reply()
219
+ +
220
+ + async def _settle_transfer(self) -> None:
221
+ + """
222
+ + :py:func:`asyncio.coroutine`
223
+ +
224
+ + Abort a transfer that is still outstanding on the control connection
225
+ + (a stream that was neither finished nor aborted) before a new command
226
+ + is written; the caller holds the control lock.
227
+ + """
228
+ + transfer = self._transfer_stream
229
+ + if transfer is None:
230
+ + return
231
+ + if transfer.final_reply_consumed:
232
+ + self._transfer_stream = None
233
+ + return
234
+ + await self._abort_transfer(transfer, wait=True, locked=True)
235
+ +
236
+ + async def _abort_transfer(
237
+ + self,
238
+ + transfer: DataConnectionThrottleStreamIO | None,
239
+ + *,
240
+ + wait: bool,
241
+ + locked: bool = False,
242
+ + ) -> None:
243
+ + """
244
+ + :py:func:`asyncio.coroutine`
245
+ +
246
+ + Send `ABOR` and, with `wait`, read its reply. When a transfer is
247
+ + outstanding its final reply comes first, whatever its code; it is
248
+ + registered as owed together with the abort reply before `ABOR` is
249
+ + written, so both are still read later if this coroutine is cancelled
250
+ + or `wait` is false. With `wait=False`, or while `finish()` is already
251
+ + reading it, the transfer's final reply stays with the stream and
252
+ + `finish()` checks it as usual. `ABOR` is written without the control
253
+ + lock, so it can interrupt a `finish()` that is waiting on the server;
254
+ + `locked` says the caller already holds the control lock for reading.
255
+ + """
256
+ + token = object()
257
+ + entries: list[tuple[tuple[Code, ...], tuple[Code, ...], object | None]] = []
258
+ + claimed = False
259
+ + if transfer is not None:
260
+ + registered = any(owed[2] is transfer for owed in self._owed_replies)
261
+ + if not transfer.final_reply_consumed and not registered:
262
+ + if wait:
263
+ + transfer.final_reply_consumed = True
264
+ + claimed = True
265
+ + entries.append(((), wrap_into_codes(("1xx",)), None if wait else transfer))
266
+ + if self._transfer_stream is transfer:
267
+ + self._transfer_stream = None
268
+ + abort_codes = wrap_into_codes(("225", "226"))
269
+ + entries.append((abort_codes, wrap_into_codes(("1xx", "426")), token))
270
+ + try:
271
+ + await self._submit("ABOR", entries)
272
+ + except BaseException:
273
+ + if transfer is not None:
274
+ + if claimed:
275
+ + transfer.final_reply_consumed = False
276
+ + self._transfer_stream = transfer
277
+ + raise
278
+ + if not wait:
279
+ + return
280
+ + try:
281
+ + if locked:
282
+ + await self._read_owed(token, abort_codes)
283
+ + else:
284
+ + async with self._control_lock():
285
+ + await self._read_owed(token, abort_codes)
286
+ + finally:
287
+ + if transfer is not None:
288
+ + transfer.close()
289
+ +
290
+ + async def _read_owed(self, owner: object, expected_codes: tuple[Code, ...]) -> tuple[Code, list[str]]:
291
+ + """
292
+ + :py:func:`asyncio.coroutine`
293
+ +
294
+ + Read everything owed before `owner`'s reply, then that reply; the
295
+ + caller holds the control lock.
296
+ + """
297
+ + entry = next(owed for owed in self._owed_replies if owed[2] is owner)
298
+ + await self._drain_owed_replies(until=entry)
299
+ + code, info = await self._collect_reply()
300
+ + self.check_codes(expected_codes, code, info)
301
+ + return code, info
302
+ +
303
+ + async def abort(self, *, wait: bool = True) -> None:
304
+ + """
305
+ + :py:func:`asyncio.coroutine`
306
+ +
307
+ + Request data transfer abort.
308
+ +
309
+ + If a transfer is in progress, its final reply (usually 426, or the
310
+ + transfer's own completion reply if it finished first) is read before
311
+ + the abort reply (225 or 226), so the control connection stays in sync.
312
+ + With `wait=False` the abort reply is read by the next command instead.
313
+ + `abort()` may be called from another task while the stream is being
314
+ + finished; the calls serialize on the control connection.
315
+ +
316
+ + :param wait: wait for abort response [426]→226 if `True`
317
+ + :type wait: :py:class:`bool`
318
+ + """
319
+ + await self._abort_transfer(self._transfer_stream, wait=wait)
320
+
321
+ @staticmethod
322
+ def parse_epsv_response(s: str) -> tuple[None, int]:
323
+ @@ -970,6 +1197,21 @@ class Client(BaseClient):
324
+ )
325
+ return cls
326
+
327
+ + async def aclose(cls) -> None:
328
+ + """
329
+ + Stop listing early: abort the listing still in progress so the
330
+ + control connection is ready for the next command.
331
+ + """
332
+ + stream, cls.stream = cls.stream, None
333
+ + if hasattr(cls, "directories"):
334
+ + cls.directories.clear()
335
+ + if stream is None:
336
+ + return
337
+ + if self._transfer_stream is stream and not stream.final_reply_consumed:
338
+ + await self.abort()
339
+ + else:
340
+ + stream.close()
341
+ +
342
+ async def __anext__(cls) -> PathWithInfo:
343
+ if cls.stream is None:
344
+ cls.stream = await cls._new_stream(path)
345
+ @@ -1405,7 +1647,7 @@ class Client(BaseClient):
346
+ reader, writer = await self.get_passive_connection(conn_type)
347
+ if offset:
348
+ await self.command("REST " + str(offset), "350")
349
+ - await self.command(command, expected_codes, wait_codes, censor_after)
350
+ + response = await self.command(command, expected_codes, wait_codes, censor_after)
351
+ stream = DataConnectionThrottleStreamIO(
352
+ self,
353
+ reader,
354
+ @@ -1413,22 +1655,11 @@ class Client(BaseClient):
355
+ throttles={"_": self.throttle},
356
+ timeout=self.socket_timeout,
357
+ )
358
+ + if command and (response is None or response[0].matches("1xx")):
359
+ + # the transfer's final reply is still to come on the control connection
360
+ + self._transfer_stream = stream
361
+ return stream
362
+
363
+ - async def abort(self, *, wait: bool = True) -> None:
364
+ - """
365
+ - :py:func:`asyncio.coroutine`
366
+ -
367
+ - Request data transfer abort.
368
+ -
369
+ - :param wait: wait for abort response [426]→226 if `True`
370
+ - :type wait: :py:class:`bool`
371
+ - """
372
+ - if wait:
373
+ - await self.command("ABOR", "226", "426")
374
+ - else:
375
+ - await self.command("ABOR")
376
+ -
377
+ @classmethod
378
+ @contextlib.asynccontextmanager
379
+ async def context(
380
+ diff --git a/src/aioftp/server.py b/src/aioftp/server.py
381
+ index 076e702..defcd66 100644
382
+ --- a/src/aioftp/server.py
383
+ +++ b/src/aioftp/server.py
384
+ @@ -584,8 +584,21 @@ def worker(
385
+ try:
386
+ await f(cls, connection, rest)
387
+ except asyncio.CancelledError:
388
+ + # an aborted transfer gives up its data path: whatever connects for it
389
+ + # later must not be picked up by the next transfer
390
+ + if connection.future.data_connection.done():
391
+ + connection.data_connection.close()
392
+ + del connection.data_connection
393
+ + cls._release_passive_server(connection)
394
+ connection.response("426", "transfer aborted")
395
+ - connection.response("226", "abort successful")
396
+ + if asyncio.current_task() in connection.aborting_workers:
397
+ + connection.response("226", "abort successful")
398
+ + except ConnectionError:
399
+ + if connection.future.data_connection.done():
400
+ + connection.data_connection.close()
401
+ + del connection.data_connection
402
+ + cls._release_passive_server(connection)
403
+ + connection.response("426", "Connection closed; transfer aborted")
404
+
405
+ return wrapper # type: ignore[return-value]
406
+
407
+ @@ -902,6 +915,31 @@ class Server:
408
+ await write(code + "-" + line)
409
+ await write(code + " " + tail)
410
+
411
+ + @staticmethod
412
+ + def _strip_telnet(b: bytes) -> bytes:
413
+ + out = bytearray()
414
+ + i = 0
415
+ + n = len(b)
416
+ + while i < n:
417
+ + if b[i] == 0xFF:
418
+ + if i + 1 < n:
419
+ + cmd = b[i + 1]
420
+ + if cmd == 0xFF:
421
+ + out.append(0xFF)
422
+ + i += 2
423
+ + continue
424
+ + elif 0xF0 <= cmd <= 0xFA:
425
+ + i += 2
426
+ + continue
427
+ + elif 0xFB <= cmd <= 0xFE:
428
+ + i += 3
429
+ + continue
430
+ + i += 1
431
+ + continue
432
+ + out.append(b[i])
433
+ + i += 1
434
+ + return bytes(out)
435
+ +
436
+ async def parse_command(self, stream: StreamIO, censor_commands: tuple[str] = ("pass",)) -> tuple[str, str]:
437
+ """
438
+ :py:func:`asyncio.coroutine`
439
+ @@ -920,7 +958,11 @@ class Server:
440
+ line = await stream.readline()
441
+ if not line:
442
+ raise ConnectionResetError
443
+ - s = line.decode(encoding=self.encoding).rstrip()
444
+ + line = self._strip_telnet(line)
445
+ + try:
446
+ + s = line.decode(encoding=self.encoding).rstrip()
447
+ + except UnicodeDecodeError:
448
+ + return "undecodable", ""
449
+ cmd, _, rest = s.partition(" ")
450
+
451
+ if cmd.lower() in censor_commands:
452
+ @@ -965,6 +1007,14 @@ class Server:
453
+ host, port, *_ = writer.transport.get_extra_info("peername", ("", ""))
454
+ current_server_host, *_ = writer.transport.get_extra_info("sockname")
455
+ logger.info("new connection from %s:%s", host, port)
456
+ +
457
+ + sock = writer.transport.get_extra_info("socket")
458
+ + if sock is not None:
459
+ + try:
460
+ + sock.setsockopt(socket.SOL_SOCKET, socket.SO_OOBINLINE, 1)
461
+ + except Exception:
462
+ + pass
463
+ +
464
+ key = stream = ThrottleStreamIO(
465
+ reader,
466
+ writer,
467
+ @@ -990,6 +1040,8 @@ class Server:
468
+ path_io_factory=self.path_io_factory,
469
+ path_timeout=self.path_timeout,
470
+ extra_workers=set(),
471
+ + aborting_workers=set(),
472
+ + transferring_workers=set(),
473
+ response=lambda *args: response_queue.put_nowait(args),
474
+ acquired=False,
475
+ restart_offset=0,
476
+ @@ -999,46 +1051,119 @@ class Server:
477
+ timeout=self.path_timeout,
478
+ connection=connection,
479
+ )
480
+ - pending = {
481
+ - asyncio.create_task(self.greeting(connection, "")),
482
+ - asyncio.create_task(self.response_writer(stream, response_queue)),
483
+ - asyncio.create_task(self.parse_command(stream)),
484
+ - }
485
+ self.connections[key] = connection
486
+ +
487
+ + response_writer_task = asyncio.create_task(self.response_writer(stream, response_queue))
488
+ + pending_cleanup = {response_writer_task}
489
+ + command_queue: asyncio.Queue[tuple[str, str]] = asyncio.Queue()
490
+ +
491
+ + async def command_reader() -> None:
492
+ + while True:
493
+ + try:
494
+ + res = await self.parse_command(stream)
495
+ + except ConnectionResetError:
496
+ + await command_queue.put(("eof", ""))
497
+ + return
498
+ + except Exception as exc:
499
+ + await command_queue.put(("error", str(exc)))
500
+ + return
501
+ + await command_queue.put(res)
502
+ +
503
+ try:
504
+ + greeting_ok = await self.greeting(connection, "")
505
+ + if not greeting_ok:
506
+ + await response_queue.join()
507
+ + return
508
+ +
509
+ + reader_task = asyncio.create_task(command_reader())
510
+ + pending_cleanup.add(reader_task)
511
+ + queue_get_task = asyncio.create_task(command_queue.get())
512
+ + pending_cleanup.add(queue_get_task)
513
+ +
514
+ while True:
515
+ - done, pending = await asyncio.wait(
516
+ - pending | connection.extra_workers,
517
+ + wait_set = {queue_get_task, reader_task, response_writer_task} | connection.extra_workers
518
+ + done, _ = await asyncio.wait(
519
+ + wait_set,
520
+ return_when=asyncio.FIRST_COMPLETED,
521
+ )
522
+ - connection.extra_workers -= done
523
+ - for task in done:
524
+ +
525
+ + for worker_task in done & connection.extra_workers:
526
+ + connection.extra_workers.remove(worker_task)
527
+ try:
528
+ - result = task.result()
529
+ + worker_task.result()
530
+ except errors.PathIOError:
531
+ connection.response("451", "file system error")
532
+ + except asyncio.CancelledError:
533
+ + pass
534
+ +
535
+ + if response_writer_task in done:
536
+ + response_writer_task.result()
537
+ + return
538
+ +
539
+ + if reader_task in done and not reader_task.cancelled():
540
+ + exc = reader_task.exception()
541
+ + if exc is not None:
542
+ + raise exc
543
+ +
544
+ + if queue_get_task in done:
545
+ + cmd, rest = queue_get_task.result()
546
+ + pending_cleanup.remove(queue_get_task)
547
+ + queue_get_task = asyncio.create_task(command_queue.get())
548
+ + pending_cleanup.add(queue_get_task)
549
+ +
550
+ + if cmd == "eof":
551
+ + return
552
+ + if cmd == "error":
553
+ + return
554
+ +
555
+ + if cmd == "undecodable":
556
+ + connection.response("500", "syntax error, command unrecognized")
557
+ continue
558
+ - # this is "command" result
559
+ - if isinstance(result, bool):
560
+ - if not result:
561
+ - await response_queue.join()
562
+ - return
563
+ - # this is parse_command result
564
+ - elif isinstance(result, tuple):
565
+ - pending.add(
566
+ - asyncio.create_task(self.parse_command(stream)),
567
+ - )
568
+ - cmd, rest = result
569
+ - f = self.commands_mapping.get(cmd)
570
+ - if f is not None:
571
+ - pending.add(
572
+ - asyncio.create_task(f(connection, rest)), # type: ignore[arg-type]
573
+ +
574
+ + f = self.commands_mapping.get(cmd)
575
+ + if f is None:
576
+ + connection.response("502", f"{cmd!r} not implemented")
577
+ + if cmd not in ("retr", "stor", "appe", "rest"):
578
+ + connection.restart_offset = 0
579
+ + continue
580
+ +
581
+ + cmd_task = asyncio.create_task(f(connection, rest))
582
+ + pending_cleanup.add(cmd_task)
583
+ + try:
584
+ + while not cmd_task.done():
585
+ + wait_cmd_set = {cmd_task, response_writer_task} | connection.extra_workers
586
+ + cmd_done, _ = await asyncio.wait(
587
+ + wait_cmd_set,
588
+ + return_when=asyncio.FIRST_COMPLETED,
589
+ )
590
+ - if cmd not in ("retr", "stor", "appe"):
591
+ - connection.restart_offset = 0
592
+ - else:
593
+ - message = f"{cmd!r} not implemented"
594
+ - connection.response("502", message)
595
+ + for worker_task in cmd_done & connection.extra_workers:
596
+ + connection.extra_workers.remove(worker_task)
597
+ + try:
598
+ + worker_task.result()
599
+ + except errors.PathIOError:
600
+ + connection.response("451", "file system error")
601
+ + except asyncio.CancelledError:
602
+ + pass
603
+ +
604
+ + if response_writer_task in cmd_done:
605
+ + response_writer_task.result()
606
+ + return
607
+ +
608
+ + result = cmd_task.result()
609
+ + except errors.PathIOError:
610
+ + connection.response("451", "file system error")
611
+ + result = True
612
+ + finally:
613
+ + pending_cleanup.discard(cmd_task)
614
+ +
615
+ + if cmd not in ("retr", "stor", "appe", "rest"):
616
+ + # a transfer's worker still has to read the REST offset
617
+ + connection.restart_offset = 0
618
+ +
619
+ + if isinstance(result, bool) and not result:
620
+ + await response_queue.join()
621
+ + return
622
+ +
623
+ except asyncio.CancelledError:
624
+ raise
625
+ except Exception:
626
+ @@ -1047,7 +1172,7 @@ class Server:
627
+ logger.info("closing connection from %s:%s", host, port)
628
+ tasks_to_wait = []
629
+ if not asyncio.get_running_loop().is_closed():
630
+ - for task in pending | connection.extra_workers:
631
+ + for task in pending_cleanup | connection.extra_workers:
632
+ task.cancel()
633
+ tasks_to_wait.append(task)
634
+ if connection.future.passive_server.done():
635
+ @@ -1065,7 +1190,7 @@ class Server:
636
+ self.user_manager.notify_logout(connection.user),
637
+ )
638
+ tasks_to_wait.append(task)
639
+ - self.connections.pop(key)
640
+ + self.connections.pop(key, None)
641
+ if tasks_to_wait:
642
+ await asyncio.wait(tasks_to_wait)
643
+
644
+ @@ -1162,6 +1287,22 @@ class Server:
645
+ return True
646
+
647
+ async def quit(self, connection: Connection, rest: str | PurePosixPath) -> bool:
648
+ + # a transfer that owns its data connection finishes and replies first; one still waiting
649
+ + # for its data connection is aborted with 426
650
+ + waiting = []
651
+ + open_workers = []
652
+ + for w in list(connection.extra_workers):
653
+ + if not w.done():
654
+ + if w in connection.transferring_workers:
655
+ + open_workers.append(w)
656
+ + else:
657
+ + waiting.append(w)
658
+ + for w in waiting:
659
+ + w.cancel()
660
+ + if waiting:
661
+ + await asyncio.wait(waiting)
662
+ + if open_workers:
663
+ + await asyncio.wait(open_workers)
664
+ connection.response("221", "bye")
665
+ return False
666
+
667
+ @@ -1245,16 +1386,17 @@ class Server:
668
+ @PathConditions(PathConditions.path_must_exists)
669
+ @PathPermissions(PathPermissions.readable)
670
+ async def mlsd(self, connection: Connection, rest: str | PurePosixPath) -> bool:
671
+ + @worker
672
+ @ConnectionConditions(
673
+ ConnectionConditions.data_connection_made,
674
+ wait=True,
675
+ fail_code="425",
676
+ fail_info="Can't open data connection",
677
+ )
678
+ - @worker
679
+ async def mlsd_worker(self: "Server", connection: Connection, rest: str | PurePosixPath) -> bool:
680
+ stream = connection.data_connection
681
+ del connection.data_connection
682
+ + connection.transferring_workers.add(asyncio.current_task())
683
+ async with stream:
684
+ async for path in connection.path_io.list(real_path):
685
+ s = await self.build_mlsx_string(connection, path)
686
+ @@ -1304,16 +1446,17 @@ class Server:
687
+ @PathConditions(PathConditions.path_must_exists)
688
+ @PathPermissions(PathPermissions.readable)
689
+ async def list(self, connection: Connection, rest: str | PurePosixPath) -> bool:
690
+ + @worker
691
+ @ConnectionConditions(
692
+ ConnectionConditions.data_connection_made,
693
+ wait=True,
694
+ fail_code="425",
695
+ fail_info="Can't open data connection",
696
+ )
697
+ - @worker
698
+ async def list_worker(self: "Server", connection: Connection, rest: str | PurePosixPath) -> bool:
699
+ stream = connection.data_connection
700
+ del connection.data_connection
701
+ + connection.transferring_workers.add(asyncio.current_task())
702
+ async with stream:
703
+ async for path in connection.path_io.list(real_path):
704
+ if not (await connection.path_io.exists(path)):
705
+ @@ -1382,16 +1525,17 @@ class Server:
706
+ )
707
+ @PathPermissions(PathPermissions.writable)
708
+ async def stor(self, connection: Connection, rest: str | PurePosixPath, mode: str = "wb") -> bool:
709
+ + @worker
710
+ @ConnectionConditions(
711
+ ConnectionConditions.data_connection_made,
712
+ wait=True,
713
+ fail_code="425",
714
+ fail_info="Can't open data connection",
715
+ )
716
+ - @worker
717
+ async def stor_worker(self: "Server", connection: Connection, rest: str | PurePosixPath) -> bool:
718
+ stream = connection.data_connection
719
+ del connection.data_connection
720
+ + connection.transferring_workers.add(asyncio.current_task())
721
+ if connection.restart_offset:
722
+ file_mode = "r+b"
723
+ else:
724
+ @@ -1426,16 +1570,17 @@ class Server:
725
+ )
726
+ @PathPermissions(PathPermissions.readable)
727
+ async def retr(self, connection: Connection, rest: str | PurePosixPath) -> bool:
728
+ + @worker
729
+ @ConnectionConditions(
730
+ ConnectionConditions.data_connection_made,
731
+ wait=True,
732
+ fail_code="425",
733
+ fail_info="Can't open data connection",
734
+ )
735
+ - @worker
736
+ async def retr_worker(self: "Server", connection: Connection, rest: str | PurePosixPath) -> bool:
737
+ stream = connection.data_connection
738
+ del connection.data_connection
739
+ + connection.transferring_workers.add(asyncio.current_task())
740
+ file_in = connection.path_io.open(real_path, mode="rb")
741
+ async with file_in, stream:
742
+ if connection.restart_offset:
743
+ @@ -1514,10 +1659,18 @@ class Server:
744
+ )
745
+ return passive_server
746
+
747
+ + def _release_passive_server(self, connection: Connection) -> None:
748
+ + if not connection.future.passive_server.done():
749
+ + return
750
+ + connection.passive_server.close()
751
+ + if self.available_data_ports is not None:
752
+ + self.available_data_ports.put_nowait((0, connection.passive_server_port))
753
+ + del connection.passive_server
754
+ +
755
+ @ConnectionConditions(ConnectionConditions.login_required)
756
+ async def pasv(self, connection: Connection, rest: str | PurePosixPath) -> bool:
757
+ async def handler(reader: asyncio.StreamReader, writer: asyncio.StreamWriter) -> None:
758
+ - if connection.future.data_connection.done():
759
+ + if connection.future.data_connection.done() or not connection.future.passive_server.done():
760
+ writer.close()
761
+ else:
762
+ connection.data_connection = ThrottleStreamIO(
763
+ @@ -1562,7 +1715,7 @@ class Server:
764
+ @ConnectionConditions(ConnectionConditions.login_required)
765
+ async def epsv(self, connection: Connection, rest: str | PurePosixPath) -> bool:
766
+ async def handler(reader: asyncio.StreamReader, writer: asyncio.StreamWriter) -> None:
767
+ - if connection.future.data_connection.done():
768
+ + if connection.future.data_connection.done() or not connection.future.passive_server.done():
769
+ writer.close()
770
+ else:
771
+ connection.data_connection = ThrottleStreamIO(
772
+ @@ -1601,11 +1754,19 @@ class Server:
773
+
774
+ @ConnectionConditions(ConnectionConditions.login_required)
775
+ async def abor(self, connection: Connection, rest: str | PurePosixPath) -> bool:
776
+ - if connection.extra_workers:
777
+ - for worker in connection.extra_workers:
778
+ + connection.aborting_workers.intersection_update(connection.extra_workers)
779
+ + active = [worker for worker in connection.extra_workers if not worker.done()]
780
+ + fresh = [worker for worker in active if worker not in connection.aborting_workers]
781
+ + if fresh:
782
+ + # the cancelled workers answer 426 then 226 themselves
783
+ + for worker in fresh:
784
+ + connection.aborting_workers.add(worker)
785
+ worker.cancel()
786
+ - else:
787
+ - connection.response("226", "nothing to abort")
788
+ + return True
789
+ + if active:
790
+ + # a repeated ABOR is answered after the abort it repeats, never before
791
+ + await asyncio.wait(active)
792
+ + connection.response("226", "nothing to abort")
793
+ return True
794
+
795
+ async def appe(self, connection: Connection, rest: str | PurePosixPath) -> bool:
harbor/sources/aioftp-v11/grading/__init__.py ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """Grading modules for aioftp_stream_abort_desynchronization.
2
+
3
+ Submodules are exposed lazily (PEP 562). Importing this package must never pull
4
+ in the grader chain, so that a missing or corrupted grader submodule surfaces as
5
+ a fail-closed result from ``env.run_grading`` instead of an import-time crash
6
+ that leaves the container with no JSON output.
7
+ """
8
+
9
+ __all__ = ["GradingRunner"]
10
+
11
+
12
+ def __getattr__(name: str):
13
+ """Import submodule attributes on first access, not at package import."""
14
+ if name == "GradingRunner":
15
+ from .runner import GradingRunner
16
+
17
+ return GradingRunner
18
+ raise AttributeError(f"module {__name__!r} has no attribute {name!r}")
harbor/sources/aioftp-v11/grading/adversarial-manifest.json ADDED
@@ -0,0 +1,2082 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "schema_version": 7,
3
+ "task_id": "aioftp_stream_abort_desynchronization",
4
+ "gold_diff_sha256": "90b71765ae5d945b112d042be7044a1f152625dcdb70a14450d0ef32ec1036d3",
5
+ "comment_syntax": [
6
+ "#"
7
+ ],
8
+ "native_commands": {
9
+ "test": {
10
+ "argv": [
11
+ "/opt/aioftp-venv/bin/python",
12
+ "-I",
13
+ "-m",
14
+ "pytest",
15
+ "-p",
16
+ "no:cacheprovider",
17
+ "-o",
18
+ "pythonpath=src"
19
+ ],
20
+ "timeout_seconds": 600,
21
+ "measured_runtime_seconds": {
22
+ "gold": 19.733,
23
+ "base": 19.029
24
+ },
25
+ "may_cap": true,
26
+ "requires": [
27
+ "repo_python"
28
+ ],
29
+ "description": "The repository's whole pytest suite from the repository root with its own [tool.pytest.ini_options] (792 node IDs: -x, --durations 10, -p no:anyio, --cov, --import-mode=importlib), invoked directly through the repository interpreter. The grader runs the same argv on a tree whose tests/ and pyproject.toml are restored from grading/baseline; a failure lands on the 0.30 regression ceiling. Where IPv6 loopback is unavailable (the HUD sandbox), the image's aioftp_ipv6_loopback pytest plugin skips exactly the 212 ::1 node IDs and the grader requires that skip count; where ::1 binds, it requires zero skips."
30
+ }
31
+ },
32
+ "runtime_requirements": {
33
+ "executables": [
34
+ {
35
+ "id": "repo_python",
36
+ "executable": "/opt/aioftp-venv/bin/python",
37
+ "role": "interpreter",
38
+ "discovery": "dynamic",
39
+ "version_probe": {
40
+ "argv": [
41
+ "/opt/aioftp-venv/bin/python",
42
+ "--version"
43
+ ],
44
+ "regex": "Python (\\d+\\.\\d+\\.\\d+)"
45
+ },
46
+ "version_constraint": {
47
+ "major": 3,
48
+ "minimum": "3.11"
49
+ },
50
+ "required_by": [
51
+ "native_command:test",
52
+ "grader:grading/runner.py",
53
+ "grader:grading/regression.py",
54
+ "agent_prompt"
55
+ ],
56
+ "offline_assets": [
57
+ "/opt/aioftp-venv/lib/python3.11/site-packages/aioftp-0.28.3.dist-info/METADATA",
58
+ "/opt/aioftp-venv/lib/python3.11/site-packages/__editable__.aioftp-0.28.3.pth",
59
+ "/opt/aioftp-venv/lib/python3.11/site-packages/pytest_asyncio",
60
+ "/opt/aioftp-venv/lib/python3.11/site-packages/pytest_cov",
61
+ "/opt/aioftp-venv/lib/python3.11/site-packages/siosocks",
62
+ "/opt/aioftp-venv/lib/python3.11/site-packages/trustme",
63
+ "/opt/aioftp-venv/lib/python3.11/site-packages/async_timeout"
64
+ ],
65
+ "description": "CPython 3.11 with the repository's dev extra; spawned by the grader through AIOFTP_REPO_PYTHON, so static discovery cannot see it."
66
+ },
67
+ {
68
+ "id": "repo_pytest",
69
+ "executable": "/opt/aioftp-venv/bin/pytest",
70
+ "role": "quality",
71
+ "discovery": "dynamic",
72
+ "version_probe": {
73
+ "argv": [
74
+ "/opt/aioftp-venv/bin/pytest",
75
+ "--version"
76
+ ],
77
+ "regex": "pytest (\\d+\\.\\d+\\.\\d+)"
78
+ },
79
+ "required_by": [
80
+ "agent_prompt"
81
+ ],
82
+ "description": "The `pytest` the prompt tells the agent to run from the repository root (first on the agent PATH)."
83
+ },
84
+ {
85
+ "id": "git",
86
+ "executable": "git",
87
+ "role": "system",
88
+ "discovery": "static",
89
+ "version_probe": {
90
+ "argv": [
91
+ "git",
92
+ "--version"
93
+ ],
94
+ "regex": "git version (\\d+\\.\\d+\\.\\d+)"
95
+ },
96
+ "required_by": [
97
+ "grader:env.py",
98
+ "grader:tests/test_env.py"
99
+ ],
100
+ "description": "Reference-tree materialization and workspace snapshot in env.py."
101
+ },
102
+ {
103
+ "id": "setpriv",
104
+ "executable": "setpriv",
105
+ "role": "system",
106
+ "discovery": "dynamic",
107
+ "version_probe": {
108
+ "argv": [
109
+ "setpriv",
110
+ "--version"
111
+ ],
112
+ "regex": "(\\d+\\.\\d+(?:\\.\\d+)?)"
113
+ },
114
+ "required_by": [
115
+ "grader:env.py"
116
+ ],
117
+ "description": "UID wall: UidWallWorkspace.shell_argv prefixes the agent shell with setpriv."
118
+ },
119
+ {
120
+ "id": "hud",
121
+ "executable": "hud",
122
+ "role": "system",
123
+ "discovery": "dynamic",
124
+ "version_probe": {
125
+ "argv": [
126
+ "hud",
127
+ "--version"
128
+ ],
129
+ "regex": "(\\d+\\.\\d+\\.\\d+)"
130
+ },
131
+ "required_by": [
132
+ "grader:env.py"
133
+ ],
134
+ "description": "The HUD server the image CMD runs (`hud serve env:env`)."
135
+ }
136
+ ],
137
+ "services": []
138
+ },
139
+ "runtime_build_inputs": {
140
+ "base_images": [
141
+ {
142
+ "stage": "runtime-contract",
143
+ "reference": "ubuntu:24.04@sha256:224a1869083a311ef3f13648a154ba79832fbef6364d31493642ca03082da254"
144
+ },
145
+ {
146
+ "stage": "runtime-contract",
147
+ "reference": "ghcr.io/astral-sh/uv:0.12.3@sha256:2d890623d310b57771ce840f0da5eed5fc6d657da05ffaa45d82797b53fa3abc"
148
+ }
149
+ ],
150
+ "package_repositories": [
151
+ {
152
+ "manager": "apt",
153
+ "snapshot": "20260915T000000Z"
154
+ },
155
+ {
156
+ "manager": "pip",
157
+ "snapshot": "runtime/aioftp-dev-requirements.txt (uv pip compile --generate-hashes --exclude-newer 2026-09-15T00:00:00Z, installed --require-hashes) and uv.lock (uv sync --frozen)"
158
+ }
159
+ ],
160
+ "artifacts": [
161
+ {
162
+ "id": "cpython_3_11_15",
163
+ "version": "3.11.15+20260807",
164
+ "source": "https://releases.astral.sh/github/python-build-standalone/releases/download/20260807/cpython-3.11.15%2B20260807-x86_64-unknown-linux-gnu-install_only_stripped.tar.gz",
165
+ "sha256": "69dfac9d0f15a0b9281a38486f212cbf76421609228c184dc0d34a0533d57ba6"
166
+ }
167
+ ]
168
+ },
169
+ "deployment_context": {
170
+ "required_files": [
171
+ ".dockerignore",
172
+ ".gitignore",
173
+ "Dockerfile.hud",
174
+ "env.py",
175
+ "gold.diff",
176
+ "grading/__init__.py",
177
+ "grading/adversarial-manifest.json",
178
+ "grading/baseline/pyproject.toml",
179
+ "grading/baseline/tests/conftest.py",
180
+ "grading/baseline/tests/test_abort.py",
181
+ "grading/baseline/tests/test_client_side_socks.py",
182
+ "grading/baseline/tests/test_connection.py",
183
+ "grading/baseline/tests/test_corner_cases.py",
184
+ "grading/baseline/tests/test_current_directory.py",
185
+ "grading/baseline/tests/test_directory_actions.py",
186
+ "grading/baseline/tests/test_extra.py",
187
+ "grading/baseline/tests/test_file.py",
188
+ "grading/baseline/tests/test_list_fallback.py",
189
+ "grading/baseline/tests/test_login.py",
190
+ "grading/baseline/tests/test_maximum_connections.py",
191
+ "grading/baseline/tests/test_passive.py",
192
+ "grading/baseline/tests/test_pathio.py",
193
+ "grading/baseline/tests/test_permissions.py",
194
+ "grading/baseline/tests/test_restart.py",
195
+ "grading/baseline/tests/test_simple_functions.py",
196
+ "grading/baseline/tests/test_throttle.py",
197
+ "grading/baseline/tests/test_tls.py",
198
+ "grading/baseline/tests/test_user.py",
199
+ "grading/graders.py",
200
+ "grading/integrity.py",
201
+ "grading/probes/client_probe.py",
202
+ "grading/probes/hudprobe_common.py",
203
+ "grading/probes/hudprobe_fixture.py",
204
+ "grading/probes/server_probe.py",
205
+ "grading/regression.py",
206
+ "grading/runner.py",
207
+ "pyproject.toml",
208
+ "runtime/aioftp-dev-requirements.txt",
209
+ "task/__init__.py",
210
+ "task/prompt.md",
211
+ "task/rubric.md",
212
+ "tasks.py",
213
+ "uv.lock"
214
+ ],
215
+ "forbidden_files": [
216
+ "artifact-manifest.json",
217
+ "scaffold-manifest.json"
218
+ ],
219
+ "forbidden_directories": [
220
+ "grading/adversarial",
221
+ "tests",
222
+ ".venv"
223
+ ]
224
+ },
225
+ "safety_gate_mutants": [
226
+ {
227
+ "id": "g1_abort_takes_completion_as_reply",
228
+ "target_gate_id": "G1_stale_reply_after_abort",
229
+ "target_criteria": [
230
+ "client_abort_after_completed_transfer"
231
+ ],
232
+ "cue_preserving": true,
233
+ "cue_tokens_required_present": [
234
+ "abort",
235
+ "ABOR",
236
+ "225",
237
+ "226",
238
+ "426",
239
+ "1xx",
240
+ "final reply",
241
+ "_transfer_stream"
242
+ ],
243
+ "patch_path": "grading/adversarial/patches/g1_abort_takes_completion_as_reply.diff",
244
+ "applies_to": "gold",
245
+ "description": "Gold whose abort() reads the transfer's final reply first and, when it is a 2xx, takes it as the ABOR reply itself (dropping the ABOR reply from the owed ledger); the error exit keeps an independent drain-any-code path. The cue tokens stay in code and comments. After a completed transfer the 226 Transfer complete is taken as the ABOR reply and the successor PWD reads the stale ABOR reply: client_abort_after_completed_transfer is lost, and client_abort_idle_rejected with it (the 500 ABOR reply after a completed transfer is never read, so abort() does not raise). Raw 0.9120, capped at 0.60.",
246
+ "expected": {
247
+ "target_raw_leaf_max": 0.0,
248
+ "gate_statuses": {
249
+ "G1_stale_reply_after_abort": false,
250
+ "G2_stale_reply_after_error_exit": true,
251
+ "G3_stale_data_connection_after_abort": true,
252
+ "G4_stale_reply_after_cancelled_finish": true
253
+ },
254
+ "safety_gates_failed": true,
255
+ "build_failed": false,
256
+ "raw_score": 0.8786,
257
+ "final_score": 0.6,
258
+ "final_score_cap": 0.6,
259
+ "unaffected_criteria": [
260
+ "server_early_abort_session",
261
+ "client_stream_exit_after_abort",
262
+ "client_abort_idle_225",
263
+ "client_abort_after_failed_transfer",
264
+ "client_error_exit_mid_transfer",
265
+ "client_error_exit_after_completed_transfer",
266
+ "client_upload_stream_abort",
267
+ "client_abort_concurrent",
268
+ "client_cancelled_abort_or_finish",
269
+ "client_abort_during_finish",
270
+ "client_abandoned_listing_resync",
271
+ "server_listener_release_after_abort",
272
+ "server_repeated_abor_order",
273
+ "server_pipelined_command_order",
274
+ "server_real_client_abor",
275
+ "server_quit_during_transfer",
276
+ "server_data_connection_loss",
277
+ "server_undecodable_command_syntax",
278
+ "client_abort_after_cancelled_finish",
279
+ "server_pipelined_abort_open_data",
280
+ "server_pipelined_quit_open_data",
281
+ "client_nowait_abort_owed_replies",
282
+ "client_command_during_abort"
283
+ ]
284
+ }
285
+ },
286
+ {
287
+ "id": "g2_error_exit_drain_expects_426",
288
+ "target_gate_id": "G2_stale_reply_after_error_exit",
289
+ "target_criteria": [
290
+ "client_error_exit_after_completed_transfer"
291
+ ],
292
+ "cue_preserving": true,
293
+ "cue_tokens_required_present": [
294
+ "__aexit__",
295
+ "abort",
296
+ "ABOR",
297
+ "226",
298
+ "225",
299
+ "Transfer complete",
300
+ "_transfer_stream"
301
+ ],
302
+ "patch_path": "grading/adversarial/patches/g2_error_exit_drain_expects_426.diff",
303
+ "applies_to": "gold",
304
+ "description": "Gold whose __aexit__ exception branch closes the data connection and finishes expecting 426; the cue tokens stay in code and comments. After a completed transfer the drain meets 226 Transfer complete and raises, replacing the caller's exception: only client_error_exit_after_completed_transfer is lost, raw 0.9932, capped at 0.60.",
305
+ "expected": {
306
+ "target_raw_leaf_max": 0.0,
307
+ "gate_statuses": {
308
+ "G1_stale_reply_after_abort": true,
309
+ "G2_stale_reply_after_error_exit": false,
310
+ "G3_stale_data_connection_after_abort": true,
311
+ "G4_stale_reply_after_cancelled_finish": true
312
+ },
313
+ "safety_gates_failed": true,
314
+ "build_failed": false,
315
+ "raw_score": 0.9393,
316
+ "final_score": 0.6,
317
+ "final_score_cap": 0.6,
318
+ "unaffected_criteria": [
319
+ "server_early_abort_session",
320
+ "client_stream_exit_after_abort",
321
+ "client_abort_after_completed_transfer",
322
+ "client_abort_idle_225",
323
+ "client_abort_after_failed_transfer",
324
+ "client_error_exit_mid_transfer",
325
+ "client_abort_idle_rejected",
326
+ "client_upload_stream_abort",
327
+ "client_abort_concurrent",
328
+ "client_cancelled_abort_or_finish",
329
+ "client_abort_during_finish",
330
+ "client_abandoned_listing_resync",
331
+ "server_listener_release_after_abort",
332
+ "server_repeated_abor_order",
333
+ "server_pipelined_command_order",
334
+ "server_real_client_abor",
335
+ "server_quit_during_transfer",
336
+ "server_data_connection_loss",
337
+ "server_undecodable_command_syntax",
338
+ "client_abort_after_cancelled_finish",
339
+ "server_pipelined_abort_open_data",
340
+ "server_pipelined_quit_open_data",
341
+ "client_nowait_abort_owed_replies",
342
+ "client_command_during_abort"
343
+ ]
344
+ }
345
+ },
346
+ {
347
+ "id": "g3_listener_kept_after_abort",
348
+ "target_gate_id": "G3_stale_data_connection_after_abort",
349
+ "target_criteria": [
350
+ "server_listener_release_after_abort"
351
+ ],
352
+ "cue_preserving": true,
353
+ "cue_tokens_required_present": [
354
+ "passive",
355
+ "data_ports",
356
+ "_release_passive_server",
357
+ "426",
358
+ "226",
359
+ "abort"
360
+ ],
361
+ "patch_path": "grading/adversarial/patches/g3_listener_kept_after_abort.diff",
362
+ "applies_to": "gold",
363
+ "description": "Gold whose cancelled transfer worker keeps the passive listener (and its data_ports entry) for the next transfer instead of releasing it; the release helper and the cue tokens stay in code and comments. A data connection arriving late for the aborted transfer is still accepted and kept: only server_listener_release_after_abort is lost, raw 0.9188, capped at 0.60.",
364
+ "expected": {
365
+ "target_raw_leaf_max": 0.0,
366
+ "gate_statuses": {
367
+ "G1_stale_reply_after_abort": true,
368
+ "G2_stale_reply_after_error_exit": true,
369
+ "G3_stale_data_connection_after_abort": false,
370
+ "G4_stale_reply_after_cancelled_finish": true
371
+ },
372
+ "safety_gates_failed": true,
373
+ "build_failed": false,
374
+ "raw_score": 0.9835,
375
+ "final_score": 0.6,
376
+ "final_score_cap": 0.6,
377
+ "unaffected_criteria": [
378
+ "server_early_abort_session",
379
+ "client_stream_exit_after_abort",
380
+ "client_abort_after_completed_transfer",
381
+ "client_abort_idle_225",
382
+ "client_abort_after_failed_transfer",
383
+ "client_error_exit_mid_transfer",
384
+ "client_error_exit_after_completed_transfer",
385
+ "client_abort_idle_rejected",
386
+ "client_upload_stream_abort",
387
+ "client_abort_concurrent",
388
+ "client_cancelled_abort_or_finish",
389
+ "client_abort_during_finish",
390
+ "client_abandoned_listing_resync",
391
+ "server_repeated_abor_order",
392
+ "server_pipelined_command_order",
393
+ "server_real_client_abor",
394
+ "server_quit_during_transfer",
395
+ "server_data_connection_loss",
396
+ "server_undecodable_command_syntax",
397
+ "client_abort_after_cancelled_finish",
398
+ "server_pipelined_abort_open_data",
399
+ "server_pipelined_quit_open_data",
400
+ "client_nowait_abort_owed_replies",
401
+ "client_command_during_abort"
402
+ ]
403
+ }
404
+ },
405
+ {
406
+ "id": "g4_abort_settles_cancelled_finish_first",
407
+ "target_gate_id": "G4_stale_reply_after_cancelled_finish",
408
+ "target_criteria": [
409
+ "client_abort_after_cancelled_finish"
410
+ ],
411
+ "cue_preserving": true,
412
+ "cue_tokens_required_present": [
413
+ "abort",
414
+ "finish",
415
+ "ABOR",
416
+ "_owed_replies",
417
+ "_drain_owed_replies",
418
+ "cancel"
419
+ ],
420
+ "patch_path": "grading/adversarial/patches/g4_abort_settles_cancelled_finish_first.diff",
421
+ "applies_to": "gold",
422
+ "description": "Gold whose abort(), when a cancelled finish() left a transfer's final reply owed and nothing else holds the control lock, first reads that owed reply and only then writes ABOR. Against a server that sends the transfer's final reply only once ABOR arrives, abort() blocks permanently (the mechanism of 9065889c candidates c397 and c7e9). CASE-12 still passes because a running finish() holds the lock. Only client_abort_after_cancelled_finish is lost: raw 0.8000, capped at 0.60 by G4.",
423
+ "expected": {
424
+ "target_raw_leaf_max": 0.0,
425
+ "gate_statuses": {
426
+ "G1_stale_reply_after_abort": true,
427
+ "G2_stale_reply_after_error_exit": true,
428
+ "G3_stale_data_connection_after_abort": true,
429
+ "G4_stale_reply_after_cancelled_finish": false
430
+ },
431
+ "safety_gates_failed": true,
432
+ "build_failed": false,
433
+ "raw_score": 0.9737,
434
+ "final_score": 0.6,
435
+ "final_score_cap": 0.6,
436
+ "unaffected_criteria": [
437
+ "server_early_abort_session",
438
+ "client_stream_exit_after_abort",
439
+ "client_abort_after_completed_transfer",
440
+ "client_abort_idle_225",
441
+ "client_abort_after_failed_transfer",
442
+ "client_error_exit_mid_transfer",
443
+ "client_error_exit_after_completed_transfer",
444
+ "client_abort_idle_rejected",
445
+ "client_upload_stream_abort",
446
+ "client_abort_concurrent",
447
+ "client_cancelled_abort_or_finish",
448
+ "client_abort_during_finish",
449
+ "client_abandoned_listing_resync",
450
+ "server_repeated_abor_order",
451
+ "server_pipelined_command_order",
452
+ "server_real_client_abor",
453
+ "server_quit_during_transfer",
454
+ "server_data_connection_loss",
455
+ "server_undecodable_command_syntax",
456
+ "server_listener_release_after_abort",
457
+ "server_pipelined_abort_open_data",
458
+ "server_pipelined_quit_open_data",
459
+ "client_nowait_abort_owed_replies",
460
+ "client_command_during_abort"
461
+ ]
462
+ }
463
+ }
464
+ ],
465
+ "keyword_stuffing_fixtures": [
466
+ {
467
+ "id": "keyword_stuffing_all_cues",
468
+ "patch_path": "grading/adversarial/patches/keyword_stuffing_all_cues.diff",
469
+ "target_files": [
470
+ "src/aioftp/client.py",
471
+ "src/aioftp/server.py"
472
+ ],
473
+ "applies_to": "base",
474
+ "description": "Base plus comments carrying every Negative-controls cue token of the fifteen criteria next to Client.abort and Server.abor, the two files the probes import from the graded copy. No behaviour changes.",
475
+ "expected": {
476
+ "final_score": 0.0,
477
+ "raw_score": 0.0,
478
+ "build_failed": false
479
+ }
480
+ }
481
+ ],
482
+ "quality_bypass_fixtures": [
483
+ {
484
+ "id": "quality_bypass_stub_with_weakened_settings",
485
+ "patch_path": "grading/adversarial/patches/quality_bypass_stub_with_weakened_settings.diff",
486
+ "applies_to": "base",
487
+ "description": "The stub/echo control plus a pyproject.toml addopts entry deselecting tests/test_abort.py and a tests/conftest.py collection hook that skips every abort test. The grader restores the pristine settings, so tests/test_abort.py fails, the 0.30 regression ceiling fires, and the diagnostic names addopts (weakened) and tests/conftest.py (changed).",
488
+ "expected": {
489
+ "build_failed": true,
490
+ "raw_score": 0.0,
491
+ "final_score": 0.0,
492
+ "final_score_cap": 0.3
493
+ }
494
+ }
495
+ ],
496
+ "broken_regression_fixtures": [
497
+ {
498
+ "id": "broken_regression_no_wait_reads_reply",
499
+ "patch_path": "grading/adversarial/patches/broken_regression_no_wait_reads_reply.diff",
500
+ "applies_to": "gold",
501
+ "description": "Gold with abort(wait=False) changed to read a reply, which breaks tests/test_abort.py::test_abort_retr_no_wait. Every probe still passes: raw 1.0000, final 0.30.",
502
+ "expected": {
503
+ "build_failed": true,
504
+ "native_checks_pass": false,
505
+ "safety_gates_failed": false,
506
+ "raw_score": 1.0,
507
+ "final_score": 0.3,
508
+ "final_score_cap": 0.3
509
+ }
510
+ }
511
+ ],
512
+ "no_op_fixtures": [
513
+ {
514
+ "id": "no_op_comment_in_client",
515
+ "patch_path": "grading/adversarial/patches/no_op_comment_in_client.diff",
516
+ "applies_to": "base",
517
+ "description": "A comment-only edit to src/aioftp/client.py, the client module every client probe imports.",
518
+ "expected": {
519
+ "final_score": 0.0,
520
+ "raw_score": 0.0,
521
+ "build_failed": false
522
+ }
523
+ }
524
+ ],
525
+ "lazy_fix_fixtures": [
526
+ {
527
+ "id": "lazy_fix_decorators_and_225",
528
+ "patch_path": "grading/adversarial/patches/lazy_fix_decorators_and_225.diff",
529
+ "applies_to": "base",
530
+ "description": "Own patch against base: the server's @worker decorator moved outermost on the four transfer handlers, and 225 added to abort()'s accepted codes. Nothing else. Approved Solution-level profile: server_early_abort_session and client_abort_idle_225 1.0, every other criterion 0.0 (its base abor handler cancels the closing worker again on a repeated ABOR, so CASE-15 is lost too); raw 0.0826, final 0.0826, inside [0.02, 0.30]. The gated children score 0, so all four gates are recorded as fired, but their shared 0.60 ceiling does not bind (final equals raw): the score is partial credit alone.",
531
+ "expected": {
532
+ "criteria_profile": {
533
+ "server_early_abort_session": 1.0,
534
+ "client_stream_exit_after_abort": 0.0,
535
+ "client_abort_after_completed_transfer": 0.0,
536
+ "client_abort_idle_225": 1.0,
537
+ "client_abort_after_failed_transfer": 0.0,
538
+ "client_error_exit_mid_transfer": 0.0,
539
+ "client_error_exit_after_completed_transfer": 0.0,
540
+ "client_abort_idle_rejected": 0.0,
541
+ "client_upload_stream_abort": 0.0,
542
+ "client_abort_concurrent": 0.0,
543
+ "client_cancelled_abort_or_finish": 0.0,
544
+ "client_abort_during_finish": 0.0,
545
+ "client_abandoned_listing_resync": 0.0,
546
+ "server_listener_release_after_abort": 0.0,
547
+ "server_repeated_abor_order": 0.0,
548
+ "server_pipelined_command_order": 0.0,
549
+ "server_real_client_abor": 0.0,
550
+ "server_quit_during_transfer": 0.0,
551
+ "server_data_connection_loss": 0.0,
552
+ "server_undecodable_command_syntax": 0.0,
553
+ "client_abort_after_cancelled_finish": 0.0,
554
+ "server_pipelined_abort_open_data": 0.0,
555
+ "server_pipelined_quit_open_data": 0.0,
556
+ "client_nowait_abort_owed_replies": 0.0,
557
+ "client_command_during_abort": 0.0
558
+ },
559
+ "final_score_min": 0.02,
560
+ "final_score_max": 0.3,
561
+ "raw_score": 0.0266,
562
+ "final_score": 0.0266,
563
+ "build_failed": false,
564
+ "safety_gates_failed": true
565
+ }
566
+ }
567
+ ],
568
+ "competent_partial_fixtures": [
569
+ {
570
+ "id": "competent_partial_naive_abort",
571
+ "patch_path": "grading/adversarial/patches/competent_partial_naive_abort.diff",
572
+ "applies_to": "base",
573
+ "description": "The semantic viability screen's shortest_competent_solution, written from the prompt: accept 225, swap the server decorators, make finish() return after abort(), and abort on an exception exit (about twenty lines). Band = the `Projected raw mean: 0.476` of the fifteen-case refit in intake/difficulty-rationale.md, +/- 0.15. Measured: it earns CASE-01, 02, 04, 06, 09 and CASE-21 (its abort() writes ABOR at once and finish() returns after abort(), so the cancelled-finish scenario passes): raw 0.2908, inside the band.",
574
+ "expected": {
575
+ "final_score_min": 0.068,
576
+ "final_score_max": 0.432
577
+ }
578
+ }
579
+ ],
580
+ "stub_echo_fixtures": [
581
+ {
582
+ "id": "stub_echo_constant_entrypoints",
583
+ "patch_path": "grading/adversarial/patches/stub_echo_constant_entrypoints.diff",
584
+ "applies_to": "base",
585
+ "description": "Client.abort() returns None without I/O, finish() and __aexit__ only close, and Server.abor returns True without replying.",
586
+ "expected": {
587
+ "final_score": 0.0,
588
+ "raw_score": 0.0,
589
+ "all_behavioural_children_zero": true
590
+ }
591
+ }
592
+ ],
593
+ "alternate_correct_fixtures": [
594
+ {
595
+ "id": "alternate_a_counter_and_cancel_guard",
596
+ "patch_path": "grading/adversarial/patches/alternate_a_counter_and_cancel_guard.diff",
597
+ "applies_to": "base",
598
+ "independence": "structural",
599
+ "purpose": "Independent implementation A. Every exchange takes an integer turn number in wire order; replies are read in turn order under a reader lock and a reply read on behalf of a cancelled or later owner is kept for it (_early_replies). Owed transfer replies are a per-client integer count (_pending_final_replies) plus a turn reserved by abort(wait=False); the owed reply is read through a private Client method (_drain_outstanding_reply) and abort stays on Client. An abandoned transfer is aborted by the next command and by the lister's aclose(). The server answers an abort that lands before the data connection by catching CancelledError around each transfer worker task (releasing the listener and its port there), refuses late data connections in the passive handlers, and answers a repeated ABOR after the running one through Task.cancelling(). Rules out coupling to gold's stream reference, its Boolean marker, its owed-reply deque, abort's placement on BaseClient, the write/control lock pair, the aborting_workers set and the decorator order.",
600
+ "materiality": {
601
+ "min_non_comment_changed_lines": 120,
602
+ "min_files_touched": 2,
603
+ "max_gold_added_line_overlap_ratio": 0.3,
604
+ "min_gold_delta_lines": 120,
605
+ "forbidden_added_symbols": [
606
+ "_transfer_stream",
607
+ "final_reply_consumed",
608
+ "_owed_replies",
609
+ "aborting_workers"
610
+ ]
611
+ },
612
+ "independence_axes": {
613
+ "callable_surface": {
614
+ "rationale": "The owed reply is read by the private Client._drain_outstanding_reply and abort() stays on Client; gold moves abort to BaseClient and reads through _exchange/_read_owed."
615
+ },
616
+ "persistence_layout": {
617
+ "rationale": "State is BaseClient._pending_final_replies (a counter) plus integer turn counters and an _early_replies map, instead of gold's BaseClient._transfer_stream stream reference and _owed_replies deque of tuples.",
618
+ "gold_literals_absent": [
619
+ "_transfer_stream",
620
+ "_owed_replies"
621
+ ]
622
+ },
623
+ "marker_representation": {
624
+ "rationale": "Integer turn numbers and a count replace gold's per-stream Boolean final_reply_consumed.",
625
+ "gold_literals_absent": [
626
+ "final_reply_consumed"
627
+ ]
628
+ }
629
+ },
630
+ "expected": {
631
+ "final_score": 1.0,
632
+ "raw_score": 1.0,
633
+ "build_failed": false,
634
+ "safety_gates_failed": false
635
+ }
636
+ },
637
+ {
638
+ "id": "alternate_b_ledger_module_and_drain_exit",
639
+ "patch_path": "grading/adversarial/patches/alternate_b_ledger_module_and_drain_exit.diff",
640
+ "applies_to": "base",
641
+ "independence": "structural",
642
+ "purpose": "Independent implementation B. Reply ownership lives in a new private module (src/aioftp/_replies.py: ReplyLedger with Slip records, tickets, reservation and an ordered collector) used by client.py; finish() is idempotent through a None ticket sentinel; the stream's exception exit, the lister's aclose() and the next command after an abandoned transfer all close the data connection and drain the owed final reply with any code without sending ABOR; the server waits for the data connection inside the abortable worker (dropping the listener and returning its port when cancelled there) and its abor handler counts live workers, answering a repeated ABOR after the running one. Rules out coupling to gold's module composition and to abort() as the error-exit and settle seam.",
643
+ "materiality": {
644
+ "min_non_comment_changed_lines": 150,
645
+ "min_files_touched": 3,
646
+ "max_gold_added_line_overlap_ratio": 0.2,
647
+ "min_gold_delta_lines": 120,
648
+ "forbidden_added_symbols": [
649
+ "_transfer_stream",
650
+ "final_reply_consumed",
651
+ "_owed_replies",
652
+ "aborting_workers"
653
+ ]
654
+ },
655
+ "independence_axes": {
656
+ "module_composition": {
657
+ "rationale": "Reply bookkeeping is a new private module src/aioftp/_replies.py imported by client.py; gold keeps everything inside client.py and server.py."
658
+ },
659
+ "injection_seam": {
660
+ "rationale": "The exception exit, aclose() and the settle of an abandoned transfer close the data connection and drain the owed final reply with any code, without calling abort() or sending ABOR; gold's exit, aclose() and settle call abort()."
661
+ }
662
+ },
663
+ "expected": {
664
+ "final_score": 1.0,
665
+ "raw_score": 1.0,
666
+ "build_failed": false,
667
+ "safety_gates_failed": false
668
+ }
669
+ }
670
+ ],
671
+ "malformed_output_fault_injections": [
672
+ {
673
+ "id": "delete_client_probe",
674
+ "kind": "delete_file",
675
+ "target": "grading/probes/client_probe.py",
676
+ "expected": {
677
+ "is_error": true,
678
+ "reward": 0.0
679
+ }
680
+ },
681
+ {
682
+ "id": "corrupt_probe_fixture",
683
+ "kind": "corrupt_file",
684
+ "target": "grading/probes/hudprobe_fixture.py",
685
+ "expected": {
686
+ "is_error": true,
687
+ "reward": 0.0
688
+ }
689
+ },
690
+ {
691
+ "id": "corrupt_scoring_module",
692
+ "kind": "corrupt_file",
693
+ "target": "grading/graders.py",
694
+ "expected": {
695
+ "is_error": true,
696
+ "reward": 0.0
697
+ }
698
+ }
699
+ ],
700
+ "keyword_stuffing_gold_fixtures": [
701
+ {
702
+ "id": "ksg_server_decorators_restored",
703
+ "patch_path": "grading/adversarial/patches/ksg_server_decorators_restored.diff",
704
+ "applies_to": "gold",
705
+ "description": "Gold with ConnectionConditions restored outermost on the four transfer handlers; the listener release and the cue tokens stay in code and comments. A transfer cancelled before its data connection (ABOR or QUIT) is not answered and the session drops: server_early_abort_session, server_listener_release_after_abort, server_pipelined_command_order, server_quit_during_transfer are lost (G3 fires), raw 0.7830, final 0.60.",
706
+ "cue_tokens_required_present": [
707
+ "426",
708
+ "226",
709
+ "transfer aborted",
710
+ "abort successful",
711
+ "worker"
712
+ ],
713
+ "expected": {
714
+ "target_criteria": [
715
+ "server_early_abort_session",
716
+ "server_listener_release_after_abort",
717
+ "server_pipelined_command_order",
718
+ "server_quit_during_transfer"
719
+ ],
720
+ "target_raw_leaf_max": 0.0,
721
+ "criteria_profile": {
722
+ "server_early_abort_session": 0.0,
723
+ "client_stream_exit_after_abort": 1.0,
724
+ "client_abort_after_completed_transfer": 1.0,
725
+ "client_abort_idle_225": 1.0,
726
+ "client_abort_after_failed_transfer": 1.0,
727
+ "client_error_exit_mid_transfer": 1.0,
728
+ "client_error_exit_after_completed_transfer": 1.0,
729
+ "client_abort_idle_rejected": 1.0,
730
+ "client_upload_stream_abort": 1.0,
731
+ "client_abort_concurrent": 1.0,
732
+ "client_cancelled_abort_or_finish": 1.0,
733
+ "client_abort_during_finish": 1.0,
734
+ "client_abandoned_listing_resync": 1.0,
735
+ "server_listener_release_after_abort": 0.0,
736
+ "server_repeated_abor_order": 1.0,
737
+ "server_pipelined_command_order": 0.0,
738
+ "server_real_client_abor": 1.0,
739
+ "server_quit_during_transfer": 0.0,
740
+ "server_data_connection_loss": 1.0,
741
+ "server_undecodable_command_syntax": 1.0,
742
+ "client_abort_after_cancelled_finish": 1.0,
743
+ "server_pipelined_abort_open_data": 1.0,
744
+ "server_pipelined_quit_open_data": 1.0,
745
+ "client_nowait_abort_owed_replies": 1.0,
746
+ "client_command_during_abort": 1.0
747
+ },
748
+ "raw_score": 0.9557,
749
+ "final_score": 0.6,
750
+ "unaffected_criteria": [
751
+ "client_stream_exit_after_abort",
752
+ "client_abort_after_completed_transfer",
753
+ "client_abort_idle_225",
754
+ "client_abort_after_failed_transfer",
755
+ "client_error_exit_mid_transfer",
756
+ "client_error_exit_after_completed_transfer",
757
+ "client_abort_idle_rejected",
758
+ "client_upload_stream_abort",
759
+ "client_abort_concurrent",
760
+ "client_cancelled_abort_or_finish",
761
+ "client_abort_during_finish",
762
+ "client_abandoned_listing_resync",
763
+ "server_repeated_abor_order",
764
+ "server_real_client_abor",
765
+ "server_data_connection_loss",
766
+ "server_undecodable_command_syntax",
767
+ "client_abort_after_cancelled_finish",
768
+ "server_pipelined_abort_open_data",
769
+ "server_pipelined_quit_open_data",
770
+ "client_nowait_abort_owed_replies",
771
+ "client_command_during_abort"
772
+ ],
773
+ "build_failed": false,
774
+ "safety_gates_failed": true,
775
+ "gate_statuses": {
776
+ "G1_stale_reply_after_abort": true,
777
+ "G2_stale_reply_after_error_exit": true,
778
+ "G3_stale_data_connection_after_abort": false,
779
+ "G4_stale_reply_after_cancelled_finish": true
780
+ }
781
+ }
782
+ },
783
+ {
784
+ "id": "ksg_finish_unguarded",
785
+ "patch_path": "grading/adversarial/patches/ksg_finish_unguarded.diff",
786
+ "applies_to": "gold",
787
+ "description": "Gold whose finish() always reads a reply; cue tokens finish, abort, consumed and __aexit__ stay in code and comments. A block exit after abort() waits for a reply that never comes: client_stream_exit_after_abort, client_abort_concurrent, client_cancelled_abort_or_finish and client_abort_after_cancelled_finish are lost (G4 fires), raw 0.5474.",
788
+ "cue_tokens_required_present": [
789
+ "finish",
790
+ "abort",
791
+ "consumed",
792
+ "__aexit__"
793
+ ],
794
+ "expected": {
795
+ "target_criteria": [
796
+ "client_stream_exit_after_abort",
797
+ "client_abort_concurrent",
798
+ "client_cancelled_abort_or_finish",
799
+ "client_abort_after_cancelled_finish"
800
+ ],
801
+ "target_raw_leaf_max": 0.0,
802
+ "criteria_profile": {
803
+ "server_early_abort_session": 1.0,
804
+ "client_stream_exit_after_abort": 0.0,
805
+ "client_abort_after_completed_transfer": 1.0,
806
+ "client_abort_idle_225": 1.0,
807
+ "client_abort_after_failed_transfer": 1.0,
808
+ "client_error_exit_mid_transfer": 1.0,
809
+ "client_error_exit_after_completed_transfer": 1.0,
810
+ "client_abort_idle_rejected": 1.0,
811
+ "client_upload_stream_abort": 1.0,
812
+ "client_abort_concurrent": 0.0,
813
+ "client_cancelled_abort_or_finish": 0.0,
814
+ "client_abort_during_finish": 1.0,
815
+ "client_abandoned_listing_resync": 1.0,
816
+ "server_listener_release_after_abort": 1.0,
817
+ "server_repeated_abor_order": 1.0,
818
+ "server_pipelined_command_order": 1.0,
819
+ "server_real_client_abor": 1.0,
820
+ "server_quit_during_transfer": 1.0,
821
+ "server_data_connection_loss": 1.0,
822
+ "server_undecodable_command_syntax": 1.0,
823
+ "client_abort_after_cancelled_finish": 0.0,
824
+ "server_pipelined_abort_open_data": 1.0,
825
+ "server_pipelined_quit_open_data": 1.0,
826
+ "client_nowait_abort_owed_replies": 1.0,
827
+ "client_command_during_abort": 1.0
828
+ },
829
+ "raw_score": 0.9367,
830
+ "final_score": 0.6,
831
+ "unaffected_criteria": [
832
+ "server_early_abort_session",
833
+ "client_abort_after_completed_transfer",
834
+ "client_abort_idle_225",
835
+ "client_abort_after_failed_transfer",
836
+ "client_error_exit_mid_transfer",
837
+ "client_error_exit_after_completed_transfer",
838
+ "client_abort_idle_rejected",
839
+ "client_upload_stream_abort",
840
+ "client_abort_during_finish",
841
+ "client_abandoned_listing_resync",
842
+ "server_listener_release_after_abort",
843
+ "server_repeated_abor_order",
844
+ "server_pipelined_command_order",
845
+ "server_real_client_abor",
846
+ "server_quit_during_transfer",
847
+ "server_data_connection_loss",
848
+ "server_undecodable_command_syntax",
849
+ "server_pipelined_abort_open_data",
850
+ "server_pipelined_quit_open_data",
851
+ "client_nowait_abort_owed_replies",
852
+ "client_command_during_abort"
853
+ ],
854
+ "build_failed": false,
855
+ "safety_gates_failed": true,
856
+ "gate_statuses": {
857
+ "G1_stale_reply_after_abort": true,
858
+ "G2_stale_reply_after_error_exit": true,
859
+ "G3_stale_data_connection_after_abort": true,
860
+ "G4_stale_reply_after_cancelled_finish": false
861
+ }
862
+ }
863
+ },
864
+ {
865
+ "id": "ksg_idle_abort_rejects_225",
866
+ "patch_path": "grading/adversarial/patches/ksg_idle_abort_rejects_225.diff",
867
+ "applies_to": "gold",
868
+ "description": "Gold whose idle abort() accepts only 226; cue tokens 225, 226 and ABOR stay in code and comments. Only client_abort_idle_225 is lost, raw 0.9986.",
869
+ "cue_tokens_required_present": [
870
+ "225",
871
+ "226",
872
+ "ABOR"
873
+ ],
874
+ "expected": {
875
+ "target_criteria": [
876
+ "client_abort_idle_225"
877
+ ],
878
+ "target_raw_leaf_max": 0.0,
879
+ "criteria_profile": {
880
+ "server_early_abort_session": 1.0,
881
+ "client_stream_exit_after_abort": 1.0,
882
+ "client_abort_after_completed_transfer": 1.0,
883
+ "client_abort_idle_225": 0.0,
884
+ "client_abort_after_failed_transfer": 1.0,
885
+ "client_error_exit_mid_transfer": 1.0,
886
+ "client_error_exit_after_completed_transfer": 1.0,
887
+ "client_abort_idle_rejected": 1.0,
888
+ "client_upload_stream_abort": 1.0,
889
+ "client_abort_concurrent": 1.0,
890
+ "client_cancelled_abort_or_finish": 1.0,
891
+ "client_abort_during_finish": 1.0,
892
+ "client_abandoned_listing_resync": 1.0,
893
+ "server_listener_release_after_abort": 1.0,
894
+ "server_repeated_abor_order": 1.0,
895
+ "server_pipelined_command_order": 1.0,
896
+ "server_real_client_abor": 1.0,
897
+ "server_quit_during_transfer": 1.0,
898
+ "server_data_connection_loss": 1.0,
899
+ "server_undecodable_command_syntax": 1.0,
900
+ "client_abort_after_cancelled_finish": 1.0,
901
+ "server_pipelined_abort_open_data": 1.0,
902
+ "server_pipelined_quit_open_data": 1.0,
903
+ "client_nowait_abort_owed_replies": 1.0,
904
+ "client_command_during_abort": 1.0
905
+ },
906
+ "raw_score": 0.99,
907
+ "final_score": 0.99,
908
+ "unaffected_criteria": [
909
+ "server_early_abort_session",
910
+ "client_stream_exit_after_abort",
911
+ "client_abort_after_completed_transfer",
912
+ "client_abort_after_failed_transfer",
913
+ "client_error_exit_mid_transfer",
914
+ "client_error_exit_after_completed_transfer",
915
+ "client_abort_idle_rejected",
916
+ "client_upload_stream_abort",
917
+ "client_abort_concurrent",
918
+ "client_cancelled_abort_or_finish",
919
+ "client_abort_during_finish",
920
+ "client_abandoned_listing_resync",
921
+ "server_listener_release_after_abort",
922
+ "server_repeated_abor_order",
923
+ "server_pipelined_command_order",
924
+ "server_real_client_abor",
925
+ "server_quit_during_transfer",
926
+ "server_data_connection_loss",
927
+ "server_undecodable_command_syntax",
928
+ "client_abort_after_cancelled_finish",
929
+ "server_pipelined_abort_open_data",
930
+ "server_pipelined_quit_open_data",
931
+ "client_nowait_abort_owed_replies",
932
+ "client_command_during_abort"
933
+ ],
934
+ "build_failed": false,
935
+ "safety_gates_failed": false,
936
+ "gate_statuses": {
937
+ "G1_stale_reply_after_abort": true,
938
+ "G2_stale_reply_after_error_exit": true,
939
+ "G3_stale_data_connection_after_abort": true,
940
+ "G4_stale_reply_after_cancelled_finish": true
941
+ }
942
+ }
943
+ },
944
+ {
945
+ "id": "ksg_failed_transfer_code_checked",
946
+ "patch_path": "grading/adversarial/patches/ksg_failed_transfer_code_checked.diff",
947
+ "applies_to": "gold",
948
+ "description": "Gold whose abort() validates the owed final reply as 2xx or 426 (code-checked tracking); cue tokens abort, ABOR, 451, final reply and any code stay in code and comments. Only client_abort_after_failed_transfer is lost, raw 0.9932.",
949
+ "cue_tokens_required_present": [
950
+ "abort",
951
+ "ABOR",
952
+ "451",
953
+ "final reply",
954
+ "any code"
955
+ ],
956
+ "expected": {
957
+ "target_criteria": [
958
+ "client_abort_after_failed_transfer"
959
+ ],
960
+ "target_raw_leaf_max": 0.0,
961
+ "criteria_profile": {
962
+ "server_early_abort_session": 1.0,
963
+ "client_stream_exit_after_abort": 1.0,
964
+ "client_abort_after_completed_transfer": 1.0,
965
+ "client_abort_idle_225": 1.0,
966
+ "client_abort_after_failed_transfer": 0.0,
967
+ "client_error_exit_mid_transfer": 1.0,
968
+ "client_error_exit_after_completed_transfer": 1.0,
969
+ "client_abort_idle_rejected": 1.0,
970
+ "client_upload_stream_abort": 1.0,
971
+ "client_abort_concurrent": 1.0,
972
+ "client_cancelled_abort_or_finish": 1.0,
973
+ "client_abort_during_finish": 1.0,
974
+ "client_abandoned_listing_resync": 1.0,
975
+ "server_listener_release_after_abort": 1.0,
976
+ "server_repeated_abor_order": 1.0,
977
+ "server_pipelined_command_order": 1.0,
978
+ "server_real_client_abor": 1.0,
979
+ "server_quit_during_transfer": 1.0,
980
+ "server_data_connection_loss": 1.0,
981
+ "server_undecodable_command_syntax": 1.0,
982
+ "client_abort_after_cancelled_finish": 1.0,
983
+ "server_pipelined_abort_open_data": 1.0,
984
+ "server_pipelined_quit_open_data": 1.0,
985
+ "client_nowait_abort_owed_replies": 1.0,
986
+ "client_command_during_abort": 1.0
987
+ },
988
+ "raw_score": 0.9393,
989
+ "final_score": 0.9393,
990
+ "unaffected_criteria": [
991
+ "server_early_abort_session",
992
+ "client_stream_exit_after_abort",
993
+ "client_abort_after_completed_transfer",
994
+ "client_abort_idle_225",
995
+ "client_error_exit_mid_transfer",
996
+ "client_error_exit_after_completed_transfer",
997
+ "client_abort_idle_rejected",
998
+ "client_upload_stream_abort",
999
+ "client_abort_concurrent",
1000
+ "client_cancelled_abort_or_finish",
1001
+ "client_abort_during_finish",
1002
+ "client_abandoned_listing_resync",
1003
+ "server_listener_release_after_abort",
1004
+ "server_repeated_abor_order",
1005
+ "server_pipelined_command_order",
1006
+ "server_real_client_abor",
1007
+ "server_quit_during_transfer",
1008
+ "server_data_connection_loss",
1009
+ "server_undecodable_command_syntax",
1010
+ "client_abort_after_cancelled_finish",
1011
+ "server_pipelined_abort_open_data",
1012
+ "server_pipelined_quit_open_data",
1013
+ "client_nowait_abort_owed_replies",
1014
+ "client_command_during_abort"
1015
+ ],
1016
+ "build_failed": false,
1017
+ "safety_gates_failed": false,
1018
+ "gate_statuses": {
1019
+ "G1_stale_reply_after_abort": true,
1020
+ "G2_stale_reply_after_error_exit": true,
1021
+ "G3_stale_data_connection_after_abort": true,
1022
+ "G4_stale_reply_after_cancelled_finish": true
1023
+ }
1024
+ }
1025
+ },
1026
+ {
1027
+ "id": "ksg_error_exit_mid_transfer_finish_replaces",
1028
+ "patch_path": "grading/adversarial/patches/ksg_error_exit_mid_transfer_finish_replaces.diff",
1029
+ "applies_to": "gold",
1030
+ "description": "Gold whose __aexit__ exception branch finishes the stream instead of aborting; cue tokens __aexit__, abort, Exception and close stay in code and comments. Mid-transfer the finish meets 426 and its StatusCodeError replaces the caller's exception: client_error_exit_mid_transfer and client_upload_stream_abort are lost, raw 0.9938.",
1031
+ "cue_tokens_required_present": [
1032
+ "__aexit__",
1033
+ "abort",
1034
+ "Exception",
1035
+ "close"
1036
+ ],
1037
+ "expected": {
1038
+ "target_criteria": [
1039
+ "client_error_exit_mid_transfer",
1040
+ "client_upload_stream_abort"
1041
+ ],
1042
+ "target_raw_leaf_max": 0.0,
1043
+ "criteria_profile": {
1044
+ "server_early_abort_session": 1.0,
1045
+ "client_stream_exit_after_abort": 1.0,
1046
+ "client_abort_after_completed_transfer": 1.0,
1047
+ "client_abort_idle_225": 1.0,
1048
+ "client_abort_after_failed_transfer": 1.0,
1049
+ "client_error_exit_mid_transfer": 0.0,
1050
+ "client_error_exit_after_completed_transfer": 1.0,
1051
+ "client_abort_idle_rejected": 1.0,
1052
+ "client_upload_stream_abort": 0.0,
1053
+ "client_abort_concurrent": 1.0,
1054
+ "client_cancelled_abort_or_finish": 1.0,
1055
+ "client_abort_during_finish": 1.0,
1056
+ "client_abandoned_listing_resync": 1.0,
1057
+ "server_listener_release_after_abort": 1.0,
1058
+ "server_repeated_abor_order": 1.0,
1059
+ "server_pipelined_command_order": 1.0,
1060
+ "server_real_client_abor": 1.0,
1061
+ "server_quit_during_transfer": 1.0,
1062
+ "server_data_connection_loss": 1.0,
1063
+ "server_undecodable_command_syntax": 1.0,
1064
+ "client_abort_after_cancelled_finish": 1.0,
1065
+ "server_pipelined_abort_open_data": 1.0,
1066
+ "server_pipelined_quit_open_data": 1.0,
1067
+ "client_nowait_abort_owed_replies": 1.0,
1068
+ "client_command_during_abort": 1.0
1069
+ },
1070
+ "raw_score": 0.989,
1071
+ "final_score": 0.989,
1072
+ "unaffected_criteria": [
1073
+ "server_early_abort_session",
1074
+ "client_stream_exit_after_abort",
1075
+ "client_abort_after_completed_transfer",
1076
+ "client_abort_idle_225",
1077
+ "client_abort_after_failed_transfer",
1078
+ "client_error_exit_after_completed_transfer",
1079
+ "client_abort_idle_rejected",
1080
+ "client_abort_concurrent",
1081
+ "client_cancelled_abort_or_finish",
1082
+ "client_abort_during_finish",
1083
+ "client_abandoned_listing_resync",
1084
+ "server_listener_release_after_abort",
1085
+ "server_repeated_abor_order",
1086
+ "server_pipelined_command_order",
1087
+ "server_real_client_abor",
1088
+ "server_quit_during_transfer",
1089
+ "server_data_connection_loss",
1090
+ "server_undecodable_command_syntax",
1091
+ "client_abort_after_cancelled_finish",
1092
+ "server_pipelined_abort_open_data",
1093
+ "server_pipelined_quit_open_data",
1094
+ "client_nowait_abort_owed_replies",
1095
+ "client_command_during_abort"
1096
+ ],
1097
+ "build_failed": false,
1098
+ "safety_gates_failed": false,
1099
+ "gate_statuses": {
1100
+ "G1_stale_reply_after_abort": true,
1101
+ "G2_stale_reply_after_error_exit": true,
1102
+ "G3_stale_data_connection_after_abort": true,
1103
+ "G4_stale_reply_after_cancelled_finish": true
1104
+ }
1105
+ }
1106
+ },
1107
+ {
1108
+ "id": "ksg_rejected_abor_accepts_5xx",
1109
+ "patch_path": "grading/adversarial/patches/ksg_rejected_abor_accepts_5xx.diff",
1110
+ "applies_to": "gold",
1111
+ "description": "Gold whose abort() accepts a 5xx as the ABOR reply; cue tokens 225, 226, ABOR and 5xx stay in code and comments. abort() does not raise on 500: only client_abort_idle_rejected is lost, raw 0.9188.",
1112
+ "cue_tokens_required_present": [
1113
+ "225",
1114
+ "226",
1115
+ "ABOR",
1116
+ "5xx"
1117
+ ],
1118
+ "expected": {
1119
+ "target_criteria": [
1120
+ "client_abort_idle_rejected"
1121
+ ],
1122
+ "target_raw_leaf_max": 0.0,
1123
+ "criteria_profile": {
1124
+ "server_early_abort_session": 1.0,
1125
+ "client_stream_exit_after_abort": 1.0,
1126
+ "client_abort_after_completed_transfer": 1.0,
1127
+ "client_abort_idle_225": 1.0,
1128
+ "client_abort_after_failed_transfer": 1.0,
1129
+ "client_error_exit_mid_transfer": 1.0,
1130
+ "client_error_exit_after_completed_transfer": 1.0,
1131
+ "client_abort_idle_rejected": 0.0,
1132
+ "client_upload_stream_abort": 1.0,
1133
+ "client_abort_concurrent": 1.0,
1134
+ "client_cancelled_abort_or_finish": 1.0,
1135
+ "client_abort_during_finish": 1.0,
1136
+ "client_abandoned_listing_resync": 1.0,
1137
+ "server_listener_release_after_abort": 1.0,
1138
+ "server_repeated_abor_order": 1.0,
1139
+ "server_pipelined_command_order": 1.0,
1140
+ "server_real_client_abor": 1.0,
1141
+ "server_quit_during_transfer": 1.0,
1142
+ "server_data_connection_loss": 1.0,
1143
+ "server_undecodable_command_syntax": 1.0,
1144
+ "client_abort_after_cancelled_finish": 1.0,
1145
+ "server_pipelined_abort_open_data": 1.0,
1146
+ "server_pipelined_quit_open_data": 1.0,
1147
+ "client_nowait_abort_owed_replies": 1.0,
1148
+ "client_command_during_abort": 1.0
1149
+ },
1150
+ "raw_score": 0.9393,
1151
+ "final_score": 0.9393,
1152
+ "unaffected_criteria": [
1153
+ "server_early_abort_session",
1154
+ "client_stream_exit_after_abort",
1155
+ "client_abort_after_completed_transfer",
1156
+ "client_abort_idle_225",
1157
+ "client_abort_after_failed_transfer",
1158
+ "client_error_exit_mid_transfer",
1159
+ "client_error_exit_after_completed_transfer",
1160
+ "client_upload_stream_abort",
1161
+ "client_abort_concurrent",
1162
+ "client_cancelled_abort_or_finish",
1163
+ "client_abort_during_finish",
1164
+ "client_abandoned_listing_resync",
1165
+ "server_listener_release_after_abort",
1166
+ "server_repeated_abor_order",
1167
+ "server_pipelined_command_order",
1168
+ "server_real_client_abor",
1169
+ "server_quit_during_transfer",
1170
+ "server_data_connection_loss",
1171
+ "server_undecodable_command_syntax",
1172
+ "client_abort_after_cancelled_finish",
1173
+ "server_pipelined_abort_open_data",
1174
+ "server_pipelined_quit_open_data",
1175
+ "client_nowait_abort_owed_replies",
1176
+ "client_command_during_abort"
1177
+ ],
1178
+ "build_failed": false,
1179
+ "safety_gates_failed": false,
1180
+ "gate_statuses": {
1181
+ "G1_stale_reply_after_abort": true,
1182
+ "G2_stale_reply_after_error_exit": true,
1183
+ "G3_stale_data_connection_after_abort": true,
1184
+ "G4_stale_reply_after_cancelled_finish": true
1185
+ }
1186
+ }
1187
+ },
1188
+ {
1189
+ "id": "ksg_upload_exit_finishes",
1190
+ "patch_path": "grading/adversarial/patches/ksg_upload_exit_finishes.diff",
1191
+ "applies_to": "gold",
1192
+ "description": "Gold whose __aexit__ exception branch finishes an upload stream instead of aborting it (a marker set by upload_stream/append_stream); cue tokens upload_stream, STOR, __aexit__ and abort stay in code and comments. Only client_upload_stream_abort is lost, raw 0.9952.",
1193
+ "cue_tokens_required_present": [
1194
+ "upload_stream",
1195
+ "STOR",
1196
+ "__aexit__",
1197
+ "abort"
1198
+ ],
1199
+ "expected": {
1200
+ "target_criteria": [
1201
+ "client_upload_stream_abort"
1202
+ ],
1203
+ "target_raw_leaf_max": 0.0,
1204
+ "criteria_profile": {
1205
+ "server_early_abort_session": 1.0,
1206
+ "client_stream_exit_after_abort": 1.0,
1207
+ "client_abort_after_completed_transfer": 1.0,
1208
+ "client_abort_idle_225": 1.0,
1209
+ "client_abort_after_failed_transfer": 1.0,
1210
+ "client_error_exit_mid_transfer": 1.0,
1211
+ "client_error_exit_after_completed_transfer": 1.0,
1212
+ "client_abort_idle_rejected": 1.0,
1213
+ "client_upload_stream_abort": 0.0,
1214
+ "client_abort_concurrent": 1.0,
1215
+ "client_cancelled_abort_or_finish": 1.0,
1216
+ "client_abort_during_finish": 1.0,
1217
+ "client_abandoned_listing_resync": 1.0,
1218
+ "server_listener_release_after_abort": 1.0,
1219
+ "server_repeated_abor_order": 1.0,
1220
+ "server_pipelined_command_order": 1.0,
1221
+ "server_real_client_abor": 1.0,
1222
+ "server_quit_during_transfer": 1.0,
1223
+ "server_data_connection_loss": 1.0,
1224
+ "server_undecodable_command_syntax": 1.0,
1225
+ "client_abort_after_cancelled_finish": 1.0,
1226
+ "server_pipelined_abort_open_data": 1.0,
1227
+ "server_pipelined_quit_open_data": 1.0,
1228
+ "client_nowait_abort_owed_replies": 1.0,
1229
+ "client_command_during_abort": 1.0
1230
+ },
1231
+ "raw_score": 0.999,
1232
+ "final_score": 0.999,
1233
+ "unaffected_criteria": [
1234
+ "server_early_abort_session",
1235
+ "client_stream_exit_after_abort",
1236
+ "client_abort_after_completed_transfer",
1237
+ "client_abort_idle_225",
1238
+ "client_abort_after_failed_transfer",
1239
+ "client_error_exit_mid_transfer",
1240
+ "client_error_exit_after_completed_transfer",
1241
+ "client_abort_idle_rejected",
1242
+ "client_abort_concurrent",
1243
+ "client_cancelled_abort_or_finish",
1244
+ "client_abort_during_finish",
1245
+ "client_abandoned_listing_resync",
1246
+ "server_listener_release_after_abort",
1247
+ "server_repeated_abor_order",
1248
+ "server_pipelined_command_order",
1249
+ "server_real_client_abor",
1250
+ "server_quit_during_transfer",
1251
+ "server_data_connection_loss",
1252
+ "server_undecodable_command_syntax",
1253
+ "client_abort_after_cancelled_finish",
1254
+ "server_pipelined_abort_open_data",
1255
+ "server_pipelined_quit_open_data",
1256
+ "client_nowait_abort_owed_replies",
1257
+ "client_command_during_abort"
1258
+ ],
1259
+ "build_failed": false,
1260
+ "safety_gates_failed": false,
1261
+ "gate_statuses": {
1262
+ "G1_stale_reply_after_abort": true,
1263
+ "G2_stale_reply_after_error_exit": true,
1264
+ "G3_stale_data_connection_after_abort": true,
1265
+ "G4_stale_reply_after_cancelled_finish": true
1266
+ }
1267
+ }
1268
+ },
1269
+ {
1270
+ "id": "ksg_concurrent_abort_rejected",
1271
+ "patch_path": "grading/adversarial/patches/ksg_concurrent_abort_rejected.diff",
1272
+ "applies_to": "gold",
1273
+ "description": "Gold whose abort() raises RuntimeError while another abort() is in flight; cue tokens concurrent, serialized, abort and ABOR stay in code and comments. Only client_abort_concurrent is lost, raw 0.9932.",
1274
+ "cue_tokens_required_present": [
1275
+ "concurrent",
1276
+ "serialized",
1277
+ "abort",
1278
+ "ABOR"
1279
+ ],
1280
+ "expected": {
1281
+ "target_criteria": [
1282
+ "client_abort_concurrent"
1283
+ ],
1284
+ "target_raw_leaf_max": 0.0,
1285
+ "criteria_profile": {
1286
+ "server_early_abort_session": 1.0,
1287
+ "client_stream_exit_after_abort": 1.0,
1288
+ "client_abort_after_completed_transfer": 1.0,
1289
+ "client_abort_idle_225": 1.0,
1290
+ "client_abort_after_failed_transfer": 1.0,
1291
+ "client_error_exit_mid_transfer": 1.0,
1292
+ "client_error_exit_after_completed_transfer": 1.0,
1293
+ "client_abort_idle_rejected": 1.0,
1294
+ "client_upload_stream_abort": 1.0,
1295
+ "client_abort_concurrent": 0.0,
1296
+ "client_cancelled_abort_or_finish": 1.0,
1297
+ "client_abort_during_finish": 1.0,
1298
+ "client_abandoned_listing_resync": 1.0,
1299
+ "server_listener_release_after_abort": 1.0,
1300
+ "server_repeated_abor_order": 1.0,
1301
+ "server_pipelined_command_order": 1.0,
1302
+ "server_real_client_abor": 1.0,
1303
+ "server_quit_during_transfer": 1.0,
1304
+ "server_data_connection_loss": 1.0,
1305
+ "server_undecodable_command_syntax": 1.0,
1306
+ "client_abort_after_cancelled_finish": 1.0,
1307
+ "server_pipelined_abort_open_data": 1.0,
1308
+ "server_pipelined_quit_open_data": 1.0,
1309
+ "client_nowait_abort_owed_replies": 1.0,
1310
+ "client_command_during_abort": 1.0
1311
+ },
1312
+ "raw_score": 0.9986,
1313
+ "final_score": 0.9986,
1314
+ "unaffected_criteria": [
1315
+ "server_early_abort_session",
1316
+ "client_stream_exit_after_abort",
1317
+ "client_abort_after_completed_transfer",
1318
+ "client_abort_idle_225",
1319
+ "client_abort_after_failed_transfer",
1320
+ "client_error_exit_mid_transfer",
1321
+ "client_error_exit_after_completed_transfer",
1322
+ "client_abort_idle_rejected",
1323
+ "client_upload_stream_abort",
1324
+ "client_cancelled_abort_or_finish",
1325
+ "client_abort_during_finish",
1326
+ "client_abandoned_listing_resync",
1327
+ "server_listener_release_after_abort",
1328
+ "server_repeated_abor_order",
1329
+ "server_pipelined_command_order",
1330
+ "server_real_client_abor",
1331
+ "server_quit_during_transfer",
1332
+ "server_data_connection_loss",
1333
+ "server_undecodable_command_syntax",
1334
+ "client_abort_after_cancelled_finish",
1335
+ "server_pipelined_abort_open_data",
1336
+ "server_pipelined_quit_open_data",
1337
+ "client_nowait_abort_owed_replies",
1338
+ "client_command_during_abort"
1339
+ ],
1340
+ "build_failed": false,
1341
+ "safety_gates_failed": false,
1342
+ "gate_statuses": {
1343
+ "G1_stale_reply_after_abort": true,
1344
+ "G2_stale_reply_after_error_exit": true,
1345
+ "G3_stale_data_connection_after_abort": true,
1346
+ "G4_stale_reply_after_cancelled_finish": true
1347
+ }
1348
+ }
1349
+ },
1350
+ {
1351
+ "id": "ksg_cancelled_wait_forgets_replies",
1352
+ "patch_path": "grading/adversarial/patches/ksg_cancelled_wait_forgets_replies.diff",
1353
+ "applies_to": "gold",
1354
+ "description": "Gold whose abort() and finish() drop their owed replies from the ledger when cancelled; cue tokens cancel, owed, CancelledError, abort and finish stay in code and comments. The next command reads the stale 426 or 226: client_cancelled_abort_or_finish and client_abort_after_cancelled_finish are lost (G4 fires), raw 0.5562.",
1355
+ "cue_tokens_required_present": [
1356
+ "cancel",
1357
+ "owed",
1358
+ "CancelledError",
1359
+ "abort",
1360
+ "finish"
1361
+ ],
1362
+ "expected": {
1363
+ "target_criteria": [
1364
+ "client_cancelled_abort_or_finish",
1365
+ "client_abort_after_cancelled_finish"
1366
+ ],
1367
+ "target_raw_leaf_max": 0.0,
1368
+ "criteria_profile": {
1369
+ "server_early_abort_session": 1.0,
1370
+ "client_stream_exit_after_abort": 1.0,
1371
+ "client_abort_after_completed_transfer": 1.0,
1372
+ "client_abort_idle_225": 1.0,
1373
+ "client_abort_after_failed_transfer": 1.0,
1374
+ "client_error_exit_mid_transfer": 1.0,
1375
+ "client_error_exit_after_completed_transfer": 1.0,
1376
+ "client_abort_idle_rejected": 1.0,
1377
+ "client_upload_stream_abort": 1.0,
1378
+ "client_abort_concurrent": 1.0,
1379
+ "client_cancelled_abort_or_finish": 0.0,
1380
+ "client_abort_during_finish": 1.0,
1381
+ "client_abandoned_listing_resync": 1.0,
1382
+ "server_listener_release_after_abort": 1.0,
1383
+ "server_repeated_abor_order": 1.0,
1384
+ "server_pipelined_command_order": 1.0,
1385
+ "server_real_client_abor": 1.0,
1386
+ "server_quit_during_transfer": 1.0,
1387
+ "server_data_connection_loss": 1.0,
1388
+ "server_undecodable_command_syntax": 1.0,
1389
+ "client_abort_after_cancelled_finish": 0.0,
1390
+ "server_pipelined_abort_open_data": 1.0,
1391
+ "server_pipelined_quit_open_data": 1.0,
1392
+ "client_nowait_abort_owed_replies": 1.0,
1393
+ "client_command_during_abort": 1.0
1394
+ },
1395
+ "raw_score": 0.9385,
1396
+ "final_score": 0.6,
1397
+ "unaffected_criteria": [
1398
+ "server_early_abort_session",
1399
+ "client_stream_exit_after_abort",
1400
+ "client_abort_after_completed_transfer",
1401
+ "client_abort_idle_225",
1402
+ "client_abort_after_failed_transfer",
1403
+ "client_error_exit_mid_transfer",
1404
+ "client_error_exit_after_completed_transfer",
1405
+ "client_abort_idle_rejected",
1406
+ "client_upload_stream_abort",
1407
+ "client_abort_concurrent",
1408
+ "client_abort_during_finish",
1409
+ "client_abandoned_listing_resync",
1410
+ "server_listener_release_after_abort",
1411
+ "server_repeated_abor_order",
1412
+ "server_pipelined_command_order",
1413
+ "server_real_client_abor",
1414
+ "server_quit_during_transfer",
1415
+ "server_data_connection_loss",
1416
+ "server_undecodable_command_syntax",
1417
+ "server_pipelined_abort_open_data",
1418
+ "server_pipelined_quit_open_data",
1419
+ "client_nowait_abort_owed_replies",
1420
+ "client_command_during_abort"
1421
+ ],
1422
+ "build_failed": false,
1423
+ "safety_gates_failed": true,
1424
+ "gate_statuses": {
1425
+ "G1_stale_reply_after_abort": true,
1426
+ "G2_stale_reply_after_error_exit": true,
1427
+ "G3_stale_data_connection_after_abort": true,
1428
+ "G4_stale_reply_after_cancelled_finish": false
1429
+ }
1430
+ }
1431
+ },
1432
+ {
1433
+ "id": "ksg_abort_waits_for_control_lock",
1434
+ "patch_path": "grading/adversarial/patches/ksg_abort_waits_for_control_lock.diff",
1435
+ "applies_to": "gold",
1436
+ "description": "Gold whose abort() writes ABOR only under the control lock, like every other command; cue tokens control lock, ABOR, abort and finish stay in code and comments. While finish() waits for the transfer's final reply the ABOR is never sent and both calls hang: only client_abort_during_finish is lost, raw 0.9932.",
1437
+ "cue_tokens_required_present": [
1438
+ "control lock",
1439
+ "ABOR",
1440
+ "abort",
1441
+ "finish"
1442
+ ],
1443
+ "expected": {
1444
+ "target_criteria": [
1445
+ "client_abort_during_finish",
1446
+ "client_command_during_abort"
1447
+ ],
1448
+ "target_raw_leaf_max": 0.0,
1449
+ "criteria_profile": {
1450
+ "server_early_abort_session": 1.0,
1451
+ "client_stream_exit_after_abort": 1.0,
1452
+ "client_abort_after_completed_transfer": 1.0,
1453
+ "client_abort_idle_225": 1.0,
1454
+ "client_abort_after_failed_transfer": 1.0,
1455
+ "client_error_exit_mid_transfer": 1.0,
1456
+ "client_error_exit_after_completed_transfer": 1.0,
1457
+ "client_abort_idle_rejected": 1.0,
1458
+ "client_upload_stream_abort": 1.0,
1459
+ "client_abort_concurrent": 1.0,
1460
+ "client_cancelled_abort_or_finish": 1.0,
1461
+ "client_abort_during_finish": 0.0,
1462
+ "client_abandoned_listing_resync": 1.0,
1463
+ "server_listener_release_after_abort": 1.0,
1464
+ "server_repeated_abor_order": 1.0,
1465
+ "server_pipelined_command_order": 1.0,
1466
+ "server_real_client_abor": 1.0,
1467
+ "server_quit_during_transfer": 1.0,
1468
+ "server_data_connection_loss": 1.0,
1469
+ "server_undecodable_command_syntax": 1.0,
1470
+ "client_abort_after_cancelled_finish": 1.0,
1471
+ "server_pipelined_abort_open_data": 1.0,
1472
+ "server_pipelined_quit_open_data": 1.0,
1473
+ "client_nowait_abort_owed_replies": 1.0,
1474
+ "client_command_during_abort": 0.0
1475
+ },
1476
+ "raw_score": 0.9379,
1477
+ "final_score": 0.9379,
1478
+ "unaffected_criteria": [
1479
+ "server_early_abort_session",
1480
+ "client_stream_exit_after_abort",
1481
+ "client_abort_after_completed_transfer",
1482
+ "client_abort_idle_225",
1483
+ "client_abort_after_failed_transfer",
1484
+ "client_error_exit_mid_transfer",
1485
+ "client_error_exit_after_completed_transfer",
1486
+ "client_abort_idle_rejected",
1487
+ "client_upload_stream_abort",
1488
+ "client_abort_concurrent",
1489
+ "client_cancelled_abort_or_finish",
1490
+ "client_abandoned_listing_resync",
1491
+ "server_listener_release_after_abort",
1492
+ "server_repeated_abor_order",
1493
+ "server_pipelined_command_order",
1494
+ "server_real_client_abor",
1495
+ "server_quit_during_transfer",
1496
+ "server_data_connection_loss",
1497
+ "server_undecodable_command_syntax",
1498
+ "client_abort_after_cancelled_finish",
1499
+ "server_pipelined_abort_open_data",
1500
+ "server_pipelined_quit_open_data",
1501
+ "client_nowait_abort_owed_replies"
1502
+ ],
1503
+ "build_failed": false,
1504
+ "safety_gates_failed": false,
1505
+ "gate_statuses": {
1506
+ "G1_stale_reply_after_abort": true,
1507
+ "G2_stale_reply_after_error_exit": true,
1508
+ "G3_stale_data_connection_after_abort": true,
1509
+ "G4_stale_reply_after_cancelled_finish": true
1510
+ }
1511
+ }
1512
+ },
1513
+ {
1514
+ "id": "ksg_abandoned_transfer_not_settled",
1515
+ "patch_path": "grading/adversarial/patches/ksg_abandoned_transfer_not_settled.diff",
1516
+ "applies_to": "gold",
1517
+ "description": "Gold whose command() no longer settles an outstanding transfer and whose aclose() only closes the listing's data connection; cue tokens outstanding, settle, aclose, ABOR and get_stream stay in code and comments. Only client_abandoned_listing_resync is lost, raw 0.9945.",
1518
+ "cue_tokens_required_present": [
1519
+ "outstanding",
1520
+ "settle",
1521
+ "aclose",
1522
+ "ABOR",
1523
+ "get_stream"
1524
+ ],
1525
+ "expected": {
1526
+ "target_criteria": [
1527
+ "client_abandoned_listing_resync"
1528
+ ],
1529
+ "target_raw_leaf_max": 0.0,
1530
+ "criteria_profile": {
1531
+ "server_early_abort_session": 1.0,
1532
+ "client_stream_exit_after_abort": 1.0,
1533
+ "client_abort_after_completed_transfer": 1.0,
1534
+ "client_abort_idle_225": 1.0,
1535
+ "client_abort_after_failed_transfer": 1.0,
1536
+ "client_error_exit_mid_transfer": 1.0,
1537
+ "client_error_exit_after_completed_transfer": 1.0,
1538
+ "client_abort_idle_rejected": 1.0,
1539
+ "client_upload_stream_abort": 1.0,
1540
+ "client_abort_concurrent": 1.0,
1541
+ "client_cancelled_abort_or_finish": 1.0,
1542
+ "client_abort_during_finish": 1.0,
1543
+ "client_abandoned_listing_resync": 0.0,
1544
+ "server_listener_release_after_abort": 1.0,
1545
+ "server_repeated_abor_order": 1.0,
1546
+ "server_pipelined_command_order": 1.0,
1547
+ "server_real_client_abor": 1.0,
1548
+ "server_quit_during_transfer": 1.0,
1549
+ "server_data_connection_loss": 1.0,
1550
+ "server_undecodable_command_syntax": 1.0,
1551
+ "client_abort_after_cancelled_finish": 1.0,
1552
+ "server_pipelined_abort_open_data": 1.0,
1553
+ "server_pipelined_quit_open_data": 1.0,
1554
+ "client_nowait_abort_owed_replies": 1.0,
1555
+ "client_command_during_abort": 1.0
1556
+ },
1557
+ "raw_score": 0.9989,
1558
+ "final_score": 0.9989,
1559
+ "unaffected_criteria": [
1560
+ "server_early_abort_session",
1561
+ "client_stream_exit_after_abort",
1562
+ "client_abort_after_completed_transfer",
1563
+ "client_abort_idle_225",
1564
+ "client_abort_after_failed_transfer",
1565
+ "client_error_exit_mid_transfer",
1566
+ "client_error_exit_after_completed_transfer",
1567
+ "client_abort_idle_rejected",
1568
+ "client_upload_stream_abort",
1569
+ "client_abort_concurrent",
1570
+ "client_cancelled_abort_or_finish",
1571
+ "client_abort_during_finish",
1572
+ "server_listener_release_after_abort",
1573
+ "server_repeated_abor_order",
1574
+ "server_pipelined_command_order",
1575
+ "server_real_client_abor",
1576
+ "server_quit_during_transfer",
1577
+ "server_data_connection_loss",
1578
+ "server_undecodable_command_syntax",
1579
+ "client_abort_after_cancelled_finish",
1580
+ "server_pipelined_abort_open_data",
1581
+ "server_pipelined_quit_open_data",
1582
+ "client_nowait_abort_owed_replies",
1583
+ "client_command_during_abort"
1584
+ ],
1585
+ "build_failed": false,
1586
+ "safety_gates_failed": false,
1587
+ "gate_statuses": {
1588
+ "G1_stale_reply_after_abort": true,
1589
+ "G2_stale_reply_after_error_exit": true,
1590
+ "G3_stale_data_connection_after_abort": true,
1591
+ "G4_stale_reply_after_cancelled_finish": true
1592
+ }
1593
+ }
1594
+ },
1595
+ {
1596
+ "id": "ksg_repeated_abor_immediate_226",
1597
+ "patch_path": "grading/adversarial/patches/ksg_repeated_abor_immediate_226.diff",
1598
+ "applies_to": "gold",
1599
+ "description": "Gold whose abor handler answers a repeated ABOR at once instead of after the abort it repeats; cue tokens aborting_workers, 226, nothing to abort and ABOR stay in code and comments. The wire order becomes 226, 426, 226: only server_repeated_abor_order is lost, raw 0.9980.",
1600
+ "cue_tokens_required_present": [
1601
+ "aborting_workers",
1602
+ "226",
1603
+ "nothing to abort",
1604
+ "ABOR"
1605
+ ],
1606
+ "expected": {
1607
+ "target_criteria": [
1608
+ "server_repeated_abor_order"
1609
+ ],
1610
+ "target_raw_leaf_max": 0.0,
1611
+ "criteria_profile": {
1612
+ "server_early_abort_session": 1.0,
1613
+ "client_stream_exit_after_abort": 1.0,
1614
+ "client_abort_after_completed_transfer": 1.0,
1615
+ "client_abort_idle_225": 1.0,
1616
+ "client_abort_after_failed_transfer": 1.0,
1617
+ "client_error_exit_mid_transfer": 1.0,
1618
+ "client_error_exit_after_completed_transfer": 1.0,
1619
+ "client_abort_idle_rejected": 1.0,
1620
+ "client_upload_stream_abort": 1.0,
1621
+ "client_abort_concurrent": 1.0,
1622
+ "client_cancelled_abort_or_finish": 1.0,
1623
+ "client_abort_during_finish": 1.0,
1624
+ "client_abandoned_listing_resync": 1.0,
1625
+ "server_listener_release_after_abort": 1.0,
1626
+ "server_repeated_abor_order": 0.0,
1627
+ "server_pipelined_command_order": 1.0,
1628
+ "server_real_client_abor": 1.0,
1629
+ "server_quit_during_transfer": 1.0,
1630
+ "server_data_connection_loss": 1.0,
1631
+ "server_undecodable_command_syntax": 1.0,
1632
+ "client_abort_after_cancelled_finish": 1.0,
1633
+ "server_pipelined_abort_open_data": 1.0,
1634
+ "server_pipelined_quit_open_data": 1.0,
1635
+ "client_nowait_abort_owed_replies": 1.0,
1636
+ "client_command_during_abort": 1.0
1637
+ },
1638
+ "raw_score": 0.99,
1639
+ "final_score": 0.99,
1640
+ "unaffected_criteria": [
1641
+ "server_early_abort_session",
1642
+ "client_stream_exit_after_abort",
1643
+ "client_abort_after_completed_transfer",
1644
+ "client_abort_idle_225",
1645
+ "client_abort_after_failed_transfer",
1646
+ "client_error_exit_mid_transfer",
1647
+ "client_error_exit_after_completed_transfer",
1648
+ "client_abort_idle_rejected",
1649
+ "client_upload_stream_abort",
1650
+ "client_abort_concurrent",
1651
+ "client_cancelled_abort_or_finish",
1652
+ "client_abort_during_finish",
1653
+ "client_abandoned_listing_resync",
1654
+ "server_listener_release_after_abort",
1655
+ "server_pipelined_command_order",
1656
+ "server_real_client_abor",
1657
+ "server_quit_during_transfer",
1658
+ "server_data_connection_loss",
1659
+ "server_undecodable_command_syntax",
1660
+ "client_abort_after_cancelled_finish",
1661
+ "server_pipelined_abort_open_data",
1662
+ "server_pipelined_quit_open_data",
1663
+ "client_nowait_abort_owed_replies",
1664
+ "client_command_during_abort"
1665
+ ],
1666
+ "build_failed": false,
1667
+ "safety_gates_failed": false,
1668
+ "gate_statuses": {
1669
+ "G1_stale_reply_after_abort": true,
1670
+ "G2_stale_reply_after_error_exit": true,
1671
+ "G3_stale_data_connection_after_abort": true,
1672
+ "G4_stale_reply_after_cancelled_finish": true
1673
+ }
1674
+ }
1675
+ },
1676
+ {
1677
+ "id": "ksg_reply_order_fixed_state_racing",
1678
+ "applies_to": "gold",
1679
+ "cue_tokens_required_present": [
1680
+ "response",
1681
+ "dispatcher",
1682
+ "create_task",
1683
+ "restart_offset"
1684
+ ],
1685
+ "description": "Gold running commands concurrently as tasks without executor queue synchronization; pipelined state mutations race against subsequent commands on slow storage: server_pipelined_command_order is lost, raw 0.9693.",
1686
+ "patch_path": "grading/adversarial/patches/ksg_reply_order_fixed_state_racing.diff",
1687
+ "expected": {
1688
+ "build_failed": false,
1689
+ "criteria_profile": {
1690
+ "server_early_abort_session": 1.0,
1691
+ "client_stream_exit_after_abort": 1.0,
1692
+ "client_abort_after_completed_transfer": 1.0,
1693
+ "client_abort_idle_225": 1.0,
1694
+ "client_abort_after_failed_transfer": 1.0,
1695
+ "client_error_exit_mid_transfer": 1.0,
1696
+ "client_error_exit_after_completed_transfer": 1.0,
1697
+ "client_abort_idle_rejected": 1.0,
1698
+ "client_upload_stream_abort": 1.0,
1699
+ "client_abort_concurrent": 1.0,
1700
+ "client_cancelled_abort_or_finish": 1.0,
1701
+ "client_abort_during_finish": 1.0,
1702
+ "client_abandoned_listing_resync": 1.0,
1703
+ "server_listener_release_after_abort": 1.0,
1704
+ "server_repeated_abor_order": 1.0,
1705
+ "server_pipelined_command_order": 0.0,
1706
+ "server_real_client_abor": 1.0,
1707
+ "server_quit_during_transfer": 1.0,
1708
+ "server_data_connection_loss": 1.0,
1709
+ "server_undecodable_command_syntax": 1.0,
1710
+ "client_abort_after_cancelled_finish": 1.0,
1711
+ "server_pipelined_abort_open_data": 0.0,
1712
+ "server_pipelined_quit_open_data": 0.0,
1713
+ "client_nowait_abort_owed_replies": 1.0,
1714
+ "client_command_during_abort": 1.0
1715
+ },
1716
+ "final_score": 0.6294,
1717
+ "gate_statuses": {
1718
+ "G1_stale_reply_after_abort": true,
1719
+ "G2_stale_reply_after_error_exit": true,
1720
+ "G3_stale_data_connection_after_abort": true,
1721
+ "G4_stale_reply_after_cancelled_finish": true
1722
+ },
1723
+ "raw_score": 0.6294,
1724
+ "safety_gates_failed": false,
1725
+ "target_criteria": [
1726
+ "server_pipelined_command_order",
1727
+ "server_pipelined_abort_open_data",
1728
+ "server_pipelined_quit_open_data"
1729
+ ],
1730
+ "target_raw_leaf_max": 0.0,
1731
+ "unaffected_criteria": [
1732
+ "server_early_abort_session",
1733
+ "client_stream_exit_after_abort",
1734
+ "client_abort_after_completed_transfer",
1735
+ "client_abort_idle_225",
1736
+ "client_abort_after_failed_transfer",
1737
+ "client_error_exit_mid_transfer",
1738
+ "client_error_exit_after_completed_transfer",
1739
+ "client_abort_idle_rejected",
1740
+ "client_upload_stream_abort",
1741
+ "client_abort_concurrent",
1742
+ "client_cancelled_abort_or_finish",
1743
+ "client_abort_during_finish",
1744
+ "client_abandoned_listing_resync",
1745
+ "server_listener_release_after_abort",
1746
+ "server_repeated_abor_order",
1747
+ "server_real_client_abor",
1748
+ "server_quit_during_transfer",
1749
+ "server_data_connection_loss",
1750
+ "server_undecodable_command_syntax",
1751
+ "client_abort_after_cancelled_finish",
1752
+ "client_nowait_abort_owed_replies",
1753
+ "client_command_during_abort"
1754
+ ]
1755
+ }
1756
+ },
1757
+ {
1758
+ "id": "ksg_telnet_stripped_no_urgent",
1759
+ "applies_to": "gold",
1760
+ "cue_tokens_required_present": [
1761
+ "SO_OOBINLINE",
1762
+ "IAC",
1763
+ "parse_command",
1764
+ "setsockopt"
1765
+ ],
1766
+ "description": "Gold stripping Telnet escapes in parse_command but omitting SO_OOBINLINE on the control socket; urgent-data ABOR sequences from real FTP clients corrupt the control stream or drop the session: server_real_client_abor is lost, raw 0.9744.",
1767
+ "patch_path": "grading/adversarial/patches/ksg_telnet_stripped_no_urgent.diff",
1768
+ "expected": {
1769
+ "build_failed": false,
1770
+ "criteria_profile": {
1771
+ "server_early_abort_session": 1.0,
1772
+ "client_stream_exit_after_abort": 1.0,
1773
+ "client_abort_after_completed_transfer": 1.0,
1774
+ "client_abort_idle_225": 1.0,
1775
+ "client_abort_after_failed_transfer": 1.0,
1776
+ "client_error_exit_mid_transfer": 1.0,
1777
+ "client_error_exit_after_completed_transfer": 1.0,
1778
+ "client_abort_idle_rejected": 1.0,
1779
+ "client_upload_stream_abort": 1.0,
1780
+ "client_abort_concurrent": 1.0,
1781
+ "client_cancelled_abort_or_finish": 1.0,
1782
+ "client_abort_during_finish": 1.0,
1783
+ "client_abandoned_listing_resync": 1.0,
1784
+ "server_listener_release_after_abort": 1.0,
1785
+ "server_repeated_abor_order": 1.0,
1786
+ "server_pipelined_command_order": 1.0,
1787
+ "server_real_client_abor": 0.0,
1788
+ "server_quit_during_transfer": 1.0,
1789
+ "server_data_connection_loss": 1.0,
1790
+ "server_undecodable_command_syntax": 1.0,
1791
+ "client_abort_after_cancelled_finish": 1.0,
1792
+ "server_pipelined_abort_open_data": 1.0,
1793
+ "server_pipelined_quit_open_data": 1.0,
1794
+ "client_nowait_abort_owed_replies": 1.0,
1795
+ "client_command_during_abort": 1.0
1796
+ },
1797
+ "final_score": 0.9948,
1798
+ "gate_statuses": {
1799
+ "G1_stale_reply_after_abort": true,
1800
+ "G2_stale_reply_after_error_exit": true,
1801
+ "G3_stale_data_connection_after_abort": true,
1802
+ "G4_stale_reply_after_cancelled_finish": true
1803
+ },
1804
+ "raw_score": 0.9948,
1805
+ "safety_gates_failed": false,
1806
+ "target_criteria": [
1807
+ "server_real_client_abor"
1808
+ ],
1809
+ "target_raw_leaf_max": 0.0,
1810
+ "unaffected_criteria": [
1811
+ "server_early_abort_session",
1812
+ "client_stream_exit_after_abort",
1813
+ "client_abort_after_completed_transfer",
1814
+ "client_abort_idle_225",
1815
+ "client_abort_after_failed_transfer",
1816
+ "client_error_exit_mid_transfer",
1817
+ "client_error_exit_after_completed_transfer",
1818
+ "client_abort_idle_rejected",
1819
+ "client_upload_stream_abort",
1820
+ "client_abort_concurrent",
1821
+ "client_cancelled_abort_or_finish",
1822
+ "client_abort_during_finish",
1823
+ "client_abandoned_listing_resync",
1824
+ "server_listener_release_after_abort",
1825
+ "server_repeated_abor_order",
1826
+ "server_pipelined_command_order",
1827
+ "server_quit_during_transfer",
1828
+ "server_data_connection_loss",
1829
+ "server_undecodable_command_syntax",
1830
+ "client_abort_after_cancelled_finish",
1831
+ "server_pipelined_abort_open_data",
1832
+ "server_pipelined_quit_open_data",
1833
+ "client_nowait_abort_owed_replies",
1834
+ "client_command_during_abort"
1835
+ ]
1836
+ }
1837
+ },
1838
+ {
1839
+ "id": "ksg_quit_cancels_transfers_with_426",
1840
+ "applies_to": "gold",
1841
+ "cue_tokens_required_present": [
1842
+ "quit",
1843
+ "221",
1844
+ "extra_workers",
1845
+ "cancel"
1846
+ ],
1847
+ "description": "Gold whose quit() immediately cancels active data transfers with 426 instead of awaiting completion of open transfers with 226: server_quit_during_transfer is lost, raw 0.9761.",
1848
+ "patch_path": "grading/adversarial/patches/ksg_quit_cancels_transfers_with_426.diff",
1849
+ "expected": {
1850
+ "build_failed": false,
1851
+ "criteria_profile": {
1852
+ "server_early_abort_session": 1.0,
1853
+ "client_stream_exit_after_abort": 1.0,
1854
+ "client_abort_after_completed_transfer": 1.0,
1855
+ "client_abort_idle_225": 1.0,
1856
+ "client_abort_after_failed_transfer": 1.0,
1857
+ "client_error_exit_mid_transfer": 1.0,
1858
+ "client_error_exit_after_completed_transfer": 1.0,
1859
+ "client_abort_idle_rejected": 1.0,
1860
+ "client_upload_stream_abort": 1.0,
1861
+ "client_abort_concurrent": 1.0,
1862
+ "client_cancelled_abort_or_finish": 1.0,
1863
+ "client_abort_during_finish": 1.0,
1864
+ "client_abandoned_listing_resync": 1.0,
1865
+ "server_listener_release_after_abort": 1.0,
1866
+ "server_repeated_abor_order": 1.0,
1867
+ "server_pipelined_command_order": 1.0,
1868
+ "server_real_client_abor": 1.0,
1869
+ "server_quit_during_transfer": 0.0,
1870
+ "server_data_connection_loss": 1.0,
1871
+ "server_undecodable_command_syntax": 1.0,
1872
+ "client_abort_after_cancelled_finish": 1.0,
1873
+ "server_pipelined_abort_open_data": 1.0,
1874
+ "server_pipelined_quit_open_data": 0.0,
1875
+ "client_nowait_abort_owed_replies": 1.0,
1876
+ "client_command_during_abort": 1.0
1877
+ },
1878
+ "final_score": 0.8737,
1879
+ "gate_statuses": {
1880
+ "G1_stale_reply_after_abort": true,
1881
+ "G2_stale_reply_after_error_exit": true,
1882
+ "G3_stale_data_connection_after_abort": true,
1883
+ "G4_stale_reply_after_cancelled_finish": true
1884
+ },
1885
+ "raw_score": 0.8737,
1886
+ "safety_gates_failed": false,
1887
+ "target_criteria": [
1888
+ "server_quit_during_transfer",
1889
+ "server_pipelined_quit_open_data"
1890
+ ],
1891
+ "target_raw_leaf_max": 0.0,
1892
+ "unaffected_criteria": [
1893
+ "server_early_abort_session",
1894
+ "client_stream_exit_after_abort",
1895
+ "client_abort_after_completed_transfer",
1896
+ "client_abort_idle_225",
1897
+ "client_abort_after_failed_transfer",
1898
+ "client_error_exit_mid_transfer",
1899
+ "client_error_exit_after_completed_transfer",
1900
+ "client_abort_idle_rejected",
1901
+ "client_upload_stream_abort",
1902
+ "client_abort_concurrent",
1903
+ "client_cancelled_abort_or_finish",
1904
+ "client_abort_during_finish",
1905
+ "client_abandoned_listing_resync",
1906
+ "server_listener_release_after_abort",
1907
+ "server_repeated_abor_order",
1908
+ "server_pipelined_command_order",
1909
+ "server_real_client_abor",
1910
+ "server_data_connection_loss",
1911
+ "server_undecodable_command_syntax",
1912
+ "client_abort_after_cancelled_finish",
1913
+ "server_pipelined_abort_open_data",
1914
+ "client_nowait_abort_owed_replies",
1915
+ "client_command_during_abort"
1916
+ ]
1917
+ }
1918
+ },
1919
+ {
1920
+ "id": "ksg_data_loss_no_listener_release",
1921
+ "applies_to": "gold",
1922
+ "cue_tokens_required_present": [
1923
+ "ConnectionError",
1924
+ "426",
1925
+ "_release_passive_server",
1926
+ "data_ports"
1927
+ ],
1928
+ "description": "Gold whose worker catches ConnectionError on the data stream and sends 426 but fails to release the passive listener and return the port to data_ports: server_data_connection_loss is lost, raw 0.9812.",
1929
+ "patch_path": "grading/adversarial/patches/ksg_data_loss_no_listener_release.diff",
1930
+ "expected": {
1931
+ "build_failed": false,
1932
+ "criteria_profile": {
1933
+ "server_early_abort_session": 1.0,
1934
+ "client_stream_exit_after_abort": 1.0,
1935
+ "client_abort_after_completed_transfer": 1.0,
1936
+ "client_abort_idle_225": 1.0,
1937
+ "client_abort_after_failed_transfer": 1.0,
1938
+ "client_error_exit_mid_transfer": 1.0,
1939
+ "client_error_exit_after_completed_transfer": 1.0,
1940
+ "client_abort_idle_rejected": 1.0,
1941
+ "client_upload_stream_abort": 1.0,
1942
+ "client_abort_concurrent": 1.0,
1943
+ "client_cancelled_abort_or_finish": 1.0,
1944
+ "client_abort_during_finish": 1.0,
1945
+ "client_abandoned_listing_resync": 1.0,
1946
+ "server_listener_release_after_abort": 1.0,
1947
+ "server_repeated_abor_order": 1.0,
1948
+ "server_pipelined_command_order": 1.0,
1949
+ "server_real_client_abor": 1.0,
1950
+ "server_quit_during_transfer": 1.0,
1951
+ "server_data_connection_loss": 0.0,
1952
+ "server_undecodable_command_syntax": 1.0,
1953
+ "client_abort_after_cancelled_finish": 1.0,
1954
+ "server_pipelined_abort_open_data": 1.0,
1955
+ "server_pipelined_quit_open_data": 1.0,
1956
+ "client_nowait_abort_owed_replies": 1.0,
1957
+ "client_command_during_abort": 1.0
1958
+ },
1959
+ "final_score": 0.9962,
1960
+ "gate_statuses": {
1961
+ "G1_stale_reply_after_abort": true,
1962
+ "G2_stale_reply_after_error_exit": true,
1963
+ "G3_stale_data_connection_after_abort": true,
1964
+ "G4_stale_reply_after_cancelled_finish": true
1965
+ },
1966
+ "raw_score": 0.9962,
1967
+ "safety_gates_failed": false,
1968
+ "target_criteria": [
1969
+ "server_data_connection_loss"
1970
+ ],
1971
+ "target_raw_leaf_max": 0.0,
1972
+ "unaffected_criteria": [
1973
+ "server_early_abort_session",
1974
+ "client_stream_exit_after_abort",
1975
+ "client_abort_after_completed_transfer",
1976
+ "client_abort_idle_225",
1977
+ "client_abort_after_failed_transfer",
1978
+ "client_error_exit_mid_transfer",
1979
+ "client_error_exit_after_completed_transfer",
1980
+ "client_abort_idle_rejected",
1981
+ "client_upload_stream_abort",
1982
+ "client_abort_concurrent",
1983
+ "client_cancelled_abort_or_finish",
1984
+ "client_abort_during_finish",
1985
+ "client_abandoned_listing_resync",
1986
+ "server_listener_release_after_abort",
1987
+ "server_repeated_abor_order",
1988
+ "server_pipelined_command_order",
1989
+ "server_real_client_abor",
1990
+ "server_quit_during_transfer",
1991
+ "server_undecodable_command_syntax",
1992
+ "client_abort_after_cancelled_finish",
1993
+ "server_pipelined_abort_open_data",
1994
+ "server_pipelined_quit_open_data",
1995
+ "client_nowait_abort_owed_replies",
1996
+ "client_command_during_abort"
1997
+ ]
1998
+ }
1999
+ },
2000
+ {
2001
+ "id": "ksg_abor_queued_behind_transfer",
2002
+ "applies_to": "gold",
2003
+ "cue_tokens_required_present": [
2004
+ "abor",
2005
+ "extra_workers",
2006
+ "wait",
2007
+ "restart_offset"
2008
+ ],
2009
+ "description": "Gold whose command executor awaits active transfer workers before accepting the next command; an ABOR sent while a transfer is pending or running is not executed until that transfer ends, so it is answered late or never: server_early_abort_session, server_listener_release_after_abort, server_repeated_abor_order, server_pipelined_command_order, server_real_client_abor, server_quit_during_transfer are lost (G3 fires), raw 0.7554, final 0.60.",
2010
+ "patch_path": "grading/adversarial/patches/ksg_abor_queued_behind_transfer.diff",
2011
+ "expected": {
2012
+ "build_failed": false,
2013
+ "criteria_profile": {
2014
+ "server_early_abort_session": 0.0,
2015
+ "client_stream_exit_after_abort": 1.0,
2016
+ "client_abort_after_completed_transfer": 1.0,
2017
+ "client_abort_idle_225": 1.0,
2018
+ "client_abort_after_failed_transfer": 1.0,
2019
+ "client_error_exit_mid_transfer": 1.0,
2020
+ "client_error_exit_after_completed_transfer": 1.0,
2021
+ "client_abort_idle_rejected": 1.0,
2022
+ "client_upload_stream_abort": 1.0,
2023
+ "client_abort_concurrent": 1.0,
2024
+ "client_cancelled_abort_or_finish": 1.0,
2025
+ "client_abort_during_finish": 1.0,
2026
+ "client_abandoned_listing_resync": 1.0,
2027
+ "server_listener_release_after_abort": 0.0,
2028
+ "server_repeated_abor_order": 0.0,
2029
+ "server_pipelined_command_order": 0.0,
2030
+ "server_real_client_abor": 0.0,
2031
+ "server_quit_during_transfer": 0.0,
2032
+ "server_data_connection_loss": 1.0,
2033
+ "server_undecodable_command_syntax": 1.0,
2034
+ "client_abort_after_cancelled_finish": 1.0,
2035
+ "server_pipelined_abort_open_data": 0.0,
2036
+ "server_pipelined_quit_open_data": 1.0,
2037
+ "client_nowait_abort_owed_replies": 1.0,
2038
+ "client_command_during_abort": 1.0
2039
+ },
2040
+ "final_score": 0.6,
2041
+ "gate_statuses": {
2042
+ "G1_stale_reply_after_abort": true,
2043
+ "G2_stale_reply_after_error_exit": true,
2044
+ "G3_stale_data_connection_after_abort": false,
2045
+ "G4_stale_reply_after_cancelled_finish": true
2046
+ },
2047
+ "raw_score": 0.6976,
2048
+ "safety_gates_failed": true,
2049
+ "target_criteria": [
2050
+ "server_early_abort_session",
2051
+ "server_listener_release_after_abort",
2052
+ "server_repeated_abor_order",
2053
+ "server_pipelined_command_order",
2054
+ "server_real_client_abor",
2055
+ "server_quit_during_transfer",
2056
+ "server_pipelined_abort_open_data"
2057
+ ],
2058
+ "target_raw_leaf_max": 0.0,
2059
+ "unaffected_criteria": [
2060
+ "client_stream_exit_after_abort",
2061
+ "client_abort_after_completed_transfer",
2062
+ "client_abort_idle_225",
2063
+ "client_abort_after_failed_transfer",
2064
+ "client_error_exit_mid_transfer",
2065
+ "client_error_exit_after_completed_transfer",
2066
+ "client_abort_idle_rejected",
2067
+ "client_upload_stream_abort",
2068
+ "client_abort_concurrent",
2069
+ "client_cancelled_abort_or_finish",
2070
+ "client_abort_during_finish",
2071
+ "client_abandoned_listing_resync",
2072
+ "server_data_connection_loss",
2073
+ "server_undecodable_command_syntax",
2074
+ "client_abort_after_cancelled_finish",
2075
+ "server_pipelined_quit_open_data",
2076
+ "client_nowait_abort_owed_replies",
2077
+ "client_command_during_abort"
2078
+ ]
2079
+ }
2080
+ }
2081
+ ]
2082
+ }
harbor/sources/aioftp-v11/grading/baseline/pyproject.toml ADDED
@@ -0,0 +1,117 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [project]
2
+ name = "aioftp"
3
+ version = "0.28.3"
4
+ description = "ftp client/server for asyncio"
5
+ readme = "README.rst"
6
+ requires-python = ">= 3.10"
7
+ license = {file = "license.txt"}
8
+ authors = [
9
+ {name = "pohmelie", email = "multisosnooley@gmail.com"},
10
+ {name = "yieyu"},
11
+ {name = "rsichnyi"},
12
+ {name = "jw4js"},
13
+ {name = "asvetlov", email = "andrew.svetlov@gmail.com"},
14
+ {name = "decaz", email = "decaz89@gmail.com"},
15
+ {name = "oleksandr-kuzmenko"},
16
+ {name = "ndhansen"},
17
+ {name = "janneronkko", email="janne.ronkko@iki.fi"},
18
+ {name = "thirtyseven", email="ted@shlashdot.org"},
19
+ {name = "modelmat"},
20
+ {name = "greut"},
21
+ {name = "ported-pw", email="contact@ported.pw"},
22
+ {name = "PonyPC"},
23
+ {name = "jacobtomlinson"},
24
+ {name = "Olegt0rr", email="t0rr@mail.ru"},
25
+ {name = "michalc", email="michal@charemza.name"},
26
+ {name = "bachya"},
27
+ {name = "ch3pjw", email="paul@concertdaw.co.uk"},
28
+ {name = "puddly", email="puddly3@gmail.com"},
29
+ {name = "CrafterKolyan"},
30
+ {name = "jkr78"},
31
+ {name = "AMDmi3", email="amdmi3@amdmi3.ru"},
32
+ {name = "webknjaz", email="webknjaz+github/profile@redhat.com"},
33
+ {name = "rcfox", email="ryan@rcfox.ca"},
34
+ {name = "bellini666", email="thiago@bellini.dev"},
35
+ {name = "sakosha"},
36
+ {name = "rwakulszowa"},
37
+ ]
38
+ classifiers = [
39
+ "Programming Language :: Python",
40
+ "Programming Language :: Python :: 3",
41
+ "Development Status :: 5 - Production/Stable",
42
+ "Topic :: Internet :: File Transfer Protocol (FTP)",
43
+ ]
44
+
45
+ # TODO: remove `typing-extensions` when requires-python = ">= 3.11"
46
+ dependencies = [
47
+ "typing-extensions>=4.13.2; python_version < '3.11'", # 3.9-10 typing support
48
+ ]
49
+
50
+ [project.urls]
51
+ Github = "https://github.com/aio-libs/aioftp"
52
+ Documentation = "https://aioftp.rtfd.io"
53
+
54
+ [project.optional-dependencies]
55
+ socks = [
56
+ "siosocks >= 0.2.0",
57
+ ]
58
+ dev = [
59
+ # tests
60
+ "async_timeout >= 4.0.0",
61
+ "pytest-asyncio",
62
+ "pytest-cov",
63
+ "pytest-mock",
64
+ "pytest",
65
+ "siosocks",
66
+ "trustme",
67
+
68
+ # linters
69
+ "pre-commit",
70
+ "ruff",
71
+ "mypy",
72
+ ]
73
+
74
+ [build-system]
75
+ requires = ["setuptools", "wheel"]
76
+ build-backend = "setuptools.build_meta"
77
+
78
+ [tool.setuptools]
79
+ packages.find.where = ["src"]
80
+ package-data.aioftp = ["py.typed"]
81
+
82
+ # tools
83
+ [tool.ruff]
84
+ line-length = 120
85
+ target-version = "py310"
86
+ lint.select = ["E", "W", "F", "Q", "UP", "I", "ASYNC"]
87
+ lint.ignore = ["ASYNC240"]
88
+ src = ["src"]
89
+ exclude = ["ftpbench.py"]
90
+
91
+
92
+ [tool.mypy]
93
+ files = "src/aioftp"
94
+ pretty = true
95
+ strict = true
96
+ ignore_missing_imports = true
97
+ warn_unreachable = true
98
+
99
+ [tool.coverage]
100
+ run.source = ["./src/aioftp"]
101
+ run.omit = ["./src/aioftp/__main__.py"]
102
+ report.show_missing = true
103
+ report.precision = 2
104
+
105
+ [tool.pytest.ini_options]
106
+ addopts = [
107
+ "-x",
108
+ "--durations", "10",
109
+ "-p", "no:anyio",
110
+ "--cov",
111
+ "--import-mode=importlib",
112
+ ]
113
+ testpaths = "tests"
114
+ log_format = "%(asctime)s.%(msecs)03d %(name)-20s %(levelname)-8s %(filename)-15s %(lineno)-4d %(message)s"
115
+ log_date_format = "%H:%M:%S"
116
+ log_level = "DEBUG"
117
+ asyncio_mode = "strict"
harbor/sources/aioftp-v11/grading/baseline/tests/__pycache__/conftest.cpython-312-pytest-9.1.1.pyc ADDED
Binary file (14.2 kB). View file
 
harbor/sources/aioftp-v11/grading/baseline/tests/conftest.py ADDED
@@ -0,0 +1,232 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import asyncio
2
+ import collections
3
+ import contextlib
4
+ import functools
5
+ import math
6
+ import socket
7
+ import ssl
8
+ import tempfile
9
+ import time
10
+ from pathlib import Path
11
+
12
+ import pytest
13
+ import pytest_asyncio
14
+ import trustme
15
+ from async_timeout import timeout
16
+ from siosocks.io.asyncio import socks_server_handler
17
+
18
+ import aioftp
19
+
20
+ # No ssl tests since https://bugs.python.org/issue36098
21
+ ca = trustme.CA()
22
+ server_cert = ca.issue_server_cert("127.0.0.1", "::1")
23
+
24
+ ssl_server = ssl.create_default_context(ssl.Purpose.CLIENT_AUTH)
25
+ server_cert.configure_cert(ssl_server)
26
+
27
+ ssl_client = ssl.create_default_context(ssl.Purpose.SERVER_AUTH)
28
+ ca.configure_trust(ssl_client)
29
+
30
+
31
+ class Container:
32
+ def __init__(self, *args, **kwargs):
33
+ self.args = args
34
+ self.kwargs = kwargs
35
+
36
+
37
+ @pytest.fixture
38
+ def Client():
39
+ return Container
40
+
41
+
42
+ @pytest.fixture
43
+ def Server():
44
+ return Container
45
+
46
+
47
+ def _wrap_with_defaults(kwargs):
48
+ test_defaults = dict(
49
+ path_io_factory=aioftp.MemoryPathIO,
50
+ )
51
+ return collections.ChainMap(kwargs, test_defaults)
52
+
53
+
54
+ @pytest.fixture(params=["127.0.0.1", "::1"])
55
+ def pair_factory(request):
56
+ class Factory:
57
+ def __init__(
58
+ self,
59
+ client=None,
60
+ server=None,
61
+ *,
62
+ connected=True,
63
+ logged=True,
64
+ do_quit=True,
65
+ host=request.param,
66
+ server_factory=aioftp.Server,
67
+ client_factory=aioftp.Client,
68
+ ):
69
+ if client is None:
70
+ client = Container()
71
+ self.client = client_factory(*client.args, **_wrap_with_defaults(client.kwargs))
72
+ if server is None:
73
+ server = Container()
74
+ self.server = server_factory(*server.args, **_wrap_with_defaults(server.kwargs))
75
+ self.connected = connected
76
+ self.logged = logged
77
+ self.do_quit = do_quit
78
+ self.host = host
79
+ self.timeout = timeout(1)
80
+
81
+ async def make_server_files(self, *paths, size=None, atom=b"-"):
82
+ if size is None:
83
+ size = aioftp.DEFAULT_BLOCK_SIZE * 3
84
+ data = atom * size
85
+ for p in paths:
86
+ await self.client.make_directory(Path(p).parent)
87
+ async with self.client.upload_stream(p) as stream:
88
+ await stream.write(data)
89
+
90
+ async def make_client_files(self, *paths, size=None, atom=b"-"):
91
+ if size is None:
92
+ size = aioftp.DEFAULT_BLOCK_SIZE * 3
93
+ data = atom * size
94
+ for p in map(Path, paths):
95
+ await self.client.path_io.mkdir(
96
+ p.parent,
97
+ parents=True,
98
+ exist_ok=True,
99
+ )
100
+ async with self.client.path_io.open(p, mode="wb") as f:
101
+ await f.write(data)
102
+
103
+ async def server_paths_exists(self, *paths):
104
+ values = []
105
+ for p in paths:
106
+ values.append(await self.client.exists(p))
107
+ if all(values):
108
+ return True
109
+ if any(values):
110
+ raise ValueError("Mixed exists/not exists list")
111
+ return False
112
+
113
+ async def client_paths_exists(self, *paths):
114
+ values = []
115
+ for p in paths:
116
+ values.append(await self.client.path_io.exists(Path(p)))
117
+ if all(values):
118
+ return True
119
+ if any(values):
120
+ raise ValueError("Mixed exists/not exists list")
121
+ return False
122
+
123
+ async def __aenter__(self):
124
+ await self.timeout.__aenter__()
125
+ await self.server.start(host=self.host)
126
+ if self.connected:
127
+ await self.client.connect(
128
+ self.server.server_host,
129
+ self.server.server_port,
130
+ )
131
+ if self.logged:
132
+ await self.client.login()
133
+ return self
134
+
135
+ async def __aexit__(self, *exc_info):
136
+ if self.connected and self.do_quit:
137
+ await self.client.quit()
138
+ self.client.close()
139
+ await self.server.close()
140
+ await self.timeout.__aexit__(*exc_info)
141
+
142
+ return Factory
143
+
144
+
145
+ @pytest.fixture
146
+ def expect_codes_in_exception():
147
+ @contextlib.contextmanager
148
+ def context(*codes):
149
+ try:
150
+ yield
151
+ except aioftp.StatusCodeError as e:
152
+ assert set(e.received_codes) == set(codes)
153
+ else:
154
+ raise RuntimeError("There was no exception")
155
+
156
+ return context
157
+
158
+
159
+ @pytest.fixture(
160
+ params=[
161
+ aioftp.MemoryPathIO,
162
+ aioftp.PathIO,
163
+ aioftp.AsyncPathIO,
164
+ ],
165
+ )
166
+ def path_io(request):
167
+ return request.param()
168
+
169
+
170
+ @pytest.fixture
171
+ def temp_dir(path_io):
172
+ if isinstance(path_io, aioftp.MemoryPathIO):
173
+ yield Path("/")
174
+ else:
175
+ with tempfile.TemporaryDirectory() as name:
176
+ yield Path(name)
177
+
178
+
179
+ class Sleep:
180
+ def __init__(self):
181
+ self.delay = 0
182
+ self.first_sleep = None
183
+
184
+ async def sleep(self, delay, result=None, **kwargs):
185
+ if self.first_sleep is None:
186
+ self.first_sleep = time.monotonic()
187
+ delay = (time.monotonic() - self.first_sleep) + delay
188
+ self.delay = max(self.delay, delay)
189
+ return result
190
+
191
+ def is_close(self, delay, *, rel_tol=0.05, abs_tol=0.5):
192
+ ok = math.isclose(self.delay, delay, rel_tol=rel_tol, abs_tol=abs_tol)
193
+ if not ok:
194
+ print(
195
+ f"latest sleep: {self.delay}; expected delay: {delay}; rel: {rel_tol}",
196
+ )
197
+ return ok
198
+
199
+
200
+ @pytest.fixture
201
+ def skip_sleep(monkeypatch):
202
+ with monkeypatch.context() as m:
203
+ sleeper = Sleep()
204
+ m.setattr(asyncio, "sleep", sleeper.sleep)
205
+ yield sleeper
206
+
207
+
208
+ @pytest_asyncio.fixture(
209
+ params=[
210
+ ("127.0.0.1", socket.AF_INET),
211
+ ("::1", socket.AF_INET6),
212
+ ],
213
+ )
214
+ async def socks(request, unused_tcp_port):
215
+ handler = functools.partial(
216
+ socks_server_handler,
217
+ allowed_versions={5},
218
+ username="foo",
219
+ password="bar",
220
+ )
221
+ Socks = collections.namedtuple("Socks", "host port server")
222
+ host, family = request.param
223
+ port = unused_tcp_port
224
+ server = await asyncio.start_server(
225
+ handler,
226
+ host=host,
227
+ port=port,
228
+ family=family,
229
+ )
230
+ yield Socks(host, port, server)
231
+ server.close()
232
+ await server.wait_closed()
harbor/sources/aioftp-v11/grading/baseline/tests/test_abort.py ADDED
@@ -0,0 +1,96 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import asyncio
2
+ import itertools
3
+ import pathlib
4
+
5
+ import pytest
6
+
7
+ import aioftp
8
+
9
+
10
+ @pytest.mark.asyncio
11
+ async def test_abort_stor(pair_factory):
12
+ async with pair_factory() as pair:
13
+ stream = await pair.client.upload_stream("test.txt")
14
+ with pytest.raises((ConnectionResetError, BrokenPipeError)):
15
+ while True:
16
+ await stream.write(b"-" * aioftp.DEFAULT_BLOCK_SIZE)
17
+ await pair.client.abort()
18
+
19
+
20
+ class SlowReadMemoryPathIO(aioftp.MemoryPathIO):
21
+ async def read(self, *args, **kwargs):
22
+ await asyncio.sleep(0.01)
23
+ return await super().read(*args, **kwargs)
24
+
25
+
26
+ @pytest.mark.asyncio
27
+ async def test_abort_retr(pair_factory, Server):
28
+ s = Server(path_io_factory=SlowReadMemoryPathIO)
29
+ async with pair_factory(None, s) as pair:
30
+ await pair.make_server_files("test.txt")
31
+ stream = await pair.client.download_stream("test.txt")
32
+ for i in itertools.count():
33
+ data = await stream.read(aioftp.DEFAULT_BLOCK_SIZE)
34
+ if not data:
35
+ stream.close()
36
+ break
37
+ if i == 0:
38
+ await pair.client.abort()
39
+
40
+
41
+ @pytest.mark.asyncio
42
+ async def test_abort_retr_no_wait(
43
+ pair_factory,
44
+ Server,
45
+ expect_codes_in_exception,
46
+ ):
47
+ s = Server(path_io_factory=SlowReadMemoryPathIO)
48
+ async with pair_factory(None, s) as pair:
49
+ await pair.make_server_files("test.txt")
50
+ stream = await pair.client.download_stream("test.txt")
51
+ with expect_codes_in_exception("426"):
52
+ for i in itertools.count():
53
+ data = await stream.read(aioftp.DEFAULT_BLOCK_SIZE)
54
+ if not data:
55
+ await stream.finish()
56
+ break
57
+ if i == 0:
58
+ await pair.client.abort(wait=False)
59
+
60
+
61
+ @pytest.mark.asyncio
62
+ async def test_nothing_to_abort(pair_factory):
63
+ async with pair_factory() as pair:
64
+ await pair.client.abort()
65
+
66
+
67
+ class SlowListMemoryPathIO(aioftp.MemoryPathIO):
68
+ async def is_file(self, *a, **kw):
69
+ return True
70
+
71
+ def list(self, *args, **kwargs):
72
+ class Lister(aioftp.AbstractAsyncLister):
73
+ async def __anext__(cls):
74
+ await asyncio.sleep(0.01)
75
+ return pathlib.PurePath("/test.txt")
76
+
77
+ return Lister()
78
+
79
+ async def stat(self, *a, **kw):
80
+ class Stat:
81
+ st_size = 0
82
+ st_mtime = 0
83
+ st_ctime = 0
84
+
85
+ return Stat
86
+
87
+
88
+ @pytest.mark.asyncio
89
+ async def test_mlsd_abort(pair_factory, Server):
90
+ s = Server(path_io_factory=SlowListMemoryPathIO)
91
+ async with pair_factory(None, s) as pair:
92
+ cwd = await pair.client.get_current_directory()
93
+ assert cwd == pathlib.PurePosixPath("/")
94
+ async for path, info in pair.client.list():
95
+ await pair.client.abort()
96
+ break
harbor/sources/aioftp-v11/grading/baseline/tests/test_client_side_socks.py ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import pytest
2
+ from siosocks.exceptions import SocksException
3
+
4
+
5
+ @pytest.mark.asyncio
6
+ async def test_socks_success(pair_factory, Client, socks):
7
+ client = Client(
8
+ socks_host=socks.host,
9
+ socks_port=socks.port,
10
+ socks_version=5,
11
+ username="foo",
12
+ password="bar",
13
+ )
14
+ async with pair_factory(client):
15
+ pass
16
+
17
+
18
+ @pytest.mark.asyncio
19
+ async def test_socks_fail(pair_factory, Client, socks):
20
+ client = Client(
21
+ socks_host=socks.host,
22
+ socks_port=socks.port,
23
+ socks_version=5,
24
+ username="bar",
25
+ password="bar",
26
+ )
27
+ with pytest.raises(SocksException):
28
+ async with pair_factory(client):
29
+ pass
harbor/sources/aioftp-v11/grading/baseline/tests/test_connection.py ADDED
@@ -0,0 +1,336 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import asyncio
2
+ import ipaddress
3
+
4
+ import pytest
5
+
6
+ import aioftp
7
+
8
+
9
+ @pytest.mark.asyncio
10
+ async def test_client_without_server(pair_factory, unused_tcp_port_factory):
11
+ f = pair_factory(connected=False, logged=False, do_quit=False)
12
+ async with f as pair:
13
+ pass
14
+ with pytest.raises(OSError):
15
+ await pair.client.connect("127.0.0.1", unused_tcp_port_factory())
16
+
17
+
18
+ @pytest.mark.asyncio
19
+ async def test_connection(pair_factory):
20
+ async with pair_factory(connected=True, logged=False, do_quit=False):
21
+ pass
22
+
23
+
24
+ @pytest.mark.asyncio
25
+ async def test_quit(pair_factory):
26
+ async with pair_factory(connected=True, logged=False, do_quit=True):
27
+ pass
28
+
29
+
30
+ @pytest.mark.asyncio
31
+ async def test_not_implemented(pair_factory, expect_codes_in_exception):
32
+ async with pair_factory() as pair:
33
+ with expect_codes_in_exception("502"):
34
+ await pair.client.command("FOOBAR", "2xx", "1xx")
35
+
36
+
37
+ @pytest.mark.asyncio
38
+ async def test_type_success(pair_factory, expect_codes_in_exception):
39
+ async with pair_factory() as pair:
40
+ await pair.client.get_passive_connection("A")
41
+
42
+
43
+ @pytest.mark.asyncio
44
+ async def test_custom_passive_commands(pair_factory):
45
+ async with pair_factory(host="127.0.0.1") as pair:
46
+ pair.client._passive_commands = None
47
+ await pair.client.get_passive_connection(
48
+ "A",
49
+ commands=["pasv", "epsv"],
50
+ )
51
+
52
+
53
+ @pytest.mark.asyncio
54
+ async def test_extra_pasv_connection(pair_factory):
55
+ async with pair_factory() as pair:
56
+ r, w = await pair.client.get_passive_connection()
57
+ er, ew = await pair.client.get_passive_connection()
58
+ with pytest.raises((ConnectionResetError, BrokenPipeError)):
59
+ while True:
60
+ w.write(b"-" * aioftp.DEFAULT_BLOCK_SIZE)
61
+ await w.drain()
62
+
63
+
64
+ @pytest.mark.parametrize("method", ["epsv", "pasv"])
65
+ @pytest.mark.asyncio
66
+ async def test_closing_passive_connection(pair_factory, method):
67
+ async with pair_factory(host="127.0.0.1") as pair:
68
+ r, w = await pair.client.get_passive_connection(commands=[method])
69
+ host, port, *_ = w.transport.get_extra_info("peername")
70
+ nr, nw = await asyncio.open_connection(host, port)
71
+ with pytest.raises((ConnectionResetError, BrokenPipeError)):
72
+ while True:
73
+ nw.write(b"-" * aioftp.DEFAULT_BLOCK_SIZE)
74
+ await nw.drain()
75
+
76
+
77
+ @pytest.mark.asyncio
78
+ async def test_pasv_connection_ports_not_added(pair_factory):
79
+ async with pair_factory() as pair:
80
+ r, w = await pair.client.get_passive_connection()
81
+ assert pair.server.available_data_ports is None
82
+
83
+
84
+ @pytest.mark.asyncio
85
+ async def test_pasv_connection_ports(
86
+ pair_factory,
87
+ Server,
88
+ unused_tcp_port_factory,
89
+ ):
90
+ ports = [unused_tcp_port_factory(), unused_tcp_port_factory()]
91
+ async with pair_factory(None, Server(data_ports=ports)) as pair:
92
+ r, w = await pair.client.get_passive_connection()
93
+ host, port, *_ = w.transport.get_extra_info("peername")
94
+ assert port in ports
95
+ assert pair.server.available_data_ports.qsize() == 1
96
+
97
+
98
+ @pytest.mark.asyncio
99
+ async def test_data_ports_remains_empty(pair_factory, Server):
100
+ async with pair_factory(None, Server(data_ports=[])) as pair:
101
+ assert pair.server.available_data_ports.qsize() == 0
102
+
103
+
104
+ @pytest.mark.asyncio
105
+ async def test_pasv_connection_port_reused(
106
+ pair_factory,
107
+ Server,
108
+ unused_tcp_port,
109
+ ):
110
+ s = Server(data_ports=[unused_tcp_port])
111
+ async with pair_factory(None, s) as pair:
112
+ r, w = await pair.client.get_passive_connection()
113
+ host, port, *_ = w.transport.get_extra_info("peername")
114
+ assert port == unused_tcp_port
115
+ assert pair.server.available_data_ports.qsize() == 0
116
+ w.close()
117
+ await pair.client.quit()
118
+ pair.client.close()
119
+ assert pair.server.available_data_ports.qsize() == 1
120
+ await pair.client.connect(
121
+ pair.server.server_host,
122
+ pair.server.server_port,
123
+ )
124
+ await pair.client.login()
125
+ r, w = await pair.client.get_passive_connection()
126
+ host, port, *_ = w.transport.get_extra_info("peername")
127
+ assert port == unused_tcp_port
128
+ assert pair.server.available_data_ports.qsize() == 0
129
+
130
+
131
+ @pytest.mark.asyncio
132
+ async def test_pasv_connection_pasv_forced_response_address(pair_factory, Client, Server):
133
+ def ipv4_used():
134
+ try:
135
+ ipaddress.IPv4Address(pair.host)
136
+ return True
137
+ except ValueError:
138
+ return False
139
+
140
+ # using TEST-NET-1 address
141
+ ipv4_address = "192.0.2.1"
142
+ async with pair_factory(
143
+ client=Client(trust_server_pasv_ipv4_address=True),
144
+ server=Server(ipv4_pasv_forced_response_address=ipv4_address),
145
+ ) as pair:
146
+ assert pair.server.ipv4_pasv_forced_response_address == ipv4_address
147
+
148
+ if ipv4_used():
149
+ # The connection should fail here because the server starts to listen for
150
+ # the passive connections on the host (IPv4 address) that is used
151
+ # by the control channel. In reality, if the server is behind NAT,
152
+ # the server is reached with the defined external IPv4 address,
153
+ # i.e. we can check that the connection to
154
+ # pair.server.ipv4_pasv_forced_response_address failed to know that
155
+ # the server returned correct external IP
156
+ # ...
157
+ # but we can't use check like this:
158
+ # with pytest.raises(OSError):
159
+ # await pair.client.get_passive_connection(commands=["pasv"])
160
+ # because there is no such ipv4 which will be non-routable, so
161
+ # we can only check `PASV` response
162
+ ip, _ = await pair.client._do_pasv()
163
+ assert ip == ipv4_address
164
+
165
+ # With epsv the connection should open as that does not use the
166
+ # external IPv4 address but just tells the client the port to connect
167
+ # to
168
+ await pair.client.get_passive_connection(commands=["epsv"])
169
+
170
+
171
+ @pytest.mark.parametrize("method", ["epsv", "pasv"])
172
+ @pytest.mark.asyncio
173
+ async def test_pasv_connection_no_free_port(
174
+ pair_factory,
175
+ Server,
176
+ expect_codes_in_exception,
177
+ method,
178
+ ):
179
+ s = Server(data_ports=[])
180
+ async with pair_factory(None, s, do_quit=False, host="127.0.0.1") as pair:
181
+ assert pair.server.available_data_ports.qsize() == 0
182
+ with expect_codes_in_exception("421"):
183
+ await pair.client.get_passive_connection(commands=[method])
184
+
185
+
186
+ @pytest.mark.asyncio
187
+ async def test_pasv_connection_busy_port(
188
+ pair_factory,
189
+ Server,
190
+ unused_tcp_port_factory,
191
+ ):
192
+ ports = [unused_tcp_port_factory(), unused_tcp_port_factory()]
193
+ async with pair_factory(None, Server(data_ports=ports)) as pair:
194
+ conflicting_server = await asyncio.start_server(
195
+ lambda r, w: w.close(),
196
+ host=pair.server.server_host,
197
+ port=ports[0],
198
+ )
199
+ r, w = await pair.client.get_passive_connection()
200
+ host, port, *_ = w.transport.get_extra_info("peername")
201
+ assert port == ports[1]
202
+ assert pair.server.available_data_ports.qsize() == 1
203
+ conflicting_server.close()
204
+ await conflicting_server.wait_closed()
205
+
206
+
207
+ @pytest.mark.asyncio
208
+ async def test_pasv_connection_busy_port2(
209
+ pair_factory,
210
+ Server,
211
+ unused_tcp_port_factory,
212
+ expect_codes_in_exception,
213
+ ):
214
+ ports = [unused_tcp_port_factory()]
215
+ s = Server(data_ports=ports)
216
+ async with pair_factory(None, s, do_quit=False) as pair:
217
+ conflicting_server = await asyncio.start_server(
218
+ lambda r, w: w.close(),
219
+ host=pair.server.server_host,
220
+ port=ports[0],
221
+ )
222
+ with expect_codes_in_exception("421"):
223
+ await pair.client.get_passive_connection()
224
+ conflicting_server.close()
225
+ await conflicting_server.wait_closed()
226
+
227
+
228
+ @pytest.mark.asyncio
229
+ async def test_server_shutdown(pair_factory):
230
+ async with pair_factory(do_quit=False) as pair:
231
+ await pair.client.list()
232
+ await pair.server.close()
233
+ with pytest.raises(ConnectionResetError):
234
+ await pair.client.list()
235
+
236
+
237
+ @pytest.mark.asyncio
238
+ async def test_client_session_context_manager(pair_factory):
239
+ async with pair_factory(connected=False) as pair:
240
+ async with aioftp.Client.context(*pair.server.address) as client:
241
+ await client.list()
242
+
243
+
244
+ @pytest.mark.asyncio
245
+ async def test_long_login_sequence_fail(
246
+ pair_factory,
247
+ expect_codes_in_exception,
248
+ ):
249
+ class CustomServer(aioftp.Server):
250
+ def __init__(self, *args, **kwargs):
251
+ super().__init__(*args, **kwargs)
252
+ self.commands_mapping["acct"] = self.acct
253
+
254
+ async def user(self, connection, rest):
255
+ connection.response("331")
256
+ return True
257
+
258
+ async def pass_(self, connection, rest):
259
+ connection.response("332")
260
+ return True
261
+
262
+ async def acct(self, connection, rest):
263
+ connection.response("333")
264
+ return True
265
+
266
+ factory = pair_factory(
267
+ logged=False,
268
+ server_factory=CustomServer,
269
+ do_quit=False,
270
+ )
271
+ async with factory as pair:
272
+ with expect_codes_in_exception("333"):
273
+ await pair.client.login()
274
+
275
+
276
+ @pytest.mark.asyncio
277
+ async def test_bad_sublines_seq(pair_factory, expect_codes_in_exception):
278
+ class CustomServer(aioftp.Server):
279
+ async def write_response(self, stream, code, lines="", list=False):
280
+ import functools
281
+
282
+ lines = aioftp.wrap_with_container(lines)
283
+ write = functools.partial(self.write_line, stream)
284
+ *body, tail = lines
285
+ for line in body:
286
+ await write(code + "-" + line)
287
+ await write(str(int(code) + 1) + "-" + tail)
288
+ await write(code + " " + tail)
289
+
290
+ factory = pair_factory(connected=False, server_factory=CustomServer)
291
+ async with factory as pair:
292
+ with expect_codes_in_exception("220"):
293
+ await pair.client.connect(
294
+ pair.server.server_host,
295
+ pair.server.server_port,
296
+ )
297
+ await pair.client.login()
298
+
299
+
300
+ @pytest.mark.asyncio
301
+ async def test_welcome_message(pair_factory, Server):
302
+ welcome_message = "Welcome to the FTP server!"
303
+ async with pair_factory(
304
+ server=Server(welcome_message=welcome_message),
305
+ connected=False,
306
+ ) as pair:
307
+ lines = await pair.client.connect(
308
+ pair.server.server_host,
309
+ pair.server.server_port,
310
+ )
311
+ assert lines == [" " + welcome_message]
312
+
313
+
314
+ @pytest.mark.asyncio
315
+ async def test_system_type(pair_factory, Server):
316
+ system_type = "My custom OS"
317
+ async with pair_factory(
318
+ server=Server(system_type=system_type),
319
+ ) as pair:
320
+ resp = await pair.client.command("SYST", expected_codes=(215,))
321
+ assert resp == ("215", [" " + system_type])
322
+
323
+
324
+ @pytest.mark.asyncio
325
+ async def test_client_timeout_passive_connection(pair_factory, Client, monkeypatch):
326
+ open_connection = asyncio.open_connection
327
+
328
+ async def slow_open_connection(host, port, **kwargs):
329
+ await asyncio.sleep(1)
330
+ return await open_connection(host, port, **kwargs)
331
+
332
+ async with pair_factory(Client(connection_timeout=0.5), logged=True) as pair:
333
+ with monkeypatch.context() as m:
334
+ m.setattr("asyncio.open_connection", slow_open_connection)
335
+ with pytest.raises(asyncio.TimeoutError):
336
+ await pair.client.get_passive_connection()
harbor/sources/aioftp-v11/grading/baseline/tests/test_corner_cases.py ADDED
@@ -0,0 +1,77 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from pathlib import Path
2
+
3
+ import pytest
4
+
5
+ import aioftp
6
+
7
+
8
+ @pytest.mark.asyncio
9
+ async def test_server_side_exception(pair_factory):
10
+ class CustomServer(aioftp.Server):
11
+ def __init__(self, *args, **kwargs):
12
+ super().__init__(*args, **kwargs)
13
+ self.commands_mapping["custom"] = self.custom
14
+
15
+ async def custom(*args, **kwargs):
16
+ raise RuntimeError("Test error")
17
+
18
+ factory = pair_factory(server_factory=CustomServer, do_quit=False)
19
+ async with factory as pair:
20
+ with pytest.raises(ConnectionResetError):
21
+ await pair.client.command("custom", "200")
22
+
23
+
24
+ @pytest.mark.asyncio
25
+ async def test_bad_type_value(pair_factory, expect_codes_in_exception):
26
+ async with pair_factory() as pair:
27
+ with expect_codes_in_exception("502"):
28
+ await pair.client.command("type FOO", "200")
29
+
30
+
31
+ @pytest.mark.asyncio
32
+ async def test_pbsz(pair_factory):
33
+ async with pair_factory() as pair:
34
+ await pair.client.command("pbsz", "200")
35
+
36
+
37
+ @pytest.mark.asyncio
38
+ async def test_prot(pair_factory, expect_codes_in_exception):
39
+ async with pair_factory() as pair:
40
+ await pair.client.command("prot P", "200")
41
+ with expect_codes_in_exception("502"):
42
+ await pair.client.command("prot foo", "200")
43
+
44
+
45
+ @pytest.mark.asyncio
46
+ async def test_server_ipv6_pasv(pair_factory, expect_codes_in_exception):
47
+ async with pair_factory(host="::1", do_quit=False) as pair:
48
+ with expect_codes_in_exception("503"):
49
+ await pair.client.get_passive_connection(commands=["pasv"])
50
+
51
+
52
+ @pytest.mark.asyncio
53
+ async def test_epsv_extra_arg(pair_factory, expect_codes_in_exception):
54
+ async with pair_factory(do_quit=False) as pair:
55
+ with expect_codes_in_exception("522"):
56
+ await pair.client.command("epsv foo", "229")
57
+
58
+
59
+ @pytest.mark.asyncio
60
+ async def test_bad_server_path_io(
61
+ pair_factory,
62
+ Server,
63
+ expect_codes_in_exception,
64
+ ):
65
+ class BadPathIO(aioftp.MemoryPathIO):
66
+ async def is_file(*a, **kw):
67
+ return False
68
+
69
+ async def is_dir(*a, **kw):
70
+ return False
71
+
72
+ s = Server(path_io_factory=BadPathIO)
73
+ async with pair_factory(None, s) as pair:
74
+ pio = pair.server.path_io_factory()
75
+ async with pio.open(Path("/foo"), "wb"):
76
+ pass
77
+ await pair.client.list()
harbor/sources/aioftp-v11/grading/baseline/tests/test_current_directory.py ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import pathlib
2
+
3
+ import pytest
4
+
5
+ import aioftp
6
+
7
+
8
+ @pytest.mark.asyncio
9
+ async def test_current_directory_simple(pair_factory):
10
+ async with pair_factory() as pair:
11
+ cwd = await pair.client.get_current_directory()
12
+ assert cwd == pathlib.PurePosixPath("/")
13
+
14
+
15
+ @pytest.mark.asyncio
16
+ async def test_current_directory_not_default(pair_factory, Server):
17
+ s = Server([aioftp.User(home_path="/home")])
18
+ async with pair_factory(None, s) as pair:
19
+ cwd = await pair.client.get_current_directory()
20
+ assert cwd == pathlib.PurePosixPath("/home")
21
+
22
+
23
+ @pytest.mark.asyncio
24
+ async def test_mlsd(pair_factory):
25
+ async with pair_factory() as pair:
26
+ await pair.make_server_files("test.txt")
27
+ (path, stat), *_ = files = await pair.client.list()
28
+ assert len(files) == 1
29
+ assert path == pathlib.PurePosixPath("test.txt")
30
+ assert stat["type"] == "file"
31
+
32
+
33
+ @pytest.mark.asyncio
34
+ async def test_resolving_double_dots(pair_factory):
35
+ async with pair_factory() as pair:
36
+ await pair.make_server_files("test.txt")
37
+
38
+ async def f():
39
+ cwd = await pair.client.get_current_directory()
40
+ assert cwd == pathlib.PurePosixPath("/")
41
+ (path, stat), *_ = files = await pair.client.list()
42
+ assert len(files) == 1
43
+ assert path == pathlib.PurePosixPath("test.txt")
44
+ assert stat["type"] == "file"
45
+
46
+ await f()
47
+ await pair.client.change_directory("../../../")
48
+ await f()
49
+ await pair.client.change_directory("/a/../b/..")
50
+ await f()