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

Suggestion: A value which should never be filled for dummy values (e.g. #throw) #96

Open
SevereOverfl0w opened this issue Nov 12, 2020 · 1 comment

Comments

@SevereOverfl0w
Copy link
Contributor

Inspired by https://lobste.rs/s/chxlum/changeme_is_valid_base64#c_drqazo

The use case is for when setting up a config early in a project, and you're not sure what the value will be, something like this:

:api-token {:dev "dev-token" :prod "changeme"}

In order to assist with forgetting to change the token, you could instead do

:api-token {:dev "dev-token" :prod #throw "changeme"}

which would give you early warning that something was amiss. Ideally Aero's reporting would bubble out information such as what k-path the error was at.

@SevereOverfl0w
Copy link
Contributor Author

It might be useful to have this be the default return value for #profile, etc. too:

(read-config "#profile {:foo 10}" {:profile :bar}) ;; => 💥 

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

No branches or pull requests

1 participant