Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG]Slet aktivitet giver Error 500 #1040

Open
mhewel opened this issue May 16, 2024 · 4 comments
Open

[BUG]Slet aktivitet giver Error 500 #1040

mhewel opened this issue May 16, 2024 · 4 comments
Assignees
Labels
bug noget der ikke virker efter hensigten

Comments

@mhewel
Copy link
Contributor

mhewel commented May 16, 2024

Beskriv fejlen overordnet

Forøsger at slette en aktivitet der hverken har deltagere eller invitationer, men det fejler med Error 500

@mhewel mhewel added the bug noget der ikke virker efter hensigten label May 16, 2024
@mhewel
Copy link
Contributor Author

mhewel commented May 16, 2024

Fandt flg log error:

update or delete on table "members_activity" violates foreign key constraint "members_emailitem_activity_id_409890cf_fk_members_activity_id" on table "members_emailitem"
DETAIL: Key (id)=(2434) is still referenced from table "members_emailitem".

Så det ser ud til at der er noget med en email (der har nok været en invitation, der er slettet men stadigvæk noget i emailitem

@mhewel
Copy link
Contributor Author

mhewel commented May 25, 2024

emailitem.py:
template, activity og department: Alle har on_delete=models.DO_NOTHING

Det er eneste sted der bruges DO_NOTHING

@rasmusselsmark
Copy link
Contributor

Genskabt lokalt:

  1. Oprettet aktivitet og inviteret medlemmer
  2. Forsøger at slette aktivitet, får følgende fejl:
image image

@rasmusselsmark
Copy link
Contributor

rasmusselsmark commented Sep 2, 2024

Startet i https://github.com/CodingPirates/forenings_medlemmer/compare/fix-deleting-activities-with-participants, dog skriver Django stadig "1 aktivitet slettet", selvom den ikke blev slettet

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug noget der ikke virker efter hensigten
Projects
None yet
Development

No branches or pull requests

2 participants