home-assistant / core

:house_with_garden: Open source home automation that puts local control and privacy first.
https://www.home-assistant.io
Apache License 2.0
72.65k stars 30.41k forks source link

javascript errors on stdout with version 0.62.1 #12122

Closed azrdev closed 6 years ago

azrdev commented 6 years ago
$ hass --version
0.62.1
$ python3 --version
Python 3.6.4

Installed with pip3 install --upgrade homeassistant in a separate, otherwise unused unix-user. OS: Fedora 26

Description of problem

After upgrading to 0.62.1 the webinterface shows a warning Service system_log/write called. upon load and frequently thereafter. On stdout, the following error ist dumped:

INFO:homeassistant.components.http:Serving /states to 192.168.x.y (auth: True)
INFO:homeassistant.components.http:Serving /states to 192.168.x.y (auth: True)
INFO:homeassistant.components.http:Serving /api/websocket to 192.168.x.y (auth: True)
INFO:homeassistant.loader:Loaded persistent_notification from homeassistant.components.persistent_notification
INFO:homeassistant.components.http:Serving /api/themes to 192.168.x.y (auth: True)
INFO:homeassistant.core:Bus:Handling <Event call_service[L]: domain=system_log, service=write, service_data=logger=frontend.js.latest.201801300, message=data:text/javascript;charset=utf-8,!function()%7B%22use%20strict%22%3Bconst%20e%3DElement.prototype%2Ct%3De.matches%7C%7Ce.matchesSelector%7C%7Ce.mozMatchesSelector%7C%7Ce.msMatchesSelector%7C%7Ce.oMatchesSelector%7C%7Ce.webkitMatchesSelector%2Co%3Dfunction(e%2Co)%7Breturn%20t.call(e%2Co)%7D%3Bclass%20r%7Bconstructor(e)%7Bthis.node%3De%7DobserveNodes(e)%7Breturn%20new%20Polymer.FlattenedNodesObserver(this.node%2Ce)%7DunobserveNodes(e)%7Be.disconnect()%7DnotifyObserver()%7B%7DdeepContains(e)%7Bif(this.node.contains(e))return!0%3Blet%20t%3De%2Co%3De.ownerDocument%3Bfor(%3Bt%26%26t!%3D%3Do%26%26t!%3D%3Dthis.node%3B)t%3Dt.parentNode%7C%7Ct.host%3Breturn%20t%3D%3D%3Dthis.node%7DgetOwnerRoot()%7Breturn%20this.node.getRootNode()%7DgetDistributedNodes()%7Breturn%22slot%22%3D%3D%3Dthis.node.localName%3Fthis.node.assignedNodes(%7Bflatten%3A!0%7D)%3A%5B%5D%7DgetDestinationInsertionPoints()%7Blet%20e%3D%5B%5D%2Ct%3Dthis.node.assignedSlot%3Bfor(%3Bt%3B)e.push(t)%2Ct%3Dt.assignedSlot%3Breturn%20e%7DimportNode(e%2Ct)%7Breturn(this.node%20instanceof%20Document%3Fthis.node%3Athis.node.ownerDocument).importNode(e%2Ct)%7DgetEffectiveChildNodes()%7Breturn%20Polymer.FlattenedNodesObserver.getFlattenedNodes(this.node)%7DqueryDistributedElements(e)%7Blet%20t%3Dthis.getEffectiveChildNodes()%2Cr%3D%5B%5D%3Bfor(let%20n%2Ci%3D0%2Cl%3Dt.length%3Bi%3Cl%26%26(n%3Dt%5Bi%5D)%3Bi%2B%2B)n.nodeType%3D%3D%3DNode.ELEMENT_NODE%26%26o(n%2Ce)%26%26r.push(n)%3Breturn%20r%7Dget%20activeElement()%7Blet%20e%3Dthis.node%3Breturn%20void%200!%3D%3De._activeElement%3Fe._activeElement%3Ae.activeElement%7D%7D!function(e%2Ct)%7Bfor(let%20o%3D0%3Bo%3Ct.length%3Bo%2B%2B)%7Blet%20r%3Dt%5Bo%5D%3Be%5Br%5D%3Dfunction()%7Breturn%20this.node%5Br%5D.apply(this.node%2Carguments)%7D%7D%7D(r.prototype%2C%5B%22cloneNode%22%2C%22appendChild%22%2C%22insertBefore%22%2C%22removeChild%22%2C%22replaceChild%22%2C%22setAttribute%22%2C%22removeAttribute%22%2C%22querySelector%22%2C%22querySelectorAll%22%5D)%2Cfunction(e%2Ct)%7Bfor(let%20o%3D0%3Bo%3Ct.length%3Bo%2B%2B)%7Blet%20r%3Dt%5Bo%5D%3BObject.defineProperty(e%2Cr%2C%7Bget%3Afunction()%7Breturn%20this.node%5Br%5D%7D%2Cconfigurable%3A!0%7D)%7D%7D(r.prototype%2C%5B%22parentNode%22%2C%22firstChild%22%2C%22lastChild%22%2C%22nextSibling%22%2C%22previousSibling%22%2C%22firstElementChild%22%2C%22lastElementChild%22%2C%22nextElementSibling%22%2C%22previousElementSibling%22%2C%22childNodes%22%2C%22children%22%2C%22classList%22%5D)%2Cfunction(e%2Ct)%7Bfor(let%20o%3D0%3Bo%3Ct.length%3Bo%2B%2B)%7Blet%20r%3Dt%5Bo%5D%3BObject.defineProperty(e%2Cr%2C%7Bget%3Afunction()%7Breturn%20this.node%5Br%5D%7D%2Cset%3Afunction(e)%7Bthis.node%5Br%5D%3De%7D%2Cconfigurable%3A!0%7D)%7D%7D(r.prototype%2C%5B%22textContent%22%2C%22innerHTML%22%5D)%3Bclass%20n%7Bconstructor(e)%7Bthis.event%3De%7Dget%20rootTarget()%7Breturn%20this.event.composedPath()%5B0%5D%7Dget%20localTarget()%7Breturn%20this.event.target%7Dget%20path()%7
Breturn%20this.event.composedPath()%7D%7DPolymer.DomApi%3Dr%2CPolymer.DomApi.prototype.cloneNode%2CPolymer.DomApi.prototype.appendChild%2CPolymer.DomApi.prototype.insertBefore%2CPol
ymer.DomApi.prototype.removeChild%2CPolymer.DomApi.prototype.replaceChild%2CPolymer.DomApi.prototype.setAttribute%2CPolymer.DomApi.prototype.removeAttribute%2CPolymer.DomApi.prototype.querySelector%2CPolymer.DomApi.prototype.querySelectorAll%2CPolymer.dom%3Dfunction(e)%7Bif(!(e%3De%7C%7Cdocument).__domApi)%7Blet%20t%3Bt%3De%20instanceof%20Event%3Fnew%20n(e)%3Anew%20r(e)%2Ce.__domApi%3Dt%7Dreturn%20e.__domApi%7D%2CPolymer.dom.matchesSelector%3Do%2CPolymer.dom.flush%3DPolymer.flush%2CPolymer.dom.addDebouncer%3DPolymer.enqueueDebouncer%7D()%3B%0A%2F%2F%23%20sourceURL%3Dhttp%3A%2F%2Ftolimon%3A8123%2Ffrontend_latest%2Ffrontend-2216be04a5c7ff162a7ea60688a711e8.html-29.js%0A:0:0 Script error., service_call_id=139972132634520-1>                    

[... much more gibberish ...]
ERROR:frontend.js.latest.201801300:data:text/javascript;charset=utf-8,!function()%7B%22use%20strict%22%3Bconst%20e%3DElement.prototype%2Ct%3De.matches%7C%7Ce.matchesSelector%7C%7Ce.mozMatchesSelector%7C%7Ce.msMatchesSelector%7C%7Ce.oMatchesSelector%7C%7Ce.webkitMatchesSelector%2Co%3Dfunction(e%2Co)%7Breturn%20t.call(e%2Co)%7D%3Bclass%20r%7Bconstructor(e)%7Bthis.node%3De%7DobserveNodes(e)%7Breturn%20new%20Polymer.FlattenedNodesObserver(this.node%2Ce)%7DunobserveNodes(e)%7Be.disconnect()%7DnotifyObserver()%7B%7DdeepContains(e)%7Bif(this.node.contains(e))return!0%3Blet%20t%3De%2Co%3De.ownerDocument%3Bfor(%3Bt%26%26t!%3D%3Do%26%26t!%3D%3Dthis.node%3B)t%3Dt.parentNode%7C%7Ct.host%3Breturn%20t%3D%3D%3Dthis.node%7DgetOwnerRoot()%7Breturn%20this.node.getRootNode()%7DgetDistributedNodes()%7Breturn%22slot%22%3D%3D%3Dthis.node.localName%3Fthis.node.assignedNodes(%7Bflatten%3A!0%7D)%3A%5B%5D%7DgetDestinationInsertionPoints()%7Blet%20e%3D%5B%5D%2Ct%3Dthis.node.assignedSlot%3Bfor(%3Bt%3B)e.push(t)%2Ct%3Dt.assignedSlot%3Breturn%20e%7DimportNode(e%2Ct)%7Breturn(this.node%20instanceof%20Document%3Fthis.node%3Athis.node.ownerDocument).importNode(e%2Ct)%7DgetEffectiveChildNodes()%7Breturn%20Polymer.FlattenedNodesObserver.getFlattenedNodes(this.node)%7DqueryDistributedElements(e)%7Blet%20t%3Dthis.getEffectiveChildNodes()%2Cr%3D%5B%5D%3Bfor(let%20n%2Ci%3D0%2Cl%3Dt.length%3Bi%3Cl%26%26(n%3Dt%5Bi%5D)%3Bi%2B%2B)n.nodeType%3D%3D%3DNode.ELEMENT_NODE%26%26o(n%2Ce)%26%26r.push(n)%3Breturn%20r%7Dget%20activeElement()%7Blet%20e%3Dthis.node%3Breturn%20void%200!%3D%3De._activeElement%3Fe._activeElement%3Ae.activeElement%7D%7D!function(e%2Ct)%7Bfor(let%20o%3D0%3Bo%3Ct.length%3Bo%2B%2B)%7Blet%20r%3Dt%5Bo%5D%3Be%5Br%5D%3Dfunction()%7Breturn%20this.node%5Br%5D.apply(this.node%2Carguments)%7D%7D%7D(r.prototype%2C%5B%22cloneNode%22%2C%22appendChild%22%2C%22insertBefore%22%2C%22removeChild%22%2C%22replaceChild%22%2C%22setAttribute%22%2C%22removeAttribute%22%2C%22querySelector%22%2C%22querySelectorAll%22%5D)%2Cfunction(e%2Ct)%7Bfor(let%20o%3D0%3Bo%3Ct.length%3Bo%2B%2B)%7Blet%20r%3Dt%5Bo%5D%3BObject.defineProperty(e%2Cr%2C%7Bget%3Afunction()%7Breturn%20this.node%5Br%5D%7D%2Cconfigurable%3A!0%7D)%7D%7D(r.prototype%2C%5B%22parentNode%22%2C%22firstChild%22%2C%22lastChild%22%2C%22nextSibling%22%2C%22previousSibling%22%2C%22firstElementChild%22%2C%22lastElementChild%22%2C%22nextElementSibling%22%2C%22previousElementSibling%22%2C%22childNodes%22%2C%22children%22%2C%22classList%22%5D)%2Cfunction(e%2Ct)%7Bfor(let%20o%3D0%3Bo%3Ct.length%3Bo%2B%2B)%7Blet%20r%3Dt%5Bo%5D%3BObject.defineProperty(e%2Cr%2C%7Bget%3Afunction()%7Breturn%20this.node%5Br%5D%7D%2Cset%3Afunction(e)%7Bthis.node%5Br%5D%3De%7D%2Cconfigurable%3A!0%7D)%7D%7D(r.prototype%2C%5B%22textContent%22%2C%22innerHTML%22%5D)%3Bclass%20n%7Bconstructor(e)%7Bthis.event%3De%7Dget%20rootTarget()%7Breturn%20this.event.composedPath()%5B0%5D%7Dget%20localTarget()%7Breturn%20this.event.target%7Dget%20path()%7Breturn%20this.event.composedPath()%7D%7DPolymer.DomApi%3Dr%2CPolymer.DomApi.prototype.cloneNode%2CPolymer.DomApi.prototype.appendChild%2CPolymer.DomApi.prototype.insertBefore%2CPolymer.DomApi.prototype.removeChild%2CPolymer.DomApi.prototype.replaceChild%2CPolymer.DomApi.prototype.setAttribute%2CPolymer.DomApi.prototype.removeAttribute%2CPolymer.DomApi.prototype.querySelector%2CPolymer.DomApi.prototype.querySelectorAll%2CPolymer.dom%3Dfunction(e)%7Bif(!(e%3De%7C%7Cdocument).__domApi)%7Blet%20t%3Bt%3De%20instanceof%20Event%3Fnew%20n(e)%3Anew%20r(e)%2Ce.__domApi%3Dt%7Dreturn%20e.__domApi%7D%2CPolymer.dom.matchesSelector%3Do%2CPolymer.dom.flush%3DPolymer.flush%2CPolymer.dom.addDebouncer%3DPolymer.enqueueDebouncer%7D()%3B%0A%2F%2F%23%20sourceURL%3Dhttp%3A%2F%2Ftolimon%3A8123%2Ffrontend_latest%2Ffrontend-2216be04a5c7ff162a7ea60688a711e8.html-29.js%0A:0:0 Script error.                                                                                                                                                                                                                                                                                           

Browser console contains:


20:39:01.585
TypeError: this.event.composedPath is not a function
[Weitere Informationen]
data:!function()%7B%22use%20strict%22%3Bconst%20e%3DElement.prototype%2Ct%3De.matches%7C%7Ce.matches:1:2122
20:39:01.913 Passwort-Felder sind auf einer unsicheren (http://) Seite vorhanden. Dies ist ein Sicherheitsrisiko, durch das Zugangsdaten gestohlen werden können.
[Weitere Informationen]
states
20:39:06.935 paper-drawer-panel is deprecated. Please use app-layout instead!
frontend-2216be04a5c7ff162a7ea60688a711e8.html-93.js:1:1535
20:39:07.107
TypeError: this.event.composedPath is not a function
[Weitere Informationen]
data:!function()%7B%22use%20strict%22%3Bconst%20e%3DElement.prototype%2Ct%3De.matches%7C%7Ce.matches:1:2122
20:39:07.143
TypeError: this.event.composedPath is not a function
[Weitere Informationen]
data:!function()%7B%22use%20strict%22%3Bconst%20e%3DElement.prototype%2Ct%3De.matches%7C%7Ce.matches:1:2212
20:39:07.145
TypeError: this.event.composedPath is not a function
[Weitere Informationen]
data:!function()%7B%22use%20strict%22%3Bconst%20e%3DElement.prototype%2Ct%3De.matches%7C%7Ce.matches:1:2122
20:39:07.149
TypeError: this.event.composedPath is not a function
[Weitere Informationen]
data:!function()%7B%22use%20strict%22%3Bconst%20e%3DElement.prototype%2Ct%3De.matches%7C%7Ce.matches:1:2212
20:39:07.156
TypeError: this.event.composedPath is not a function
[Weitere Informationen]
data:!function()%7B%22use%20strict%22%3Bconst%20e%3DElement.prototype%2Ct%3De.matches%7C%7Ce.matches:1:2122
20:39:07.274
TypeError: this.event.composedPath is not a function
[Weitere Informationen]
data:!function()%7B%22use%20strict%22%3Bconst%20e%3DElement.prototype%2Ct%3De.matches%7C%7Ce.matches:1:2212
20:39:10.694
TypeError: this.event.composedPath is not a function
[Weitere Informationen]
data:!function()%7B%22use%20strict%22%3Bconst%20e%3DElement.prototype%2Ct%3De.matches%7C%7Ce.matches:1:2212
  1. install homeassistant=0.62.1
  2. (re)move your existing config, so ~/.homeassistant/ does not exist
  3. start hass
  4. open webinterface
fakezeta commented 6 years ago

Hi, I have the same behaviour with 0.63.3 and firefox 58.0.2. I' using the homeassistant/home-assistant:0.63.3 docker image.

I'd like to add that the same error is logged in the config: section using the dropdown menu data:text/javascript;charset=utf-8,!function()%7B%22use%20strict%22%3Bconst%20e%3DElement.prototype%2Ct%3De.matches%7C%7Ce.matchesSelector%7C%7Ce.mozMatchesSelector%7C%7Ce.msMatchesSelector%7C%7Ce.oMatchesSelector%7C%7Ce.webkitMatchesSelector%2Co%3Dfunction(e%2Co)%7Breturn%20t.call(e%2Co)%7D%3Bclass%20r%7Bconstructor(e)%7Bthis.node%3De%7DobserveNodes(e)%7Breturn%20new%20Polymer.FlattenedNodesObserver(this.node%2Ce)%7DunobserveNodes(e)%7Be.disconnect()%7DnotifyObserver()%7B%7DdeepContains(e)%7Bif(this.node.contains(e))return!0%3Blet%20t%3De%2Co%3De.ownerDocument%3Bfor(%3Bt%26%26t!%3D%3Do%26%26t!%3D%3Dthis.node%3B)t%3Dt.parentNode%7C%7Ct.host%3Breturn%20t%3D%3D%3Dthis.node%7DgetOwnerRoot()%7Breturn%20this.node.getRootNode()%7DgetDistributedNodes()%7Breturn%22slot%22%3D%3D%3Dthis.node.localName%3Fthis.node.assignedNodes(%7Bflatten%3A!0%7D)%3A%5B%5D%7DgetDestinationInsertionPoints()%7Blet%20e%3D%5B%5D%2Ct%3Dthis.node.assignedSlot%3Bfor(%3Bt%3B)e.push(t)%2Ct%3Dt.assignedSlot%3Breturn%20e%7DimportNode(e%2Ct)%7Breturn(this.node%20instanceof%20Document%3Fthis.node%3Athis.node.ownerDocument).importNode(e%2Ct)%7DgetEffectiveChildNodes()%7Breturn%20Polymer.FlattenedNodesObserver.getFlattenedNodes(this.node)%7DqueryDistributedElements(e)%7Blet%20t%3Dthis.getEffectiveChildNodes()%2Cr%3D%5B%5D%3Bfor(let%20n%2Ci%3D0%2Cl%3Dt.length%3Bi%3Cl%26%26(n%3Dt%5Bi%5D)%3Bi%2B%2B)n.nodeType%3D%3D%3DNode.ELEMENT_NODE%26%26o(n%2Ce)%26%26r.push(n)%3Breturn%20r%7Dget%20activeElement()%7Blet%20e%3Dthis.node%3Breturn%20void%200!%3D%3De._activeElement%3Fe._activeElement%3Ae.activeElement%7D%7D!function(e%2Ct)%7Bfor(let%20o%3D0%3Bo%3Ct.length%3Bo%2B%2B)%7Blet%20r%3Dt%5Bo%5D%3Be%5Br%5D%3Dfunction()%7Breturn%20this.node%5Br%5D.apply(this.node%2Carguments)%7D%7D%7D(r.prototype%2C%5B%22cloneNode%22%2C%22appendChild%22%2C%22insertBefore%22%2C%22removeChild%22%2C%22replaceChild%22%2C%22setAttribute%22%2C%22removeAttribute%22%2C%22querySelector%22%2C%22querySelectorAll%22%5D)%2Cfunction(e%2Ct)%7Bfor(let%20o%3D0%3Bo%3Ct.length%3Bo%2B%2B)%7Blet%20r%3Dt%5Bo%5D%3BObject.defineProperty(e%2Cr%2C%7Bget%3Afunction()%7Breturn%20this.node%5Br%5D%7D%2Cconfigurable%3A!0%7D)%7D%7D(r.prototype%2C%5B%22parentNode%22%2C%22firstChild%22%2C%22lastChild%22%2C%22nextSibling%22%2C%22previousSibling%22%2C%22firstElementChild%22%2C%22lastElementChild%22%2C%22nextElementSibling%22%2C%22previousElementSibling%22%2C%22childNodes%22%2C%22children%22%2C%22classList%22%5D)%2Cfunction(e%2Ct)%7Bfor(let%20o%3D0%3Bo%3Ct.length%3Bo%2B%2B)%7Blet%20r%3Dt%5Bo%5D%3BObject.defineProperty(e%2Cr%2C%7Bget%3Afunction()%7Breturn%20this.node%5Br%5D%7D%2Cset%3Afunction(e)%7Bthis.node%5Br%5D%3De%7D%2Cconfigurable%3A!0%7D)%7D%7D(r.prototype%2C%5B%22textContent%22%2C%22innerHTML%22%5D)%3Bclass%20n%7Bconstructor(e)%7Bthis.event%3De%7Dget%20rootTarget()%7Breturn%20this.event.composedPath()%5B0%5D%7Dget%20localTarget()%7Breturn%20this.event.target%7Dget%20path()%7Breturn%20this.event.composedPath()%7D%7DPolymer.DomApi%3Dr%2CPolymer.DomApi.prototype.cloneNode%2CPolymer.DomApi.prototype.appendChild%2CPolymer.DomApi.prototype.insertBefore%2CPolymer.DomApi.prototype.removeChild%2CPolymer.DomApi.prototype.replaceChild%2CPolymer.DomApi.prototype.setAttribute%2CPolymer.DomApi.prototype.removeAttribute%2CPolymer.DomApi.prototype.querySelector%2CPolymer.DomApi.prototype.querySelectorAll%2CPolymer.dom%3Dfunction(e)%7Bif(!(e%3De%7C%7Cdocument).__domApi)%7Blet%20t%3Bt%3De%20instanceof%20Event%3Fnew%20n(e)%3Anew%20r(e)%2Ce.__domApi%3Dt%7Dreturn%20e.__domApi%7D%2CPolymer.dom.matchesSelector%3Do%2CPolymer.dom.flush%3DPolymer.flush%2CPolymer.dom.addDebouncer%3DPolymer.enqueueDebouncer%7D()%3B%0A%2F%2F%23%20sourceURL%3Dhttps%3A%2F%2Ff<MYURL>%3A8123%2Ffrontend_latest%2Ffrontend-ebcb41952b21503c6a09065b084a638d.html-29.js%0A:0:0 Script error.

azrdev commented 6 years ago

Looks like this is fixed with homeassistant-0.64.3 (from pip)

fakezeta commented 6 years ago

Hi @azrdev can you confirm? I just updated homeassistant with Firefox 58.0.2 and still have the same error.

azrdev commented 6 years ago

@fakezeta as I said, I don't see it anymore with 0.64.3 -- what's your version? (I'm also on firefox 58.0.2, to rule that out)

fakezeta commented 6 years ago

I'm running Docker image 0.64.3 from https://hub.docker.com/r/homeassistant/home-assistant/

BTW I've also tried cleaning cache, cookies and all the usual stuff.

ghost commented 6 years ago

For me the same problem persists in 0.64.3 and Firefox 58.0.2 on a RPi2 with hassbian.

In addition I usually cannot access the 'developer tools' in the webUI. When I can I see the error repeatedly written into the logs.

I had this issue before in 0.64.1. It disappeared in 0.64.2 and then reappeared in 0.64.3.

Any suggestions what could be wrong? Will this be fixed?

@azrdev Can you reopen this issue? It is certainly not solved for me.

I also played around with javascript_frontend: auto/latest/ES5 which did not help.

UPDATE: Seems to be solved with Firefox 59.0 on Windows 10.

fakezeta commented 6 years ago

Update: I just updated Firefox to 59.0 on Windows 7 (still not tested on macOs) and the issue seem solved with hass docker image 0.65.3.

@darioce can you check?