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

Parsing log #4

Open
FormozaxXaw opened this issue Oct 15, 2020 · 0 comments
Open

Parsing log #4

FormozaxXaw opened this issue Oct 15, 2020 · 0 comments

Comments

@FormozaxXaw
Copy link

Hi.
In maillog have russian simbols. After pars, i have a problem

/postfix-parser$ ./run.sh parse
Loading .env environment variables…
2020-10-15 17:42:28,307 postfixparser.main INFO Importing log file
2020-10-15 17:42:28,307 postfixparser.main INFO Opening log file /var/log/mail.log
Traceback (most recent call last):
File "./manage.py", line 70, in
args.func(args)
File "./manage.py", line 56, in runparse
asyncio.run(main())
File "/usr/lib/python3.8/asyncio/runners.py", line 43, in run
return loop.run_until_complete(main)
File "/usr/lib/python3.8/asyncio/base_events.py", line 608, in run_until_complete
return future.result()
File "/home/mailparser/postfix-parser/postfixparser/main.py", line 96, in main
msgs = await import_log(settings.mail_log)
File "/home/mailparser/postfix-parser/postfixparser/main.py", line 74, in import_log
line = f.readline()
File "/usr/lib/python3.8/codecs.py", line 322, in decode
(result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xb4 in position 7150: invalid start byte

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