The compiler throws an error Unable to determine value type for type IntentPackage.Shelf.
According to comments in this question it's because the type I'm extending to AppEnum is not in the app target's module, but in a Swift Package.
I really don't like having to duplicate the types just to make it work and was wondering if I'm missing something.
It does seem that moving your Shelf type into the main project solves the issue.
Exactly. That would solve it, but I'd really prefer a cleaner way if there is one.
(Usually I'm just making a mistake somewhere, so I wanted to check.)
I ran your project and had the same. I experimented with moving OpenShelf into the package and building. But then the intent would no longer work. I suspect this is all expected and agree moving your Shelf type is the way to resolve.
I tried putting your Shelf type in the external Package inside a type that conformed to AppIntentsPackage then in the main app defining a type that conforms to AppIntentsPackage and gave it an includedPackages property that listed that IntentsPackage from the external package, but the compiler still complained about 'Unable to determine value type for type '.
Googling for that specific error yields very few results, all about the same issue (which are either your posts, or the SO post that you linked above.)
I thought I was going crazy with this issue, glad to hear it's not just me. This bug also happens to classes, not just enums. @martin.p do you have a link to the radar so I can add that information?