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

iOS 11 problem with opening app page in the App Store #302

Open
janbjelicic-sunhill opened this issue Jul 11, 2017 · 20 comments
Open

iOS 11 problem with opening app page in the App Store #302

janbjelicic-sunhill opened this issue Jul 11, 2017 · 20 comments

Comments

@janbjelicic-sunhill
Copy link

Hi guys,

when using this code:
[[iRate sharedInstance] openRatingsPageInAppStore];

The app opens the app store but the message stands "Verbindung zum App Store nicht möglich" (I think the english translation is Can't connect to App Store)

The app already exists on the app store, and this code worked for the previous iOS versions.

P.S. I assume this is expected since Apple changed the whole App Store in iOS 11.

@nicklockwood
Copy link
Owner

Is this using the latest version of iRate? The URL changed recently.

@janbjelicic-sunhill
Copy link
Author

I tried it an hour ago, updated to the version 1.12.1 via Cocoapods

@EddyLB
Copy link

EddyLB commented Jul 26, 2017

I use version 1.12.1 via Cocoapods and confirm.
I get the message 'Cannot Connect to App Store' in the App Store app when calling [[iRate sharedInstance] openRatingsPageInAppStore];

@bvirlet
Copy link

bvirlet commented Sep 11, 2017

The URL seems not to work anymore with the action=write-review parameter (I can reproduce the issue in Safari). Eg the App Store doesn't support opening (scrolling) to the new "Ratings & Reviews" section.

@vtourraine
Copy link

I confirm this is an issue. Even using the https-based URL (e.g. https://itunes.apple.com/app/blabla/idXXXXXX?action=write-review) fails to load.

The documentation is still suggesting to use action=write-review, so I think it’s Radar time.

In the meantime, apps should not open the “write review” URL on iOS 11, just the basic App Store link.

@hixfield
Copy link

I confirm I have the same issue on the iOS 11 GM seed. How can we fix this?

@zapjonny
Copy link

zapjonny commented Sep 20, 2017

Will this repo be fixed soon?

How can we fix this in the meantime?

@zapjonny
Copy link

Update:

First, sorry my bad, I had locked iRate below version 12 in my podfile.

Fixing that, I think I know what was going on. I probably locked iRate below 12 in order to avoid the iOS 10.3+ way of opening the in-app rate alert (I don't remember the reason for this, but hey).

In my app I had two cases where I used iRate.

  1. When you do an in-app action enough times, the alert "wanna rate?" popped up.
  2. In the options menu, I had an extra option "rate now" which directed the user to the app store review page, so the user could rate easily at any time.

Now, the iRate.sharedInstance().openRatingsPageInAppStore() is still broken for iOS 11.0 users.
However iRate.sharedInstance().promptIfNetworkAvailable() will work, if we accept the 10.3 in our app. I guess that should be the proper way since iOS 10.3 anyway and we just have to live with it.

So at this point, I assume that for me, 1 should work if I use the latest iRate, and 2 will work if use iRate.sharedInstance().promptIfNetworkAvailable() instead of iRate.sharedInstance().openRatingsPageInAppStore() which won't work on iOS 11.0.

@zapjonny
Copy link

zapjonny commented Sep 20, 2017

Okay, I guess even that's not the end of the story. I thought twice and thrice and I guess case 2 above is a no-go since iOS 11.0 (or probably also since 10.3, in a way).

First, it doesn't make sense to prompt the user in the same way in 2 as I do in 1, I'd want to open the review page below 10.3 and open the in-app SKStoreReviewController from 10.3 and up. However with the current iRate there is no way to do that, unless possibly if we fix it so we can call [self promptForRating: NO];.

But the discussion doesn't end there because on iOS 10.3+ that would ultimately call https://developer.apple.com/documentation/storekit/skstorereviewcontroller/2851536-requestreview which, as is stated in the docs, might or might not open the review UI. Which is in terms with how Apple wants the review experience to work...

I guess I will have to advocate to my director to remove case 2 and only use case 1 above - rate upon some rare user interaction.

Also in the long run I guess Apple is specifically wanting to shoot down iRate and similar libraries that show review popups.

@neave
Copy link

neave commented Sep 20, 2017

A workaround is to include a two-letter country code and app name in the URL, such as this:

https://itunes.apple.com/us/app/twitter/id333903271?mt=8&action=write-review
or
itms-apps://itunes.apple.com/us/app/twitter/id333903271?mt=8&action=write-review

The full URL for your app can be obtained from https://linkmaker.itunes.apple.com/

This successfully opens the "write a review" interface in the iOS 11 App Store. This workaround is not ideal however as changing the app title would also change its URL, thus breaking the workaround. Hopefully Apple will fix this soon for the shorter URL.

See rdar://34498138

@dpa99c
Copy link

dpa99c commented Sep 21, 2017

The country code and app name must be present in the URL but are ignored - only the ID needs to change. Also mt=8 is not required. I.e. this works:

itms-apps://itunes.apple.com/xy/app/foo/id{your_app_id}?acti‌​on=write-review

Tested on iOS 11.0 (15A372).

@zapjonny
Copy link

^ That one really works... so for a fast fix, I guess I could go with it if iRate was updated with this. Will iRate be updated or will I have to fork this? 🙄

@bvirlet
Copy link

bvirlet commented Sep 21, 2017

Maybe you can fork, and offer a pull request 😉

@nicklockwood
Copy link
Owner

nicklockwood commented Sep 21, 2017

@zapjonny you can override the URL without forking iRate by adding this to your setup code:

 [iRate sharedInstance].ratingsURL = ...

@zapjonny
Copy link

@nicklockwood Good one! It works ✌️
I’ll use this and go back to iRate below 12 for minimum code changes.

@tirrorex
Copy link

Can confirm workaround to be working, thanks

@EddyLB
Copy link

EddyLB commented Sep 21, 2017

Confirmed. Thanks

@spookyhouse
Copy link

Thanks @neave. This works!

@alper
Copy link

alper commented Sep 22, 2017

OK. And this also works on iOS 10 I just tested.

@mstolin
Copy link

mstolin commented Nov 3, 2017

@dpa99c
I fixed this issue for my app (im not using iRate) with using an url like tms-apps://itunes.apple.com/app/twitter/id333903271?mt=8&action=write-review. I didnt add a language code but mt=8 is still necessary. Without mt=8 the App Store app will show the Can't connect to App Store error message. I tested on iPhone 5s iOS 11.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests