App Updater helper for Levure

Collaborate on tools, libraries, and applications beyond the IDE

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

trevordevore
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 1005
Joined: Sat Apr 08, 2006 3:06 pm
Location: Overland Park, Kansas
Contact:

Re: App Updater helper for Levure

Post by trevordevore » Wed Feb 06, 2019 8:59 pm

That is correct.
Trevor DeVore
ScreenSteps - https://www.screensteps.com

LiveCode Repos - https://github.com/search?q=user%3Atrevordevore+topic:livecode
LiveCode Builder Repos - https://github.com/search?q=user%3Atrevordevore+topic:livecode-builder

martyknapp
Posts: 52
Joined: Fri Mar 24, 2006 5:33 pm
Location: Blaine, Washington - USA

Re: App Updater helper for Levure

Post by martyknapp » Tue Jul 21, 2020 7:54 pm

I just updated to the latest version of the Levure framework and the app updater helper. When I try to build (with LC 9.6 and 9.5.1 on mac) I get an error about copying Sparkle.framework. "cp: .../helpers/app_updater/code/x86_64-mac/Sparkle.framework/PrivateHeaders is a directory (not copied)."

I reverted to the previous app updater and could build OK. I must be missing something with the new version?

Thanks,
Marty

martyknapp
Posts: 52
Joined: Fri Mar 24, 2006 5:33 pm
Location: Blaine, Washington - USA

Re: App Updater helper for Levure

Post by martyknapp » Wed Jul 22, 2020 6:34 pm

I've been trying to trouble shoot this - I went back to the previous version of the app updater and started replacing individual pieces with those from the newer version. I started with "Sparkle.framework" and the "app_updater-packager" and those would build fine. Then I went with the full new app updater version and tried replacing "helper.yml" with a copy from the *older* version and that will build without error (though I don't know if it actually works). Hopefully that helps to narrow down what is going wrong.

Building on Mac running Mojave. LC 9.6

Marty

martyknapp
Posts: 52
Joined: Fri Mar 24, 2006 5:33 pm
Location: Blaine, Washington - USA

Re: App Updater helper for Levure

Post by martyknapp » Wed Jul 22, 2020 7:40 pm

I compared the helper.yml file with the main app.yml file and saw what looked like redundancy, so I removed the following from my app.yml file and I was able to build. Here are the lines I removed since the helper.yml file seemed to have this info:

macos:
- filename: ./helpers/app_updater/code/x86_64-mac/Sparkle.framework
destination: ./Externals
windows:
- filename: ./helpers/app_updater/code/x86-win32/WinSparkle.dll
destination: ./Externals

I then de-incremented the build number and tried an actual update on Mac but got an error when it tried to install the update: Error code: 3001 Reason: The update is improperly signed

Since I knew that updating with the previous app updater had been working fine, I re-codesigned my test app with AppWrapper and tried again and that worked fine. I'm guessing something isn't getting codesigned or not properly anyway when building with Levure?

trevordevore
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 1005
Joined: Sat Apr 08, 2006 3:06 pm
Location: Overland Park, Kansas
Contact:

Re: App Updater helper for Levure

Post by trevordevore » Fri Jul 24, 2020 4:16 pm

@martyknapp - It sounds like you downloaded the latest from master from the levurehelper-app_updater helper rather than the latest release which was 0.6.6. For some reason I had pushed some updates to master which weren't released yet and should have been on a develop branch. I've pushed a version 0.6.7 which is available from the releases page:

https://github.com/trevordevore/levureh ... r/releases

As you have already discovered, 0.6.7 includes this change:
The Sparkle.framework and WinSparke.dll libraries are now automatically packaged. Your app.yml file should no longer include macos and windows keys to copy files which copy /helpers/app_updater/code/x86_64-mac/Sparkle.framework and ./helpers/app_updater/code/x86-win32/WinSparkle.dll to the ./Externals folder.
You must use Levure 0.9.5 (I just published that release as well) with 0.6.7 of the app updater. Levure adds some functionality which simplifies the use of code libraries with helpers and support for 32 and 64-bit code libraries. You can read about those changes in the 0.9.4 and 0.9.5 release notes:

https://github.com/trevordevore/levure/ ... g/v0.9.4.0

https://github.com/trevordevore/levure/ ... g/v0.9.5.0

That leaves us with the code signing problem. I haven't experienced any problems with code signing. If you look at the build.log file do you see any error messages?
Trevor DeVore
ScreenSteps - https://www.screensteps.com

LiveCode Repos - https://github.com/search?q=user%3Atrevordevore+topic:livecode
LiveCode Builder Repos - https://github.com/search?q=user%3Atrevordevore+topic:livecode-builder

martyknapp
Posts: 52
Joined: Fri Mar 24, 2006 5:33 pm
Location: Blaine, Washington - USA

Re: App Updater helper for Levure

Post by martyknapp » Fri Jul 24, 2020 6:51 pm

I've updated to the latest versions of Levure and app updater. I am building successfully. I can look in the Mac app bundle and see that it is code signed but when I run it and try to update I get "Error code: 3001" error "Reason: The update is improperly signed." If I then go back and redo the codesign with AppWrapper, I can run the app and update with no errors. I looked in the build log and see no errors.

I have an app I found somewhere named "CodesSignChecker." When I try that on my original build it shows an error of "invalid info.plist (it's been modified)." When I check my re-codesigned app with "CodesSignChecker" it shows as good.

In AppWrapper, after a successful codesign it shows that it fixed a few things (codesigned them) and I've attached a screenshot of that.
Attachments
AppWrapper Fixes.png
screenshot from AppWrapper

trevordevore
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 1005
Joined: Sat Apr 08, 2006 3:06 pm
Location: Overland Park, Kansas
Contact:

Re: App Updater helper for Levure

Post by trevordevore » Sat Jul 25, 2020 6:48 am

I just created a new Levure app and added the app_updater helper to it. I successfully packaged the app using `levurePackageApplication "release"` and then checked that it was properly code signed using this command:

Code: Select all

spctl --assess --verbose --ignore-cache --type execute -v /path/to/Test\ Signing.app
The output looked like this:

Code: Select all

/Users/USERNAME/Test Signing/builds/release/0.0.1-1/macos/Test Signing.app: accepted
source=Developer ID
origin=Developer ID Application: CERT_NAME (ID...)
When you say that you "de-incremented the build number" to test auto updating how did you do that? Did you modify the plist file of the packaged app? If so then that would explain the error that CodeSignChecker is returning.
Trevor DeVore
ScreenSteps - https://www.screensteps.com

LiveCode Repos - https://github.com/search?q=user%3Atrevordevore+topic:livecode
LiveCode Builder Repos - https://github.com/search?q=user%3Atrevordevore+topic:livecode-builder

martyknapp
Posts: 52
Joined: Fri Mar 24, 2006 5:33 pm
Location: Blaine, Washington - USA

Re: App Updater helper for Levure

Post by martyknapp » Sun Jul 26, 2020 1:50 am

I just mean that I built it with a previous version number so I could test with the currently uploaded update app. This is an existing "live" app and don't want to update with an untested configuration. I did not touch the plist after building the app. Of course it was modified before the build with the additions needed for app updater.

When I check the codesign with terminal I get:
invalid Info.plist (plist or signature have been modified)

After I re-codesign with AppWrapper it shows that it was "accepted"

Perhaps there is something amiss with my plist file in its current configuration?

martyknapp
Posts: 52
Joined: Fri Mar 24, 2006 5:33 pm
Location: Blaine, Washington - USA

Re: App Updater helper for Levure

Post by martyknapp » Wed May 19, 2021 7:08 pm

With the latest version of LC 9.6.2 stable I'm having some issues with the app updater module. Occasionally (but not always) I'm getting time out errors when the app starts up and checks for an update. I'm seeing this on both Mac (Mojave) and Windows 10. On Mac I get "Error code: 1002 Reason: The request timed out." When I build with previous versions of LC, I'm not seeing this.

mwieder
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3581
Joined: Mon Jan 22, 2007 7:36 am
Location: Berkeley, CA, US
Contact:

Re: App Updater helper for Levure

Post by mwieder » Mon Jul 19, 2021 2:17 am

Marty-

I just submitted a one-line PR to libURL that may have some bearing on this. I'm not expecting the pull request to be accepted any time soon, but you might try patching your copy of revlibURL.livecodescript with this patch to see if it helps.

https://github.com/livecode/livecode/pull/7595

In short, once you initiate a socket connection through libURL, a ulTickleMe message is issued once a second. In theory once the libURL command finishes the ulTickleMe message is no longer issued. But if you have any other sockets open the once-per-second messages will continue. I found this problem when I had an "accept connections" message and then issued a "get url" message.

You can check to see if this is a problem by opening the messagebox and typing "put the pendingmessages".

martyknapp
Posts: 52
Joined: Fri Mar 24, 2006 5:33 pm
Location: Blaine, Washington - USA

Re: App Updater helper for Levure

Post by martyknapp » Mon Jul 19, 2021 5:29 pm

Thanks Mark!

Locked

Return to “Community Projects”