skodaconnect / homeassistant-myskoda

Homeassistant integration for MySkoda.
73 stars 10 forks source link

Installation problems with Skoda Enyaq Coupe RS starting with v1.2.5 #18

Closed jrjuniortkf closed 1 month ago

jrjuniortkf commented 1 month ago

When I try to install v1.2.7 I receive the following error.

I tried it with lower versions as well, the error comes with v1.2.5. Let me please know if I can provide additional information.

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 354, in _async_refresh
    self.data = await self._async_update_data()
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/myskoda/__init__.py", line 81, in _async_update_data
    "vehicles": await self.hub.get_all_vehicles(),
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/myskoda/rest_api.py", line 193, in get_all_vehicles
    return await gather(*[self.get_vehicle(vehicle) for vehicle in await self.list_vehicles()])
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

File "/usr/local/lib/python3.12/site-packages/myskoda/rest_api.py", line 172, in get_vehicle
    [info, charging, status, air_conditioning, position, health] = await gather(
                                                                   ^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/myskoda/rest_api.py", line 78, in get_info
    return Info(**await response.json())
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "pydantic/main.py", line 341, in pydantic.main.BaseModel.__init__

pydantic.error_wrappers.ValidationError: 1 validation error for Info
specification -> body
  value is not a valid enumeration member; permitted: 'SUV', 'Combi' (type=type_error.enum; enum_values=[<BodyType.SUV: 'SUV'>, <BodyType.COMBI: 'Combi'>])
dvx76 commented 1 month ago

We've added some debug to get the actual API response values which are currently not define in our models. After the next version is released please retry with debug enabled and before the same error you should see a line like

vin {vin}: received basic info: {response_text}

That's the line we need. Consider redacting any personal info like your VIN.

jrjuniortkf commented 1 month ago

@dvx76 here's the log - I hope you are able to find the required information

I downloaded v1.3.0 and the problem is still there.

Traceback (most recent call last): File "/config/custom_components/myskoda/coordinator.py", line 75, in _on_mqtt_event await self._on_access_event(event) File "/config/custom_components/myskoda/coordinator.py", line 107, in _on_access_event await self.update_vehicle(event.vin) File "/config/custom_components/myskoda/coordinator.py", line 138, in update_vehicle vehicle = await self.myskoda.get_vehicle(vin) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/myskoda/myskoda.py", line 180, in get_vehicle info = await self.get_info(vin) ^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/myskoda/myskoda.py", line 136, in get_info return await self.rest_api.get_info(vin) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/myskoda/rest_api.py", line 51, in get_info return Info.parse_raw(response_text) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "pydantic/main.py", line 549, in pydantic.main.BaseModel.parse_raw File "pydantic/main.py", line 526, in pydantic.main.BaseModel.parse_obj File "pydantic/main.py", line 341, in pydantic.main.BaseModel.__init__ pydantic.error_wrappers.ValidationError: 1 validation error for Info specification -> body value is not a valid enumeration member; permitted: 'SUV', 'Combi' (type=type_error.enum; enum_values=[<BodyType.SUV: 'SUV'>, <BodyType.COMBI: 'Combi'>]) 2024-09-22 12:34:35.456 DEBUG (MainThread) [myskoda.rest_api] vin XXXXXXXXXXXXXXXX: received basic info: {"vin":"XXXXXXXXXXXXXXXX","name":"Enyaq Coupé","workshopModeEnabled":false,"licensePlate":"XXXXXXXX","state":"ACTIVATED","devicePlatform":"WCAR","softwareVersion":"3.7","specification":{"title":"Škoda Enyaq Coupé","manufacturingDate":"2023-10-19","model":"Enyaq Coupé","modelYear":"2023","body":"SUV Coupe","trimLevel":"RS","systemCode":"UNKNOWN","systemModelId":"5ACJP4","maxChargingPowerInKW":125,"battery":{"capacityInKWh":77},"engine":{"type":"iV","powerInKW":225},"gearbox":{"type":"E1A"}},"servicePartner":{"servicePartnerId":"DEUC58424"},"renders":[{"url":"https://iprenders.blob.core.windows.net/base5acv23200003/8E8E4uAqJgGsy1n0E-N6kIJUuZmxoVe98wFcR-.Lh3oj9KnVcOSXe7g5twAIu0q-qjDNyVhSdoPvugHXRrZGm-19201080dayvext_side1080.png","viewPoint":"exterior_side","type":"REAL","order":0},{"url":"https://ip-modcwp.azureedge.net/modcwp5acv23200003/8E8E4uAqJgGsy1n0E-N6kIJUuZmxoVe98wFcR-.Lh3oj9KnVcOSXe7g5twAIu0q-qjDNyVhSdoPvugHXRrZGm-1920658dayvext_side1080.png?v=638518971670000000","viewPoint":"garage_l","type":"REAL","order":1},{"url":"https://ip-modcwp.azureedge.net/modcwp5acv23200003/8E8E4uAqJgGsy1n0E-N6kIJUuZmxoVe98wFcR-.Lh3oj9KnVcOSXe7g5twAIu0q-qjDNyVhSdoPvugHXRrZGm-700390dayvext_front1080.png?v=638518971670000000","viewPoint":"main","type":"REAL","order":2}],"compositeRenders":[{"layers":[{"url":"https://iprenders.blob.core.windows.net/base5acv23200003/8E8E4uAqJgGsy1n0E-N6kIJUuZmxoVe98wFcR-.Lh3oj9KnVcOSXe7g5twAIu0q-qjDNyVhSdoPvugHXRrZGm-19201080dayvext_side1080.png","viewPoint":"exterior_side","type":"REAL","order":0}],"viewType":"UNMODIFIED_EXTERIOR_SIDE"},{"layers":[{"url":"https://iprenders.blob.core.windows.net/base5acv23200003/8E8E4uAqJgGsy1n0E-N6kIJUuZmxoVe98wFcR-.Lh3oj9KnVcOSXe7g5twAIu0q-qjDNyVhSdoPvugHXRrZGm-19201080dayvext_side1080.png","viewPoint":"exterior_side","type":"REAL","order":0}],"modifications":{"adjustSpaceInPx":{"top":-317,"bottom":-193,"left":-149,"right":-111},"densityIndependentHeight":270,"flipHorizontal":false,"anchorTo":"LEFT"},"viewType":"HOME"},{"layers":[{"url":"https://iprenders.blob.core.windows.net/base5acv23200003/8E8E4uAqJgGsy1n0E-N6kIJUuZmxoVe98wFcR-.Lh3oj9KnVcOSXe7g5twAIu0q-qjDNyVhSdoPvugHXRrZGm-19201080dayvext_side1080.png","viewPoint":"exterior_side","type":"REAL","order":0},{"url":"https://mspgwlivestorage.blob.core.windows.net/renders/cables/enyaq_5A_cable_charging_light_v1.png","viewPoint":"exterior_side","type":"REAL","order":1}],"modifications":{"adjustSpaceInPx":{"top":-317,"bottom":-193,"left":-149,"right":-111},"densityIndependentHeight":270,"flipHorizontal":true,"anchorTo":"LEFT"},"viewType":"CHARGING_LIGHT"},{"layers":[{"url":"https://iprenders.blob.core.windows.net/base5acv23200003/8E8E4uAqJgGsy1n0E-N6kIJUuZmxoVe98wFcR-.Lh3oj9KnVcOSXe7g5twAIu0q-qjDNyVhSdoPvugHXRrZGm-19201080dayvext_side1080.png","viewPoint":"exterior_side","type":"REAL","order":0},{"url":"https://mspgwlivestorage.blob.core.windows.net/renders/cables/enyaq_5A_cable_charging_dark_v1.png","viewPoint":"exterior_side","type":"REAL","order":1}],"modifications":{"adjustSpaceInPx":{"top":-317,"bottom":-193,"left":-149,"right":-111},"densityIndependentHeight":270,"flipHorizontal":true,"anchorTo":"LEFT"},"viewType":"CHARGING_DARK"},{"layers":[{"url":"https://iprenders.blob.core.windows.net/base5acv23200003/8E8E4uAqJgGsy1n0E-N6kIJUuZmxoVe98wFcR-.Lh3oj9KnVcOSXe7g5twAIu0q-qjDNyVhSdoPvugHXRrZGm-19201080dayvext_side1080.png","viewPoint":"exterior_side","type":"REAL","order":0},{"url":"https://mspgwlivestorage.blob.core.windows.net/renders/cables/enyaq_5A_cable_plugged_in_light_v1.png","viewPoint":"exterior_side","type":"REAL","order":1}],"modifications":{"adjustSpaceInPx":{"top":-317,"bottom":-193,"left":-149,"right":-111},"densityIndependentHeight":270,"flipHorizontal":true,"anchorTo":"LEFT"},"viewType":"PLUGGED_IN_LIGHT"},{"layers":[{"url":"https://iprenders.blob.core.windows.net/base5acv23200003/8E8E4uAqJgGsy1n0E-N6kIJUuZmxoVe98wFcR-.Lh3oj9KnVcOSXe7g5twAIu0q-qjDNyVhSdoPvugHXRrZGm-19201080dayvext_side1080.png","viewPoint":"exterior_side","type":"REAL","order":0},{"url":"https://mspgwlivestorage.blob.core.windows.net/renders/cables/enyaq_5A_cable_plugged_in_dark_v1.png","viewPoint":"exterior_side","type":"REAL","order":1}],"modifications":{"adjustSpaceInPx":{"top":-317,"bottom":-193,"left":-149,"right":-111},"densityIndependentHeight":270,"flipHorizontal":true,"anchorTo":"LEFT"},"viewType":"PLUGGED_IN_DARK"}],"capabilities":{"capabilities":[{"id":"AUTOMATION","statuses":[]},{"id":"BATTERY_CHARGING_CARE","statuses":[]},{"id":"BATTERY_SUPPORT","statuses":[]},{"id":"CHARGING_PROFILES","statuses":[]},{"id":"CHARGING_STATIONS","statuses":[]},{"id":"DEALER_APPOINTMENT","statuses":[]},{"id":"DIGICERT","statuses":[]},{"id":"MAP_UPDATE","statuses":[]},{"id":"MEASUREMENTS","statuses":[]},{"id":"PARKING_INFORMATION","statuses":[]},{"id":"PARKING_POSITION","statuses":[]},{"id":"PLUG_AND_CHARGE","statuses":["DEACTIVATED_BY_ACTIVE_VEHICLE_USER"]},{"id":"POI_SEARCH","statuses":[]},{"id":"ROADSIDE_ASSISTANT","statuses":[]},{"id":"ROUTING","statuses":[]},{"id":"STATE","statuses":[]},{"id":"TRAFFIC_INFORMATION","statuses":[]},{"id":"VEHICLE_HEALTH_INSPECTION","statuses":[]},{"id":"WARNING_LIGHTS","statuses":[]},{"id":"AIR_CONDITIONING_TIMERS","statuses":[]},{"id":"AIR_CONDITIONING_SMART_SETTINGS","statuses":[]},{"id":"POWERPASS_TARIFFS","statuses":[]},{"id":"AIR_CONDITIONING_SAVE_AND_ACTIVATE","statuses":[]},{"id":"CUBIC","statuses":[]},{"id":"ROUTE_PLANNING_5_CHARGERS","statuses":[]},{"id":"SUBSCRIPTIONS","statuses":[]},{"id":"DESTINATIONS","statuses":[]},{"id":"CHARGING_MEB","statuses":[]},{"id":"VEHICLE_SERVICES_BACKUPS","statuses":[]},{"id":"EV_ROUTE_PLANNING","statuses":[]},{"id":"CHARGE_MODE_SELECTION","statuses":[]},{"id":"DIGICERT","statuses":[]},{"id":"VEHICLE_HEALTH_WARNINGS","statuses":[]},{"id":"PAY_TO_PARK","statuses":[]},{"id":"ONLINE_SPEECH_GPS","statuses":[]},{"id":"GUEST_USER_MANAGEMENT","statuses":[]},{"id":"SERVICE_PARTNER","statuses":[]},{"id":"WINDOW_HEATING","statuses":[]},{"id":"ROUTE_IMPORT","statuses":[]},{"id":"CHARGING","statuses":[]},{"id":"AIR_CONDITIONING","statuses":[]},{"id":"EXTENDED_CHARGING_SETTINGS","statuses":[]},{"id":"VEHICLE_WAKE_UP_TRIGGER","statuses":[]}]}} 2024-09-22 12:34:35.457 ERROR (MainThread) [custom_components.myskoda.coordinator] Unexpected error fetching myskoda data

dvx76 commented 1 month ago

Yep, got what I need, "body":"SUV Coupe". Thanks.