Skip to content
This repository has been archived by the owner on Jan 23, 2025. It is now read-only.

Canceled attribute not true for canceled connections #24

Open
gitolicious opened this issue Nov 16, 2023 · 9 comments
Open

Canceled attribute not true for canceled connections #24

gitolicious opened this issue Nov 16, 2023 · 9 comments
Labels
dependency Issue within schiene python module, not the HA integration

Comments

@gitolicious
Copy link

The problem

The ongoing strike today is a good chance to test the "canceled" attribute.

Steps to reproduce:

  • Add a connection, in this example Frankfurt(M)Flughafen to Köln, direct connection. Check the DB website and compare to the integration's attributes

Expected result:

  • Trains shown as canceled on the DB website should be shown as canceled in the integration.

Actual result:

  • Canceled: false

image

What version of Home Assistant Core has the issue?

2023.11.2

What version of DeutscheBahn Integration has the issue?

bbd7bcd

What type of installation are you running?

Home Assistant OS

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

@gitolicious gitolicious changed the title Canceled not shown Canceled attribute not true for canceled connections Nov 16, 2023
@bcutter
Copy link

bcutter commented Dec 4, 2023

I had many chances throughout the last days (including today, even now) to test this and wanted to create an issue for the very same problem.

Integration says everything is fine (even on time, no delay). Actually not a single train is driving. "SEV" by bus is the alternative following the DB app / website.

As I just started to actually use this integration productively, this first impression does not paint a very reliable picture unfortunately :-(

  1. Where does the data come from? Why the difference to the DB data (website / app)?
  2. Idea to improve the entity status in regards to this:
  • current implementation: on time = hh:mm, delayed = hh:mm +X
  • proposed addition when train is cancelled: (!) hh:mm (!) (or a similar indicator the train is cancelled)

@FaserF
Copy link
Owner

FaserF commented Jan 11, 2024

Hi, thanks for the issue. Unfortunatly I dont think it's a issue with the integration. Most likely its a issue with the dependency where this integration is based on:
https://github.com/kennell/schiene

The schiene module graps the informations from the bahn.de website. More details can be found above.
The better solution is fetching the data via hafas api, but until now it has not been merged to Homeassistant:
home-assistant/core#78839

@FaserF FaserF added the dependency Issue within schiene python module, not the HA integration label Jan 11, 2024
@bcutter
Copy link

bcutter commented Jan 11, 2024

So what can we do NOW about this?

  • wait for the hafas being integrated into core?
  • raise an issue in the schiene repo?

@FaserF
Copy link
Owner

FaserF commented Jan 11, 2024

Unfortunatly at homeassistant noone has showed support to the hafas homeassistant integration developer, therefore no new work has been done since some months on the pull request.
You can give the custom integration a try here: https://github.com/akloeckner/hacs-hafas

Otherwise you can raise a ticket at schiene repo, but the developer there is not actively working anymore on schiene and I dont think that he will work on it.

@bcutter
Copy link

bcutter commented Jan 11, 2024

Oh great... sounds like only bad options - and therefore none at all.

So...?

Unreliable data produced by this issue is a real problem unfortunately. If I need to pull out my phone and check with official DB app if the train is actually driving at all - it makes the whole integration useless pretty fast unfortunately.

@FaserF
Copy link
Owner

FaserF commented Jan 11, 2024

For now I have no better options for you. The best to try is the custom integration from above.

Please note that me and all the other developers mentioned here are doing it as a hobby within our free time. The current way is more a "hacky" way to grab the data from the bahn.de website, since DB does not offer any API connection. The HAFAS way is a real API (which is not meant for personal use, but does work).

@SupiTrobi
Copy link

Hi, I tried the custom integration you mentioned above. To me it seems that the same "mistake" exists since the GDL is on its "usual" strike today ;-). Also with that integration I receive cancelled = false even on the bahn.de Site the connection is cancelled. Pretty sad that it also doesn't work properly. :-(

@FaserF
Copy link
Owner

FaserF commented May 1, 2024

Unfortunatly I dont think that we can do there anything on our end, since the API from the train sites then is providing it wrongly 👎🏼

@bcutter
Copy link

bcutter commented Aug 5, 2024

Today:

Integration: punctual

DB app/actual reality:
image

Doesn't add anything to this issue - but reminded me once again I simply can't rely on the integration's data. Therefore unfortunately useless most of the time. Very sad to say.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
dependency Issue within schiene python module, not the HA integration
Projects
None yet
Development

No branches or pull requests

4 participants