feat: distinguish local-only repos from broken remotes on sync - #116
Merged
Merged
Conversation
Missing git remotes now return status not_configured with a next step instead of a rebase error. Configured unreachable or permission-denied remotes remain errors. Required startup sync stays fail-closed. Local save, recall, review, and supersession still work without a remote.
…s-105 # Conflicts: # README.md # src/fava_trails/cli.py # src/fava_trails/server.py
JJ 0.42+ removed --allow-new. Use --allow-empty-description --all so the healthy local-only sync test runs on the 0.28 and 0.45.1 matrix.
timeleft--
approved these changes
Sep 11, 2026
timeleft--
left a comment
Member
There was a problem hiding this comment.
Independent review is clean at exact head 88e4d52. Reproduced absent, unreachable, permission-denied, and healthy disposable-remote behavior with JJ 0.45.1; verified local save/recall/review/supersession without a remote and fail-closed startup sync. Focused lint and 74 tests passed, the full 1,061-test suite passed, and all nine GitHub checks are green across JJ 0.28.0 and 0.45.1. No hosted remote, private push, or automatic remote mutation is introduced.
This was referenced Sep 11, 2026
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.
Summary
syncreturnsnot_configuredwith a concrete next step, and remotes are never added or changed automatically.--sync-on-startfail-closed for every non-okresult, including missing remotes.Closes #105
Motivation
A separate local JJ/Git repository is a valid evaluation setup, but sync without a configured Git remote was reported as a rebase error. Cross-machine sharing needs a reachable remote and operational work that onboarding should explain first.
Changes
fetch_and_rebaseinspects git remotes before fetch; empty remotes skip fetch/rebase.syncmaps missing remotes tonot_configured(operators get the next step; non-operators get a generic not-configured message).not_configuredorerrorinstead ofokon failure.Test Plan
--sync-on-startfail-closed fornot_configureduv run pytest tests/test_local_only_sync.py tests/test_gateway_sync.py tests/test_navigation_tools.py(21 passed)jjPATH misses in this environment (jjlives in~/.local/bin)Notes for Reviewers
FAVA does not create hosted repositories, push private content, or change remote settings automatically. Tests use only local disposable remotes.
AGENTS.md could not be updated in this environment (protected file); README, setup instructions, tunnel docs, and tool descriptions carry the same guidance.