fix(health-check): read vault.remote_url from config, not SUTANDO_MEMORY_REPO (#1450)#1862
Open
bassilkhilo-ag2 wants to merge 2 commits into
Open
Conversation
…ORY_REPO (sonichi#1450 closes health-check portion) check_memory_sync() was reading SUTANDO_MEMORY_REPO from .env — the legacy env var retired in sonichi#1446. Users who correctly configured vault.remote_url in sutando.config.local.json (M2+ / sync-workspace.sh) saw a false-positive "SUTANDO_MEMORY_REPO not set — cross-machine sync disabled" warning on every health-check run. Fix: try resolve_vault(repo_root=REPO_DIR) first (canonical M2+ path); fall back to SUTANDO_MEMORY_REPO from .env during the sonichi#1446 deprecation window. Update the "not configured" warning message to name vault.remote_url (the actual config key to set) and point at sync-workspace.sh --init. Also update the "never synced" legacy-clone warning from sync-memory.sh → sync-workspace.sh (supersedes the string-only change from PR sonichi#1847 so sonichi#1847's base issue no longer matters — both files change here). Tests: 4 new cases in health-check-memory-sync-vault.test.py cover vault-url path, .env fallback, unconfigured warning text, and the never-synced message pointing at sync-workspace.sh. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KXQJogmVSdYrKtYX1LwzwT
Contributor
|
@cla-assistant check |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
check_memory_sync()insrc/health-check.pyreadSUTANDO_MEMORY_REPOfrom.env— the env var retired in #1446. Users who correctly configuredvault.remote_urlinsutando.config.local.json(M2+ /sync-workspace.sh) saw a false-positive:…on every health-check run, even with sync working correctly via
sync-workspace.sh.Additionally, the "never synced" fallback message said
sync-memory.sh(deprecated), notsync-workspace.sh.Fix
resolve_vault(repo_root=REPO_DIR)["remote_url"]fromsutando_config.py— readsvault.remote_urlfromsutando.config.local.json.vault.remote_urlis empty, fall back toSUTANDO_MEMORY_REPOin.envfor installs that haven't migrated yet (the feat(sync): PR-2 — vault URL from config + --vault-url flag, sync-memory.sh deprecation #1446 deprecation window).vault.remote_url(the config key to set) and points atsync-workspace.sh --init.sync-workspace.sh(supersedes PR fix(health-check): point legacy sync warning at sync-workspace.sh (#1450 partial) #1847's string-only change; both files differ here so there's no conflict).Tests
4 new cases in
tests/health-check-memory-sync-vault.test.py:vault.remote_urlset in config → no "not configured" warningvault.remote_urlempty +SUTANDO_MEMORY_REPOin.env→ .env fallback worksvault.remote_url, notSUTANDO_MEMORY_REPOsync-workspace.sh, notsync-memory.shAll 4 pass. Existing health-check tests unaffected.
Closes
SUTANDO_MEMORY_REPO/sync-memory.shreferences inhealth-check.py)health-check.py(line 190 now sayssync-workspace.shhere too). fix(health-check): point legacy sync warning at sync-workspace.sh (#1450 partial) #1847 may close or rebase out that line if it lands after this one.🤖 Generated with Claude Code
https://claude.ai/code/session_01KXQJogmVSdYrKtYX1LwzwT