distlib.database.Metadata.get_requirements throws a type error

Issue #73 closed
Alex LordThorsen
created an issue


from distlib.database import Metadata
meta_data = Metadata()
meta_data.get_requirements(['uttt'], set()) # Valid pypi package, ultimate tick tack toe =P
Traceback (most recent call last):                                                                  
  File "<stdin>", line 1, in <module>                                                               
  File "/home/alex/.virtualenvs/caniusepython3/lib/python3.4/site-packages/distlib-0.2.0-py3.4.egg/distlib/metadata.py", line 874, in get_requirements                                                  
TypeError: string indices must be integers  

Ran into this while attempting to run caniusepython3 on all of pypi. Bound to run into some strange things.



Comments (2)

  1. Vinay Sajip

    You're not using get_requirements correctly here - it needs to be passed a list of dicts in the format of PEP426 run_requires. However, from looking at the context, it might be a bug in how distlib.database is calling this method, or it might be data-related. Will investigate.

  2. Log in to comment