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

LMS: Deleting e.g. front page twice fails: #19

Closed
nygrenh opened this issue May 26, 2021 · 1 comment
Closed

LMS: Deleting e.g. front page twice fails: #19

nygrenh opened this issue May 26, 2021 · 1 comment

Comments

@nygrenh
Copy link
Member

nygrenh commented May 26, 2021

Reproduce:

  • Create course front page
  • Delete course front page
  • Create course front page
  • Delete course front page -> FAILS
[2021-05-06T08:57:29Z ERROR actix_http::response] Internal Server Error: InternalServerError("error returned from database: duplicate key value violates unique constraint \"pages_url_path_course_id_deleted_key\"")
[headless-lms] [2021-05-06T08:57:29Z INFO  actix_web::middleware::logger] "DELETE /api/v0/cms/pages/7d3e3666-7491-439f-9c98-80f718bfabfa HTTP/1.1" 500 213 "http://project-331.local/cms/courses/d86cf910-4d26-40e9-8c9c-1cc35294fdbb/overview" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.93 Safari/537.36" 172.17.0.2:35108 14.703912ms
@nygrenh
Copy link
Member Author

nygrenh commented May 26, 2021

This is because of the database design. The planned migration to use timestamps instead of booleans in deleted fields should resolve this.

@sebazai sebazai closed this as completed Jun 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants