Skip to content

Ignore empty provider overrides#7998

Merged
silv-io merged 1 commit intomasterfrom
fix-empty-provider-override
Mar 29, 2023
Merged

Ignore empty provider overrides#7998
silv-io merged 1 commit intomasterfrom
fix-empty-provider-override

Conversation

@silv-io
Copy link
Member

@silv-io silv-io commented Mar 29, 2023

Currently, when explicitly setting "" for provider overrides (e.g., PROVIDER_OVERRIDE_S3="") the ServiceProviderConfig assumes that a provider with the name "" (i.e. an empty string) is requested. This happens, e.g., in the bin/test-in-docker.sh script and leads to NotImplementedErrors.
Since we can safely assume that we won't create new provider variants with the explicit name of an empty string, we can ignore all falsey values for provider overrides and thus assume a selection of the default provider.

This PR also adds a unit test to verify this new behavior.

/cc @bentsku

@silv-io silv-io requested a review from dfangl March 29, 2023 09:04
@silv-io silv-io requested a review from thrau as a code owner March 29, 2023 09:04
Copy link
Member

@dfangl dfangl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@silv-io silv-io merged commit 62254ed into master Mar 29, 2023
@silv-io silv-io deleted the fix-empty-provider-override branch March 29, 2023 09:26
@coveralls
Copy link

Coverage Status

Coverage: 81.856%. Remained the same when pulling 89d8c42 on fix-empty-provider-override into 5211924 on master.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants