GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix: preserve semantic features when vector deletion fails by pcbeingused333 · Pull Request #1945 · MemMachine/MemMachine

Conversation

@pcbeingused333

@pcbeingused333 pcbeingused333 commented Nov 6, 2026

Copy link
Copy Markdown
Contributor

Fixes #1938

Purpose of the change

On main, VectorStoreSemanticStorage.delete_features and delete_feature_set commit the row delete before deleting the vectors. If the vector store is unavailable, the delete fails after the rows that locate those vectors are gone, so a retry cannot remove them.

Description

Delete the vectors first, then the rows (the order #1831 uses for delete_feature_set on feat/horizontal-scaling). delete_feature_set now resolves the matching feature IDs and goes through delete_features, so only the selected rows are removed and rows added while the vectors are being deleted are kept. A vector-store failure leaves the rows in place and a retry deletes both.

Fixes/Closes

Fixes #1938

Type of change

  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

  • Unit Test

A new parameterized test in test_vector_store_semantic_storage.py (SQLite + in-memory vector collection) makes the vector delete fail once, checks the features are still there, then retries and checks rows and vectors are gone, through both delete_features and delete_feature_set.

Test Results: pytest packages/server/server_tests/memmachine_server/semantic_memory/storage/test_vector_store_semantic_storage.py: 5 passed; with the source file from main, both new cases fail (rows lost after the failed vector delete). ruff check and ruff format --check (0.16.8) pass.

Checklist

  • I have signed the commit(s) within this pull request
  • My code follows the style guidelines of this project (See STYLE_GUIDE.md)
  • I have performed a self-review of my own code
  • My changes generate no new warnings
  • I have added unit tests that prove my fix is effective or that my feature works

Further comments

Prepared with AI assistance; the change and test results were reviewed before submission.

Publication note

CONTRIBUTING-CORE.md requests an ownership comment on an existing issue.
No GitHub writes were performed; the moderator should handle this before publication.

Local validation

  • Base: main at 377510d.
  • Regression before fix: 2 failed, 3 passed (both failures confirm lost rows).
  • After fix: 5 passed, including both failure/retry regressions.
  • Ruff 0.16.8: check and format --check pass for both changed files.
  • Commit includes Alex's DCO signoff and a verified SSH signature (G),
    with no Co-Authored-By trailer.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@pcbeingused333
fix: preserve semantic features when vector deletion fails
0975d4d
Signed-off-by: Alex Castillo González <[email protected]>

This branch has not been deployed

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

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

[Bug]: A semantic feature delete that fails at the vector store commits the row delete anyway, leaving vectors no retry can reach

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@pcbeingused333
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.