© 2026 LinearBytes Inc.
Search posts, tags, users, and pages
Matimu Ignatius
Hello Azim Ahmed Great article...
How do I resolve the error below?
Unhandled Runtime Error TypeError: Cannot read properties of undefined (reading 'toHexString')
Azim Ahmed
Seems like you don't have private key environment variable in your .env.local file. You want to add that file and set that variable.
Azim Ahmed Thank you for your reply.
I did set it up still getting same error
Matimu Ignatius Ah next for some reason doesn't let you put variable names without a prepend NEXT_PUBLIC. So you should probably rename your env variable to NEXT_PUBLIC_PRIVATE_KEY in all the places.
Azim Ahmed I renamed crossing my fingers it works but new server error.
Azim Ahmed I attempted
Resluted to this error