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

deprecate settings module #1273

Closed
jku opened this issue Feb 5, 2021 · 3 comments
Closed

deprecate settings module #1273

jku opened this issue Feb 5, 2021 · 3 comments

Comments

@jku
Copy link
Member

jku commented Feb 5, 2021

We should aim to deprecate and remove the settings module

Some of the settings should not be exposed and AFAICT none of them should be global variables.

This is likely to be implemented piece by piece so the bug may just be a reminder to do that.

@jku
Copy link
Member Author

jku commented Feb 5, 2021

The issue here is how to deprecate a global variable in a reasonable way?

variables cannot be deprecated (in the sense that using them would lead to a DeprecationWarning). We could workaround by replacing settings with an object in module import, and then giving deprecation warnings on property access... but I'm not sure the complexity is warranted here.

@joshuagl
Copy link
Member

joshuagl commented Feb 5, 2021

This might just be piecemeal as we implement new components during the rewrite and new code gradually moves away from tuf.settings. i.e. new client implementation has a new paradigm for constants and configurable settings.

See also secure-systems-lab/securesystemslib#219

@jku
Copy link
Member Author

jku commented Jul 19, 2021

We have succeeded 🙏 ngclient does not import settings anymore

(to be clear: settings module still exists and is used in the legacy code. But Metadata API and ngclient do not use it and there's 0 reason for any repo-side tools to do that either)

@jku jku closed this as completed Jul 19, 2021
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

2 participants