-
Notifications
You must be signed in to change notification settings - Fork 101
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
"load from url" fails with Granicus Website #1813
Comments
Thanks for opening your first issue in this project! If you haven't already, you can join our slack and join the #gtfs-validators channel to meet our awesome community. Come say hi 👋! |
Hi @vevetron - thanks for flagging this! We tested this and saw this notice from the Granicus website in our logs:
We suspect this may because our user agent is blocked by the website. The user agent we provide is shared here. We'd suggest troubleshooting this on the Granicus website to verify if this is the issue. Let us know if there's anything else we can do to support with this problem. |
We saw something similar since we made requests from Google Cloud. Options:
|
I tested the URL, and it works in a browser, but the curl command fails to download the ZIP file because the required headers, including User-Agent and sec-ch-ua, are missing. @emmambd We can do better error handling as part of the solution to this bug and ask the engagement team to contact Granicus. curl 'https://www.cityofcalabasas.com/home/showpublisheddocument/31620/638611519891730000' |
Hi @vevetron, could you please reach out to Granicus and request them to whitelist MobilityData's header for GTFS validation? The header to whitelist is: user-agent: MobilityData GTFS-Validator/6.0.0 (Java 17.0.6). Please make sure it matches the correct GTFS validation version (You can check the validation version in the report). |
I sent a first email to Granicus and cc'd @qcdyx on it. We can try. Y'all would probably need to set up a custom header that we keep secret. Also since each time java or the validator's version changed the header would change. I had emailed Calabasus website team previously and they never got back to me, so we might want to find an easier target. I'm guessing all the granicus websites will be blocked from MobilityData. |
Hey @vevetron Thanks for the update! Please also note that the current version is 5.0.1, which can be found in the validation report. https://gtfs-validator.mobilitydata.org/ |
I wonder what the 6.0.0 means. Here are some of the CAS agencies we had trouble with: City of Inglewood | Civic Plus I tested Glendora through MobilityData validator and it also failed, so I'm guessing the rest will as well. |
Hey @vevetron Thanks for pointing that out! The "6.0.0" is actually a placeholder for the version we're currently working on for the GTFS Validator's next release. The current public version is 5.0.1, as I mentioned. I included 6.0.0 in the whitelist request to future-proof it for when the new release goes live. For now, we can proceed with the request using 5.0.1, and once 6.0.0 is released, we can update it if needed. I tested the City of Tracy's URL (http://data.trilliumtransit.com/gtfs/tracy-ca-us/tracy-ca-us.zip) from the MobilityDatabase (https://mobilitydatabase.org/feeds/mdb-877), and it is working. The URL of City of Glendora (https://raw.githubusercontent.com/LACMTA/los-angeles-regional-gtfs/main/glendora-ca-us/glendora-ca-us.zip) found on the MobilityDatabase https://mobilitydatabase.org/feeds/mdb-609 gives me a 404 when I tried it in browser. Please continue testing using the URLs on MobilityDatase https://mobilitydatabase.org/ for the other cities. |
Looks like Tracy hosts their gtfs in two places- this is the one new one we have been using that fails without a firewall exception. |
Question - does MobilityData use a stable IP address when downloading gtfs?
If the ip address is static, it would be easier to get a firewall passthrough approved for Granicus rather than getting the user-agent whitelisted. (For CAL-ITP, our ips in this case are ephemeral). |
David says the servers run in the cloud and don't have stable ip addresses. |
Hi @vevetron, yes unfortunately we don't have a static IP that producers can rely on. As a follow up, we will work in the different branches of this issue.
We are looking at having this implemented by the next release. |
Hi! Can someone from your team test the new granicus auth keys from your cloud server? Refer to the emails for the code. |
Describe the bug
Attempts to validated: Calabasas but get "Error Processing Report".
I don't see anything in the inspection that suggests an error.
But I think what could be happening, Granicus probably blocks requests from cloud servers. So we put in the url, mobility-data server puts in a request for the file, it gets blocked, and we get an error.
It's okay if you download the file and upload it directly.
Steps/Code to Reproduce
Go here:
https://gtfs-validator.mobilitydata.org/
Put in this url: Calabasas to "Load from a URL"
Expected Results
Should process the gtfs
Actual Results
"Error Processing Result"
Screenshots
No response
Files used
No response
Validator version
Can't tell - 9/9/2024 version
Operating system
Windows - Chrome
Java version
No response
Additional notes
No response
The text was updated successfully, but these errors were encountered: