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

KeyError: 'steering_wheel_heater' #199

Closed
alandtse opened this issue Apr 24, 2022 · 1 comment · Fixed by #200
Closed

KeyError: 'steering_wheel_heater' #199

alandtse opened this issue Apr 24, 2022 · 1 comment · Fixed by #200
Labels
bug Something isn't working teslajsonpy Issue with dependency

Comments

@alandtse
Copy link
Owner

alandtse commented Apr 24, 2022

Version of the custom_component

2.1.0

Describe the bug

Vehicles without steering_wheel_heaters result in an error.

Debug log


2022-04-24 13:43:03 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 137, in _handle_refresh_interval
    await self._async_refresh(log_failures=True, scheduled=True)
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 268, in _async_refresh
    update_callback()
  File "/config/custom_components/tesla_custom/tesla_device.py", line 121, in refresh
    self.tesla_device.refresh()
  File "/usr/local/lib/python3.9/site-packages/teslajsonpy/homeassistant/heated_steering_wheel.py", line 62, in refresh
    data["steering_wheel_heater"] if data else None
KeyError: 'steering_wheel_heater'
@alandtse
Copy link
Owner Author

alandtse commented Apr 24, 2022

2.1.0 has been pulled until this is resolved.

@alandtse alandtse added the bug Something isn't working label Apr 24, 2022
alandtse added a commit that referenced this issue Apr 24, 2022
Fixes keyerror for vehicles lacking heated seats/steering wheels

closes #199
alandtse added a commit that referenced this issue Apr 24, 2022
fix: bump teslajsonpy to 2.0.3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working teslajsonpy Issue with dependency
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant