Skip to content

some session data are not cleaned up on unshare, leading to inconsistencies on reshare #11372

Closed as not planned

Description

@sazary

Description

When a session is unshared and then reshared, stale data from the previous share appears mixed with the new data.
The share_event and share_compaction storage entries are not cleaned up during unshare, causing old sync events to be replayed when the session is reshared.

Besides the inconsistency on reshare, I think it's important to clear storage properly when the user asks to delete his data.

The session included in the video is this

Plugins

No response

OpenCode version

v1.1.45

Steps to reproduce

  1. Create a session and send a message ("hi 1" in the shared video)
  2. Share the session with /share
  3. Open the share URL in a browser (this triggers compaction cache)
  4. Unshare with /unshare
  5. /undo and edit the previous message ("hi 2" in the shared video)
  6. Share again with /share
  7. Open/refresh the share URL in browser
  8. Observe that both the old message AND the new message appear, when only the new message should be visible

Screenshot and/or share link

Screen.Recording.1404-11-11.at.1.13.41.AM.mov

Operating System

macos

Terminal

ghostty

Activity

  1. github-actions commented on Jan 30, 2026

    @github-actions
    Contributor

    This issue might be a duplicate of existing issues. Please check:

    Feel free to ignore if none of these address your specific case.

  2. sazary commented on Jan 30, 2026

    @sazary
    Author

    none of those are relevant

  3. geidsonc commented on Feb 27, 2026

    @geidsonc

    I also noticed this issue and I'm quite concerned about it. This is a serious issue that deserves urgent attention.

    Mainly because, for users who use the default endpoint (opncd.ai), the shared information is probably not being deleted from OpenCode's storage after /unshare. This represents a serious privacy issue — users trust the documentation which states that data is deleted when sharing is cancelled.

    The documentation clearly says in https://opencode.ai/docs/share/:

    /unshare - "This will remove the share link and delete the data related to the conversation."

    But as demonstrated in this issue, this is not happening. The data remains orphaned in S3.

    I'll wait for the fix you've already implemented. Thank you for investigating and resolving this! #11376

  4. assigned and unassigned on Apr 26, 2026
  5. removed
    bugSomething isn't working
    on May 3, 2026
  6. github-actions commented on Jul 3, 2026

    @github-actions
    Contributor

    To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.

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

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions