Selecting an element before another's update is finished causes it to be updated instead
To reproduce, first add something to slow the PartialUpdateElement
endpoint down in the backend, such as this:
if request.method == 'PATCH':
import time
time.sleep(3)
This will give you a bit more time to reproduce:
Selecting another element
- Annotate two elements A and B on any image
- With the
👆 tool, move element A or move one point of element A - Before the
PATCH
is completed, move element B or move one point of element B - Once A's patch is completed, B is shown to have A's polygon and A is not updated
- Once B's patch is completed, B is shown to have B's polygon again.
Selecting nothing
- Annotate two elements A and B on any image
- With the
👆 tool, move element A or move one point of element A - Before the
PATCH
is completed:- Move element B or move one point of element B
- Click on an empty space on the image to deselect element B
- Once A's patch is completed, A is shown to have A's polygon, as expected
- Trying to update A again causes
HTTP 405
due to a call toPATCH /api/v1/element/undefined/
@ChloeFize sent a screencast on Slack to try to show us how to reproduce: https://teklia.slack.com/files/U01158838P2/F017G9Y70CD/deplacement_boites_bug.mp4
Edited by Erwan Rouchet