-
Notifications
You must be signed in to change notification settings - Fork 54
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
Gracefully handle unknown config #1632
Gracefully handle unknown config #1632
Conversation
d273571
to
0c65888
Compare
0c65888
to
0adc184
Compare
Signed-off-by: alexandru solomes <solo@softwareag.com>
f54d302
to
e28b718
Compare
Signed-off-by: alexandru solomes <solo@softwareag.com>
e28b718
to
6766056
Compare
Signed-off-by: alexandru solomes <solo@softwareag.com>
7667160
to
a8f2af7
Compare
Signed-off-by: alexandru solomes <solo@softwareag.com>
a8f2af7
to
89c07e5
Compare
crates/common/tedge_config/src/tedge_config_cli/tedge_config_repository.rs
Show resolved
Hide resolved
@@ -19,6 +19,7 @@ const BROKER_GROUP: &str = "mosquitto"; | |||
|
|||
fn main() -> anyhow::Result<()> { | |||
let opt = cli::Opt::parse(); | |||
tedge_utils::logging::initialise_tracing_subscriber(false); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is not it should be like below, this also needs to pass --debug flag when one uses the tedge cli.
tedge_utils::logging::initialise_tracing_subscriber(false); | |
tedge_utils::logging::initialise_tracing_subscriber(opt.debug); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This might be updated when merged with #1624.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For this, we need to add --debug
option for tedge
command. This can be a separate PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved
New macro crate that introduces the `serde_other` proc macro attribute for capturing unknown fields when deserialising to a struct. Signed-off-by: alexandru solomes <solo@softwareag.com>
Signed-off-by: alexandru solomes <solo@softwareag.com>
Added logging to `tedge` and warning is displayed when they toml field or keys are not known. Signed-off-by: alexandru solomes <solo@softwareag.com>
Signed-off-by: alexandru solomes <solo@softwareag.com>
89c07e5
to
ab7d89b
Compare
Proposed changes
This PR:
other
.tedge
binaryTypes of changes
Paste Link to the issue
Checklist
cargo fmt
as mentioned in CODING_GUIDELINEScargo clippy
as mentioned in CODING_GUIDELINESFurther comments