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
When saving a FileAnswer, Caluma assumes that the file is uploaded to the bucket afterwards. There are cases where this doesn't happen and Caluma has data about a file that doesn't exist in the bucket. For example, when the upload to MinIO fails for some reason, the browser crashes or something similar.
We want to know when a file is not uploaded, and treat FileAnswers without actual file as potentially equal to non-existing.
When saving a
FileAnswer
, Caluma assumes that the file is uploaded to the bucket afterwards. There are cases where this doesn't happen and Caluma has data about a file that doesn't exist in the bucket. For example, when the upload to MinIO fails for some reason, the browser crashes or something similar.We want to know when a file is not uploaded, and treat
FileAnswer
s without actual file as potentially equal to non-existing.Proposal
In Alexandria we let MinIO call an endpoint on our side after completed uploads. There we use it to generate Thumbnails (https://github.com/projectcaluma/alexandria/blob/main/alexandria/core/views.py#L144). The same mechanism could be used in Caluma to know if a file really was uploaded.
Process
The process would look like this:
FileAnswer
in CalumaFile
and marks it as "draft"File
as draft.Caluma then could treat draft
Files
as non-existent and also ignore the correspondingFileAnswer
.Implementation suggestion
draft
flag toFile
modeldraft
flag to GQL schema, so frontend can treat it accordinglyThe text was updated successfully, but these errors were encountered: