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.

[protobufjs] Error Cannot read property 'emptyArray' of undefined with rollup

See original GitHub issue

This project has a dependency on protobufjs

protobufjs has a known issue with rollup: https://github.com/rollup/rollup/issues/2747

Which means that projects using rollups might have build errors when using nodejs-pubsub.

I am creating this issue for 2 purposes:

  • To make it easier to debug the Cannot read property 'emptyArray' of undefined with rollup when it is generated,
  • To suggest to switch with other proto alternatives. I have been using protobuf-ts that generates type safe typescript code and look more robust that protobufjs.

Ref: https://github.com/protobufjs/protobuf.js/issues/1503

Issue Analytics

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

github_iconTop GitHub Comments

1reaction
vicbcommented, Feb 19, 2021

@feywind it seems like rollup is working on fixing this in https://github.com/rollup/plugins/pull/658

I’ll update here when I have more info.

0reactions
feywindcommented, Jan 26, 2022

I’m going to close this out for now, since there’s not a big emphasis on rollup support just yet, but we’ll re-visit from the web tag later.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Uncaught TypeError: Cannot read property 'emptyArray' of ...
Im using typescript and trying with awesomemessage example. It reports error of emptyArray. import protobuf from 'protobufjs'; protobuf.load("t.
Read more >
ProtoBuf.js
I have a shared library of .proto files. I'd like to be able to publish it as an npm module consisting of one...
Read more >
Rollup.js: undefined objects in external dependencies
This sort of errors: Cannot read property 'parse' of undefined coming from crypto-js. It complains about this line in the code: var ciphertext...
Read more >
Bug Reports - Fuse Community
Importing webpack/rollup processed code results with `Cannot read property ... TypeError: Cannot read property 'get' of undefined in Fuse.
Read more >
firebase/firebase-firestore-lite.js.map
\"function\" && b !== null)\r\n throw new TypeError(\"Class extends value \" + ... !state.has(receiver)) throw new TypeError(\"Cannot read private member ...
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