frontend, backend: fix traceback for non-existing tasks
Fix #2390
First, take a look at the frontend change. The
BuildsLogic.get_srpm_build_task never raises an exception. It returns None for non-existing tasks instead. The route therefore returns 200 status code even for non-existing tasks, and simply returns nil. I am changing this to return 404 instead.
This prompted the backend changes because exceptions started appearing.
Would you mind bumping MIN_FE_BE_API?
Why backend even asked for those build IDs?
Why backend even asked for those build IDs?
I am thinking of something like
- User submitted a build
- Backend added it to its priority queue
- Because of one of the post-release bugs, the building was stuck
- User deleted the build because it wasn't working
- Before updating the priority queue, backend picked the build and started it
I need to check if this was the case and if this situation can happen. If yes, we should fix it.
I am thinking of something like
Now it looks more like an issue caused by #2398.
So are we going to skip this PR then?
We should probably skip this for the next mini-release. But the change is valid, I think.
Thank you for this patch, it makes the code more robust..