Commit Graph

15 Commits (b1f538b62286f64d196f41284e398da3b913db46)

Author SHA1 Message Date
Fabian Affolter 13df925795 Do not call update() in constructor (#7912)
* Do not call update() in constructor

* Do not call update() in constructor

* Remove unused import
2017-06-05 17:35:26 +02:00
Fabian Affolter a4f1f6e724 Update docstrings (#7374)
* Update docstrings

* Update docstrings

* Update docstrings

* Update docstrings

* Update docstrings

* Update docstrings

* Update docstring

* Update docstrings

* Update docstrings

* Fix lint issues

* Update docstrings

* Revert changes in dict
2017-05-02 09:18:47 -07:00
Fabian Affolter 87764a51ba Use device_state_attributes() for platforms (#5649)
* Use device_state_attributes() for platforms

* Update test

* Fix lint issue
2017-01-30 16:16:49 +01:00
Fabian Affolter 75bcb1ff0f Upgrade schiene to 0.18 (#4359) 2016-11-12 12:30:05 -08:00
Fabian Affolter be272ac64a Disable too-many-* (#4107)
* Disable too-many-* and too-few-public-methods

* Remove globally disabled pylint warnings
2016-10-30 22:18:53 +01:00
Fabian Affolter e8c6e4d561 Clean-up, ordering, constants, and extend of schema (#2903)
* Clean-up, ordering, constants, and extend of schema

* Put REQUIREMENTS back and re-add line breaks

* Clean-up, ordering, constants, and extend of schema

* Extend platform
2016-08-20 15:40:16 -07:00
Fabian Affolter 0abc50e844 Use voluptuous for transport sensors (#2867) 2016-08-19 00:12:56 -07:00
Fabian Affolter 21d3be4027 Fix update (#2402) 2016-07-02 09:09:22 +02:00
Fabian Affolter 8dd7ebb08e Add the two next trains (#2390) 2016-06-29 17:44:35 -07:00
Fabian Affolter 9a7ea72fa0 Upgrade schiene to 0.17 (#2231) 2016-06-05 15:59:54 -07:00
Fabian Affolter 7331f4910e Upgrade schiene to 0.15 (#1929) 2016-04-28 08:23:23 +02:00
deisi 3b0a35f571 Ontime and delay attribute are allways present in deutsche_bahn sensor (#1875) 2016-04-24 06:43:25 +02:00
Fabian Affolter 8bff97083c Fix PEPE257 issues 2016-03-08 16:46:34 +01:00
Fabian Affolter 9da8679dbd Add link to docs 2016-02-28 15:35:20 +01:00
Malte Deiseroth b096004449 New deutsche_bahn component
Uses the (schiene)[https://pypi.python.org/pypi/schiene/0.14] API to communicate with the webserver of bahn.de
and pulls iformation about a specific connection from the (bahn.de)[http://www.bahn.de/p/view/index.shtml]
webpage. The departure time of the next train for the given connection is shown.
In case of delay, the delay is also shown. Additional `ATTRIBUTES` are used to
inform about e.g. the type of the train, price and if it is ontime.

Usage:

    sensor:
      platform: deutsche_bahn
        from: name_of_start_station
	  to: name_of_final_station

Problems:
I'm testing it for quite some time, but I have never seen the `ATTRIBUTES` in case
of a delayed train. The `ATTRIBUTES` are directly passed from the `schiene` API. So this
usecase has not been tested yet.

deutsche_bahn ist not supporting the `schiene` api unlike in the swiss_public_transport case.
It's not guaranteed that `schiene` will work forever, infact it can happen that Bahn AG will
intentionally brake the API at some point. In the past Bahn AG has not allways been very supportive
to the opensource community.
2016-02-24 17:35:00 +01:00