TypeError: Cannot read property 'text' of undefined
See original GitHub issuenot entirely sure if this is an issue with istanbul directly or karma-coverage, but i think it’s an istanbul thing so i created this issue with them but you may want to look into it too:
04 10 2017 09:34:48.018:ERROR [coverage]: TypeError: Cannot read property 'text' of undefined
at project/node_modules/istanbul/lib/report/html.js:288:53
at Array.forEach (native)
at annotateBranches (project/node_modules/istanbul/lib/report/html.js:255:30)
at HtmlReport.writeDetailPage (project/node_modules/istanbul/lib/report/html.js:426:9)
at project/node_modules/istanbul/lib/report/html.js:489:26
at SyncFileWriter.writeFile (project/node_modules/istanbul/lib/util/file-writer.js:57:9)
at FileWriter.writeFile (project/node_modules/istanbul/lib/util/file-writer.js:147:23)
at project/node_modules/istanbul/lib/report/html.js:488:24
at Array.forEach (native)
at HtmlReport.writeFiles (project/node_modules/istanbul/lib/report/html.js:482:23)
at project/node_modules/istanbul/lib/report/html.js:484:22
at Array.forEach (native)
at HtmlReport.writeFiles (project/node_modules/istanbul/lib/report/html.js:482:23)
at HtmlReport.writeReport (project/node_modules/istanbul/lib/report/html.js:566:14)
at writeReport (project/node_modules/karma-coverage/lib/reporter.js:68:16)
at project/node_modules/karma-coverage/lib/reporter.js:296:11
the problem is:
text = structuredText[startLine].text;
i guess it assumes structuredText[startLine] is always going to be a thing, and apparently at least once it is not a thing? I don’t know how you can reproduce it; just let me know what you need that i can provide and i’ll provide it.
Issue Analytics
- State:
- Created 6 years ago
- Reactions:4
- Comments:7 (2 by maintainers)
Top Results From Across the Web
Error: Cannot read property 'text' of undefined - Stack Overflow
Yep, only two places that .text is referred to-- either $("headingWiki_0 h3 span") isn't returning anything or your data return from the $....
Read more >ERROR in : TypeError: Cannot read property 'text' of ... - GitHub
Hard to say, since the error seems deep into the typescript stack. Assuming you have a similar error stack to the one shown...
Read more >Cannot read property 'text' of undefined | Jira
Cause and possible solutions: This can be caused by more than one thing: The Board's estimation: If you go to the board's configuration...
Read more >JS error. Cannot read property 'text' of undefined...unsure what
The error means that quiz.getCurrentQuestion() returns undefined, so take a look at your implementation of that method. If you cannot see the ...
Read more >Uncaught TypeError: Cannot read property of undefined In
Uncaught TypeError: Cannot read property of undefined ... JavaScript TypeError is thrown when an operand or argument passed to a function is incompatible...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I’m having a similar problem with flow and closure:
this will throw an error:
this works fine
Should I open a new issue?
Not a npm package, juste a reporter config.