Hi, Nish is right, this This appears to be a syntax error wrt. to python3. Orig Xenial release 2:4.3.8+dfsg-0ubuntu1 Current Xenial 2:4.3.11+dfsg-0ubuntu0.16.04.3
And the error seems on pre-removal script according to the log: dpkg: warning: subprocess old pre-removal script returned error exit status 1 dpkg: trying script from the new package instead ... File "/usr/bin/pyclean", line 63 except (IOError, OSError), e: In the reported case the versions were: Reporter prior to update 2:4.3.9+dfsg-0ubuntu0.16.04.2 Trying to update to: 4.3.11+dfsg-0ubuntu0.16.04.1 But just as Nish assumed I think we do not have to look at the samba versions too much, essentially the bug is in /usr/bin/pyclean which is part of "python-minimal". And in fact the line: except (IOError, OSError), e: Gets highlighted by syntax checkers as: "Python 3.x incompatible 'except x,y:' construct [H231]" The code is still as-is on Zesty with #! /usr/bin/python. I'd assume this only triggers when the system is tweaked to run /usr/bin/python as python3? Does that match your case? Quick verify: $ python2.7 /usr/bin/pyclean Usage: pyclean [-p PACKAGE] [DIR_OR_FILE] $ python3.5 /usr/bin/pyclean File "/usr/bin/pyclean", line 63 except (IOError, OSError), e: SyntaxError: invalid syntax Therefore I'd file it against python-defaults and subscribe Barry as he is way deeper into the future of py2/py3 transition. ** Tags removed: bitesize xenial ** Summary changed: - package python-samba 2:4.3.9+dfsg-0ubuntu0.16.04.2 failed to install/upgrade: subprocess new pre-removal script returned error exit status 1 + /usr/bin/pyclean fails with python3 ** Also affects: python-defaults (Ubuntu) Importance: Undecided Status: New ** Changed in: python-defaults (Ubuntu) Importance: Undecided => High -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1633331 Title: /usr/bin/pyclean fails with python3 To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/python-defaults/+bug/1633331/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs