verifiers 0.3.2.dev41__py3-none-any.whl → 0.3.2.dev42__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- verifiers/v1/harnesses/openclaw/harness.py +59 -15
- {verifiers-0.3.2.dev41.dist-info → verifiers-0.3.2.dev42.dist-info}/METADATA +1 -1
- {verifiers-0.3.2.dev41.dist-info → verifiers-0.3.2.dev42.dist-info}/RECORD +6 -6
- {verifiers-0.3.2.dev41.dist-info → verifiers-0.3.2.dev42.dist-info}/WHEEL +0 -0
- {verifiers-0.3.2.dev41.dist-info → verifiers-0.3.2.dev42.dist-info}/entry_points.txt +0 -0
- {verifiers-0.3.2.dev41.dist-info → verifiers-0.3.2.dev42.dist-info}/licenses/LICENSE +0 -0
|
@@ -20,10 +20,48 @@ logger = logging.getLogger(__name__)
|
|
|
20
20
|
# OpenClaw and its bundled Node runtime exceed the small /tmp tmpfs in some VMs.
|
|
21
21
|
OPENCLAW_DIR = "/var/tmp/vf-openclaw-{version}"
|
|
22
22
|
OPENCLAW_BIN = f"{OPENCLAW_DIR}/bin/openclaw"
|
|
23
|
-
|
|
23
|
+
SETUP = r"""
|
|
24
24
|
set -e
|
|
25
|
-
|
|
26
|
-
|
|
25
|
+
if [ ! -x "$VF_OPENCLAW_BIN" ]; then
|
|
26
|
+
command -v curl >/dev/null || (apt-get update -qq && apt-get install -y -qq curl ca-certificates >/dev/null)
|
|
27
|
+
curl -fsSL --proto '=https' --tlsv1.2 https://openclaw.ai/install-cli.sh \
|
|
28
|
+
| bash -s -- --prefix "$VF_OPENCLAW_DIR" --version "$VF_OPENCLAW_VERSION" --no-onboard
|
|
29
|
+
fi
|
|
30
|
+
set -- $(find "$VF_OPENCLAW_DIR/tools" -type f -path '*/openclaw/dist/session-accessor.sqlite-transcript-store-*.js')
|
|
31
|
+
[ "$#" -eq 1 ] || { echo "could not locate OpenClaw's transcript sanitizer for replay patch" >&2; exit 1; }
|
|
32
|
+
"$VF_OPENCLAW_DIR/tools/node/bin/node" - "$1" <<'NODE'
|
|
33
|
+
const fs = require("node:fs");
|
|
34
|
+
const file = process.argv[2];
|
|
35
|
+
const stat = fs.statSync(file);
|
|
36
|
+
if (stat.size > 1_000_000) {
|
|
37
|
+
throw new Error("OpenClaw's transcript sanitizer exceeds the replay patch size limit");
|
|
38
|
+
}
|
|
39
|
+
const source = fs.readFileSync(file, "utf8");
|
|
40
|
+
const patches = [
|
|
41
|
+
[
|
|
42
|
+
"const OPAQUE_REPLAY_TOKEN_RE = /^[A-Za-z0-9+/_-]+={0,2}$/;",
|
|
43
|
+
"const OPAQUE_REPLAY_TOKEN_RE = /^[A-Za-z0-9+/_-]+={0,2}(?:[.][A-Za-z0-9+/_-]+={0,2})*$/;",
|
|
44
|
+
],
|
|
45
|
+
["\t\tsummary: [],", "\t\tsummary: parsed.summary ?? [],"],
|
|
46
|
+
];
|
|
47
|
+
let patched = source;
|
|
48
|
+
for (const [before, after] of patches) {
|
|
49
|
+
patched = patched.replaceAll(before, after);
|
|
50
|
+
}
|
|
51
|
+
if (!patches.every(([, after]) => patched.includes(after))) {
|
|
52
|
+
throw new Error("OpenClaw's transcript sanitizer does not match the replay patch");
|
|
53
|
+
}
|
|
54
|
+
if (patched !== source) {
|
|
55
|
+
const temporary = `${file}.${process.pid}.tmp`;
|
|
56
|
+
try {
|
|
57
|
+
// Publish complete bytes at once so live and concurrent setups never see a partial bundle.
|
|
58
|
+
fs.writeFileSync(temporary, patched, { mode: stat.mode });
|
|
59
|
+
fs.renameSync(temporary, file);
|
|
60
|
+
} finally {
|
|
61
|
+
fs.rmSync(temporary, { force: true });
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
NODE
|
|
27
65
|
"""
|
|
28
66
|
|
|
29
67
|
OPENCLAW_COMMAND = [
|
|
@@ -82,7 +120,7 @@ wait "$acp_pid"
|
|
|
82
120
|
|
|
83
121
|
|
|
84
122
|
class OpenClawHarnessConfig(HarnessConfig):
|
|
85
|
-
version: str = Field(default="2026.
|
|
123
|
+
version: str = Field(default="2026.8.1", pattern=r"^[A-Za-z0-9._+-]+$")
|
|
86
124
|
"""OpenClaw release to install, pinned for reproducibility."""
|
|
87
125
|
use_bundled_skill: bool = True
|
|
88
126
|
"""Enable OpenClaw's bundled skill catalog in addition to uploaded harness skills."""
|
|
@@ -117,20 +155,27 @@ class OpenClawHarness(ACPHarness[OpenClawHarnessConfig]):
|
|
|
117
155
|
await runtime.write(ready_path, b"")
|
|
118
156
|
directory = OPENCLAW_DIR.format(version=self.config.version)
|
|
119
157
|
binary = OPENCLAW_BIN.format(version=self.config.version)
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
)
|
|
123
|
-
ensure = shlex.quote(f"[ -x {binary} ] || ({script})")
|
|
158
|
+
# Borrowed runtimes can share this cache, so one filesystem lock owns both
|
|
159
|
+
# installation and the transcript adjustment.
|
|
124
160
|
guarded = (
|
|
125
|
-
f"mkdir -p {directory} && "
|
|
126
|
-
f'"$(command -v flock || command -v lockf)"
|
|
127
|
-
f"
|
|
161
|
+
f"mkdir -p {shlex.quote(directory)} && "
|
|
162
|
+
f'"$(command -v flock || command -v lockf)" '
|
|
163
|
+
f"{shlex.quote(f'{directory}/install.lock')} "
|
|
164
|
+
f"bash -o pipefail -c {shlex.quote(SETUP)}"
|
|
128
165
|
)
|
|
129
166
|
logger.info("openclaw: ensuring OpenClaw %s is installed", self.config.version)
|
|
130
|
-
result = await runtime.run(
|
|
167
|
+
result = await runtime.run(
|
|
168
|
+
["sh", "-c", guarded],
|
|
169
|
+
{
|
|
170
|
+
**self.config.resolved_env,
|
|
171
|
+
"VF_OPENCLAW_BIN": binary,
|
|
172
|
+
"VF_OPENCLAW_DIR": directory,
|
|
173
|
+
"VF_OPENCLAW_VERSION": self.config.version,
|
|
174
|
+
},
|
|
175
|
+
)
|
|
131
176
|
if result.exit_code != 0:
|
|
132
177
|
detail = (result.stderr or result.stdout).strip()[-500:]
|
|
133
|
-
raise RuntimeError(f"OpenClaw
|
|
178
|
+
raise RuntimeError(f"OpenClaw setup failed: {detail}")
|
|
134
179
|
await super().setup(runtime)
|
|
135
180
|
|
|
136
181
|
async def prepare_acp(
|
|
@@ -149,8 +194,6 @@ class OpenClawHarness(ACPHarness[OpenClawHarnessConfig]):
|
|
|
149
194
|
config_path = f"{state_dir}/openclaw.json"
|
|
150
195
|
skills_dir = f"{state_dir}/skills"
|
|
151
196
|
config = {
|
|
152
|
-
# Provider state must remain byte-exact within this isolated rollout.
|
|
153
|
-
"logging": {"redactSensitive": "off"},
|
|
154
197
|
"gateway": {
|
|
155
198
|
"mode": "local",
|
|
156
199
|
"bind": "loopback",
|
|
@@ -180,6 +223,7 @@ class OpenClawHarness(ACPHarness[OpenClawHarnessConfig]):
|
|
|
180
223
|
provider: {
|
|
181
224
|
"baseUrl": endpoint,
|
|
182
225
|
"apiKey": "${OPENCLAW_INTERCEPT_KEY}",
|
|
226
|
+
"request": {"allowPrivateNetwork": True},
|
|
183
227
|
}
|
|
184
228
|
},
|
|
185
229
|
},
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: verifiers
|
|
3
|
-
Version: 0.3.2.
|
|
3
|
+
Version: 0.3.2.dev42
|
|
4
4
|
Summary: Verifiers: Environments for LLM Reinforcement Learning
|
|
5
5
|
Project-URL: Homepage, https://github.com/primeintellect-ai/verifiers
|
|
6
6
|
Project-URL: Documentation, https://github.com/primeintellect-ai/verifiers
|
|
@@ -101,7 +101,7 @@ verifiers/v1/harnesses/mini_swe_agent/program.py,sha256=Beej-JLIgSqnqIqB746oKU6k
|
|
|
101
101
|
verifiers/v1/harnesses/null/__init__.py,sha256=XDeKOPeoXUQi9US9_Z3_yH9YaZ4EiOMKJmUtNNdtD7s,127
|
|
102
102
|
verifiers/v1/harnesses/null/harness.py,sha256=RWj2I7auxYe4dJ885DhqH1MN15iUS-TKT7-gEWNrgmM,1412
|
|
103
103
|
verifiers/v1/harnesses/openclaw/__init__.py,sha256=kNyfPB1sGwEf4K3mTfKN0VEyxun3SGvNpvArVKvH-x8,160
|
|
104
|
-
verifiers/v1/harnesses/openclaw/harness.py,sha256=
|
|
104
|
+
verifiers/v1/harnesses/openclaw/harness.py,sha256=EREEYr3J0Qn8mK_YShnCSHctMtsiIN07rj00kq1Lxoc,11229
|
|
105
105
|
verifiers/v1/harnesses/pi/__init__.py,sha256=1mSnzOf-RdEchdeg6IHtcdobG5KIpAhuTdUIgsCIn74,117
|
|
106
106
|
verifiers/v1/harnesses/pi/harness.py,sha256=M0BRsfJxnBNP-KCrp0vT5gHlaJEDnyti5x_3V5Py40M,7024
|
|
107
107
|
verifiers/v1/harnesses/pool/__init__.py,sha256=HTYsNiWGdiNEsSHj4xhPmshJSNb7SHjQ7d4yZQ4p3HM,127
|
|
@@ -185,8 +185,8 @@ verifiers/v1/utils/prime.py,sha256=UTYRjp9cbjNb6CVmBHda-1wWZAIIfxNOmTyNuT7_wL4,9
|
|
|
185
185
|
verifiers/v1/utils/retries.py,sha256=Y2ZgrAjn-qNkRKZP_RVNL_7EK0iaRcZeCa404lpGYi4,5417
|
|
186
186
|
verifiers/v1/utils/score.py,sha256=493yJVMw8teCu9JxapxMFPFzI0hNUqdo0Y2nGW4kckk,6200
|
|
187
187
|
verifiers/v1/utils/version.py,sha256=-obEo_-l9-D8FLef4hYxncOe-uJpxrM1g2Hig_37Sgs,1607
|
|
188
|
-
verifiers-0.3.2.
|
|
189
|
-
verifiers-0.3.2.
|
|
190
|
-
verifiers-0.3.2.
|
|
191
|
-
verifiers-0.3.2.
|
|
192
|
-
verifiers-0.3.2.
|
|
188
|
+
verifiers-0.3.2.dev42.dist-info/METADATA,sha256=jUn_EzfMNYKrakZ9wtcpZBjuM5u1gagwHsU0tS_8oow,4065
|
|
189
|
+
verifiers-0.3.2.dev42.dist-info/WHEEL,sha256=zOwg4jB6zX2kU910N-cMawjivD6tO8NEWvE12je1bVk,87
|
|
190
|
+
verifiers-0.3.2.dev42.dist-info/entry_points.txt,sha256=uqQje0TMsr7k6nXlWxlPs13Si0evb3pVCEDF6c-YL80,241
|
|
191
|
+
verifiers-0.3.2.dev42.dist-info/licenses/LICENSE,sha256=v0RrUsdV3IDoZhrRce297IXS3xMHNJ-_LdLpFAUWb9k,1072
|
|
192
|
+
verifiers-0.3.2.dev42.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|