Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean up handling of missing DOI_API_PREFIX setting #1721

Closed
wants to merge 2 commits into from

Conversation

mvandenburgh
Copy link
Member

@mvandenburgh mvandenburgh commented Oct 18, 2023

This setting should never be unset in a real deployment of DANDI, so silently replacing it with a default if it's missing is not ideal.
Instead, this PR changes it so that things fail loudly and raise and error if this setting is not supplied in an env var. In dev/testing configurations it is still hardcoded to the placeholder value, but this is done at the Django setting layer instead of directly in the application code.

This setting should never be unset in a real deployment of DANDI, so
silently replacing it with a default if it's missing is not ideal.
Instead, this changes it so that things fail loudly and an error is
raised if this setting is not supplied in an env var. In dev/testing
configurations, it is hardcoded to the placeholder value.
@mvandenburgh
Copy link
Member Author

Closing this. I'll re-evaluate whether this refactor makes sense as part of redesigning the DOI creation process.

@mvandenburgh mvandenburgh deleted the move-doi-prefix-default branch November 17, 2023 19:21
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.

1 participant