sync user own repos
This commit is contained in:
@@ -130,12 +130,12 @@ flowchart TD
|
||||
announcements. Caveat: coverage depends on whether state events reach the bootstrap
|
||||
relays; if a grasp server is the only holder, those repositories remain unseen.
|
||||
|
||||
- **B. Targeted fetch for the user's own repositories. — not implemented.**
|
||||
In `sync_inbox` (`crates/signed_state/src/backend.rs` L1126-1152), where the user's
|
||||
own repositories' relays are already connected, also sync `filters::state(addr)` per
|
||||
own repository. This directly addresses "my repositories updated elsewhere" at low
|
||||
cost. Note the existing race: `sync_inbox` reads the announcement list right after
|
||||
login, which may not be loaded yet.
|
||||
- **B. Targeted fetch for the user's own repositories. — implemented.**
|
||||
`RepoListStore` fetches each own repository's state event from the relays that
|
||||
repository announces, once the list discovers it. Driving this from the list rather
|
||||
than `sync_inbox` sidesteps the login race described above: whenever the announcement
|
||||
list is (re)loaded, any own repository not yet fetched is covered. The fetched-set is
|
||||
cleared on `SignerChanged`, so a login or account switch re-fetches.
|
||||
|
||||
- **C. Reactivity fixes. — implemented.**
|
||||
`Kind::RepoState` is now included in the `BackendEvent::Published` refresh condition of
|
||||
@@ -144,5 +144,4 @@ flowchart TD
|
||||
matching misses them — and locally published state updates by owner plus the `d`
|
||||
identifier.
|
||||
|
||||
A + C are implemented; B remains available if own-repository freshness on fresh profiles
|
||||
matters.
|
||||
A + B + C are implemented.
|
||||
|
||||
Reference in New Issue
Block a user