Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Release Tooling] Only embed bundles containing privacy manifests #12324

Merged
merged 2 commits into from
Jan 28, 2024

Conversation

ncooke3
Copy link
Member

@ncooke3 ncooke3 commented Jan 27, 2024

Xcode 14 friendly version of #12114.

The first commit was something I had stashed a few weeks back. Revisiting it now, I simplified it with the file enumerator approach.

FirebaseInAppMessaging.xcframework
├── Info.plist
├── Resources ← 🎯 Non-privacy manifest bundles are NOT embedded for Xcode 14 users.
│   └── InAppMessagingDisplayResources.bundle
│       ├── FIRInAppMessageDisplayStoryboard.storyboard
│       │   ├── Info.plist
│       │   ├── banner-view-vc.nib
│       │   ├── card-view-vc.nib
│       │   ├── image-only-vc.nib
│       │   ├── lGH-bl-7Xw-view-ef6-R8-q1S.nib
│       │   ├── lbb-HM-tHJ-view-vRb-yf-OWE.nib
│       │   ├── modal-view-vc.nib
│       │   ├── oTF-1C-LZP-view-SM1-hn-m3n.nib
│       │   └── x01-lq-3r6-view-1pz-BP-O6T.nib
│       ├── Info.plist
│       ├── close-with-transparency.png
│       └── [email protected]
├── ios-arm64
│   └── FirebaseInAppMessaging.framework
│       ├── FirebaseInAppMessaging
│       ├── FirebaseInAppMessaging_Privacy.bundle  ← 🎯 Privacy manifest bundles are embedded.
│       │   ├── Info.plist
│       │   └── PrivacyInfo.xcprivacy
│       ├── Headers
│       │   ├── FIRInAppMessaging.h
│       │   ├── FIRInAppMessagingRendering.h
│       │   ├── FirebaseInAppMessaging-Swift.h
│       │   ├── FirebaseInAppMessaging-umbrella.h
│       │   └── FirebaseInAppMessaging.h
│       └── Modules
│           ├── FirebaseInAppMessaging.swiftmodule
│           │   ├── Project
│           │   │   └── arm64-apple-ios.swiftsourceinfo
│           │   ├── arm64-apple-ios.abi.json
│           │   ├── arm64-apple-ios.private.swiftinterface
│           │   ├── arm64-apple-ios.swiftdoc
│           │   └── arm64-apple-ios.swiftinterface
│           └── module.modulemap

@google-oss-bot
Copy link

1 Warning
⚠️ Did you forget to add a changelog entry? (Add #no-changelog to the PR description to silence this warning.)

Generated by 🚫 Danger

@ncooke3
Copy link
Member Author

ncooke3 commented Jan 27, 2024

Zip built successfully locally.

Verified that the three existing bundles are still packed in their own resources directory, with the GTM session fetcher directories being embedded:

find . -path '*.bundle' | tree --fromfile /dev/stdin
/dev/stdin
└── .
    ├── FirebaseAuth
    │   └── GTMSessionFetcher.xcframework
    │       ├── ios-arm64
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       ├── ios-arm64_x86_64-maccatalyst
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       ├── ios-arm64_x86_64-simulator
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       ├── macos-arm64_x86_64
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       ├── tvos-arm64
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       └── tvos-arm64_x86_64-simulator
    │           └── GTMSessionFetcher.framework
    │               └── GTMSessionFetcher_Core_Privacy.bundle
    ├── FirebaseFirestore
    │   └── Resources
    │       └── gRPCCertificates-Cpp.bundle
    ├── FirebaseFunctions
    │   └── GTMSessionFetcher.xcframework
    │       ├── ios-arm64
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       ├── ios-arm64_x86_64-maccatalyst
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       ├── ios-arm64_x86_64-simulator
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       ├── macos-arm64_x86_64
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       ├── tvos-arm64
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       └── tvos-arm64_x86_64-simulator
    │           └── GTMSessionFetcher.framework
    │               └── GTMSessionFetcher_Core_Privacy.bundle
    ├── FirebaseInAppMessaging
    │   └── Resources
    │       └── InAppMessagingDisplayResources.bundle
    ├── FirebaseStorage
    │   └── GTMSessionFetcher.xcframework
    │       ├── ios-arm64
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       ├── ios-arm64_x86_64-maccatalyst
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       ├── ios-arm64_x86_64-simulator
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       ├── macos-arm64_x86_64
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       ├── tvos-arm64
    │       │   └── GTMSessionFetcher.framework
    │       │       └── GTMSessionFetcher_Core_Privacy.bundle
    │       └── tvos-arm64_x86_64-simulator
    │           └── GTMSessionFetcher.framework
    │               └── GTMSessionFetcher_Core_Privacy.bundle
    └── GoogleSignIn
        ├── GTMSessionFetcher.xcframework
        │   ├── ios-arm64
        │   │   └── GTMSessionFetcher.framework
        │   │       └── GTMSessionFetcher_Core_Privacy.bundle
        │   ├── ios-arm64_x86_64-maccatalyst
        │   │   └── GTMSessionFetcher.framework
        │   │       └── GTMSessionFetcher_Core_Privacy.bundle
        │   ├── ios-arm64_x86_64-simulator
        │   │   └── GTMSessionFetcher.framework
        │   │       └── GTMSessionFetcher_Core_Privacy.bundle
        │   ├── macos-arm64_x86_64
        │   │   └── GTMSessionFetcher.framework
        │   │       └── GTMSessionFetcher_Core_Privacy.bundle
        │   ├── tvos-arm64
        │   │   └── GTMSessionFetcher.framework
        │   │       └── GTMSessionFetcher_Core_Privacy.bundle
        │   └── tvos-arm64_x86_64-simulator
        │       └── GTMSessionFetcher.framework
        │           └── GTMSessionFetcher_Core_Privacy.bundle
        └── Resources
            └── GoogleSignIn.bundle

63 directories, 27 files

Copy link
Member

@paulb777 paulb777 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does the README with instructions about resources need to be updated?

@ncooke3
Copy link
Member Author

ncooke3 commented Jan 28, 2024

Does the README with instructions about resources need to be updated?

No. Eventually, we will want to recommend zip users to embed frameworks so their apps include the privacy manifests. I'd like to better understand https://stackoverflow.com/questions/77888962/issue-trying-to-run-app-on-ios-simulator-missing-a-plist-from-firebase before adding those docs. Because if that issue is widespread, we may have to add plists back– which will cause issues when embedding and will require a different approach/docs.

@ncooke3 ncooke3 merged commit 4914cc2 into main Jan 28, 2024
59 checks passed
@ncooke3 ncooke3 deleted the nc/bundle-resources-in-framework-3 branch January 28, 2024 00:24
ncooke3 added a commit that referenced this pull request Feb 19, 2024
@firebase firebase locked and limited conversation to collaborators Feb 27, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants