This commit is contained in:
Shreyas Goenka 2024-09-15 23:37:28 +02:00
parent 73826acb2f
commit de7eb94e45
No known key found for this signature in database
GPG Key ID: 92A07DF49CCB0622
1 changed files with 3 additions and 2 deletions

View File

@ -204,6 +204,8 @@ func (u *upload) Name() string {
// //
// -> exception for when the schema value is fully or partially interpolated. // -> exception for when the schema value is fully or partially interpolated.
// In that case only check the catalog name. // In that case only check the catalog name.
//
// TODO: Convert to warning? We don't error today if you specify an invalid volume path.
func GetFilerForLibraries(ctx context.Context, b *bundle.Bundle, uploadPath string) (filer.Filer, diag.Diagnostics) { func GetFilerForLibraries(ctx context.Context, b *bundle.Bundle, uploadPath string) (filer.Filer, diag.Diagnostics) {
w := b.WorkspaceClient() w := b.WorkspaceClient()
isVolumesPath := strings.HasPrefix(uploadPath, "/Volumes/") isVolumesPath := strings.HasPrefix(uploadPath, "/Volumes/")
@ -241,8 +243,7 @@ func GetFilerForLibraries(ctx context.Context, b *bundle.Bundle, uploadPath stri
} }
// The volume does not exist. Check if the volume is defined in the bundle. // The volume does not exist. Check if the volume is defined in the bundle.
// TODO: Does this break? Did it work before if the volume was not defined, but // TODO: Note that this is not a breaking change.
// the schema was?
l, ok := locationForVolume(b, catalogName, schemaName, volumeName) l, ok := locationForVolume(b, catalogName, schemaName, volumeName)
if !ok { if !ok {
return nil, diag.Errorf("the bundle is configured to upload artifacts to %s but a UC volume at %s does not exist", uploadPath, volumePath) return nil, diag.Errorf("the bundle is configured to upload artifacts to %s but a UC volume at %s does not exist", uploadPath, volumePath)