fix(memory): reject reused branch IDs when creating a branch - #4186
Conversation
Co-authored-by: Henry Su <henrysu4707@gmail.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: cf322479e1
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 290b2de6ac
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Co-authored-by: Henry Su <henrysu4707@gmail.com>
This pull request fixes branch ID reuse in
AdvancedSQLiteSession, which could silently append messages to an existing populated branch.It takes over and supersedes #4152, preserving the original contribution and crediting Henry Su via the commit's
Co-authored-bytrailer.Generated branch IDs now receive a numeric suffix when a collision occurs, while explicitly reused populated branch IDs raise
ValueErrorbefore any session state is modified.This pull request resolves #4150.