Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[React Native] [Thirdweb V4] : JSON value '<null>' of type NSNull cannot be converted to NSString warning #3283

Open
jimit-raval-sf opened this issue Jun 12, 2024 · 8 comments
Assignees
Labels
React Native SDK Involves changes to the React Native SDK.

Comments

@jimit-raval-sf
Copy link

I am getting this warning while connecting my wallet in React Native,
Basically What I am doing is...

I am using the ConnectWallet component in the React native project.
whenever I try to connect the wallet using the ConnectWallet component I get "JSON value '' of type NSNull cannot be converted to NSString" this warning.
it doesn't affect the app in development mode but in release mode the app crashes.
I tried using custom UI to connect wallet but it throws the same warning.

Here is the picture of the warning that I got in Xcode:
unnamed (3)

Here is the dependency version:

"@thirdweb-dev/chains": "^0.1.116",
"@thirdweb-dev/react-native": "0.7.3",
"@thirdweb-dev/react-native-compat": "0.7.3",
"@thirdweb-dev/sdk": "4.0.6",

Thank you

@jimit-raval-sf jimit-raval-sf changed the title JSON value '<null>' of type NSNull cannot be converted to NSString warning [React Native] [Thirdweb V4] : JSON value '<null>' of type NSNull cannot be converted to NSString warning Jun 12, 2024
@joaquim-verges
Copy link
Member

have you tried upgrading to the new thirdweb@^5 package? we recently added support for react native and is going to be the only supported version moving forward.

It has everything to build custom connection UI already, and prebuilt connect UI components are in the works (you can follow along in this PR #3246

@joaquim-verges joaquim-verges added the React Native SDK Involves changes to the React Native SDK. label Jun 15, 2024
@jimit-raval-sf
Copy link
Author

Hi @joaquim-verges Thanks for the reply

No, I've not tried upgrading to V5 yet.

In v4, it was working perfectly fine but somehow it suddenly started crashing on iOS only, in the release build.

Here I'm attaching the screenshot of crashlytics, please have a look:

Screenshot 2024-06-17 at 12 07 01 PM

@joaquim-verges
Copy link
Member

which wallet are you connecting in this case? looks lit might be sending a null value via WalletConnect websocket

@jimit-raval-sf
Copy link
Author

@joaquim-verges
I'm trying to connect the "Meta Mask" mobile wallet, through the ConnectWallet component.

Here is the code snippet:

Screenshot 2024-06-18 at 10 36 17 AM

@jimit-raval-sf
Copy link
Author

Hi @joaquim-verges
Is there any progress on this issue?
Thanks!

@joaquim-verges
Copy link
Member

does it happen with other wallets? one thing i would check is making sure the metamask app is updated to the latest version

@jimit-raval-sf
Copy link
Author

Hey @joaquim-verges I've the latest meta mask app installed but it is not working and the same issue.

PS: this issue is on iOS only, it is working fine in android

@jimit-raval-sf
Copy link
Author

Hi @gregfromstl & @joaquim-verges

is there any progress / update on this issue?

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
React Native SDK Involves changes to the React Native SDK.
Projects
None yet
Development

No branches or pull requests

2 participants