Pressing return on image attachment form throws 404 #5651

Closed
opened 2025-12-29 19:30:40 +01:00 by adam · 2 comments
Owner

Originally created by @jasonyates on GitHub (Nov 12, 2021).

NetBox version

3.0.9

Python version

3.8

Steps to Reproduce

  1. Click Attach an Image to a rack / location / site
  2. Select image file, give it a name
  3. Hit Return to submit the form

The image is uploaded correctly but the form redirects to /extras/image-attachments/add/ and throws a 404 not found instead of back to the previous page

Note this ONLY happens when hitting return to submit the form. Selecting Create or Create & Add Another behaves as expected.

Screenshot 2021-11-12 at 11 21 21

Expected Behavior

Form submits and redirects to previous page in line with clicking Create

Observed Behavior

The image is uploaded correctly but the form redirects to /extras/image-attachments/add/ and throws a 404 not found instead of back to the previous page

Originally created by @jasonyates on GitHub (Nov 12, 2021). ### NetBox version 3.0.9 ### Python version 3.8 ### Steps to Reproduce 1. Click Attach an Image to a rack / location / site 2. Select image file, give it a name 3. Hit Return to submit the form The image is uploaded correctly but the form redirects to /extras/image-attachments/add/ and throws a 404 not found instead of back to the previous page Note this ONLY happens when hitting return to submit the form. Selecting Create or Create & Add Another behaves as expected. ![Screenshot 2021-11-12 at 11 21 21](https://user-images.githubusercontent.com/242483/141459355-815ce925-4bc9-426e-9a44-7f3e5db03e7e.png) ### Expected Behavior Form submits and redirects to previous page in line with clicking Create ### Observed Behavior The image is uploaded correctly but the form redirects to /extras/image-attachments/add/ and throws a 404 not found instead of back to the previous page
adam added the type: bugstatus: duplicate labels 2025-12-29 19:30:40 +01:00
adam closed this issue 2025-12-29 19:30:41 +01:00
Author
Owner

@jeremystretch commented on GitHub (Nov 12, 2021):

I'm not able to reproduce this on v3.0.10; upon hitting enter the attachment is created and I'm redirected back to the same form. It was probably fixed under #7741. @jasonyates can you confirm?

@jeremystretch commented on GitHub (Nov 12, 2021): I'm not able to reproduce this on v3.0.10; upon hitting enter the attachment is created and I'm redirected back to the same form. It was probably fixed under #7741. @jasonyates can you confirm?
Author
Owner

@jasonyates commented on GitHub (Nov 14, 2021):

@jeremystretch confirmed, 3.0.10 does not throw a 404 error. Thanks!

@jasonyates commented on GitHub (Nov 14, 2021): @jeremystretch confirmed, 3.0.10 does not throw a 404 error. Thanks!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#5651