chore: started working on #38
This commit is contained in:
@@ -137,9 +137,13 @@ func processZipFile(c *Context, model *BaseModel) {
|
||||
f.Write(file_data)
|
||||
|
||||
if !testImgForModel(c, model, file_path) {
|
||||
c.Logger.Errorf("Image did not have valid format for model %s\n", file_path)
|
||||
ModelUpdateStatus(c, model.Id, FAILED_PREPARING_ZIP_FILE)
|
||||
return
|
||||
c.Logger.Errorf("Image did not have valid format for model %s (in zip: %s)!", file_path, file.Name)
|
||||
c.Logger.Warn("Not failling updating data point to status -1")
|
||||
message := "Image did not have valid format for the model"
|
||||
if err = model_classes.UpdateDataPointStatus(c.Db, data_point_id, -1, &message); err != nil {
|
||||
c.Logger.Error("Failed to update data point status")
|
||||
ModelUpdateStatus(c, model.Id, FAILED_PREPARING_ZIP_FILE)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user