react-native-store-version
react-native-store-version copied to clipboard
Error: JSON Parse error: Unexpected token: <
I am intermittently seeing an exception when calling "checkVersion". The exception happens about 25% of the time. im calling the function as follows:
let check = await checkVersion({
version: versionLocal, // app local version
iosStoreURL: updateConfig.urls.ios.check,
androidStoreURL: updateConfig.urls.android.check,
country: 'us',
});
where variables are (expect i am using my real id# and app name) :
ios: {
check: 'https://apps.apple.com/us/app/yachtwave/id1234567890',
},
android: {
check: 'https://play.google.com/store/apps/details?id=com.myapp.app',
Hoping you can help find the issue as it is affecting version checks - thanks!
i am also having same issue
[Error: JSON Parse error: Unrecognized token '<']
@jeokeefe did you found solution for this?
@KiranRadish I have not found a solution, we pushed our latest update with it like that. We catch the exception and then just move on...
We are having the same issues here. As @jeokeefe pointed out, it does not happen every time.
Hi everyone.
Sorry to reply. I will fix this, so please wait. I can probably fix this in 2 days.
thanks
@jeokeefe @McFlyssss @KiranRadish I think it's because the version is no longer listed on the play store. Please yours play store url. I found there may be certain rules.
Pattern A
This app using my library.
Press the button [About this app ->] and see if the version notation part in the displayed modal looks like this.
Pattern B
This app I created, and version is displayed.
What?
So, I want to check different. My app build type is .aab. Which type aab or apk your apps.
Maybe it's different depending on whether it's aab or apk. or maybe something else...
First of all, please tell me if it's aab or apk.
thanks
Hi @watanabeyu ,
Thanks for taking a look into this. We actually are having those issues on the iOS side of the things. Android is working just fine for us.
Umm...please your app store url
Sure thing! There you go: https://apps.apple.com/app/nuvolops-crew-app/id1536764075
Here you go thanks! I believe this is only happening with the apple App Store (not google)“ https://apps.apple.com/us/app/yachtwave/id6447794172”Thanks! Sent from my iPhoneOn May 25, 2023, at 5:15 AM, Yu Watanabe @.***> wrote: Umm...please your app store url
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you were mentioned.Message ID: @.***>
@McFlyssss Thanks url. I can get version. Enter the appstore url in the url below and try it https://snack.expo.dev/@watanabe_yu/react-native-store-version-example?platform=ios
@jeokeefe Thanks url. I can get version. Enter the appstore url in the url below and try it.
I think it's probably because I didn't put in the country. Is it because the default countryCode is jp? https://snack.expo.dev/@watanabe_yu/react-native-store-version-example?platform=ios
I’ll send you my code when I get back to my desk on 1 hour. I’m using “us” and the issue only happens about 20% of the time, all others it works. It is odd. Sent from my iPhoneOn May 25, 2023, at 8:25 AM, Yu Watanabe @.> wrote: @jeokeefe Thanks url. I can get version. Enter the appstore url in the url below and try it. I think it's probably because I didn't put in the country. Is it because the default countryCode is jp? @._yu/react-native-store-version-example?platform=ios
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you were mentioned.Message ID: @.***>
const updateConfig = { urls: { ios: { check: 'https://apps.apple.com/us/app/yachtwave/id6447794172', }, android: { check: 'https://play.google.com/store/apps/details?id=com.yachtwave.app', } } }
let check = await checkVersion({ version: versionLocal, // app local version iosStoreURL: updateConfig.urls.ios.check, androidStoreURL: updateConfig.urls.android.check, country: 'us', });
On Thu, May 25, 2023 at 8:25 AM Yu Watanabe @.***> wrote:
@jeokeefe https://github.com/jeokeefe Thanks url. I can get version. Enter the appstore url in the url below and try it.
I think it's probably because I didn't put in the country. Is it because the default countryCode is jp?
@.***_yu/react-native-store-version-example?platform=ios
[image: スクリーンショット 2023-05-25 21 24 29] https://user-images.githubusercontent.com/6455904/240910906-086e52cb-edd0-456d-931d-3bd57dd50ebc.png
— Reply to this email directly, view it on GitHub https://github.com/watanabeyu/react-native-store-version/issues/55#issuecomment-1562817858, or unsubscribe https://github.com/notifications/unsubscribe-auth/A7OOXAEOXSJGFVYCWDTW46DXH5FVFANCNFSM6AAAAAAX43CNAU . You are receiving this because you were mentioned.Message ID: @.***>
-- John O'Keefe CEO, YACHTWAVE
(917) 945-0186 | www.yachtwave.com | @.*** @.***>
935 N Beneva Rd, Ste 609 PMB 2056, Sarasota, FL 34232 https://maps.google.com/?q=935+N+Beneva+Rd,+Ste+609+PMB+2056,+Sarasota,+FL+34232
Hi again @watanabeyu
Thanks again for checking this out. As you can see on my screenshot I got to reproduce the error:
@jeokeefe
I’m using “us” and the issue only happens about 20% of the time, all others it works. It is odd.
Hmm, I've never encountered that phenomenon. I don't think it's a problem if you can get it even once, but maybe the iOS lookup API is sometimes strange. For the time being, I feel that this library does not seem to be... Let me know once again if you find something like that.
@McFlyssss
const check = await checkVersion({
version,
iosStoreURL: 'https://apps.apple.com/app/nuvolops-crew-app/id1536764075',
country:"us",
});
Could you try putting in the countryCode like this?
i just made the change to "us" (double quotes) ill run for a bit and provide an update.