-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Updated app won't run because Sparkle.framework is missing #311
Comments
Actually, the bug seems to randomly occur and can go away if you just try opening the app again, and occurs whether downloaded directly or through sparkle, but the crashes lead back to sparkle framework. This is the build script I'm using with it: |
What error message are you getting, exactly? There's probably a crash report. Show that. |
Sometimes it complains that Sparkle.framework is missing and sometimes it gives a more general exception fully captured here:
I'm using 1.5b6 |
Sounds like two separate issues. Show a crash report from when it complains that Sparkle.framework is missing. Regarding the crash report you linked: you're evidently calling |
I'll double check for sloppy string assignment… |
So that says that there's no binary at /Applications/MacMiner.app/Contents/Frameworks/Sparkle.framework/Versions/A/Sparkle. You originally said that "[t]he file works fine if it's downloaded from the website directly". Is that downloaded from the same URL that your feed specifies? Also, are any of the folders within your app bundle marked as read-only (lacking the write permission)? I've seen problems where the various folder copying APIs fail in that case. They create the subdirectory and then dutifully set its permissions to read-only to match the source. They then try to copy in the contents but fail because it's read-only. |
It’s the same file - either way, updated or direct download there’s a chance of this crash. Re-downloading (and I suspect trying to open the app a second time) allow the app to open. Nothing is marked as read-only and I’ve been building the app in a very similar manner for half a year. I’m hoping that somehow a string setting problem is causing this false report of a missing framework… just applied an update with an extra safety in place so I’ll see whether it helps things! On 13 Dec 2013, at 11:03, KenThomases [email protected] wrote:
|
I can't imagine the crash report is false. It's coming from dyld, the dynamic loader. It's happening during the loading of your app, before any of its code has had a chance to run, so there's very little opportunity for it to be due to a bug in the app code. Could it be that the copy operation is still in progress when the app is being launched? |
I wanted to chime in here and say that some of our customers are having the same problem (some or all of the Sparkle framework is missing after Sparkle downloads the new app, unzips it, moves it into place, and relaunches it). We've seen it randomly in earlier versions of the OS, but it seems to be happening more with our 10.9 customers. However, I'm beginning to suspect this isn't a bug with Sparkle, but rather with OS X. Here's why:
So we're definitely seeing this problem as well, but given the above I'm beginning to suspect that the issue isn't with Sparkle but rather something in the Finder or the file system. I've spent hours scouring the net for anyone else having these problems, and so far this is about the only thread I've found that matches the problems we're seeing. I haven't tried filing Radar yet (mainly because I can't reproduce the problem with any certainty and Radar always seems like a black hole anyway). But I gotta think that there's more than just one or two developers having this problem, right? phil |
@psulak: When checking the archive, are you using the built-in Archive Utility to uncompress the archive or do you have a third-party unarchiving tool? We've seen problems with third-party tools failing on valid archives, leaving files missing or truncated. |
I ran in to the bug once personally and it was with Archive Utility on a VM close to a standard system install but as you say it's hard to reproduce, so most of my information comes from app users. |
Ken, Typically to check the archive I do two things:
I've occasionally used zipinfo in the Terminal, but that's a bit of a pain:-) I'm trying to get into the habit of using ditto in the Terminal to compress the app, but usually I'm too lazy to fire up the Terminal. If I use right-click in Finder, then I'll typically compress the original app at least twice. The first zip is the one that's sometimes too small. The second zip is usually the correct size. |
Just had this exact thing happen. I 'as usual' zipped the app and uploaded the zip file. Comparing the zips: That scenario is more likely IMHO than the Finder doing archives 'wrong' sometimes. |
Hey Everyone - FWIW, we switched from ZIP to TGZ files for our Sparkle updates. The problem of the app missing files after Sparkle downloads and decompresses the update has been reduced significantly. It still happens from time to time, but the problem isn't nearly as bad as when we were using ZIP files for our updates. YMMV. |
@tomandersen, I don't think time is a factor with the Finder Zip bug (as I now call it). In my experience, I can wait 1 minute, 5 minutes, 10 minutes, etc after Xcode completes its build before right-clicking to ZIP the application, and it just doesn't matter. The first Zip file is always bad, and the second is fine. BTW, I opened a Radar with Apple about this bug. I've been able to verify that the bug isn't being caused by either my fusion drive, or apps such as Dropbox (which do code injections into the Finder). If any of y'all are able to reproduce the Finder Zip bug, please open Radars as well. |
Quick update: I'm unable to reproduce the Finder Zip bug in 10.9.2. Please note that is on the archiving side of things and not on Sparkle's side (unarchiving). As far as unarchiving goes, we've been using TGZ files for several weeks now, and although the missing frameworks problem is greatly reduced, it still occurs from time to time. |
For most of the apps it should be safe to link Sparkle.framework as Optional, so when OS X can't find/load it the app will still run, it just won't be able to update. So for now I suggest doing that as a workaround/fail-safety. I've also created #345 to explore what can be done when Sparkle fails to load. |
Sparkle as optional is a double edge, right? the auto update is one of the most important features to get right, so that you can fix (other) issues. |
Yes, very good point. Please have a look at issue #345 and see if that approach can be improved. |
@pornel Has any progress been made on this? I'm seeing it on first launch of an app with Sparkle 1.8. Any idea which version introduced this so that I can get the version before it? |
@danielchasehooper nothing has changed in that area recently. Please file a bug with more information, especially console output. |
@pornel Fixed my own problem: the framework was in the copy bundle resources phase rather than a custom "frameworks" copy files phase |
The file works fine if it's downloaded from the website directly…
Could this be due to having switched my development environment to 10.9 and thus having to add a run script to compile the app with Sparkle included?
The text was updated successfully, but these errors were encountered: