Files
buzz/mobile/ios/Runner.xcodeproj/xcshareddata/xcschemes
Tom Brow 148585c804 build(mobile): link iOS plugins through Swift Package Manager (#9597)
## Summary

The iOS app stops opting out of Flutter's Swift Package Manager
integration. The 19 iOS plugins that ship a Swift package are now linked
through it. The three that don't (`google_mlkit_commons`,
`google_mlkit_selfie_segmentation` and `open_filex`) keep installing
through CocoaPods, which Flutter supports side by side.

Why now:

- CocoaPods is winding down: its spec repo [becomes read-only on
December 2, 2026](https://blog.cocoapods.org/CocoaPods-Specs-Repo/), and
plugin releases have started to ship as Swift packages only. Staying
opted out pins those plugins at their last CocoaPods release.
- The opt-out dates from the Flutter 3.47 upgrade (#8419), which kept
the existing CocoaPods integration. With it removed, the app builds and
runs as before.

What is in the diff:

- `pubspec.yaml`: the opt-out is removed.
- `project.pbxproj` and `Runner.xcscheme`: the edits Flutter's own tool
makes on the first build with the integration on (a local reference to
its generated plugin package, and a scheme pre-action that prepares the
Flutter framework). They are committed so a build does not dirty the
tree.
- `Podfile.lock`: only the three CocoaPods plugins and their
dependencies remain.

No Dart code, plugin version or remote Swift package changes. All 19
packages resolve to local paths in the pub cache, so `Package.resolved`
is untouched and builds fetch nothing new.

### Related issue

N/A. No existing issue or PR for this was found.

### Regressions

- **App behavior:** the same plugin code at the same versions. The 19
plugins are linked statically into the app binary instead of embedded as
dynamic frameworks, which leaves fewer libraries to load at launch and a
slightly smaller app (numbers below). One resource bundle is lost; see
the second accepted tradeoff.
- **Extensions:** the notification service extension links no plugins,
so it is unchanged.
- **Build and release:** CocoaPods is still required for the three
remaining plugins, so the Podfile, its post-install steps and the
release tooling are unchanged. The first build after this change spends
about 17 extra seconds adding the integration.
- **Accepted tradeoff, build warning:** Flutter now prints a warning
naming the three plugins without Swift packages. It goes away when those
plugins add support or are replaced.
- **Accepted tradeoff, one privacy manifest dropped:** the app no longer
bundles `app_badge_plus`'s privacy manifest, and Xcode prints `Invalid
Resource 'Resources': File not found` for it. Version 1.2.10's Swift
package looks for `Resources` under its source directory, but the
manifest sits at the package root, so the Swift package bundles nothing
where the podspec bundled it. This is harmless: that manifest declares
only UserDefaults access, and the plugin's single source file never
touches UserDefaults. The other 16 plugin privacy manifests are still in
the release app. Fixing it means a plugin bump, which is left out of
this PR.
- **Android:** unaffected.

### Validation

Unsigned release build, this branch against unmodified `main`:

| | `main` | This branch |
| --- | --- | --- |
| App size | 87.0 MB | 85.6 MB |
| Embedded frameworks | 31 | 12 |

Focused existing validation: the three iOS steps CI runs (simulator
debug build, the 116 native `RunnerTests`, and the unsigned release
build) pass locally.

Full-app run on an iOS 27 simulator (iPhone 17 Pro), driven by an agent,
with the debug build from this branch installed over an existing
signed-in install:

- The app stayed signed in and loaded its channel list and message
history (keychain, preferences and local storage plugins).
- Photo library picker, attaching a photo, and sending a video, which
uploaded and played back.
- Image viewer, the share sheet, and saving an image to Photos.
- The file picker, and the camera and microphone permission prompts.
- A link in a message opened in the browser, and a `buzz://` deep link
reached the app.

Two failures showed up and both reproduce identically on unmodified
`main` on the same simulator, so neither comes from this change: a
recorded voice note is empty because the host Mac has no microphone, and
saving an image adds it to Photos but then reports "Could not save
image".

Limits: no physical device run. Camera capture, QR scanning, selfie
segmentation and biometric prompts cannot be exercised on a simulator.
Voice note playback was not exercised.

Human testing is waived for this PR under the author's standing policy
for mobile changes; the agent-driven run above stands in for it.

Signed-off-by: Tom Brow <tomb@squareup.com>
Co-authored-by: Tom Brow <tomb@squareup.com>
Co-authored-by: judge <7615ec4b7ddf99f0bb48e913297f99f8f772d289a1c9ef54e1d906dd55a93ba8@buzz.block.builderlab.xyz>
2026-11-17 10:11:28 -07:00
..