frontend icon indicating copy to clipboard operation
frontend copied to clipboard

Frontend 20240103.3 & 20240104.0 - Error logged on Thermostat card

Open zzwhg opened this issue 1 year ago • 12 comments

Checklist

  • [X] I have updated to the latest available Home Assistant version.
  • [X] I have cleared the cache of my browser.
  • [X] I have tried a different browser to see if it is related to my browser.
  • [X] I have tried reproducing the issue in safe mode to rule out problems with unsupported custom resources.

Describe the issue you are experiencing

Whenever a Thermostat card is viewed in the iOS Homeassistant app, the card displays correctly but an error is logged in the Homeassistant log:

2024-01-07 07:37:27.097 ERROR (MainThread) [frontend.js.latest.202401040] Uncaught error from WebKit 605.1.15 on iOS 15.6.1 TypeError: Right side of assignment cannot be destructured ref (node_modules/element-internals-polyfill/dist/index.js:360:47) this (node_modules/element-internals-polyfill/dist/index.js:772:41) this (node_modules/element-internals-polyfill/dist/index.js:770:52) this (src/scoped-custom-element-registry.js:248:47) insertBefore ([native code]::) t (src/lit-html.ts:1454:43) i (src/lit-html.ts:1563:23) t (src/lit-html.ts:1384:33) t (src/lit-html.ts:2183:18) i (src/lit-element.ts:165:30)

The exact same error message is logged twice for each instance of the Thermostat card in the displayed Dashboard. When the same Dashboard is displayed on a laptop (via Chrome or Bing), no error is logged.

The Thermostat card is associated with a standard Google/Nest integration and has been working flawlessly for the past 2+ years until the introduction of Frontend 20240103.3.

Describe the behavior you expected

The Thermostat card should not log errors when viewed in the iOS Homeassistant app.

Steps to reproduce the issue

  1. Add Google/Nest Thermostat integration into Homeassistant
  2. Create new, blank Dashboard with UI
  3. Add Thermostat card to blank Dashboard and save
  4. Display Dashboard with Thermostat card using iOS Homeassistant app
  5. Check homeassistant.log in /config for errors. ...

What version of Home Assistant Core has the issue?

core-2024.1.2 with Frontend 20240103.3 or Frontend 20240104.0

What was the last working version of Home Assistant Core?

Any Core release prior to the introduction of Frontend 20240103.3 or later

In which browser are you experiencing the issue with?

iOS 15.6.1 + iOS Companion app 2023.12

Which operating system are you using to run this browser?

iOS 15.6.1

State of relevant entities

Physical Thermostat is online and viewable using laptop Homeassistant + Chrome with no errors logged.

Problem-relevant frontend configuration

Standard Google/Nest Thermostat integration

Javascript errors shown in your browser console/inspector

No response

Additional information

Installation: HA Supervised core - 2024.1.2 supervisor - 2023.12 frontend - 20240104.0

zzwhg avatar Jan 07 '24 13:01 zzwhg

same here,

Source: components/system_log/__init__.py:300
First occurred: 18:20:23 (1 occurrences)
Last logged: 18:20:23

Uncaught error from WebKit 605.1.15 on iOS 16.7.2 Script error. null @:0:0

to be honest noticed since 2023.12 on iPhone, and iPad At first I wasn't sure about the root cause but I have three thermostat card on my default dashboard, so I get this error on each app access..

Core 2024.1.3 Supervisor 2023.12.0 Operating System 11.4 Frontend 20240104.0

ios 16.7.2 Home assistant Companion app 2023.12.1

mbuico avatar Jan 13 '24 17:01 mbuico

Exactly the same problem (or strikingly similar) when Thermostat displayed on an LG TV browser. Works fine on Chrome and Edge browsers under Windows on a PC. Error only started being displayed after updating to HA 2024.1. Error logged every time Thermostat is displayed. Error alters slightly, sometimes.

2024-01-22 21:37:32.981 ERROR (MainThread) [frontend.js.latest.202401040] Uncaught error from Chrome 79.0.3945.79 on Linux TypeError: Cannot destructure property 'labels' of 't' as it is undefined. labels (node_modules/element-internals-polyfill/dist/index.js:361:20) upgradeInternals (node_modules/element-internals-polyfill/dist/index.js:772:24) apply (node_modules/element-internals-polyfill/dist/index.js:770:46) apply (src/scoped-custom-element-registry.js:248:41) insertBefore (src/lit-html.ts:1411:52) k (src/lit-html.ts:1454:35) $ (src/lit-html.ts:1563:11) g (src/lit-html.ts:1384:11) _$AI (src/lit-html.ts:2183:7) i (src/lit-element.ts:165:30)

2024-01-22 21:41:49.650 ERROR (MainThread) [frontend.js.latest.202401040] Uncaught error from Chrome 79.0.3945.79 on Linux TypeError: Cannot destructure property 'labels' of 't' as it is undefined. labels (node_modules/element-internals-polyfill/dist/index.js:361:20) upgradeInternals (node_modules/element-internals-polyfill/dist/index.js:772:24) apply (node_modules/element-internals-polyfill/dist/index.js:770:46) apply (src/scoped-custom-element-registry.js:248:41) document.createElement (src/panels/lovelace/hui-root.ts:980:9) this._navigateToView (src/panels/lovelace/hui-root.ts:681:33)

guardianbs avatar Jan 23 '24 16:01 guardianbs

Issue persist after update to 2024.1.5 and on with access from macos too

2024-01-21 23:27:41.054 ERROR (MainThread) [frontend.js.latest.202401040] Uncaught error from WebKit 605.1.15 on Mac OS 10.15.6
TypeError: Right side of assignment cannot be destructured
ref (node_modules/element-internals-polyfill/dist/index.js:360:47)
this (node_modules/element-internals-polyfill/dist/index.js:772:41)
this (node_modules/element-internals-polyfill/dist/index.js:770:52)
this (src/scoped-custom-element-registry.js:248:47)
insertBefore ([native code]::)
t (src/lit-html.ts:1454:43)
i (src/lit-html.ts:1563:23)
t (src/lit-html.ts:1384:33)
t (src/lit-html.ts:2183:18)
i (src/lit-element.ts:165:30)

I'd add some "frontend" tag to be sure anybody will take care of this issue. Not sure it'll be addressed by this old proposed change https://github.com/home-assistant/frontend/pull/18638

mbuico avatar Jan 23 '24 19:01 mbuico

Additional failure scenario:

UI component: Lovelace display of Climate.Ecobee Client Platform: Mac OS X 10.15.7 / Safari v15.6.1 HA Platform: Core 2024.2.1 - Docker

Loged error: _ TypeError: Right side of assignment cannot be destructured ref

Logger: frontend.js.latest.202402071
Source: components/system_log/__init__.py:306 
First occurred: February 11, 2024, 10:55:15 AM (64 occurrences) 
Last logged: 9:04:19 AM

Uncaught error from Safari 15.6.1 on Mac OS 10.15.7 TypeError: Right side of assignment cannot be destructured ref (node_modules/element-internals-polyfill/dist/index.js:360:47) this (node_modules/element-internals-polyfill/dist/index.js:772:41) this (node_modules/element-internals-polyfill/dist/index.js:770:52) this (src/scoped-custom-element-registry.js:248:47) insertBefore ([native code]::) t (src/lit-html.ts:1454:43) i (src/lit-html.ts:1563:23) t (src/lit-html.ts:1384:33) t (src/lit-html.ts:2183:18) i (src/lit-element.ts:165:30)

Issue APPEARS to have started with 2024.1x or possibly as late as 2024.2. Additional config data available upon request and since I have over a year of logs I can further qualify onset if helpful.

taw123 avatar Feb 13 '24 17:02 taw123

It was indeed caused by the Thermostat card, so I initially removed it from the dashboard to avoid further issues. However, I eventually had to add it back because I require its functionality. I am uncertain whether adding it back will have any negative impact on the system’s performance.

yangrusen avatar Feb 20 '24 03:02 yangrusen

Still a problem on HA 2024.3.1 with LG Webos Browser.

2024-03-17 13:18:49.000 ERROR (MainThread) [frontend.js.latest.202403070] Uncaught error from Chrome 79.0.3945.79 on Linux TypeError: Cannot destructure property 'labels' of 't' as it is undefined. labels (node_modules/element-internals-polyfill/dist/index.js:361:20) upgradeInternals (node_modules/element-internals-polyfill/dist/index.js:772:24) apply (node_modules/element-internals-polyfill/dist/index.js:770:46) apply (src/scoped-custom-element-registry.js:248:41) insertBefore (src/lit-html.ts:1411:52) k (src/lit-html.ts:1454:35) $ (src/lit-html.ts:1563:11) g (src/lit-html.ts:1384:11) _$AI (src/lit-html.ts:2183:7) i (src/lit-element.ts:165:30)

guardianbs avatar Mar 17 '24 13:03 guardianbs

Still a problem on HA 2024.5.4 with LG Webos Browser.

2024-05-19 09:42:51.530 ERROR (MainThread) [frontend.js.latest.202405011] Uncaught error from Chrome 79.0.3945.79 on Linux TypeError: Cannot destructure property 'labels' of 't' as it is undefined. labels (node_modules/element-internals-polyfill/dist/index.js:365:20) upgradeInternals (node_modules/element-internals-polyfill/dist/index.js:776:24) apply (node_modules/element-internals-polyfill/dist/index.js:774:46) apply (src/scoped-custom-element-registry.js:248:41) _createPanel (src/layouts/hass-router-page.ts:318:9) loadProm.then( (src/layouts/hass-router-page.ts:214:13)

guardianbs avatar May 19 '24 16:05 guardianbs

Most likely a bug in the polyfill: https://github.com/calebdwilliams/element-internals-polyfill/issues/127

silamon avatar May 23 '24 18:05 silamon

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Aug 21 '24 19:08 github-actions[bot]