Closed cjer closed 6 years ago
Hi @cjer. I recommend using ptg.writers.extract_feed
, instead of using write_feed_dangerously
.
inpath = 'mygtfs.zip'
outpath = 'mygtfs-pruned.zip'
agency_ids = ['2', '4']
ptg.writers.extract_feed(inpath, outpath, {
{'routes.txt': {'agency_id': agency_ids}}
})
feed = ptg.feed(outpath)
Does that work for your use case?
Hey! that seems to work great!
docs anyone? :)
I recently added extract_feed
to the docs under "Extracting a new feed" in the Usage section: https://github.com/remix/partridge#usage.
I would like to have the option for creating a valid pruned GTFS feed based on a partridge feed. I tried to use
write_feed_dangerously
, but:Thanks