Post

Replies

Boosts

Views

Activity

Reply to AppIntentsPackage protocol with SPM package not working
+1. I have roughly the same setup except I'm using a dynamic framework instead of a SPM package. I got the same error when I reference my AppIntent in a AppShortcutsProvider. Weirdly enough I just discovered that prefixing all the AppShortcut types with AppIntents fixed the issue for me. import AppIntents import MyIntentsFramework struct MyShortcutsProvider: AppShortcutsProvider { static var appShortcuts: [AppIntents.AppShortcut] { AppIntents.AppShortcut( intent: MyAppIntent(), phrases: ["Open \(.applicationName)"], shortTitle: "Title", systemImageName: "plus" ) } }
Jun ’23
Reply to AppIntentsPackage protocol with SPM package not working
Agree, I'm seeing the same thing here. It looks like prefixing AppIntents. in the shortcut provider actually just hides the shortcuts entirely from the metadata parser. if you look at the built Metadata.appintents/extract.actionsdata in derived data, it's clear the AppShortcutsProvider is detected correctly but that the intents, entities, and queries are not detected from the underlying package / framework. Assuming a beta bug with the package intent re-exporting at this point, too.
Jun ’23
Reply to AppIntentsPackage protocol with SPM package not working
As far as I can tell, reexporting an AppIntent defined in a framework using AppIntentsPackage and includedPackages has never worked since it was introduced at WWDC23. @gohnjanotis @alexanderwe I believe the only solution is to add your app intents directly to your app target and also any other extension target that uses them, I was able to get my shortcuts showing up in Shortcuts doing this. Unfortunately this workaround wouldn't work for an AppIntent defined in an SPM package like in the original question prompt.
Sep ’23