Skip to content
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

Navitia: Add Brazil providers #179

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

grote
Copy link
Contributor

@grote grote commented Dec 5, 2017

Currently working in São Paulo, Rio de Janeiro, Belo Horizonte and Porto Alegre.

Both providers have been used in Transportr already. Time to upstream.

Currently working in São Paulo, Rio de Janeiro, Belo Horizonte and Porto Allegre
@@ -721,6 +721,9 @@ public NearbyLocationsResult queryNearbyLocations(final EnumSet<LocationType> ty

try {
final JSONObject head = new JSONObject(page.toString());
if (head.has("error")) {
return new NearbyLocationsResult(resultHeader, Status.INVALID_ID);
}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One of the live tests with an invalid station arrived here and head had no pagination, but an error.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe this change should go into a different PR that implements error handling for all Navitia calls?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You seem to be merging PRs manually somehow. Couldn't you just split these 3 lines out into a separate commit when you do? I am happy to waive ownership on them.

@schildbach
Copy link
Owner

What's the difference between the two providers. Is one of the datasets likely to be a superset of the other?

@grote
Copy link
Contributor Author

grote commented Dec 6, 2017

The BrProvider is using the official navitia.io server and is currently working in São Paulo, Rio de Janeiro, Belo Horizonte and Porto Alegre.

The BrFloripaProvider uses osm2gtfs to create the GTFS which is not available at the official server. I am personally running a server for it. The URL is used in the tests.

@Xinayder
Copy link

Any update on this?

@schildbach schildbach added the navitia issue concerning AbstractNavitiaProvider, its implementations or the Navitia.io API label Jan 24, 2020
@schildbach
Copy link
Owner

I just merged the Navitia-based provider.

The other one currently only throws errors. I must admit I'm a bit reluctant on merging – is there any chance this can go to Navitia too? If we continue, this needs a rebase.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
navitia issue concerning AbstractNavitiaProvider, its implementations or the Navitia.io API
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants