Skip to content

flutter_tools: correct iOS signing log for manual code signing (CODE_SIGN_STYLE=Manual)#177852

Merged
auto-submit[bot] merged 3 commits into
flutter:masterfrom
MohammedTarigg:fix-ios-signing-log-clean
Nov 13, 2025
Merged

flutter_tools: correct iOS signing log for manual code signing (CODE_SIGN_STYLE=Manual)#177852
auto-submit[bot] merged 3 commits into
flutter:masterfrom
MohammedTarigg:fix-ios-signing-log-clean

Conversation

@MohammedTarigg

@MohammedTarigg MohammedTarigg commented Oct 31, 2025

Copy link
Copy Markdown
Contributor

Summary

When running flutter build ipa with a project that uses manual code signing (CODE_SIGN_STYLE=Manual) for Release/Profile, the tool currently prints:

Automatically signing iOS for device deployment using specified development team in Xcode project: x

This is misleading in two ways:

  1. The project is not using automatic signing for Release/Profile, it's explicitly using manual signing with a provisioning profile.
  2. The build in this mode is typically for App Store/TestFlight distribution, not just device deployment.

Users who rely on manual signing (for example, Push Notifications + Sign in with Apple entitlements) often hit an xcodebuild -exportArchive failure later ("Runner.app" requires a provisioning profile ...) and assume Flutter overrode their signing, because of this log line. This confusion has been reported in the context of flutter build ipa where archive succeeds but export fails, and Flutter's messaging doesn't match the actual signing setup.

Related issues:

What this change does

  • Before logging "Automatically signing iOS ...", we now check the active build configuration's CODE_SIGN_STYLE.
  • If the style is Manual, we suppress the automatic-signing message (since manual signing is not automatic).
  • If the style is Automatic or not set, we keep the original behavior.
  • No functional behavior of signing or export is changed.

Before

Automatically signing iOS for device deployment using specified development team in Xcode project: x

(This message appears even when CODE_SIGN_STYLE=Manual)

After

(No message when CODE_SIGN_STYLE=Manual, since signing is not automatic)

(The message only appears when CODE_SIGN_STYLE=Automatic or not set)

Tests

  • Added test in packages/flutter_tools/test/general.shard/ios/code_signing_test.dart to assert we don't emit the automatic-signing message when CODE_SIGN_STYLE=Manual.
  • All existing tests pass (40/40 tests in code_signing_test.dart).

Why this helps

  • Reduces confusion around manual signing / App Store export flows.
  • Matches expectations from users who configure provisioning profiles manually and expect Flutter to respect that configuration.
  • Prevents users from thinking Flutter is overriding their manual signing setup based on misleading log output.

Breaking Changes

None. This change only affects log output and does not modify any signing behavior, export behavior, or CLI interface.

Verification

Reviewers can verify this fix by:

  1. Creating a test iOS project with CODE_SIGN_STYLE=Manual and DEVELOPMENT_TEAM set in Xcode project settings
  2. Running flutter build ipa --release --verbose
  3. Confirming the log does NOT show "Automatically signing iOS..."
  4. Verifying the app still builds/signs correctly

The included unit test covers this scenario automatically.


Supersedes #177851 (that PR accidentally included unrelated commits from my fork history). This version only includes the intended change and tests.

@MohammedTarigg MohammedTarigg requested a review from a team as a code owner October 31, 2025 18:10
@google-cla

google-cla Bot commented Oct 31, 2025

Copy link
Copy Markdown

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@github-actions github-actions Bot added platform-ios iOS applications specifically tool Affects the "flutter" command-line tool. See also t: labels. team-ios Owned by iOS platform team labels Oct 31, 2025

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request corrects a misleading log message that appeared during iOS builds using manual code signing. The change adds a condition to check the CODE_SIGN_STYLE from the build settings. If the style is 'Manual', it correctly suppresses the 'Automatically signing...' log. This is a good improvement as it reduces user confusion. A new test is included to verify that the log message is not displayed for manual signing setups, ensuring the fix is effective. The implementation is straightforward and the changes look good.

@MohammedTarigg

Copy link
Copy Markdown
Contributor Author

CLA signed

@MohammedTarigg

Copy link
Copy Markdown
Contributor Author

CI Status Follow-up

I see the ci.yaml validation check is failing. Since this PR only modifies:

  • packages/flutter_tools/lib/src/ios/code_signing.dart (logging logic)
  • packages/flutter_tools/test/general.shard/ios/code_signing_test.dart (unit test)

This appears unrelated to ci.yaml configuration. Could the maintainers please review the ci.yaml failure to determine if it's a check issue or requires action on my end?

All other checks (CLA, code review) are passing. The fix is minimal, focused, and includes test coverage.

@MohammedTarigg MohammedTarigg force-pushed the fix-ios-signing-log-clean branch 2 times, most recently from aca02ed to a8bbfd5 Compare October 31, 2025 22:21
Comment thread packages/flutter_tools/test/general.shard/ios/code_signing_test.dart Outdated
MohammedTarigg and others added 3 commits November 8, 2025 13:24
…nual

When DEVELOPMENT_TEAM is set in the Xcode project but CODE_SIGN_STYLE
is Manual, Flutter was still logging 'Automatically signing iOS...'
which is misleading since manual signing is not automatic.

This change checks CODE_SIGN_STYLE before logging the automatic signing
message. If it's Manual, no message is logged (or a more accurate
message could be logged in the future).

Fixes the misleading log output for users who use manual code signing
with ExportOptions.plist for App Store distribution.
…t.dart


test(code_signing): assert manual signing does NOT log "Automatically signing..."

Co-authored-by: Navaron Bracke <brackenavaron@gmail.com>
…=Manual test

Addresses reviewer feedback to explicitly test that the misleading
'Auto signing iOS...' message is not present, rather than just checking
isEmpty. Uses single quotes and proper formatting.
@MohammedTarigg MohammedTarigg force-pushed the fix-ios-signing-log-clean branch from df4408b to 6ebb110 Compare November 8, 2025 10:24
@vashworth vashworth requested a review from LouiseHsu November 13, 2025 15:47
@vashworth

Copy link
Copy Markdown
Contributor

@LouiseHsu Can you do a second review?

@LouiseHsu LouiseHsu added the autosubmit Merge PR when tree becomes green via auto submit App label Nov 13, 2025
@auto-submit auto-submit Bot added this pull request to the merge queue Nov 13, 2025
Merged via the queue into flutter:master with commit e98205f Nov 13, 2025
145 of 146 checks passed
@flutter-dashboard flutter-dashboard Bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Nov 13, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 14, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 14, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 14, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 14, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 15, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 15, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 16, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 16, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 16, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 17, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 17, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 17, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 17, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 17, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 17, 2025
IvoneDjaja pushed a commit to IvoneDjaja/flutter that referenced this pull request Nov 22, 2025
…SIGN_STYLE=Manual) (flutter#177852)

## Summary

When running `flutter build ipa` with a project that uses manual code
signing (`CODE_SIGN_STYLE=Manual`) for Release/Profile, the tool
currently prints:

```
Automatically signing iOS for device deployment using specified development team in Xcode project: x
```

This is misleading in two ways:

1. The project is not using automatic signing for Release/Profile, it's
explicitly using manual signing with a provisioning profile.
2. The build in this mode is typically for App Store/TestFlight
distribution, not just device deployment.

Users who rely on manual signing (for example, Push Notifications + Sign
in with Apple entitlements) often hit an `xcodebuild -exportArchive`
failure later (`"Runner.app" requires a provisioning profile ...`) and
assume Flutter overrode their signing, because of this log line. This
confusion has been reported in the context of `flutter build ipa` where
archive succeeds but export fails, and Flutter's messaging doesn't match
the actual signing setup.

**Related issues:**
- flutter#106612 - Support `flutter build ipa` with manual signing and
provisioning profiles
- flutter#113977 - Flutter build IPA with --export-options-plist not working

## What this change does

* Before logging "Automatically signing iOS ...", we now check the
active build configuration's `CODE_SIGN_STYLE`.
* If the style is `Manual`, we suppress the automatic-signing message
(since manual signing is not automatic).
* If the style is `Automatic` or not set, we keep the original behavior.
* No functional behavior of signing or export is changed.

## Before

```
Automatically signing iOS for device deployment using specified development team in Xcode project: x
```

(This message appears even when `CODE_SIGN_STYLE=Manual`)

## After

```
(No message when CODE_SIGN_STYLE=Manual, since signing is not automatic)
```

(The message only appears when `CODE_SIGN_STYLE=Automatic` or not set)

## Tests

* Added test in
`packages/flutter_tools/test/general.shard/ios/code_signing_test.dart`
to assert we don't emit the automatic-signing message when
`CODE_SIGN_STYLE=Manual`.
* All existing tests pass (40/40 tests in code_signing_test.dart).

## Why this helps

* Reduces confusion around manual signing / App Store export flows.
* Matches expectations from users who configure provisioning profiles
manually and expect Flutter to respect that configuration.
* Prevents users from thinking Flutter is overriding their manual
signing setup based on misleading log output.

## Breaking Changes

None. This change only affects log output and does not modify any
signing behavior, export behavior, or CLI interface.

## Verification

Reviewers can verify this fix by:
1. Creating a test iOS project with `CODE_SIGN_STYLE=Manual` and
`DEVELOPMENT_TEAM` set in Xcode project settings
2. Running `flutter build ipa --release --verbose`
3. Confirming the log does NOT show "Automatically signing iOS..."
4. Verifying the app still builds/signs correctly

The included unit test covers this scenario automatically.

---

Supersedes flutter#177851 (that PR accidentally included unrelated commits from
my fork history). This version only includes the intended change and
tests.

---------

Co-authored-by: Navaron Bracke <brackenavaron@gmail.com>
mboetger pushed a commit to mboetger/flutter that referenced this pull request Dec 2, 2025
…SIGN_STYLE=Manual) (flutter#177852)

## Summary

When running `flutter build ipa` with a project that uses manual code
signing (`CODE_SIGN_STYLE=Manual`) for Release/Profile, the tool
currently prints:

```
Automatically signing iOS for device deployment using specified development team in Xcode project: x
```

This is misleading in two ways:

1. The project is not using automatic signing for Release/Profile, it's
explicitly using manual signing with a provisioning profile.
2. The build in this mode is typically for App Store/TestFlight
distribution, not just device deployment.

Users who rely on manual signing (for example, Push Notifications + Sign
in with Apple entitlements) often hit an `xcodebuild -exportArchive`
failure later (`"Runner.app" requires a provisioning profile ...`) and
assume Flutter overrode their signing, because of this log line. This
confusion has been reported in the context of `flutter build ipa` where
archive succeeds but export fails, and Flutter's messaging doesn't match
the actual signing setup.

**Related issues:**
- flutter#106612 - Support `flutter build ipa` with manual signing and
provisioning profiles
- flutter#113977 - Flutter build IPA with --export-options-plist not working

## What this change does

* Before logging "Automatically signing iOS ...", we now check the
active build configuration's `CODE_SIGN_STYLE`.
* If the style is `Manual`, we suppress the automatic-signing message
(since manual signing is not automatic).
* If the style is `Automatic` or not set, we keep the original behavior.
* No functional behavior of signing or export is changed.

## Before

```
Automatically signing iOS for device deployment using specified development team in Xcode project: x
```

(This message appears even when `CODE_SIGN_STYLE=Manual`)

## After

```
(No message when CODE_SIGN_STYLE=Manual, since signing is not automatic)
```

(The message only appears when `CODE_SIGN_STYLE=Automatic` or not set)

## Tests

* Added test in
`packages/flutter_tools/test/general.shard/ios/code_signing_test.dart`
to assert we don't emit the automatic-signing message when
`CODE_SIGN_STYLE=Manual`.
* All existing tests pass (40/40 tests in code_signing_test.dart).

## Why this helps

* Reduces confusion around manual signing / App Store export flows.
* Matches expectations from users who configure provisioning profiles
manually and expect Flutter to respect that configuration.
* Prevents users from thinking Flutter is overriding their manual
signing setup based on misleading log output.

## Breaking Changes

None. This change only affects log output and does not modify any
signing behavior, export behavior, or CLI interface.

## Verification

Reviewers can verify this fix by:
1. Creating a test iOS project with `CODE_SIGN_STYLE=Manual` and
`DEVELOPMENT_TEAM` set in Xcode project settings
2. Running `flutter build ipa --release --verbose`
3. Confirming the log does NOT show "Automatically signing iOS..."
4. Verifying the app still builds/signs correctly

The included unit test covers this scenario automatically.

---

Supersedes flutter#177851 (that PR accidentally included unrelated commits from
my fork history). This version only includes the intended change and
tests.

---------

Co-authored-by: Navaron Bracke <brackenavaron@gmail.com>
reidbaker pushed a commit to AbdeMohlbi/flutter that referenced this pull request Dec 10, 2025
…SIGN_STYLE=Manual) (flutter#177852)

## Summary

When running `flutter build ipa` with a project that uses manual code
signing (`CODE_SIGN_STYLE=Manual`) for Release/Profile, the tool
currently prints:

```
Automatically signing iOS for device deployment using specified development team in Xcode project: x
```

This is misleading in two ways:

1. The project is not using automatic signing for Release/Profile, it's
explicitly using manual signing with a provisioning profile.
2. The build in this mode is typically for App Store/TestFlight
distribution, not just device deployment.

Users who rely on manual signing (for example, Push Notifications + Sign
in with Apple entitlements) often hit an `xcodebuild -exportArchive`
failure later (`"Runner.app" requires a provisioning profile ...`) and
assume Flutter overrode their signing, because of this log line. This
confusion has been reported in the context of `flutter build ipa` where
archive succeeds but export fails, and Flutter's messaging doesn't match
the actual signing setup.

**Related issues:**
- flutter#106612 - Support `flutter build ipa` with manual signing and
provisioning profiles
- flutter#113977 - Flutter build IPA with --export-options-plist not working

## What this change does

* Before logging "Automatically signing iOS ...", we now check the
active build configuration's `CODE_SIGN_STYLE`.
* If the style is `Manual`, we suppress the automatic-signing message
(since manual signing is not automatic).
* If the style is `Automatic` or not set, we keep the original behavior.
* No functional behavior of signing or export is changed.

## Before

```
Automatically signing iOS for device deployment using specified development team in Xcode project: x
```

(This message appears even when `CODE_SIGN_STYLE=Manual`)

## After

```
(No message when CODE_SIGN_STYLE=Manual, since signing is not automatic)
```

(The message only appears when `CODE_SIGN_STYLE=Automatic` or not set)

## Tests

* Added test in
`packages/flutter_tools/test/general.shard/ios/code_signing_test.dart`
to assert we don't emit the automatic-signing message when
`CODE_SIGN_STYLE=Manual`.
* All existing tests pass (40/40 tests in code_signing_test.dart).

## Why this helps

* Reduces confusion around manual signing / App Store export flows.
* Matches expectations from users who configure provisioning profiles
manually and expect Flutter to respect that configuration.
* Prevents users from thinking Flutter is overriding their manual
signing setup based on misleading log output.

## Breaking Changes

None. This change only affects log output and does not modify any
signing behavior, export behavior, or CLI interface.

## Verification

Reviewers can verify this fix by:
1. Creating a test iOS project with `CODE_SIGN_STYLE=Manual` and
`DEVELOPMENT_TEAM` set in Xcode project settings
2. Running `flutter build ipa --release --verbose`
3. Confirming the log does NOT show "Automatically signing iOS..."
4. Verifying the app still builds/signs correctly

The included unit test covers this scenario automatically.

---

Supersedes flutter#177851 (that PR accidentally included unrelated commits from
my fork history). This version only includes the intended change and
tests.

---------

Co-authored-by: Navaron Bracke <brackenavaron@gmail.com>
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

platform-ios iOS applications specifically team-ios Owned by iOS platform team tool Affects the "flutter" command-line tool. See also t: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants