Update From Disk Image Alert — Sparkle Will Still Search Then Crash

Asked by Chunk1978

i've noticed that when i search for updates while my app is launched from it's disk image, it will correctly alert that update checking is not possible from a disk image. however, when i click "cancel update", it still searches for the update which it never finds (it just keeps searching). at this point when i click Cancel, i get beachballed for a few seconds and finally the app crashes.

Question information

Language:
English Edit question
Status:
Solved
For:
Sparkle Edit question
Assignee:
No assignee Edit question
Solved by:
Chunk1978
Solved:
Last query:
Last reply:
Revision history for this message
Andy Matuschak (andymatuschak) said :
#1

This was a known bug with a previous revision of Sparkle, but it's since been fixed, and I can't reproduce the problem with the current build. Which version are you using?

Revision history for this message
Chunk1978 (chunk1978) said :
#2

im using Sparkle 1.5b4

i did change the Nib windows to texture windows though, because my app icon is very bright (so it doesn't look clear with basic windows), and i changed that broken key/value pair in the french localization strings... not sure if any of my changes would cause this problem or not.

Revision history for this message
Andy Matuschak (andymatuschak) said :
#3

Hm. I really can't make this happen. Can you post the .dmg?

Revision history for this message
Chunk1978 (chunk1978) said :
#4

if it works for you and everyone else it must be something i've done... but i know that it's not my computer, as i sent the app to a tester on the east coast and she experiences the same crash if trying to update from the disk image.

instead of posting my large app, i've taken the exact same sparkle 1.5b4 framework out of my app and used it in a new much smaller app, created a .dmg... it's 400kb... i've posted it to my site here:

http://www.imagectrl.com/SparkleCrashTest.dmg

oh yeah, the new app also crashes... so have a look, i'm very curious now why my version of 1.5b4 still has this bug... anxious to hear back.

Revision history for this message
Chunk1978 (chunk1978) said :
#5

i've tried also downloading Sparkle 1.5b4, changing nothing in the framework, building the app, making the .DMG file, and i still get the same crash.

maybe it's how i'm creating the .DMG file? this is how:

1. Created manually using Disk Utility

2. New Image: Save As: "Temp", Volume Name: "Disk Image", Size: 10 MB, Format Mac OS Extended (Journaled), Encryption: None, Partitions: No Partition Map, Image Format: read/write disk image. Create. close Disk Utility.

3. from the desktop, open "Disk Image", drag and drop my app in "Disk Image" (from project folder > build > release), Close and eject "Disk Image"

4. launch Disk Utility. Select "Temp" from Disk Utility's sidebar, from the top menu i goto Images > Convert... Save As: "App", Image Format: Compressed, Encryption: None. Save.

so now if i launch the .dmg, the removable disk icon appears and the window opens automatically. i launch TestApp. if i choose "Check For Updates" (or if the app is launched for a 2nd time and i select Automatically Check) it will alert saying i can't check for updates from the disk image. i press Cancel but it then continues to search for updates and eventually crashes.

Revision history for this message
Chunk1978 (chunk1978) said :
#6

excellent... the new 1.5b5 version has fixed this for me... it no longer tries checking after pressing cancel update from the disk image... thanks a million!

also, skipping the prompt on the 2nd launch and just having the app automatically display whenever there's an update works quite nicely with your code suggestion:

- (
void
)applicationDidFinishLaunching:(NSNotification *)aNotification
 {
 [[SUUpdater sharedUpdater] setAutomaticallyChecksForUpdates:YES];
 }

thanks again Andy and contributors! :)