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

Naming of config variables #47

Closed
mafrosis opened this issue Nov 20, 2015 · 6 comments
Closed

Naming of config variables #47

mafrosis opened this issue Nov 20, 2015 · 6 comments

Comments

@mafrosis
Copy link

Hey folks, I just added Flask-S3 to a project, and I think the naming of the config variables ought to be changed to be specific to this module; perhaps with a FLASKS3_ prefix (like how the Flask-Security module does it).

I already have a config var called S3_BUCKET in my project, and now I have S3_BUCKET_NAME.. Which doesn't provide the clearest distinction in the code base.

Just a thought. Interested to see what you think.

@bool-dev
Copy link
Contributor

👍

@Fuyukai
Copy link
Collaborator

Fuyukai commented Nov 20, 2015

Unfortunately, this would break backwards compatibility, and as most users probably don't pin their dependency versions, it would break their things.

@bool-dev
Copy link
Contributor

@SunDwarf how about throwing deprecation warnings, and falling back to old naming structure if new structure is not used? I'd be happy to spend some time over the weekend and send a pull request.
(I also have some variables in my config starting with S3_ but thankfully no conflicts!)

@mafrosis
Copy link
Author

I was thinking of @bool-dev's approach as well (which is how Django handle's this kind of thing). Support both variable names, and show deprecation warnings until the next major release.

@Fuyukai
Copy link
Collaborator

Fuyukai commented Nov 21, 2015

I think that's a better idea.

@mafrosis
Copy link
Author

@SunDwarf We definitely can't just change the names of the config variables on everyone! ;)

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

3 participants