BlinkTagInc / gtfs-to-html

Build human readable transit timetables as HTML or PDF from GTFS.
https://gtfstohtml.com
MIT License
181 stars 57 forks source link

timetables.zip output is empty when using "zipOutput: true" #108

Closed anniekfifer closed 3 years ago

anniekfifer commented 3 years ago

Hi @brendannee --

When I use the zipOutput option, it looks like timetables are created without issue but the timetables.zip file is empty. Experienced when running command-line tool and when using https://run.gtfstohtml.com/

This is my config (uses default options from run.gtfstohtml.com), running on 1.4.10:

{
  "agencies": [
    {
      "agency_key": "lubbock-tx",
      "url": "http://data.trilliumtransit.com/gtfs/lubbock-tx-us/lubbock-tx-us--ttable.zip"
    }
  ],
  "verbose": true,
  "zipOutput": true,
  "allowEmptyTimetables": false,
  "beautify": false,
  "coordinatePrecision": 5,
  "dateFormat": "MMM D, YYYY",
  "daysShortStrings": [
    "Mon",
    "Tue",
    "Wed",
    "Thu",
    "Fri",
    "Sat",
    "Sun"
  ],
  "daysStrings": [
    "Monday",
    "Tuesday",
    "Wednesday",
    "Thursday",
    "Friday",
    "Saturday",
    "Sunday"
  ],
  "defaultOrientation": "vertical",
  "interpolatedStopSymbol": "•",
  "interpolatedStopText": "Estimated time of arrival",
  "linkStopUrls": true,
  "menuType": "jump",
  "noDropoffSymbol": "‡",
  "noDropoffText": "No drop off available",
  "noHead": false,
  "noPickupSymbol": "**",
  "noPickupText": "No pickup available",
  "noServiceSymbol": "-",
  "noServiceText": "No service at this stop",
  "outputFormat": "html",
  "requestDropoffSymbol": "†",
  "requestDropoffText": "Must request drop off",
  "requestPickupSymbol": "***",
  "requestPickupText": "Request stop - call for pickup",
  "serviceNotProvidedOnText": "Service not provided on",
  "serviceProvidedOnText": "Service provided on",
  "showArrivalOnDifference": 0.2,
  "showMap": false,
  "showOnlyTimepoint": false,
  "showRouteTitle": true,
  "showStopCity": false,
  "showStopDescription": false,
  "sortingAlgorithm": "common",
  "timeFormat": "h:mma",
  "useParentStation": true
}

contents of output:

(base) Annies-MacBook-Pro:script anniefifer$ ls -l html/lubbock-tx/
total 56
drwxr-xr-x  45 anniefifer  staff   1440 Feb 17 10:44 20201101-20210701
drwxr-xr-x   4 anniefifer  staff    128 Feb 17 10:28 css
-rw-r--r--   1 anniefifer  staff  19103 Feb 17 10:28 index.html
drwxr-xr-x   5 anniefifer  staff    160 Feb 17 10:28 js
-rw-r--r--   1 anniefifer  staff    348 Feb 17 10:28 log.txt
-rw-r--r--   1 anniefifer  staff     22 Feb 17 10:28 timetables.zip

I'm newer to this tool so I asked a coworker double-check, she reproduced on 1.3.1 with this config and noted that this option does work for her on an older version that uses mongo.

Thanks!

brendannee commented 3 years ago

Thanks for reporting this issue. I pushed an updated version 1.4.11 which solves this.

Try it out and let me know if there are any other issues.

anniekfifer commented 3 years ago

Works great, thank you for the quick turnaround!!