[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-06-16 Thread Launchpad Bug Tracker
This bug was fixed in the package apport - 2.20.11-0ubuntu27.3

---
apport (2.20.11-0ubuntu27.3) focal; urgency=medium

  * apport_python_hook.py: if python apt modules are not built for the python
version then do capture the crash. (LP: #1774843)
  * apport/report.py: If the user is not a part of any system groups then
set UserGroups to 'N/A'. (LP: #1427600)

 -- Brian Murray   Mon, 01 Jun 2020 09:44:37 -0700

** Changed in: apport (Ubuntu Focal)
   Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Released
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Released
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  Fix Released
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case for 18.04]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Test Case for 20.04]
  1) Install python3.7 and python3.8 on an Ubuntu 19.10 system
  2) Upgrade from 19.10 to 20.04 LTS and keep python3.7 installed
  3) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  $ python3.7 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
    File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
    File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
    File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
    File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'

  Original exception was:
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  Python 3.6.5 (default, Apr  1 2018, 05:46:30)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more 

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-06-08 Thread Brian Murray
I successfully performed the verification on Ubuntu 20.04 LTS.

Get:1 http://archive.ubuntu.com/ubuntu focal-proposed/main amd64 python3-apport 
all 2.20.11-0ubuntu27.3 [83.8 kB]
Fetched 83.8 kB in 1s (117 kB/s)
(Reading database ... 307919 files and directories currently installed.)
Preparing to unpack .../python3-apport_2.20.11-0ubuntu27.3_all.deb ...
Unpacking python3-apport (2.20.11-0ubuntu27.3) over (2.20.11-0ubuntu27.2) ...
Setting up python3-apport (2.20.11-0ubuntu27.3) ...
bdmurray@clean-bionic-amd64:~$ python3.7 -c 'print hello'
  File "", line 1
print hello
  ^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(hello)?


** Tags removed: verification-needed verification-needed-focal
** Tags added: verification-done verification-done-focal

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Released
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Released
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  Fix Committed
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case for 18.04]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Test Case for 20.04]
  1) Install python3.7 and python3.8 on an Ubuntu 19.10 system
  2) Upgrade from 19.10 to 20.04 LTS and keep python3.7 installed
  3) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  $ python3.7 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
    File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
    File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
    File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
    File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'

  Original 

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-06-05 Thread Łukasz Zemczak
Hello Bart, or anyone else affected,

Accepted apport into focal-proposed. The package will build now and be
available at
https://launchpad.net/ubuntu/+source/apport/2.20.11-0ubuntu27.3 in a few
hours, and then in the -proposed repository.

Please help us by testing this new package.  See
https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how
to enable and use -proposed.  Your feedback will aid us getting this
update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug,
mentioning the version of the package you tested, what testing has been
performed on the package and change the tag from verification-needed-
focal to verification-done-focal. If it does not fix the bug for you,
please add a comment stating that, and change the tag to verification-
failed-focal. In either case, without details of your testing we will
not be able to proceed.

Further information regarding the verification process can be found at
https://wiki.ubuntu.com/QATeam/PerformingSRUVerification .  Thank you in
advance for helping!

N.B. The updated package will be released to -updates after the bug(s)
fixed by this package have been verified and the package has been in
-proposed for a minimum of 7 days.

** Changed in: apport (Ubuntu Focal)
   Status: In Progress => Fix Committed

** Tags removed: verification-done
** Tags added: verification-needed verification-needed-focal

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Released
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Released
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  Fix Committed
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case for 18.04]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Test Case for 20.04]
  1) Install python3.7 and python3.8 on an Ubuntu 19.10 system
  2) Upgrade from 19.10 to 20.04 LTS and keep python3.7 installed
  3) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  $ python3.7 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import 

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-06-01 Thread Brian Murray
** Changed in: apport (Ubuntu Focal)
   Status: New => In Progress

** Changed in: apport (Ubuntu Focal)
 Assignee: (unassigned) => Brian Murray (brian-murray)

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Released
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Released
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  In Progress
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case for 18.04]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Test Case for 20.04]
  1) Install python3.7 and python3.8 on an Ubuntu 19.10 system
  2) Upgrade from 19.10 to 20.04 LTS and keep python3.7 installed
  3) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  $ python3.7 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
    File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
    File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
    File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
    File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'

  Original exception was:
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  Python 3.6.5 (default, Apr  1 2018, 05:46:30)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >>> import apt_pkg
  >>> apt_pkg.__file__
  '/usr/lib/python3/dist-packages/apt_pkg.cpython-36m-x86_64-linux-gnu.so'
  >>>

  Python 3.7.0b3 (default, Mar 30 2018, 04:35:22)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> 

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-06-01 Thread Launchpad Bug Tracker
** Branch linked: lp:~ubuntu-core-dev/ubuntu/focal/apport/ubuntu

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Released
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Released
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  New
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case for 18.04]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Test Case for 20.04]
  1) Install python3.7 and python3.8 on an Ubuntu 19.10 system
  2) Upgrade from 19.10 to 20.04 LTS and keep python3.7 installed
  3) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  $ python3.7 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
    File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
    File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
    File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
    File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'

  Original exception was:
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  Python 3.6.5 (default, Apr  1 2018, 05:46:30)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >>> import apt_pkg
  >>> apt_pkg.__file__
  '/usr/lib/python3/dist-packages/apt_pkg.cpython-36m-x86_64-linux-gnu.so'
  >>>

  Python 3.7.0b3 (default, Mar 30 2018, 04:35:22)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >> import apt_pkg
  Traceback (most recent call last):
    File "", line 1, in 
  

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-06-01 Thread Brian Murray
** Description changed:

  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.
  
- [Test Case]
+ [Test Case for 18.04]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.
  
  With the version of python3-apport from -proposed you'll not receive the
  Traceback from step # 2.
  
+ [Test Case for 20.04]
+ 1) Install python3.7 and python3.8 on an Ubuntu 19.10 system
+ 2) Upgrade from 19.10 to 20.04 LTS and keep python3.7 installed
+ 3) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.
+ 
+ With the version of python3-apport from -proposed you'll not receive the
+ Traceback from step # 2
+ 
  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.
- 
- [NOTE]
- It isn't necessary to fix this in Ubuntu 20.04 LTS, as there is only 
python3.8 available, so I haven't.
  
  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)
  
  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6
  
  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04
  
  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1
  
  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  
  $ python3.7 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
    File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
    File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
    File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
    File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'
  
  Original exception was:
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  
  Python 3.6.5 (default, Apr  1 2018, 05:46:30)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >>> import apt_pkg
  >>> apt_pkg.__file__
  '/usr/lib/python3/dist-packages/apt_pkg.cpython-36m-x86_64-linux-gnu.so'
  >>>
  
  Python 3.7.0b3 (default, Mar 30 2018, 04:35:22)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >> import apt_pkg
  Traceback (most recent call last):
    File "", line 1, in 
  ModuleNotFoundError: No module named 'apt_pkg'

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Released
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Released
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source 

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-05-28 Thread Launchpad Bug Tracker
This bug was fixed in the package apport - 2.20.9-0ubuntu7.15

---
apport (2.20.9-0ubuntu7.15) bionic; urgency=medium

  * apport_python_hook.py: if python apt modules are not built for the python
version then do capture the crash. (LP: #1774843)

 -- Brian Murray   Wed, 13 May 2020 15:12:14 -0700

** Changed in: apport (Ubuntu Bionic)
   Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Released
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Released
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  New
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [NOTE]
  It isn't necessary to fix this in Ubuntu 20.04 LTS, as there is only 
python3.8 available, so I haven't.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  $ python3.7 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
    File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
    File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
    File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
    File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'

  Original exception was:
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  Python 3.6.5 (default, Apr  1 2018, 05:46:30)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >>> import apt_pkg
  >>> apt_pkg.__file__
  '/usr/lib/python3/dist-packages/apt_pkg.cpython-36m-x86_64-linux-gnu.so'
  >>>

  Python 3.7.0b3 (default, Mar 30 2018, 04:35:22)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >> 

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-05-28 Thread Launchpad Bug Tracker
This bug was fixed in the package apport - 2.20.11-0ubuntu8.9

---
apport (2.20.11-0ubuntu8.9) eoan; urgency=medium

  * apport_python_hook.py: if python apt modules are not built for the python
version then do capture the crash. (LP: #1774843)

 -- Brian Murray   Wed, 13 May 2020 14:09:52 -0700

** Changed in: apport (Ubuntu Eoan)
   Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Released
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Released
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  New
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [NOTE]
  It isn't necessary to fix this in Ubuntu 20.04 LTS, as there is only 
python3.8 available, so I haven't.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  $ python3.7 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
    File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
    File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
    File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
    File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'

  Original exception was:
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  Python 3.6.5 (default, Apr  1 2018, 05:46:30)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >>> import apt_pkg
  >>> apt_pkg.__file__
  '/usr/lib/python3/dist-packages/apt_pkg.cpython-36m-x86_64-linux-gnu.so'
  >>>

  Python 3.7.0b3 (default, Mar 30 2018, 04:35:22)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >> 

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-05-28 Thread Łukasz Zemczak
** Changed in: apport (Ubuntu Focal)
   Status: Invalid => New

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Released
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Released
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  New
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [NOTE]
  It isn't necessary to fix this in Ubuntu 20.04 LTS, as there is only 
python3.8 available, so I haven't.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  $ python3.7 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
    File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
    File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
    File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
    File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'

  Original exception was:
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  Python 3.6.5 (default, Apr  1 2018, 05:46:30)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >>> import apt_pkg
  >>> apt_pkg.__file__
  '/usr/lib/python3/dist-packages/apt_pkg.cpython-36m-x86_64-linux-gnu.so'
  >>>

  Python 3.7.0b3 (default, Mar 30 2018, 04:35:22)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >> import apt_pkg
  Traceback (most recent call last):
    File "", line 1, in 
  ModuleNotFoundError: No module named 'apt_pkg'

To manage notifications about this bug go to:
https://bugs.launchpad.net/apport/+bug/1774843/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : 

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-05-22 Thread Bart Goeman
Łukasz's remark on focal: +1

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Committed
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Committed
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  Invalid
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [NOTE]
  It isn't necessary to fix this in Ubuntu 20.04 LTS, as there is only 
python3.8 available, so I haven't.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  $ python3.7 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
    File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
    File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
    File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
    File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'

  Original exception was:
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  Python 3.6.5 (default, Apr  1 2018, 05:46:30)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >>> import apt_pkg
  >>> apt_pkg.__file__
  '/usr/lib/python3/dist-packages/apt_pkg.cpython-36m-x86_64-linux-gnu.so'
  >>>

  Python 3.7.0b3 (default, Mar 30 2018, 04:35:22)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >> import apt_pkg
  Traceback (most recent call last):
    File "", line 1, in 
  ModuleNotFoundError: No module named 'apt_pkg'

To manage notifications about this bug go to:
https://bugs.launchpad.net/apport/+bug/1774843/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : 

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-05-22 Thread Bart Goeman
Verified on Ubuntu 19.10
on 19.10 python3-apt is built for pyton3.7, the system python for 19.10
so i tested against python3.8 from universe.

bart@DH170:~$ apt-cache policy python3-apport
python3-apport:
  Geïnstalleerd: 2.20.11-0ubuntu8.9
  Kandidaat: 2.20.11-0ubuntu8.9
  Versietabel:
 *** 2.20.11-0ubuntu8.9 400
400 http://nl.archive.ubuntu.com/ubuntu eoan-proposed/main amd64 
Packages
400 http://nl.archive.ubuntu.com/ubuntu eoan-proposed/main i386 Packages
100 /var/lib/dpkg/status
 2.20.11-0ubuntu8.8 500
500 http://nl.archive.ubuntu.com/ubuntu eoan-updates/main amd64 Packages
500 http://nl.archive.ubuntu.com/ubuntu eoan-updates/main i386 Packages
500 http://nl.archive.ubuntu.com/ubuntu eoan-security/main amd64 
Packages
500 http://nl.archive.ubuntu.com/ubuntu eoan-security/main i386 Packages
 2.20.11-0ubuntu8 500
500 http://nl.archive.ubuntu.com/ubuntu eoan/main amd64 Packages
500 http://nl.archive.ubuntu.com/ubuntu eoan/main i386 Packages


bart@DH170:~$ python3.7 -c 'import apt_pkg'
bart@DH170:~$ python3.8 -c 'import apt_pkg'
Traceback (most recent call last):
  File "", line 1, in 
ModuleNotFoundError: No module named 'apt_pkg'
bart@DH170:~$ python3.8 -c 'print hello'
  File "", line 1
print hello
  ^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(hello)?

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Committed
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Committed
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  Invalid
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [NOTE]
  It isn't necessary to fix this in Ubuntu 20.04 LTS, as there is only 
python3.8 available, so I haven't.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  $ python3.7 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
    File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
    File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
    File 

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-05-21 Thread Brian Murray
Hmm, that was a bad paste here is the regression test for 19.10:

bdmurray@clean-eoan-amd64:~$ apport-cli coreutils < /dev/null

*** Collecting problem information

The collected information can be sent to the developers to improve the
application. This might take a few minutes.
.

*** Send problem report to the developers?

After the problem report has been sent, please fill out the form in the
automatically opened web browser.

What would you like to do? Your options are:
  S: Send report (1.6 KB)
  V: View report
  K: Keep report file for sending later or copying to somewhere else
  I: Cancel and ignore future crashes of this program version
  C: Cancel
Please choose (S/V/K/I/C): Traceback (most recent call last):
  File "/usr/bin/apport-cli", line 387, in 
if not app.run_argv():
  File "/usr/lib/python3/dist-packages/apport/ui.py", line 711, in run_argv
return self.run_report_bug()
  File "/usr/lib/python3/dist-packages/apport/ui.py", line 550, in 
run_report_bug
response = self.ui_present_report_details(allowed_to_report)
  File "/usr/bin/apport-cli", line 213, in ui_present_report_details
response = dialog.run()
  File "/usr/bin/apport-cli", line 101, in run
multi_char)
  File "/usr/bin/apport-cli", line 49, in raw_input_char
saved_attributes = termios.tcgetattr(file)
termios.error: (25, 'Inappropriate ioctl for device')

And for Ubuntu 18.04 LTS:

bdmurray@clean-bionic-amd64:~$ apport-cli coreutils < /dev/null

*** Collecting problem information

The collected information can be sent to the developers to improve the
application. This might take a few minutes.
.

*** Send problem report to the developers?

After the problem report has been sent, please fill out the form in the
automatically opened web browser.

What would you like to do? Your options are:
  S: Send report (1.6 KB)
  V: View report
  K: Keep report file for sending later or copying to somewhere else
  I: Cancel and ignore future crashes of this program version
  C: Cancel
Please choose (S/V/K/I/C): Traceback (most recent call last):
  File "/usr/bin/apport-cli", line 387, in 
if not app.run_argv():
  File "/usr/lib/python3/dist-packages/apport/ui.py", line 693, in run_argv
return self.run_report_bug()
  File "/usr/lib/python3/dist-packages/apport/ui.py", line 532, in 
run_report_bug
response = self.ui_present_report_details(allowed_to_report)
  File "/usr/bin/apport-cli", line 213, in ui_present_report_details
response = dialog.run()
  File "/usr/bin/apport-cli", line 101, in run
multi_char)
  File "/usr/bin/apport-cli", line 49, in raw_input_char
saved_attributes = termios.tcgetattr(file)
termios.error: (25, 'Inappropriate ioctl for device')


** Tags removed: verification-needed verification-needed-bionic 
verification-needed-eoan
** Tags added: verification-done verification-done-bionic verification-done-eoan

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Committed
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Committed
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  Invalid
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [NOTE]
  It isn't necessary to fix this in Ubuntu 20.04 LTS, as there is only 
python3.8 available, so I haven't.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-05-21 Thread Brian Murray
Verified on Ubuntu 19.10:

bdmurray@clean-bionic-amd64:~$ apt-cache policy python3-apport
python3-apport:
  Installed: 2.20.9-0ubuntu7.15
  Candidate: 2.20.9-0ubuntu7.15
  Version table:
 *** 2.20.9-0ubuntu7.15 500
500 http://archive.ubuntu.com/ubuntu bionic-proposed/main amd64 Packages
500 http://archive.ubuntu.com/ubuntu bionic-proposed/main i386 Packages
100 /var/lib/dpkg/status
 2.20.9-0ubuntu7.14 500
500 http://192.168.10.7/ubuntu bionic-updates/main amd64 Packages
500 http://192.168.10.7/ubuntu bionic-updates/main i386 Packages
500 http://192.168.10.7/ubuntu bionic-security/main amd64 Packages
500 http://192.168.10.7/ubuntu bionic-security/main i386 Packages
 2.20.9-0ubuntu7 500
500 http://192.168.10.7/ubuntu bionic/main amd64 Packages
500 http://192.168.10.7/ubuntu bionic/main i386 Packages
bdmurray@clean-bionic-amd64:~$ python3.7 -c 'print hello'
  File "", line 1
print hello
  ^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(hello)?

and the regression test passes:

bdmurray@clean-bionic-amd64:~$ apt-cache policy python3-apport
python3-apport:
  Installed: 2.20.9-0ubuntu7.15
  Candidate: 2.20.9-0ubuntu7.15
  Version table:
 *** 2.20.9-0ubuntu7.15 500
500 http://archive.ubuntu.com/ubuntu bionic-proposed/main amd64 Packages
500 http://archive.ubuntu.com/ubuntu bionic-proposed/main i386 Packages
100 /var/lib/dpkg/status
 2.20.9-0ubuntu7.14 500
500 http://192.168.10.7/ubuntu bionic-updates/main amd64 Packages
500 http://192.168.10.7/ubuntu bionic-updates/main i386 Packages
500 http://192.168.10.7/ubuntu bionic-security/main amd64 Packages
500 http://192.168.10.7/ubuntu bionic-security/main i386 Packages
 2.20.9-0ubuntu7 500
500 http://192.168.10.7/ubuntu bionic/main amd64 Packages
500 http://192.168.10.7/ubuntu bionic/main i386 Packages
bdmurray@clean-bionic-amd64:~$ python3.7 -c 'print hello'
  File "", line 1
print hello
  ^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(hello)?

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Committed
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Committed
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  Invalid
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [NOTE]
  It isn't necessary to fix this in Ubuntu 20.04 LTS, as there is only 
python3.8 available, so I haven't.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print 

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-05-21 Thread Brian Murray
Verified on Ubuntu 18.04 LTS:

bdmurray@clean-bionic-amd64:~$ apt-cache policy python3-apport
python3-apport:
  Installed: 2.20.9-0ubuntu7.15
  Candidate: 2.20.9-0ubuntu7.15
  Version table:
 *** 2.20.9-0ubuntu7.15 500
500 http://archive.ubuntu.com/ubuntu bionic-proposed/main amd64 Packages
500 http://archive.ubuntu.com/ubuntu bionic-proposed/main i386 Packages
100 /var/lib/dpkg/status
 2.20.9-0ubuntu7.14 500
500 http://192.168.10.7/ubuntu bionic-updates/main amd64 Packages
500 http://192.168.10.7/ubuntu bionic-updates/main i386 Packages
500 http://192.168.10.7/ubuntu bionic-security/main amd64 Packages
500 http://192.168.10.7/ubuntu bionic-security/main i386 Packages
 2.20.9-0ubuntu7 500
500 http://192.168.10.7/ubuntu bionic/main amd64 Packages
500 http://192.168.10.7/ubuntu bionic/main i386 Packages
bdmurray@clean-bionic-amd64:~$ python3.7 -c 'print hello'
  File "", line 1
print hello
  ^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(hello)?

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Committed
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Committed
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  Invalid
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [NOTE]
  It isn't necessary to fix this in Ubuntu 20.04 LTS, as there is only 
python3.8 available, so I haven't.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  $ python3.7 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
    File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
    File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
    File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
    File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No 

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-05-21 Thread Łukasz Zemczak
Seeing that focal is an LTS, don't you think that it might still useful
to have this 'fix' for that series? Currently we only have python3.8,
but I assume we might backport newer python versions in the future.
Wouldn't that make people potentially affected by this bug then?

I'll accept it as is, but let's reconsider pushing it to focal as well.

** Changed in: apport (Ubuntu Eoan)
   Status: In Progress => Fix Committed

** Tags added: verification-needed verification-needed-eoan

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  Fix Committed
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  Fix Committed
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  Invalid
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [NOTE]
  It isn't necessary to fix this in Ubuntu 20.04 LTS, as there is only 
python3.8 available, so I haven't.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  $ python3.7 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
    File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
    File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
    File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
    File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'

  Original exception was:
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  Python 3.6.5 (default, Apr  1 2018, 05:46:30)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >>> import apt_pkg
  >>> apt_pkg.__file__
  '/usr/lib/python3/dist-packages/apt_pkg.cpython-36m-x86_64-linux-gnu.so'
  >>>

  Python 3.7.0b3 (default, Mar 30 2018, 04:35:22)
  [GCC 7.3.0] on linux
  Type "help", 

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-05-13 Thread Launchpad Bug Tracker
This bug was fixed in the package apport - 2.20.11-0ubuntu34

---
apport (2.20.11-0ubuntu34) groovy; urgency=medium

  * apport_python_hook.py: if python apt modules are not built for the python
version then do capture the crash. (LP: #1774843)

 -- Brian Murray   Wed, 13 May 2020 16:17:11 -0700

** Changed in: apport (Ubuntu)
   Status: In Progress => Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  Fix Released
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  In Progress
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  In Progress
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  Invalid
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  [Impact]
  apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.

  [Test Case]
  1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
  2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.

  With the version of python3-apport from -proposed you'll not receive
  the Traceback from step # 2.

  [Regression Potential]
  Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.

  [NOTE]
  It isn't necessary to fix this in Ubuntu 20.04 LTS, as there is only 
python3.8 available, so I haven't.

  [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  $ python3.7 -c 'print hello'
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
    File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
    File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
    File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
    File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'

  Original exception was:
    File "", line 1
  print hello
    ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  Python 3.6.5 (default, Apr  1 2018, 05:46:30)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >>> import apt_pkg
  >>> apt_pkg.__file__
  '/usr/lib/python3/dist-packages/apt_pkg.cpython-36m-x86_64-linux-gnu.so'
  >>>

  Python 3.7.0b3 (default, Mar 30 2018, 04:35:22)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >> import 

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-05-13 Thread Brian Murray
** Description changed:

+ [Impact]
+ apport's python crash handler runs for every installed version of python e.g. 
on Ubuntu 18.04 LTS it will run for crashes with python3.6 or python3.7 as an 
interpreter. However, python apt modules are only available for the the 
supported version of python so the crash handler generates an exception which 
is annoying.
+ 
+ [Test Case]
+ 1) Install the non-default version of python3 e.g. python3.7 on Ubuntu 18.04 
LTS.
+ 2) Run 'python3.7 -c 'print hello' and observe a Traceback re apt_pkg not 
being found.
+ 
+ With the version of python3-apport from -proposed you'll not receive the
+ Traceback from step # 2.
+ 
+ [Regression Potential]
+ Its possible the crash handler change is incorrect so it should be confirmed 
that we still get python crashes about the system version of python. One way to 
do this is to run 'apport-cli coreutils < /dev/null'.
+ 
+ [NOTE]
+ It isn't necessary to fix this in Ubuntu 20.04 LTS, as there is only 
python3.8 available, so I haven't.
+ 
+ [Original Description]
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)
  
  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6
- 
  
  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04
  
  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1
  
  Demo with a trivial error:
  $ python3 -c 'print hello'
-   File "", line 1
- print hello
-   ^
+   File "", line 1
+ print hello
+   ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  
- 
  $ python3.7 -c 'print hello'
-   File "", line 1
- print hello
-   ^
+   File "", line 1
+ print hello
+   ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
-   File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
- from apport.fileutils import likely_packaged, get_recent_crashes
-   File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

- from apport.report import Report
-   File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
- import apport.fileutils
-   File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

- from apport.packaging_impl import impl as packaging
-   File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

- import apt
-   File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
- import apt_pkg
+   File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
+ from apport.fileutils import likely_packaged, get_recent_crashes
+   File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

+ from apport.report import Report
+   File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
+ import apport.fileutils
+   File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

+ from apport.packaging_impl import impl as packaging
+   File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

+ import apt
+   File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
+ import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'
  
  Original exception was:
-   File "", line 1
- print hello
-   ^
+   File "", line 1
+ print hello
+   ^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  
- 
- Python 3.6.5 (default, Apr  1 2018, 05:46:30) 
+ Python 3.6.5 (default, Apr  1 2018, 05:46:30)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >>> import apt_pkg
  >>> apt_pkg.__file__
  '/usr/lib/python3/dist-packages/apt_pkg.cpython-36m-x86_64-linux-gnu.so'
- >>> 
+ >>>
  
- Python 3.7.0b3 (default, Mar 30 2018, 04:35:22) 
+ Python 3.7.0b3 (default, Mar 30 2018, 04:35:22)
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >> import apt_pkg
  Traceback (most recent call last):
-   File "", line 1, in 
+   File "", line 1, in 
  ModuleNotFoundError: No module named 'apt_pkg'

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.

[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-05-13 Thread Launchpad Bug Tracker
** Branch linked: lp:~ubuntu-core-dev/ubuntu/groovy/apport/ubuntu

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  In Progress
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  In Progress
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  In Progress
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  Invalid
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  
  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
File "", line 1
  print hello
^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  
  $ python3.7 -c 'print hello'
File "", line 1
  print hello
^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'

  Original exception was:
File "", line 1
  print hello
^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?


  Python 3.6.5 (default, Apr  1 2018, 05:46:30) 
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >>> import apt_pkg
  >>> apt_pkg.__file__
  '/usr/lib/python3/dist-packages/apt_pkg.cpython-36m-x86_64-linux-gnu.so'
  >>> 

  Python 3.7.0b3 (default, Mar 30 2018, 04:35:22) 
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >> import apt_pkg
  Traceback (most recent call last):
File "", line 1, in 
  ModuleNotFoundError: No module named 'apt_pkg'

To manage notifications about this bug go to:
https://bugs.launchpad.net/apport/+bug/1774843/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-05-13 Thread Brian Murray
** Changed in: python-apt (Ubuntu Eoan)
   Status: Invalid => In Progress

** Changed in: python-apt (Ubuntu Eoan)
 Assignee: (unassigned) => Brian Murray (brian-murray)

** Package changed: python-apt (Ubuntu) => apport (Ubuntu)

** Changed in: apport (Ubuntu)
   Status: Invalid => In Progress

** Changed in: apport (Ubuntu)
 Assignee: (unassigned) => Brian Murray (brian-murray)

** Changed in: apport (Ubuntu Bionic)
   Status: Invalid => In Progress

** Changed in: apport (Ubuntu Bionic)
 Assignee: (unassigned) => Brian Murray (brian-murray)

** Changed in: python3.7 (Ubuntu Bionic)
   Status: Triaged => Won't Fix

** Changed in: python3.7 (Ubuntu Eoan)
   Status: Triaged => Won't Fix

** Changed in: python3.8 (Ubuntu Bionic)
   Status: Triaged => Won't Fix

** Changed in: python3.8 (Ubuntu Eoan)
   Status: Triaged => Won't Fix

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to python-apt in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in apport package in Ubuntu:
  In Progress
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in apport source package in Bionic:
  In Progress
Status in python3.7 source package in Bionic:
  Won't Fix
Status in python3.8 source package in Bionic:
  Won't Fix
Status in apport source package in Eoan:
  In Progress
Status in python3.7 source package in Eoan:
  Won't Fix
Status in python3.8 source package in Eoan:
  Won't Fix
Status in apport source package in Focal:
  Invalid
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  
  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
File "", line 1
  print hello
^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  
  $ python3.7 -c 'print hello'
File "", line 1
  print hello
^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'

  Original exception was:
File "", line 1
  print hello
^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?


  Python 3.6.5 (default, Apr  1 2018, 05:46:30) 
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >>> import apt_pkg
  >>> apt_pkg.__file__
  '/usr/lib/python3/dist-packages/apt_pkg.cpython-36m-x86_64-linux-gnu.so'
  >>> 

  Python 3.7.0b3 (default, Mar 30 2018, 04:35:22) 
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >> import apt_pkg
  Traceback (most recent call last):
File "", line 1, in 
  ModuleNotFoundError: No module named 'apt_pkg'

To manage notifications about this bug go to:
https://bugs.launchpad.net/apport/+bug/1774843/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1774843] Re: apport python exception for python versions which python-apt is not built on

2020-04-14 Thread Brian Murray
** Changed in: python3.8 (Ubuntu Bionic)
   Status: New => Triaged

** Changed in: python-apt (Ubuntu Bionic)
   Status: New => Invalid

** Changed in: python-apt (Ubuntu Eoan)
   Status: New => Invalid

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to python-apt in Ubuntu.
https://bugs.launchpad.net/bugs/1774843

Title:
  apport python exception for python versions which python-apt is not
  built on

Status in Apport:
  New
Status in python-apt package in Ubuntu:
  Invalid
Status in python3.7 package in Ubuntu:
  Invalid
Status in python3.8 package in Ubuntu:
  Invalid
Status in python-apt source package in Bionic:
  Invalid
Status in python3.7 source package in Bionic:
  Triaged
Status in python3.8 source package in Bionic:
  Triaged
Status in python-apt source package in Eoan:
  Invalid
Status in python3.7 source package in Eoan:
  Triaged
Status in python3.8 source package in Eoan:
  Triaged
Status in python-apt source package in Focal:
  Invalid
Status in python3.7 source package in Focal:
  Invalid
Status in python3.8 source package in Focal:
  Invalid

Bug description:
  it seems apport installs an exception hook whenever running python3.
  This hook is apparently installed for python3.7 too.
  This exception handler has a dependency on apt_pkg, which is a binary that is 
not compatible with python3.7 it seems (you can't import it, see below)

  As a result, whenever I run a python3.7 script and run into an exception 
(which happens often when writing code), I get an additional exception in the 
exception handler + a copy of the original exception, so three stacktraces in 
total.
  A solution would be to only install the exception hook for the system python  
i.e. python3.6

  
  $ lsb_release -rd
  Description:  Ubuntu 18.04 LTS
  Release:  18.04

  apport: 2.20.9-0ubuntu7
  python-apt: 1.6.0
  python3.7: 3.7.0~b3-1

  Demo with a trivial error:
  $ python3 -c 'print hello'
File "", line 1
  print hello
^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?

  
  $ python3.7 -c 'print hello'
File "", line 1
  print hello
^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?
  Error in sys.excepthook:
  Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in 
apport_excepthook
  from apport.fileutils import likely_packaged, get_recent_crashes
File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in 

  from apport.report import Report
File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in 
  import apport.fileutils
File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in 

  from apport.packaging_impl import impl as packaging
File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 24, in 

  import apt
File "/usr/lib/python3/dist-packages/apt/__init__.py", line 23, in 
  import apt_pkg
  ModuleNotFoundError: No module named 'apt_pkg'

  Original exception was:
File "", line 1
  print hello
^
  SyntaxError: Missing parentheses in call to 'print'. Did you mean 
print(hello)?


  Python 3.6.5 (default, Apr  1 2018, 05:46:30) 
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >>> import apt_pkg
  >>> apt_pkg.__file__
  '/usr/lib/python3/dist-packages/apt_pkg.cpython-36m-x86_64-linux-gnu.so'
  >>> 

  Python 3.7.0b3 (default, Mar 30 2018, 04:35:22) 
  [GCC 7.3.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> import sys
  >>> sys.excepthook
  
  >> import apt_pkg
  Traceback (most recent call last):
File "", line 1, in 
  ModuleNotFoundError: No module named 'apt_pkg'

To manage notifications about this bug go to:
https://bugs.launchpad.net/apport/+bug/1774843/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp