package sosreport 4.4-1ubuntu0.18.04.1 failed to install/upgrade: installed sosreport package post-installation script subprocess returned error exit status 1
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
sosreport (Ubuntu) |
Invalid
|
Undecided
|
Unassigned | ||
Bionic |
Triaged
|
High
|
Unassigned |
Bug Description
This is what I got when I tried do-release-upgrade from 16.04 to 18.04
Setting up sosreport (4.4-1ubuntu0.
File "/usr/lib/
f"Failed to communicate with Metadata Server "
SyntaxError: invalid syntax
dpkg: error processing package sosreport (--configure):
installed sosreport package post-installation script subprocess returned error exit status 1
Errors were encountered while processing:
sosreport
ERROR: Cannot create report: [Errno 17] File exists: '/var/crash/
Exception during pm.DoInstall(): E:Sub-process /usr/bin/dpkg returned an error code (1)
ProblemType: Package
DistroRelease: Ubuntu 16.04
Package: sosreport 4.4-1ubuntu0.
ProcVersionSign
Uname: Linux 4.15.0-213-generic x86_64
ApportVersion: 2.20.9-0ubuntu7.29
AptOrdering: NULL: ConfigurePending
Architecture: amd64
Date: Fri Oct 6 11:34:34 2023
Ec2AMI: ami-1e749f67
Ec2AMIManifest: (unknown)
Ec2Availability
Ec2InstanceType: m3.xlarge
Ec2Kernel: unavailable
Ec2Ramdisk: unavailable
ErrorMessage: installed sosreport package post-installation script subprocess returned error exit status 1
Python3Details: /usr/bin/python3.5, Python 3.5.2, python3-minimal, 3.5.1-3
PythonDetails: /usr/bin/python2.7, Python 2.7.17, python-minimal, 2.7.15~rc1-1
RelatedPackageV
dpkg 1.19.0.5ubuntu2.4
apt 1.6.17
SourcePackage: sosreport
Title: package sosreport 4.4-1ubuntu0.
UpgradeStatus: Upgraded to xenial on 2023-10-06 (0 days ago)
Changed in sosreport (Ubuntu Bionic): | |
importance: | Undecided → High |
tags: | added: patch |
tags: | removed: server-triage-discuss |
Changed in sosreport (Ubuntu Bionic): | |
status: | Incomplete → Triaged |
Thanks for reporting this bug.
This is an interesting one. The user is upgrading from xenial to bionic.
xenial has python 3.5, bionic has python 3.6.
During the postinst (included by dh_python), sosreport runs a python script containing an f-string. However f-strings were only introduced in python 3.6. In this case, the postinst ran with python 3.5, which results in a syntax error when the f-string is parsed.