Skip to content

Commit

Permalink
Downgrade missing metadata file when checking model output submission…
Browse files Browse the repository at this point in the history
… to check failure and remove early return. Resolves #138
  • Loading branch information
annakrystalli committed Oct 30, 2024
1 parent 5c83952 commit 8c2d46d
Show file tree
Hide file tree
Showing 5 changed files with 711 additions and 171 deletions.
2 changes: 1 addition & 1 deletion R/check_submission_metadata_file_exists.R
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,6 @@ check_submission_metadata_file_exists <- function(file_path, hub_path = ".") {
msg_subject = "Metadata file",
msg_attribute = msg_attribute,
msg_verbs = c("exists", "does not exist"),
error = TRUE
error = FALSE
)
}
3 changes: 0 additions & 3 deletions R/validate_model_file.R
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,6 @@ validate_model_file <- function(hub_path, file_path,
file_path = file_path
), file_path
)
if (is_any_error(checks$metadata_exists)) {
return(checks)
}

custom_checks <- execute_custom_checks(validations_cfg_path = validations_cfg_path)
checks <- combine(checks, custom_checks)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
Code
check_submission_metadata_file_exists(hub_path = hub_path, file_path = "random-model/2022-10-01-random-model.csv")
Output
<error/check_error>
<error/check_failure>
Error:
! Metadata file does not exist at path 'model-metadata/random-model.yml' or 'model-metadata/random-model.yaml'.

Loading

0 comments on commit 8c2d46d

Please sign in to comment.