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

Wait for a threshold amount of time before replying with status info data #2230

Merged
merged 4 commits into from
Aug 19, 2022

Conversation

zorgiepoo
Copy link
Member

This reverts #2223 and #2221 in favor of making a simpler and lower-risk change in having the updater / progress app wait for a threshold amount of time before replying back with the status info, in case the service gets the data very soon afterwards. Before with #2221, this regressed installing an update to an app that was already terminated (e.g. from sparkle-cli) where the delegate callbacks were being called out of order. Also, this improves not having the framework have to wait for a registration complete reply in the common case.

Misc Checklist

  • My change requires a documentation update on Sparkle's website repository
  • My change requires changes to generate_appcast, generate_keys, or sign_update

Only bug fixes to regressions or security fixes are being backported to the 1.x (master) branch now. If you believe your change is significant enough to backport, please also create a separate pull request against the master branch.

Testing

I tested and verified my change by using one or multiple of these methods:

  • Sparkle Test App
  • Unit Tests
  • My own app
  • Other (please specify)

Tested test app and cases in #2221 as well as sparkle-cli on an app not terminated and an app already terminated.

macOS version tested: 12.5 (21G72)

@zorgiepoo zorgiepoo added this to the 2.3 milestone Aug 19, 2022
@Sparkle-Bot
Copy link
Contributor

In file included from /Users/runner/work/Sparkle/Sparkle/Autoupdate/StatusInfo.m:9: /Users/runner/work/Sparkle/Sparkle/Autoupdate/StatusInfo.h:18:41: warning: auto property synthesis is synthesizing property not explicitly synthesized [-Wobjc-missing-property-synthesis] @property (nonatomic, nullable) NSData *installationInfoData; ^ /Users/runner/work/Sparkle/Sparkle/Autoupdate/StatusInfo.m:20:17: note: detected while default synthesizing properties in class implementation @implementation StatusInfo ^ 1 warning generated. In file included from /Users/runner/work/Sparkle/Sparkle/Autoupdate/StatusInfo.m:9: /Users/runner/work/Sparkle/Sparkle/Autoupdate/StatusInfo.h:18:41: warning: auto property synthesis is synthesizing property not explicitly synthesized [-Wobjc-missing-property-synthesis] @property (nonatomic, nullable) NSData *installationInfoData; ^ /Users/runner/work/Sparkle/Sparkle/Autoupdate/StatusInfo.m:20:17: note: detected while default synthesizing properties in class implementation @implementation StatusInfo ^ 1 warning generated. note: Using new build system note: Planning note: Build preparation complete note: Building targets in dependency order

@zorgiepoo zorgiepoo merged commit 47f3356 into 2.x Aug 19, 2022
@zorgiepoo zorgiepoo deleted the delayed-updater-response branch August 19, 2022 17:40
zorgiepoo added a commit that referenced this pull request Aug 28, 2022
…data (#2230)

Without this, critical update alerts may not show up as promptly as they should when automatically installing them.

This fixes a potential race issue where sometimes the automatic update driver on completion would sometimes not trigger to prompt an update alert immediately for critical updates. Note in this case, the update would still be installed on app termination and would still be scheduled to alert the user on the regular update check interval, so this issue is not severe.
@zorgiepoo zorgiepoo modified the milestones: 2.3, 2.2.2 Aug 28, 2022
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

Successfully merging this pull request may close these issues.

2 participants