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

Improve Error Messages #13

Merged
merged 3 commits into from Jan 2, 2023
Merged

Improve Error Messages #13

merged 3 commits into from Jan 2, 2023

Conversation

brkp
Copy link
Collaborator

@brkp brkp commented Jan 2, 2023

This PR introduces context messages for each error message, providing additional information to help understand the cause of the error. Here's an example before/after:

Before:

[2023-01-02T13:15:03Z INFO  mmproxy::listener::tcp] listening on: 127.0.0.1:25577
[2023-01-02T13:15:06Z INFO  mmproxy::listener::tcp] [new conn] [origin: 127.0.0.1:53566 [src: 127.0.0.1:0]
[2023-01-02T13:15:06Z ERROR mmproxy::listener::tcp] while handling a connection: Operation not permitted (os error 1)

After:

[2023-01-02T13:12:59Z INFO  mmproxy::listener::tcp] listening on: 127.0.0.1:25577
[2023-01-02T13:13:16Z INFO  mmproxy::listener::tcp] [new conn] [origin: 127.0.0.1:46780] [src: 127.0.0.1:0]
[2023-01-02T13:13:16Z ERROR mmproxy::listener::tcp] failed to set ip transparent on the upstream socket: Operation not permitted (os error 1)

@markus-wa
Copy link
Member

markus-wa commented Jan 2, 2023

LGTM - feel free to merge if the PR is ready from your side 🙂

@brkp brkp merged commit 6ab2b52 into main Jan 2, 2023
@brkp brkp deleted the eyre-error-handling branch January 2, 2023 14:48
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.

None yet

2 participants