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.

Version 4.4.0+ causes this runtime error: Uncaught ReferenceError: can't access lexical declaration 'Buffer' before initialization

See original GitHub issue

My application builds and runs fine with 4.3.0, but after upgrading to 4.4.0, I now receive this error in the javascript console:

Uncaught ReferenceError: can't access lexical declaration 'Buffer' before initialization

My app is written in Svelte using TypeScript and Vite (or Snowpack - they both fail with the same error) to build to the final deployable version.

Happy to provide as much detail as you think is valuable. If I’m doing something obviously wrong, please let me know.

Thanks for the library, btw - I really love using it with d3 for data transformation!

Issue Analytics

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

github_iconTop GitHub Comments

2reactions
domoritzcommented, May 19, 2021

Arrow 4.0.1 will fix this issue.

0reactions
jheercommented, May 12, 2021

I’ve reverted to Apache Arrow v3.0.0 in v4.6.0. We can update the dependency once a fixed version of Arrow is released.

Read more comments on GitHub >

github_iconTop Results From Across the Web

ReferenceError: can't access lexical declaration 'X' before ...
This happens within any block statement, when let or const variables are accessed before the line in which they are declared is executed....
Read more >
Can't access lexical declaration`variable' before initialization
Error Type: ReferenceError. Cause of the error: Somewhere in the code, there is a lexical variable that was accessed before initialization.
Read more >
ReferenceError: can't access lexical declaration`X' before ...
A variable defined by a LexicalBinding with an Initializer is assigned the value ... As said here, it cannot be accessed, hence the...
Read more >
can't access lexical declaration`X' before initialization
This happens within any block statement, when let or const declarations are accessed before they are defined. Message. ReferenceError: Use before delaration ( ......
Read more >
Error "ReferenceError: can't access lexical declaration `XXX ...
I think the reason for the error is that webpack generates code which tries to access const before it is declared: /* harmony...
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