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: return stored project descriptions on idempotent creation by flysheep-ai · Pull Request #1943 · MemMachine/MemMachine

Conversation

@flysheep-ai

@flysheep-ai flysheep-ai commented Nov 6, 2026

Copy link
Copy Markdown

Purpose of the change

Creating an existing project with matching configuration and a different description returns 201 with the requested description, even though the stored description remains unchanged. A subsequent /projects/get response therefore disagrees with the creation response.

Description

Build the creation response from session.description, just as its configuration comes from the resolved session. Preserve the existing idempotent creation behavior, including its 201 status and original stored description. There are no storage, schema, dependency, or authorization changes.

Fixes/Closes

Fixes #1922

Type of change

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

How Has This Been Tested?

  • Unit Test
  • Integration Test (local HTTP/session/SQLite path only)

The regression exercises the real FastAPI routes, MemMachine creation/read methods, and SQLite session manager. Only resource lookup is mocked; model-backed memory is disabled. Three cases cover replacing a nonempty description, requesting an empty description, and replacing an initially empty description. Each creates, recreates, and reads the same project, asserting equal complete responses and the original description. All three fail before the fix and pass afterward.

Python 3.12; frozen workspace dependencies:

uv sync --frozen --python 3.12 --package memmachine-server --extra qdrant
uv run --frozen pytest packages/server/server_tests/memmachine_server/server/api_v2/test_router.py packages/server/server_tests/memmachine_server/server/api_v2/test_service.py -q
uv run --frozen pytest packages/server/server_tests/memmachine_server/common/session_manager/test_session_manager.py -k create_or_validate -m 'not integration' -q

Test Results: 117 router/service tests passed (4 existing dependency deprecation warnings); 5 SQLite creation/validation tests passed (39 deselected, 3 existing warnings). Ruff lint/format and scoped ty checks pass for both changed files. PostgreSQL, live models, concurrency, and the full package suite were not exercised.

Checklist

  • I have signed the commit(s) within this pull request
  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have added unit tests that prove my fix is effective
  • New and existing relevant tests pass locally with my changes

Maintainer Checklist

  • Confirmed all checks passed
  • Contributor has signed the commit(s)
  • Reviewed the code
  • Run, Tested, and Verified the change(s) work as expected

Screenshots/Gifs

N/A.

Further comments

AI assisted the investigation, implementation, tests, and draft. Independent agent review completed; no human code review is claimed. The pre-existing API documentation's statement that every duplicate create fails is outside this response correction and remains unchanged.

Sorry, something went wrong.

Uh oh!

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

All reactions
@flysheep-ai
fix: return stored project descriptions on idempotent creation
377f906
Signed-off-by: 沈飞洋 <[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]: Re-creating an existing project with a new description answers 201 with it, but keeps the old one

Uh oh!

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

1 participant

@flysheep-ai
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.