Conversation
…son-returning API.
b06c786 to
009e126
Compare
…son-returning API.
…son-returning API.
|
Maintainer update: reconciled against current main in local commit 29e9408. The new immutable-profile snapshot regressions pass (2/2); Ruff and |
009e126 to
29e9408
Compare
|
Published: the verified current-main reconciliation is now the PR head at |
|
Closing this PR because upstream has now resolved #111647 through merged #113080 with a different design decision. #113080 keeps locked auth-database handling fail-closed, improves the per-database error reporting, and updates the documentation so macOS/Linux no longer promise live profile copying while Chrome is running. This PR instead restores live snapshots via immutable SQLite reads, so its core premise no longer matches the direction that was accepted upstream. The current head was still valid and tested, but keeping this alternate policy carrier open would now mean arguing to reverse the WAL/consistency stance rather than completing the accepted fix. |
What does this PR do?
This fixes real-profile snapshots on macOS when Google Chrome is still running. SQLite authentication databases are now opened as immutable read-only sources and backed up into a new sibling file, rather than writing into a previously used snapshot database. The completed backup atomically replaces the old file after its stale SQLite sidecars are removed, so an abandoned destination lock or WAL cannot make the browser profile appear unavailable.
Related Issue
Fixes #111647
Type of Change
Changes Made
hermes_cli/browser_connect.py— opens Chrome auth databases through an immutable read-only SQLite URI, backs each one up to a fresh temporary sibling, removes obsolete destination SQLite sidecars, and atomically replaces the old snapshot file.tests/tools/test_browser_real_profile.py— covers a live WAL source with a stale locked destination, verifies the immutable URI, and updates lock/WAL expectations for atomic snapshot replacement.How to Test
scripts/run_tests.sh tests/tools/test_browser_real_profile.py -q— 82 passed..venv/bin/ruff check hermes_cli/browser_connect.py tests/tools/test_browser_real_profile.py— all checks passed.Evidence
_copy_auth_file(...) is Truewith that lock present.scripts/run_tests.sh tests/tools/test_browser_real_profile.py -qcompleted with 82 passed, including the live-WAL and stale-destination-lock regression.Review follow-up
This is scoped to the macOS snapshot path. The regression models Chrome's live WAL and a prior Hermes destination lock locally; Windows sharing semantics and Docker publishing remain covered by their platform-specific CI paths rather than claimed as locally verified here.
Checklist
Code
Documentation & Housekeeping
cli-config.yaml.example: N/ACONTRIBUTING.mdorAGENTS.md: N/A