-
Notifications
You must be signed in to change notification settings - Fork 133
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
Allow graceful period to work around slow receipt validation #1139
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Verify connection after: - 2 minutes (App Store) - 10 minutes (TestFlight)
- Rename Fallback- to SharedReceiptReader - Discontinue local receipt (Kvitto) - Get rid of all beta receipt hacks
- Use timeout in fetchProducts() - Parallelize AppTransaction and Transaction.currentEntitlements
Start the tunnel without restrictions, then verify purchases after a delay (based on the user level). This mitigates the slow StoreKit responses often experienced on device boot. If verification fails, put the tunnel on hold (active but idle) to avoid on-demand reconnections and allow the user to see the "Purchase required" message in the app.
Prevent infinite on-demand reconnection.
Fix second paywall on interactive login by propagating the verify flag.
Stop saving ineligible profiles. Also fix a bug where a profile was being saved despite choosing "Cancel" in the paywall.
295d4e6
to
6c7e6e1
Compare
Merged
keeshux
added a commit
that referenced
this pull request
Feb 5, 2025
- Add to "General" module on macOS - Restore in profiles list/grid, removed in #1139
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
#1070 is very tricky. When the device boots, StoreKit operations seem to be severely affected by on-demand VPN profiles. Slowdowns are huge and unpredictable, as per my report on the Apple forums. I found no easy way to work around the chicken-and-egg situation where the VPN requires StoreKit validation to start, but StoreKit requires network access.
On the other hand, without StoreKit validations, the on-demand tunnel starts on boot just fine, and so does the app. No eternal activity indicators. StoreKit is clearly the culprit here.
Therefore, below is the strategy that this PR implements for a decent trade-off:
On the UI side, adjust the app accordingly:
This PR also introduces changes in TestFlight behavior:
Beta users may therefore test all paid features on iOS/macOS/tvOS for 10 minutes. Until now, paid features were only available to paying iOS users and unavailable on macOS/tvOS. The tvOS beta was, in fact, completely useless.
The downside is that paying iOS users will see beta builds restricted like anybody else. I'll see if I can find a better solution later.