Repository navigation
feat!: remove the deprecated Python bridge and inert compatibility options - #815
Conversation
A deployment that pinned FS_SAFE_PYTHON_MODE=require or off would silently run in auto after the bridge removal; say so in the changelog and migration guide.
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: blocked before merge. Reviewed October 1, 2026, 12:51 PM ET / 16:51 UTC (Revision 2). ClawSweeper reviewWhat this changesThe PR removes the deprecated Python configuration bridge and unused public options, updates API snapshots, and documents migration to native configuration. Regression provenancePossible regression — suspected (reviewed change). No predecessor PR is attributed. Merge readiness⛔ Blocked before merge - 8 items remain The removal remains distinct from current main and v0.22.0. The previous upgrade-safety finding is still present: existing native-mode requirements silently change after upgrade. Priority: P2 Review scores
Verification
How this fits togetherfs-safe guards filesystem operations on untrusted paths. Its process-wide configuration selects native operations, supported guarded fallbacks, or failure when required native support is unavailable. flowchart TD
A[Startup configuration] --> C[Native mode selection]
B[Environment settings] --> C
C --> D{Selected policy}
D --> E[Native filesystem operations]
D --> F[Guarded fallback operations]
D --> G[Helper unavailable error]
Decision needed
Why: The reported breaking-release approval does not independently establish acceptance of changing deployed native requirements to auto. Before merge
Findings
Agent review detailsSecurityNeeds attention: Removing legacy precedence can silently relax a deployed native requirement; no additional supply-chain change or root-escape exploit was established. Review metrics
Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Remove inert type options while retaining transitional legacy mode mapping and warnings, or reject obsolete policy settings before filesystem operations. Do we have a high-confidence way to reproduce the issue? Yes, from source: with only legacy require/off configured, both mode selectors now choose auto; the loader and Root removal show the resulting policy change. No runtime reproduction was executed. Is this the best way to solve the issue? No. Removing inert options is focused, but silently ignoring active legacy policy is less safe than transitional mapping or explicit rejection. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against e4d9f9b790ae. LabelsLabel changes: No label changes. Label justifications:
EvidenceSecurity concerns:
What I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (1 earlier review cycle)
|
) Collapse sync/async twin scenarios into rows, share the Root-read observer and Windows hostile-diagnostic harnesses, table the read-bypass rejections while keeping exact error codes, and delete five smoke tests strictly covered by stronger tests. Tests only; 250 to 246 expanded tests, net -363 lines.
…ptor cases (#806) Share one cfg(test) temp-path builder and the Windows test directory opener across 20 native test modules, replace six TAR codec fixture arrays with one helper, and parameterize the cancellation and descriptor-rejection twins. All 188 Rust test names are unchanged; Rust test code only, net -247 lines.
Fold the PAX security, decimal, and raw-admission suites into archive-pax.test.ts and the GNU and ignored-member suites into archive-tar-admission.test.ts, sharing one backend matrix and fixture setup while keeping every family's assertions. All 2,048 case names and routes are preserved; the CI lines selecting the removed files are updated. Net -145 test lines.
Share the Root-lock directory-replacement fixture (keeping the Windows and POSIX implementations), table durable-queue transitions, and share ownership-token acquisition and final-resolver interception scaffolding. Test counts identical; tests only, net -168 lines.
…es (#809) Share temp-workspace observers and lifecycle fixtures, staged-settlement hostile errors, and cleanup bindings through test helpers; table directory-durability error routes; merge the split canonical-admission suite into root discovery. 481 to 480 expanded tests (one merged duplicate scenario keeps both assertions); tests only, net -256 lines.
Merge five split Root test siblings back into their owners once their fixtures are shared, add shared no-replace adapter and selected-target admission helpers, and table writable-open collisions. 168 expanded tests before and after; tests only, net -267 lines and five fewer files.
…es (#811) Replace 29 copies of the bundled-addon probe with one helper that keeps optional and required-environment policies, share the native archive parity fixture, table permission diagnostics, API wrapper, home-path and queue layout cases, and delete two DACL cases strictly covered by a stronger test. Tests only; net -354 lines.
Merge the Windows locality-failure suite into the portable Windows security suite with shared setup and read spies, run workspace read contracts per sync/async variant from one body, share fallback-write cleanup and the FIFO-swap interceptor, table Root-open mode options, and drop one subsumed smoke test. Tests only; net -175 lines.
…#814) Share atomic settlement and copy close-precedence test machinery, merge the copy-wrapper and three ZIP admission siblings into their owners, and table copy-fallback guard, publication target-swap, preserved-mode, and TAR boundary twins. 525 registered tests before and after; tests only, net -562 lines and four fewer files.
…pete/deslop-r3-breaking # Conflicts: # test/atomic-dirmode-regression.test.ts # test/atomic-fchmod-regression.test.ts
…eaking # Conflicts: # test/atomic-dirmode-regression.test.ts # test/atomic-fchmod-regression.test.ts
Reject removed Python-mode variables with an actionable migration error unless explicit native configuration takes precedence. Preserve the intentional removal from #815 while preventing require/off from silently becoming auto. Document the exact environment and API migration for openclaw/acpx#877. Run manual release dry runs through unsigned Windows runtime checks and host-package smoke tests without entering release-signing. Preserve protected tag signing, signed runtime validation, package verification, and publication dependencies. Validation: legacy-version reproduction; focused regression tests; full Crabbox gate with its stale documentation assertion corrected and rerun; package checks; actionlint; isolated Codex autoreview through P2; exact-head cross-platform CI. No version bump, tag, release, security-setting change, or deployment.
What Problem This Solves
The Python configuration bridge has been deprecated since 0.5.0 and only translated old settings into native mode selection, and four public options were accepted solely for type compatibility while doing nothing: secure-temp
chmodSync, atomic adapterchmod/chmodSync, RootnonBlockingRead, and ACLprincipalSids.User Impact
Breaking (approved by the maintainer for the next minor release):
configureFsSafePython,FsSafePythonConfig,pythonPath, and the six Python environment variables (FS_SAFE_PYTHON_MODE,OPENCLAW_FS_SAFE_PYTHON_MODE,FS_SAFE_PYTHON,OPENCLAW_FS_SAFE_PYTHON,OPENCLAW_PINNED_PYTHON,OPENCLAW_PINNED_WRITE_PYTHON). UseconfigureFsSafeNative,FsSafeNativeConfig, andFS_SAFE_NATIVE_MODE(orOPENCLAW_FS_SAFE_NATIVE_MODE).FS_SAFE_PYTHON_MODE=requireoroffruns inautoafter upgrading until it setsFS_SAFE_NATIVE_MODE; the changelog and migration guide say so explicitly.descriptorfor secure-temp,FileHandle.chmod/fchmodSyncfor atomic writes), automatic nonblocking read admission, and direct SID classification are unchanged.No version bump here; releases stay separate.
Why This Change Was Made
Part of the cleanup campaign: compatibility surface that no longer does anything. Net -172 lines (production -69). Persisted formats, lock protocols, receipts, and platform policies from the compatibility inventory are untouched.
Evidence
test/public-api.jsonregenerated viacheck-pack --update-public-api: only the Python exports change;check-pack,docs:check, documentation-contract, public-api-surface, and api-coverage tests pass (36).Focused affected suites: 363 passed, 25 platform skips; seven deleted tests exercised only the removed Python behavior. A type-rejection probe confirms removed options fail to compile; 28 native-alias/removed-environment cases pass.
tsc,lint:file-size,lint:fs-boundary: pass. Codex autoreview (P0-P2): clean.Tests added or updated when behavior changed
Security and compatibility impact considered
CHANGELOG.mdupdated when release-relevantNo credentials, private paths, private hosts, or sensitive contents included