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

Exception on image delete #1113

Closed
olfway opened this issue Apr 28, 2017 · 0 comments
Closed

Exception on image delete #1113

olfway opened this issue Apr 28, 2017 · 0 comments
Labels
type: bug A confirmed report of unexpected behavior in the application

Comments

@olfway
Copy link

olfway commented Apr 28, 2017

Issue type: bug report

Python version: 2.7.13
NetBox version: v2.0-beta3-1-gb8b912b

I'm trying to delete image attached to site:
http://netbox.mtxc.co/extras/image-attachments/1/delete/

got exception:

Internal Server Error: /extras/image-attachments/1/delete/
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/site-packages/django/core/handlers/exception.py", line 41, in inner
    response = get_response(request)
  File "/usr/local/lib/python2.7/site-packages/django/core/handlers/base.py", line 187, in _get_response
    response = self.process_exception_by_middleware(e, request)
  File "/usr/local/lib/python2.7/site-packages/django/core/handlers/base.py", line 185, in _get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "/usr/local/lib/python2.7/site-packages/django/views/generic/base.py", line 68, in view
    return self.dispatch(request, *args, **kwargs)
  File "/usr/local/lib/python2.7/site-packages/django/contrib/auth/mixins.py", line 92, in dispatch
    return super(PermissionRequiredMixin, self).dispatch(request, *args, **kwargs)
  File "/usr/local/lib/python2.7/site-packages/django/views/generic/base.py", line 88, in dispatch
    return handler(request, *args, **kwargs)
  File "/opt/netbox/utilities/views.py", line 261, in get
    'return_url': self.get_return_url(request, obj),
  File "/opt/netbox/extras/views.py", line 30, in get_return_url
    return imageattachment.obj.get_absolute_url()
AttributeError: 'ImageAttachment' object has no attribute 'obj'
@jeremystretch jeremystretch added the type: bug A confirmed report of unexpected behavior in the application label Apr 28, 2017
lampwins pushed a commit to lampwins/netbox that referenced this issue Oct 13, 2017
@lock lock bot locked as resolved and limited conversation to collaborators Jan 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type: bug A confirmed report of unexpected behavior in the application
Projects
None yet
Development

No branches or pull requests

2 participants