-
Notifications
You must be signed in to change notification settings - Fork 505
Description
Bug Description
After clicking the Approve button on a workflow item, the frontend sends a HTTP POST request to the following API endpoint:
/server/api/workflow/claimedtasks/:workflow_item_id
This POST request successfully transitions the workflow item into an archived item (in_archive).
Immediately afterward, the frontend issues an additional HTTP GET request to:
/server/api/workflow/claimedtasks/:workflow_item_id/workflowitem?embed=item&embed=submitter
with the same workflow item ID (which no longer refers to a valid workflow item).
This GET request fails with a 404 Not Found error, as the workflow item no longer exists at this point β it has already been archived and removed from the workflow context.
The GET requests generates an exception in the DSpace backend as you can see in the application log:
org.dspace.app.rest.exception.DSpaceApiExceptionControllerAdvice
An exception has occurred (status:404 exception: workflow.claimedtasks with id: workflow_item_id not found at:
org.dspace.app.rest.RestResourceController.findRelInternal(RestResourceController.java:922))
This issue can be reproduced consistently on:
- official DSpace demo instance (DSpace 8.1)
- official DSpace sandbox instance (DSpace 9.0 RC)
Expected Behavior
Once a workflow item has been approved and archived, the frontend should no longer attempt to access it via the workflow endpoint.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status