Skip to content

bug(native): LinkGames can drop tracked roots after a failed carry-over #20

Open

Description

@Seagulls

Summary

Daemon.LinkGames records an alias, attempts to carry named roots into the canonical registration, logs root transfer failures, then continues adopting history and deleting the alias game. A failed mapped-root carry can therefore remove the last tracked registration of a save directory. Physical files remain, but OpenSave stops covering them.

Independent synthetic RED witness

On a disposable native Store/daemon fixture, with an existing alias root and an admitted canonical writer, the topology-guarded carry-over refuses. The current code logs that refusal and still deletes the alias game and associated root registration. No real save data was used.

Minimal complete acceptance

  • An admission refusal on either source/alias or destination/canonical game happens before destructive state changes.
  • A failed carry-over, including failure after an earlier successfully copied root, must not delete the original tracked coverage or leave an inconsistent alias/history transfer.
  • Test deterministic two-game reservation ordering where appropriate; do not nest existing AdoptHistory transactions blindly.
  • Files are never removed by a refused link.
  • Preserve normal LinkGames semantics and build/race tests; if atomic linking is necessarily larger, scope it independently.

Relationship

Discovered while reviewing upstream PR #139, which added per-game admission around root transfer but unintentionally introduced a new refusal path before the existing destructive finalisation. The issue is independently worth fixing; do not merge a change that knowingly leaves new loss-of-coverage behaviour.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions