Repository navigation
fix(groups): conservar el historial de un grupo al borrarlo - #17
Merged
bpstack merged 2 commits intoOct 12, 2026
Merged
Conversation
- 20261011_keep_group_history_on_delete.sql: drops the ON DELETE CASCADE foreign key from group_history.group_id; idempotent. - group-repository.ts: delete removes the group and writes a "deleted" history row with a snapshot of the group, in one transaction. - group-controller.ts: passes the user and the group to delete. - INDEX.md: registers the migration, applied locally, pending in Aiven. - group-deletion.test.ts: the delete writes its row, rolls back when the row fails, writes nothing when there was no group; the migration exists. Why: deleting a group deleted its whole history and logged nothing. Decided on 2026-10-11: delete the group but keep a trace. Checked in the browser against the local database with the migration applied: the group is gone, its earlier history stays and a deleted row holds the snapshot. The migration must reach Aiven before this code is deployed.
- INDEX.md: the migration row now reads applied on local and Aiven. Why: it was applied on Aiven on 2026-10-12 after a dry run and read-only checks of its preconditions, and verified afterwards.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Cambios
20261011_keep_group_history_on_delete.sql: quita la clave foráneaON DELETE CASCADEdegroup_history(ya aplicada en Aiven el 2026-10-12).deletedcon la foto del grupo, en la misma transacción.INDEX.md: migración marcada como aplicada en local y en Aiven.Por qué
Borrar un grupo se llevaba todo su historial y no dejaba rastro. Decidido el 2026-10-11: el grupo se borra pero queda constancia.