You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi!
When trying to merge storage items i get a server error and this traceback:
File "/home/partuniverse/env/lib/python3.9/site-packages/django/core/handlers/exception.py", line 34, in inner
response = get_response(request)
File "/home/partuniverse/env/lib/python3.9/site-packages/django/core/handlers/base.py", line 115, in _get_response
response = self.process_exception_by_middleware(e, request)
File "/home/partuniverse/env/lib/python3.9/site-packages/django/core/handlers/base.py", line 113, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/home/partuniverse/env/lib/python3.9/site-packages/django/contrib/auth/decorators.py", line 21, in _wrapped_view
return view_func(request, *args, **kwargs)
File "/home/partuniverse/env/lib/python3.9/site-packages/django/views/generic/base.py", line 71, in view
return self.dispatch(request, *args, **kwargs)
File "/home/partuniverse/env/lib/python3.9/site-packages/django/views/generic/base.py", line 97, in dispatch
return handler(request, *args, **kwargs)
File "/home/partuniverse/env/lib/python3.9/site-packages/django/views/generic/edit.py", line 142, in post
return self.form_valid(form)
File "/home/partuniverse/partuniverse/partuniverse/partsmanagement/views.py", line 581, in form_valid
storageiitem.part.merge_storage_items(
File "/home/partuniverse/partuniverse/partuniverse/partsmanagement/models.py", line 600, in merge_storage_items
si2.delete()
File "/home/partuniverse/env/lib/python3.9/site-packages/django/db/models/base.py", line 921, in delete
collector.collect([self], keep_parents=keep_parents)
File "/home/partuniverse/env/lib/python3.9/site-packages/django/db/models/deletion.py", line 224, in collect
field.remote_field.on_delete(self, field, sub_objs, self.using)
File "/home/partuniverse/env/lib/python3.9/site-packages/django/db/models/deletion.py", line 22, in PROTECT
raise ProtectedError(
django.db.models.deletion.ProtectedError: ("Cannot delete some instances of model 'StorageItem' because they are referenced through a protected foreign key: 'VerifiedStock.storage_item'", <QuerySet [<VerifiedStock: ATTINY85-20SU; Werkstattmagazine->Werkstattmagazin 1 2022-08-11 21:43:46.630413+00:00>]>)
However the amount of one item is added to the other item, but the other one is not deleted.
The text was updated successfully, but these errors were encountered:
Hi!
When trying to merge storage items i get a server error and this traceback:
However the amount of one item is added to the other item, but the other one is not deleted.
The text was updated successfully, but these errors were encountered: