#195 When you remove a widget it removes all widgets '/ralph/71/edit'
Closed: Fixed 7 years ago Opened 8 years ago by skrzepto.

Desc:


When you remove a widget it removes all widgets. Also this might be a seperate issue but the home page for the hub won't load since no widgets are found

Steps to Reproduce:


1. On a fresh copy of the db (run populate.py after you delete the temp db)


2. Go to /ralph/72/edit and click on remove this widget


3. This tries to redirect you to /ralph/ which the hub doesn't load anymore since there are no widgets to load


Looks like function def widget_edit_delete(hub, idx): is the one deleting all the widgets. Not sure why will continue to investigate

DB constraints going wrong?

It might be. I'm also wondering if it's not because of the patch i submitted a few weeks ago to change the tables to have a cascading delete.

But the user is still in the db just the widgets table is empty for that user.

Adding more notes:

The user ralph is missing from the association table and hubs table this is definitely the result of what I changed in the models table

https://pagure.io/fedora-hubs/c/53041da5cf11f12fe354041075f19cdba2064146

https://pagure.io/fedora-hubs/c/284a1384b629ca0ce967347e6758362f831c0527

@skrzepto changed the status to Fixed

7 years ago

Log in to comment on this ticket.

Metadata
Attachments 2
Attached 8 years ago View Comment
Attached 8 years ago View Comment