Skip to content
This repository has been archived by the owner on Dec 8, 2022. It is now read-only.

Decret_2015_1610 can't use len() on generator #34

Closed
laurentg opened this issue Feb 23, 2016 · 0 comments
Closed

Decret_2015_1610 can't use len() on generator #34

laurentg opened this issue Feb 23, 2016 · 0 comments
Labels

Comments

@laurentg
Copy link
Contributor

gtfsrun test.sqlite Decret_2015_1610
Traceback (most recent call last):
  File "/usr/local/bin/gtfsrun", line 9, in <module>
    load_entry_point('gtfslib==0.1.0', 'console_scripts', 'gtfsrun')()
  File "/home/g/gtfslib/gtfslib-python/gtfsplugins/gtfsrun.py", line 96, in main
    retval = plugin.run(context, **kwargs)
  File "/home/g/gtfslib/gtfslib-python/gtfsplugins/decret_2015_1610.py", line 111, in run
    urbain = decret_2015_1610(trips)
  File "/home/g/gtfslib/gtfslib-python/gtfsplugins/decret_2015_1610.py", line 26, in decret_2015_1610
    if len(trips) == 0:
TypeError: object of type 'generator' has no len()
@laurentg laurentg added the bug label Feb 23, 2016
laurentg added a commit that referenced this issue Feb 23, 2016
We need to loop on trips multiple times, so we
can't use a generator.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant