You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In alandtse/tesla#860 we noticed that a recent change made it impossible to close the trunk via the API.
Follow-up discussion on the pull request alandtse/tesla#868 shows that the problem is likely in teslajsonpy.
Cause
While debugging, we find that the check for .get("vehicle_config",{}).get("plg") in TeslaCar.powered_lift_gate never returns True. It's because self._car never contains a key for vehicle_config.
I think the problem is that the TeslaCar._car only contains the data from the PRODUCT_LIST query. The data stored in my TeslaCar object has the following keys: dict_keys(['id', 'user_id', 'vehicle_id', 'vin', 'color', 'access_type', 'display_name', 'option_codes', 'cached_data', 'granular_access', 'tokens', 'state', 'in_service', 'id_s', 'calendar_enabled', 'api_version', 'backseat_token', 'backseat_token_updated_at', 'ble_autopair_enrolled', 'command_signing'])
Fix
I think the fix for powered_lift_gate is to look for the vehicle_config in the self._vehicle_data dict.
The text was updated successfully, but these errors were encountered:
Background
In alandtse/tesla#860 we noticed that a recent change made it impossible to close the trunk via the API.
Follow-up discussion on the pull request alandtse/tesla#868 shows that the problem is likely in teslajsonpy.
Cause
While debugging, we find that the check for
.get("vehicle_config",{}).get("plg")
inTeslaCar.powered_lift_gate
never returns True. It's becauseself._car
never contains a key forvehicle_config
.I think the problem is that the
TeslaCar._car
only contains the data from thePRODUCT_LIST
query. The data stored in my TeslaCar object has the following keys:dict_keys(['id', 'user_id', 'vehicle_id', 'vin', 'color', 'access_type', 'display_name', 'option_codes', 'cached_data', 'granular_access', 'tokens', 'state', 'in_service', 'id_s', 'calendar_enabled', 'api_version', 'backseat_token', 'backseat_token_updated_at', 'ble_autopair_enrolled', 'command_signing'])
Fix
I think the fix for
powered_lift_gate
is to look for thevehicle_config
in theself._vehicle_data
dict.The text was updated successfully, but these errors were encountered: