tane/apps/app_seeds/test/services
vjrj 225880fc64 feat(sync): device-to-device inventory sync, end to end
Wires the encrypted sync transport into a working replication between one
identity's own devices, reusing the CRDT-ready model (HLC + tombstones +
LWW) the data model was built for.

- SocialSession gains a 5th interface, sync, over the shared connection,
  built with a per-install deviceId + the app's inventory namespace.
- DeviceIdStore: a stable random per-install id in the keystore — distinct
  from the seed-derived CRDT node id, which is IDENTICAL across a user's
  devices (so it couldn't tell them apart / they'd clobber each other's
  replaceable record).
- InventorySnapshotIO (implemented by ExportImportService): build/apply the
  inventory as the SAME interchange JSON as backups but UNSEALED — the sync
  transport does the encryption, so it must not double-seal. Apply = the
  existing idempotent LWW importInventory.
- SyncService: on (re)connect publishes this device's snapshot + subscribes
  to the others'; a local edit (debounced, off tableUpdates) republishes;
  incoming snapshots merge idempotently; skips its own echo; a byte check
  skips re-publishing an unchanged snapshot so the ping-pong converges.
  Foreground only, like the inbox.
- DI/Bootstrap/switchSocialAccount wire and lifecycle it per identity.

Tests: DeviceIdStore, ExportImportService snapshot round-trip (unsealed +
idempotent), SyncService.handleRemote (applies others', skips own).

Follow-ups: deltas vs full-snapshot pushes; background sync; conflict UI.
2026-07-10 23:45:40 +02:00
..
ocr style: dart format reflow (no behavior change) 2026-07-09 22:19:43 +02:00
auto_backup_service_test.dart feat(backup): tap automatic-backups to make a copy now 2026-07-10 11:05:36 +02:00
auto_backup_store_test.dart feat(backup): add automatic weekly encrypted backups 2026-07-10 10:17:36 +02:00
device_id_store_test.dart feat(sync): device-to-device inventory sync, end to end 2026-07-10 23:45:40 +02:00
discovery_area_test.dart fix(market): search your zone by a coarse prefix, not the exact cell 2026-07-10 16:12:38 +02:00
export_import_service_test.dart feat(sync): device-to-device inventory sync, end to end 2026-07-10 23:45:40 +02:00
inbox_service_test.dart refactor(social): one shared relay connection per identity 2026-07-10 21:50:34 +02:00
label_sheet_service_test.dart feat(labels): print seed labels with QR from an inventory selection 2026-07-10 19:14:04 +02:00
locale_store_test.dart feat(i18n): add Asturian (asturianu) as a language 2026-07-10 15:43:33 +02:00
message_store_test.dart feat(identity): switch social identity, all from the one backup 2026-07-10 20:22:24 +02:00
notification_service_test.dart feat(messages): unread badges + OS notification for private messages 2026-07-10 21:12:00 +02:00
offer_outbox_test.dart feat(block2): offline outbox — share now, publish when connected 2026-07-10 10:45:53 +02:00
offer_thumbnail_test.dart feat(market): embed offer photos inline instead of a media server 2026-07-10 21:27:59 +02:00
profile_cache_test.dart feat(block2): show contact names (resolve peers' published profiles) 2026-07-10 12:47:48 +02:00
profile_store_test.dart feat(block2): profiles — your identity card + name/about (NIP-01 kind:0) 2026-07-10 12:37:07 +02:00
share_catalog_service_test.dart feat(inventory): local sharing — per-lot share terms, filter and printable catalog 2026-07-09 22:19:55 +02:00
social_account_store_test.dart feat(identity): switch social identity, all from the one backup 2026-07-10 20:22:24 +02:00
social_connection_test.dart refactor(social): one shared relay connection per identity 2026-07-10 21:50:34 +02:00
social_service_test.dart feat(block2): wire the social identity into app_seeds (DI, no UI) 2026-07-10 02:44:37 +02:00
social_settings_test.dart feat(market): embed offer photos inline instead of a media server 2026-07-10 21:27:59 +02:00
sync_service_test.dart feat(sync): device-to-device inventory sync, end to end 2026-07-10 23:45:40 +02:00
trust_referents_test.dart feat(trust): full Duniter web-of-trust membership (params + referents) 2026-07-10 21:02:08 +02:00
unread_service_test.dart feat(messages): unread badges + OS notification for private messages 2026-07-10 21:12:00 +02:00
wot_settings_test.dart feat(trust): full Duniter web-of-trust membership (params + referents) 2026-07-10 21:02:08 +02:00