Skip to content

docs(backlog): raise DEBT-032 to high, and say why it is not debt#107

Merged
fvadicamo merged 2 commits into
developfrom
docs/promote-debt-032
Jul 14, 2026
Merged

docs(backlog): raise DEBT-032 to high, and say why it is not debt#107
fvadicamo merged 2 commits into
developfrom
docs/promote-debt-032

Conversation

@fvadicamo

Copy link
Copy Markdown
Contributor

Documentation only. No code changes.

DOCS-009 (#106) found that the cleanup of an old index version does not exist: no endpoint, no flag, no script step, and no version-scoped delete on the VectorStoreProvider Protocol — while the module docstring tells the operator that "the operator ... then triggers cleanup of old-version chunks".

Why this is not "debt", and why it is high

REQ-064 spells the cleanup out as part of the requirement: "new chunks created with incremented version alongside old, atomic switch via config change, cleanup of old version afterwards". So it is not a suboptimal-but-working solution: it is an acceptance criterion of a shipped requirement that was never built, while the code advertises the capability. Code that promises something it cannot do is the same disease as BUG-023, one level up.

And it is live only because we fixed BUG-023. Until 2026-07-14, a reindex in Qdrant mode wrote nothing, so there was never an old version to clean up and the gap was harmless. The moment reindex started actually writing, every reindex began doubling a namespace's storage permanently, and the only exit became a hand-written destructive delete against the store — run at exactly the moment the operator is least certain about what is live.

This is the third gap in this family armed by its own fix:

  1. DELETE /documents/{id} had no namespace binding — harmless while the delete was a no-op, a cross-namespace deletion once it worked (fixed in fix(index): route every chunk path through the vector store Protocol #102).
  2. The vektra-app tests had never worked — nobody ran them, so nobody found out (fixed in test: close the local-env leak and run the tests nobody ran #104).
  3. This one.

Added acceptance criterion

The endpoint refuses to delete the version the system is currently serving, and a test proves it.

The destructive failure mode here is not "an old version survives". It is "the live index is emptied".

🤖 Generated with Claude Code

REQ-064 spells out the cleanup as part of the requirement ('cleanup of old version
afterwards'), so this is not a suboptimal-but-working solution: it is an acceptance
criterion of a shipped requirement that was never built, while the module docstring
tells the operator the capability exists.

It is also live only because BUG-023 was fixed. While reindex wrote nothing, there
was never an old version to clean and the gap was harmless. Now every reindex doubles
a namespace's storage permanently, and the only exit is a hand-written destructive
delete whose failure mode is emptying the live index. Third gap in this family armed
by its own fix, after the DELETE namespace binding and the vektra-app tests.

Added the acceptance criterion that matters most: the endpoint must refuse to delete
the version currently being served, with a test that proves it.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@fvadicamo fvadicamo added the documentation Improvements or additions to documentation label Jul 14, 2026
@coderabbitai

coderabbitai Bot commented Jul 14, 2026

Copy link
Copy Markdown

Important

Review skipped

Review was skipped due to path filters

⛔ Files ignored due to path filters (1)
  • .s2s/BACKLOG.md is excluded by !.s2s/**

CodeRabbit blocks several paths by default. You can override this behavior by explicitly including those paths in the path filters. For example, including **/dist/** will override the default block on the dist directory, by removing the pattern from both the lists.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: f288a47d-3984-4f5c-b82d-8dd02b51a986

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch docs/promote-debt-032

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the backlog item DEBT-032 by raising its priority to high, providing additional context on why this issue is critical, and adding a new acceptance criterion to ensure the endpoint refuses to delete the active index version. The reviewer suggested consolidating the new acceptance criterion with an existing one to avoid redundancy and focus specifically on the testing requirement and preventing the destructive failure mode.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread .s2s/BACKLOG.md Outdated
Review follow-up on #107 (gemini): the criterion I added duplicated the refusal that
the existing one already required. Merged into one, keeping the part that was genuinely
missing — that a test must prove the refusal, since the destructive failure mode is not
'an old version survives' but 'the live index is emptied'.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@fvadicamo fvadicamo merged commit 61cb8f3 into develop Jul 14, 2026
23 checks passed
@fvadicamo fvadicamo deleted the docs/promote-debt-032 branch July 14, 2026 17:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant