Closed Madelena closed 2 years ago
I think it's the same bug as #17
I'm also getting same error. Is there any fix for this?
Logger: homeassistant.components.sensor Source: custom_components/gtfs_rt/sensor.py:167 Integration: Sensor (documentation, issues) First occurred: 8:52:17 PM (1 occurrences) Last logged: 8:52:17 PM
Error while setting up gtfs_rt platform for sensor Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 250, in _async_setup_platform await asyncio.shield(task) File "/usr/local/lib/python3.10/concurrent/futures/thread.py", line 58, in run result = self.fn(*self.args, *self.kwargs) File "/config/custom_components/gtfs_rt/sensor.py", line 78, in setup_platform sensors.append(PublicTransportSensor( File "/config/custom_components/gtfs_rt/sensor.py", line 97, in init self.update() File "/config/custom_components/gtfs_rt/sensor.py", line 145, in update self.data.update() File "/usr/src/homeassistant/homeassistant/util/init.py", line 192, in wrapper result = method(args, **kwargs) File "/config/custom_components/gtfs_rt/sensor.py", line 167, in update positions, vehicles_trips, occupancy = self._get_vehicle_positions() if self._vehicle_position_url else {} ValueError: not enough values to unpack (expected 3, got 0)
New to Github, so apologies if I'm not crediting someone appropriately, but another user submitted a Commit to a similar issue here that fixes the issue. I had been having the same issue and went into the sensor.py file and made the adjustment (adding three sets of {} where there is currently only one) and that fixed the issue for me.
Thank you. It worked!
Yes, thank you to the community for solving the issue, and apologies for missing the PR when it was submitted. It has been merged. Also @Madelena love your dashboards!
A few days ago the plugin stopped working for NYCT GTFS after updating.
Here's my settings:
And here's the error:
I tried grabbing the GTFS file manually, it works fine: nyct-gtfs.txt So I don't think it's my API key or the feed.