Skip to content

Conversation

@eval-exec
Copy link
Contributor

@eval-exec eval-exec commented Mar 7, 2023

This PR modifies the register_* macro to use the and_then method instead of unwrap to handle errors.

The purpose of this change is to improve error handling and make the code more robust.

@eval-exec eval-exec changed the title enhance: Replace unwrap() with Result to handle errors Enhance: replace unwrap() with Result to handle errors in register-* macros Mar 7, 2023
@eval-exec eval-exec force-pushed the enhance/better-error-handle branch from 7ea049f to 332edc3 Compare March 7, 2023 00:55
@eval-exec
Copy link
Contributor Author

eval-exec commented Mar 7, 2023

https://github.com/tikv/rust-prometheus/actions/runs/4349482473/jobs/7603874911

The CI action failed, I think we should upgrade the rust toolchain's version.

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

Successfully merging this pull request may close these issues.

1 participant