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

v6: pagination not working due to realtime routing #31

Open
debfx opened this issue Jun 26, 2023 · 4 comments · May be fixed by #46
Open

v6: pagination not working due to realtime routing #31

debfx opened this issue Jun 26, 2023 · 4 comments · May be fixed by #46

Comments

@debfx
Copy link
Contributor

debfx commented Jun 26, 2023

Pagination doesn't seem to be working with API v6.

For example https://v6.db.transport.rest/journeys?from=8096021&to=8000085&departure=2023-08-01 returns 3 results with the latest departure at 04:46.

Still both earlierRef and laterRef are null so it's not possible to do follow-up request for the next results.

API v5 https://v5.db.transport.rest/journeys?from=8096021&to=8000085&departure=2023-08-01 returns working earlierRef and laterRef.

@derhuerst
Copy link
Owner

In hafas-client, the HAFAS client underlying v6.db.transport.rest & v5.db.transport.rest, I have changed the default rtMode (routing mode of the HAFAS engine) from "hybrid" routing to "realtime" routing: public-transport/hafas-client@3c17678d. This change has been done in hafas-client@6 only, so that explains why the pagination is only broken in v6.db.transport.rest.

The ticket in the hafas-client repo proposes adding an option to hafas-clients's journey() method, which could then be exposed here in db-rest. Then, we should also clearly document the effects of the realtimeRouting option.

TLDR: blocked by public-transport/hafas-client#287

@derhuerst derhuerst changed the title Pagination not wokring with v6 v6: pagination not working due to realtime routing Jun 27, 2023
@derhuerst
Copy link
Owner

I have published the fix (#295) as [email protected]. 🎉

public-transport/hafas-client#287 (comment)

This is unblocked now. What needs to be done here:

@dancojocaru2000
Copy link

Is there work in progress for this? If not, I might try looking into it, since it's affecting my usecase.

@derhuerst
Copy link
Owner

Is there work in progress for this?

None that I know of.

@JohannesGandhi JohannesGandhi linked a pull request Mar 28, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants