question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

TypeError: null is not an object (evaluating '(a?e.shadowRoot:e).appendChild')

See original GitHub issue

My Home Assistant version: 0.113.1

My lovelace configuration method (GUI or yaml):

yaml What I am doing:

not sure, seems to coincide with <strike>pages using markdown. or conditional cards, though I cant state is a 100% match</strike> Entity Cards containing other (custom) cards. Really difficult to pin it down. Has been here for a very long time though. Below is an example that, even without the styling of card-mod, causes the error to appear.

What I expected to happen:

What happened instead:

Minimal steps to reproduce:

# The least ammount of code possible to reproduce my error

type: entities
entities:
  - type: custom:hui-element
    card_type: markdown
    title: |
      Home Assistant --> Google Assistant
      Voice commands
#    style: |
#      ha-card {background: url('/local/various/google_assistant.png');
#               background-size: cover;
#               box-shadow: none;
#               margin: -16px -16px 0px -16px;
#               }
    content: |
      Ok/Hey Google,

# End of code

Error messages from the browser console: in Safari (Mac)

Unhandled Promise Rejection: TypeError: null is not an object (evaluating '(a?e.shadowRoot:e).appendChild')
Schermafbeelding 2020-07-27 om 22 25 18

in Chrome (Mac)

Uncaught (in promise) TypeError: Cannot read property 'appendChild' of null
    at c (card-mod.js?v=2.0:1)
Schermafbeelding 2020-07-27 om 22 25 57

By putting an X in the boxes ([ ]) below, I indicate that I:

[ ] Understand that this is a channel for reporting bugs, not a support forum (https://community.home-assistant.io/).

[ ] Have made sure I am using the latest version of the plugin.

[ ] Have followed the troubleshooting steps of the “Common Problems” section of https://github.com/thomasloven/hass-config/wiki/Lovelace-Plugins.

[ ] Understand that leaving one or more boxes unticked or failure to follow the template above may increase the time required to handle my bug-report, or cause it to be closed without further action.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5

github_iconTop GitHub Comments

1reaction
Mariusthvdbcommented, Oct 8, 2020

thanks!

0reactions
zibouscommented, Oct 7, 2020

Same Problem here:

card-mod.js:1 Uncaught (in promise) TypeError: Cannot read property 'appendChild' of null
    at c (card-mod.js:1)

Bildschirmfoto 2020-10-07 um 15 38 19

Read more comments on GitHub >

github_iconTop Results From Across the Web

Throw error of TypeError:null is not an object (evaluating ...
Created a Working Example that works in FireFox and tested in Safari on Windows. I can test on a Mac later.
Read more >
TypeError: 'null' is not an object (evaluating 'ul.className ...
There was an error with your code: TypeError: 'null' is not an object (evaluating 'ul.className'). app.js. const list = document.
Read more >
Using shadow DOM - Web Components | MDN
shadowRoot returns null . This is the case with built in elements that contain shadow DOMs, such as <video> . Note: As this...
Read more >
Diff - 241d4738f53e9d144c5b601f4f579778859d6847^! - tour
-The deferred call's arguments are evaluated immediately, but the function call -is not executed until the surrounding function returns.
Read more >
Falcon Sandbox v8.30 © Hybrid Analysis
Not all malicious and suspicious indicators are displayed. Get your own cloud service or the full version to view all details.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found