-
Notifications
You must be signed in to change notification settings - Fork 220
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
Rethink #376
base: main
Are you sure you want to change the base?
Rethink #376
Conversation
Signed-off-by: Matthias Beyer <[email protected]>
Signed-off-by: Matthias Beyer <[email protected]>
Signed-off-by: Matthias Beyer <[email protected]>
Signed-off-by: Matthias Beyer <[email protected]>
Signed-off-by: Matthias Beyer <[email protected]>
This patch adds a type for a String buffer as a source for the configuration as well as format parser interfaces. Signed-off-by: Matthias Beyer <[email protected]>
Signed-off-by: Matthias Beyer <[email protected]>
Signed-off-by: Matthias Beyer <[email protected]>
This patch changes the Accessor type to be a helper over a list of AccessType objects. Signed-off-by: Matthias Beyer <[email protected]>
Signed-off-by: Matthias Beyer <[email protected]>
Signed-off-by: Matthias Beyer <[email protected]>
Signed-off-by: Matthias Beyer <[email protected]>
Signed-off-by: Matthias Beyer <[email protected]>
This patch also removes the associated error type from the ConfigSource trait, as we figured out that this can be simply a SourceError. Signed-off-by: Matthias Beyer <[email protected]>
Signed-off-by: Matthias Beyer <[email protected]>
This patch removes the async loading. The async loading makes everything awefully complicated and in fact it should rather be solved on the user side of things, not within this crate. Signed-off-by: Matthias Beyer <[email protected]>
Signed-off-by: Matthias Beyer <[email protected]>
… the crate Signed-off-by: Matthias Beyer <[email protected]>
Do you think it would be possible to generate sample configs including doc comments with the new approach? Or would it still need a separate macro to get the doc comments? I am thinking about writing a macro for generating sample configs with documentation of the fields. |
I could imagine that it would be possible. |
Is there any progress on this? I'm looking to move away from figment, and this crate is probably the best choice, but based on all the refactor talk, I'm hesitant to move to it. |
There's progress here: https://github.com/matthiasbeyer/config-rs-ng - still slow, but at least there's progress!
The current config-rs version is still usable 😆 - If we decide to move to the rewritten version, there will be a grace period and (if possible) compatible interfaces to make the move less complicated! |
Thanks for the update, I'll keep an eye on it 👍 |
This is my "rethink" efforts.
As this effort is done to overthink the architecture of the whole codebase, it removes the old code entirely and replaces it with my re-think work.
I hope interested parties will have a look.
Relevant issues:
ConfigBuilder::set_default
in combination withConfig::try_deserialize
? #365(maybe more will be added here)
Filed as draft, because this will be rebased as I see fit. So do not base any work on this except you want to add something to this PR!