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

TypeError: write() argument must be str, not bytes #186

Closed
mastak opened this issue Apr 5, 2018 · 3 comments
Closed

TypeError: write() argument must be str, not bytes #186

mastak opened this issue Apr 5, 2018 · 3 comments
Labels

Comments

@mastak
Copy link

mastak commented Apr 5, 2018

Here message pass to to_string and then to sys.stderr.write()
to_string – returns bytes
sys.stderr.write receives str

TypeError: write() argument must be str, not bytes:

@beniwohli
Copy link
Contributor

Hi @mastak! Thanks for the report! I assume you are getting this in connection with our logging handlers? There is indeed a bug there, and I opened a PR to fix it (#187). Sorry about that!

@mastak
Copy link
Author

mastak commented Apr 5, 2018

Hi @beniwohli!

Yes, I faced with it in logging handler.
By the way, I thought I pasted the path to file elasticapm/handlers/logging.py in the issue, but not, sorry.

PS thanks for quick response!

@beniwohli
Copy link
Contributor

The PR is merged now. We'll make a release with this in the next few days!

@beniwohli beniwohli added the bug label Apr 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants