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: Cannot read property 'token' of null

See original GitHub issue

Hi there! I found your project on twitter and was very interested to try it out. So I tried it out locally. This is my (very basic) editor (index.html)

<script src="https://unpkg.com/handel-pl"></script>
<textarea id=music style="width:100%;height:50%">
start
	chunk example using somePlayable 
		play somePlayable 
		rest for 1b
	endchunk
	save myPlayable = Eb3 for 1b
	run example using myPlayable with sound piano, loop for 5 
finish
</textarea>
<script>
function play(){
	console.log(music.value)
	Handel.RunHandel(music.value);
}
</script>
<button onclick="play()">Play</button>

Now I get similar errors as on the online editor, so there’s something wrong here? would be nice if the error reporting was bit more specific what is wrong.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
markknolcommented, Jan 26, 2021

Thanks for looking into this! 🎉 It indeed works now.

0reactions
ddj231commented, Jan 23, 2021

Lastly, you mentioned more verbose errors. The errors you mentioned were Lexer errors or errors involving invalid characters – version (0.5.2) now adds clearer messaging for those errors (they were missing line numbers as well like you mentioned). So an invalid program like this:

start
*
finish

Would now produce an error like this: error analyzing input at line: 2; invalid character: *

Read more comments on GitHub >

github_iconTop Results From Across the Web

TypeError: Cannot read property 'token' of null
You have to set the currentUser in your AuthService for your tests and that user should have a valid token. The error is...
Read more >
TypeError: Cannot read property 'tokens' of null - Help
Hello there, so, to see what is happening here, it is their/your chrome app that is faulty. Make sure they've updated to the...
Read more >
TypeError: Cannot read property 'token' of null #5
This error, on this line, indicate that you don't have select the account combo box with a valid config at temperature node. Do...
Read more >
Cannot read property tokens of 'null'? : r/FoundryVTT
Something is quite strange with my account, and I cannot type in the chat because I always end up with the "Cannot read...
Read more >
ERROR TypeError: Cannot read property 'token' of undefined ...
I and trying to build an using a php API, I have been able to login, but when I tried to access other...
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