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

UnicodeDecodeError #4

Open
luisanadal opened this issue Feb 13, 2023 · 0 comments
Open

UnicodeDecodeError #4

luisanadal opened this issue Feb 13, 2023 · 0 comments

Comments

@luisanadal
Copy link

Running the script from Nagios throw an exception:

Traceback (most recent call last): File "/usr/local/bin/telegram_nagios.py", line 74, in <module> main() File "/usr/local/bin/telegram_nagios.py", line 70, in main message = service_notification(args) File "/usr/local/bin/telegram_nagios.py", line 60, in service_notification args.output, UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 0: ordinal not in range(128)
In my case it is fixed using the decode function, line 60, although no sure if this break other people environments/deployments.
args.output.decode('utf-8'),

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

1 participant