This repository has been archived by the owner on Jan 22, 2025. It is now read-only.
Uncaught TypeError TypeError: Cannot read properties of undefined (reading 'toBase58') #2360
Labels
question
Add this to close an issue with instructions on how to repost as a question on Stack Exchange
Overview
Steps to reproduce
const publicKey = traderKeypair.publicKey;
const address = publicKey.toBase58();
console.log('Solana Address:', address);
const message = new web3.TransactionMessage({
payerKey: traderKeypair.publicKey,
instructions: [setupNewMakerIxs],
recentBlockhash,
}).compileToV0Message();
Description of bug
publicKey.toBase58() can get value ,but TransactionMessage first parameter payerKey:Uncaught TypeError TypeError: Cannot read properties of undefined (reading 'toBase58') ,Findings bug is "@solana/web3.js/lib/index.cjs.js:626:30) " ,When calling compileToV0Message
![image](https://private-user-images.githubusercontent.com/1042120/315879541-9607dbb0-080c-436a-82d2-7724bbb762dd.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkzMjEyNjUsIm5iZiI6MTczOTMyMDk2NSwicGF0aCI6Ii8xMDQyMTIwLzMxNTg3OTU0MS05NjA3ZGJiMC0wODBjLTQzNmEtODJkMi03NzI0YmJiNzYyZGQucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI1MDIxMiUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNTAyMTJUMDA0MjQ1WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9MDQzMDk0Yzk1MTdjOGZjODk1MDQ5ZmY1ZTA0NDYxNzcwM2RiNDc1NDFiMzEzMmVjYWJkMzhmNTE3MmY3ZmQ1NCZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QifQ.KxiaJMk2InoOAHTn2X2PfeIM6-MdFSY9v99eiqwO6W8)
pubkey firtst can get value ,second pubkey is null
The text was updated successfully, but these errors were encountered: