Skip to content

fix(initializer): return actionable model STORAGE_URI errors - #3868

Open
sahilleth wants to merge 1 commit into
kubeflow:masterfrom
sahilleth:fix/3834-model-initializer-storage-uri-errors
Open

fix(initializer): return actionable model STORAGE_URI errors#3868
sahilleth wants to merge 1 commit into
kubeflow:masterfrom
sahilleth:fix/3834-model-initializer-storage-uri-errors

Conversation

@sahilleth

Copy link
Copy Markdown

Summary

  • Validate missing and empty STORAGE_URI with a descriptive ValueError instead of a raw KeyError
  • Raise a stable ValueError for unsupported schemes, listing supported model providers (hf, s3)
  • Add parameterized tests for missing, empty, Hugging Face, S3, and unsupported URI cases

Fixes #3834

Test plan

  • pytest pkg/initializers/model/ -v (13 tests pass)
  • Missing STORAGE_URIValueError("STORAGE_URI environment variable must be set")
  • Empty STORAGE_URI → same ValueError
  • invalid://model/pathValueError with supported schemes
  • hf:// and s3:// success paths unchanged

Validate missing, empty, and unsupported model storage URIs with
descriptive ValueError messages and add parameterized regression tests.

Fixes kubeflow#3834

Signed-off-by: Sahil Bhardwaj <sahillbhardwaj23@gmail.com>
@google-oss-prow

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign terrytangyuan for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@github-actions

github-actions Bot commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

🎉 Welcome to the Kubeflow Trainer! 🎉

Thanks for opening your first PR! We're happy to have you as part of our community 🚀

Here's what happens next:

  • If you haven't already, please check out our Contributing Guide for repo-specific guidelines and the Kubeflow Contributor Guide for general community standards.
  • Our team will review your PR soon! cc @kubeflow/kubeflow-trainer-team

Join the community:

Feel free to ask questions in the comments if you need any help or clarification!
Thanks again for contributing to Kubeflow! 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Model initializer returns non-actionable errors for invalid STORAGE_URI

1 participant