Not starting in Sierra

I’m having issues with some of my Xojo apps in Sierra (16A284a), they don’t show the correct icon (only the standard) and after starting I get a “You can’t start the application because it is damaged or incomplete” message.

Other smaller applications are fine, but the large ones won’t open. It happens both with the signed and unsigned version of the app. It is not shown in Activity monitor.

Any clue where I should start looking?

how did you get the apps to where they are now?
Did you use a zip tool of some kind?

Did you create them on Windows 10 ?
(or lower)

I’m using an external drive for Sierra and just copied them from the internal to the new Applications folder in Sierra.

I have also installed Xojo 2015R4.1 and starting the app in debug mode (32bits) and result is “Compilation failed” An error ocurred when attempting to lauch the application.

I’m trying to empty it now and retry step by step, but it is a long work as all is “linked” in some way. If I full empty it, then it works.

Read this:
https://forum.xojo.com/33341-macos-10-12-slow-app-start-when-no-longer-quarantined-and-after

Check the file associations. We just got bit by that.
Check with this video: FileTypesSierra.mp4

Tim,

yes, I have just noticed this after spending the morning on it, last thing I deleted was FileTypes and it worked again.

Will take a look at the video now, thanks.

[quote=281618:@Tim Parnell]Check the file associations. We just got bit by that.
Check with this video: FileTypesSierra.mp4[/quote]
So are you saying that file types which are set to “None” as opposed to “Viewer”, “Editor” or “Shell” actually prevent the application from launching under Sierra?

You may set them to None but at least one filetype must be set to None or any other role. I never checked any file before.

I have now set 2 files from 4 to None, the other 2 are unchecked. Compiled and signed in 10.11 and tested in 10.12, works fine.

Yes. https://forum.xojo.com/34249-damaged-or-codesign/p1#p280212

That was a fun one to figure out. NOT.

If you haven’t, please file a bug report in Feedback about this. Make sure that the summary mentions Sierra and reference this forum thread in the body.

I just tested it to make sure that I fully understand the issue.

In my tests, an application with zero file types specified works.

If I add one file type (and do not check the box in the OS X “File Types” dialog), it doesn’t open on Sierra.
If I check the box in the dialog, it works, regardless of what role I have selected.

So it appears to me that it has a problem with having UTI types and no document types in the plist.

I want to understand because then hopefully I can adapt App Wrapper to either fix this or at the very least warn the user that their application won’t work under Sierra.

[quote=281760:@Sam Rowlands]
In my tests, an application with zero file types specified works.[/quote] Yes, same here.

[quote=281760:@Sam Rowlands]
If I add one file type (and do not check the box in the OS X “File Types” dialog), it doesn’t open on Sierra.[/quote] Yes

[quote=281760:@Sam Rowlands]
If I check the box in the dialog, it works, regardless of what role I have selected.[/quote] Yes

And you don’t need to check all boxes for all files, checking one seems enough to have it working.

OK been poking around with this and it turns out you need to have ONE (or more) checked so that there is at least one entry in CFBundleDocumentTypes

All the ROLES can still be “none”

Without any entries Sierra bitches
As soon as there’s at least one it stops complaining

That’s good to know that it’s an easy fix. Surprised that Sierra whiffs on it, though. The app has been working for years without those settings.

I’ve continued to look into this
Things seem to hinge on the undocumented CFBundleSupportedPlatforms key

CFBundleSupportedPlatforms

MacOSX

If there are no doc types & this key is present things are fine - Sierra doesn’t seem to complain
If there are doc types I’m not sure if this key is examined (since its undocumented by Xcode adds it)

Suberb. So adding this key alleviates the issue whether or not the proper types are set ?

As far as I can tell BUT this key is undocumented as far as I can find.
Xcode inserts it in a document based application that it generates.
Inserting this key into a Xojo produced app that has no document types, which happens if in the OS X build settings you have no File Types checked, makes Sierra also not complain.

Whether Apple considers this a bug or what I don’t know but we are asking them to find out.
We’ll see if we get a reply.

App Wrapper 3.6 already adds this key when wrapping.

I didn’t process the test apps for this situation. I’ll check later.