An user should not be able to delete the worker run of a started process
Linked to this Sentry issue: ARKINDEX-FRONTEND-EE
Linked to this Sentry issue: ARKINDEX-FRONTEND-EE
added 1 deleted label
assigned to @mlbonhomme
Already fixed by https://gitlab.com/arkindex/backend/-/commit/0cdb29c7aec6086acf9060ba087a007c234ff899 I think, which added
def check_object_permissions(self, request, worker_run):
(...)
# Updating a worker run is not possible once the process is started
if request.method not in permissions.SAFE_METHODS and worker_run.dataimport.workflow_id is not None:
raise ValidationError({'__all__': ["Cannot update a WorkerRun on a DataImport that has already started"]})
super().check_object_permissions(request, worker_run)
in class WorkerRunDetails(CorpusACLMixin, RetrieveUpdateDestroyAPIView)
; adding a specific test.
mentioned in merge request !1548 (closed)
created merge request !1548 (closed) to address this issue
mentioned in merge request !1549 (merged)
closed
mentioned in commit 51d2cf28