bytes has no attribute encode

Bug #1574671 reported by Serge Hallyn on 2016-04-25
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
apport (Ubuntu)
High
Unassigned

Bug Description

During reporting of a separate bug (1574566), the following was seen:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/apport/report.py", line 197, in _run_hook
    symb['add_info'](report, ui)
  File "/usr/share/apport/general-hooks/ubuntu.py", line 66, in add_info
    check_attachment_for_errors(report, attachment)
  File "/usr/share/apport/general-hooks/ubuntu.py", line 170, in check_attachment_for_errors
    trim_dpkg_log(report)
  File "/usr/share/apport/general-hooks/ubuntu.py", line 468, in trim_dpkg_log
    report['DpkgTerminalLog'] = '\n'.join([str(line.encode('utf-8')) for line in lines])
  File "/usr/share/apport/general-hooks/ubuntu.py", line 468, in <listcomp>
    report['DpkgTerminalLog'] = '\n'.join([str(line.encode('utf-8')) for line in lines])
AttributeError: 'bytes' object has no attribute 'encode'

Changed in apport (Ubuntu):
importance: Undecided → High
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers