MobileNativeFoundation / rules_xcodeproj

Bazel rules for generating Xcode projects.
MIT License
521 stars 83 forks source link

Bug: Xcode Previews failing in extensions #2997

Closed andre-alves closed 5 months ago

andre-alves commented 6 months ago

Description

I'm not sure if it's a recent regression or not, but Xcode Previews is not working with extensions:

The app extension ”WidgetExtension.appex” needs to be embedded in an app in order to use previews
image

Reproduction steps

It's possible to reproduce using the integration example without any changes:

Expected behavior

Xcode Previews to display.

rules_xcodeproj version

main (de3089fd2612fc97299e87955975e1dc34049b67)

Xcode version

15.2

Bazel version

7.1.0

rules_apple version

3.5.0

rules_swift version

1.18.0

Additional information

No response

andre-alves commented 6 months ago

Got it! Xcode Previews just need explicit dependency between the app and the extension to work.

Target Dependencies Xcode Previews
Screenshot 2024-04-06 at 11 45 37 Screenshot 2024-04-06 at 11 38 34

Draft with possible fix: https://github.com/MobileNativeFoundation/rules_xcodeproj/pull/2999

brentleyjones commented 5 months ago

@andre-alves Can you verify that #3005 fixes this for you?