[Bug 1445947] Re: 'pip3 list' throws AssertionError

Michael Terry michael.terry at canonical.com
Wed May 11 19:05:24 UTC 2016


Thanks for the patch, Liang Chen!  I've uploaded it to wily, so I'll
subscribe the sru team.

-- 
You received this bug notification because you are a member of Ubuntu
Sponsors Team, which is subscribed to the bug report.
https://bugs.launchpad.net/bugs/1445947

Title:
  'pip3 list' throws AssertionError

Status in pip:
  Fix Released
Status in python-pip package in Ubuntu:
  Fix Released
Status in python-pip source package in Wily:
  New

Bug description:
  [Impact]

   * Not able show current list of installed packages, e.g. pip freeze.

  [Test Case]

  1 - install wily/trusty-liberty python-pip package
  2 - pip freeze
  3 - the following error is shown without the patch

  Exception:
  Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/pip/basecommand.py", line 122, in main
  status = self.run(options, args)
  File "/usr/lib/python2.7/dist-packages/pip/commands/freeze.py", line 74, in run
  req = pip.FrozenRequirement.from_dist(dist, dependency_links, find_tags=find_tags)
  File "/usr/lib/python2.7/dist-packages/pip/__init__.py", line 286, in from_dist
  assert len(specs) == 1 and specs[0][0] == '=='
  AssertionError 

  [Regression Potential]

   * None

  
  The command 'pip3 list' is broken on vivid:

  maxb at altimeter:~$ pip3 list
  [snip]
  Exception:
  Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/pip/basecommand.py", line 122, in main
      status = self.run(options, args)
    File "/usr/lib/python3/dist-packages/pip/commands/list.py", line 80, in run
      self.run_listing(options)
    File "/usr/lib/python3/dist-packages/pip/commands/list.py", line 142, in run_listing
      self.output_package_listing(installed_packages)
    File "/usr/lib/python3/dist-packages/pip/commands/list.py", line 151, in output_package_listing
      if dist_is_editable(dist):
    File "/usr/lib/python3/dist-packages/pip/util.py", line 367, in dist_is_editable
      req = FrozenRequirement.from_dist(dist, [])
    File "/usr/lib/python3/dist-packages/pip/__init__.py", line 299, in from_dist
      assert len(specs) == 1 and specs[0][0] == '=='
  AssertionError

  The problem is that the version string of python-apt is not PEP 440
  compliant.  Avoiding this crash is already fixed with a one-line patch
  upstream. Please consider cherry-picking
  https://github.com/pypa/pip/commit/6cab71f422f2425b4d2283023c9e955f9663dde6
  into Vivid's pip.

  ProblemType: Bug
  DistroRelease: Ubuntu 15.04
  Package: python3-pip 1.5.6-5ubuntu2
  ProcVersionSignature: Ubuntu 3.19.0-14.14-generic 3.19.3
  Uname: Linux 3.19.0-14-generic x86_64
  ApportVersion: 2.17.2-0ubuntu1
  Architecture: amd64
  CurrentDesktop: Unity
  Date: Sun Apr 19 16:55:24 2015
  EcryptfsInUse: Yes
  InstallationDate: Installed on 2014-05-29 (325 days ago)
  InstallationMedia: Ubuntu 14.04 LTS "Trusty Tahr" - Release amd64 (20140417)
  PackageArchitecture: all
  SourcePackage: python-pip
  UpgradeStatus: Upgraded to vivid on 2015-03-29 (20 days ago)

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



More information about the Ubuntu-sponsors mailing list