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

I cannot build the iOS Test app with CI/CD, always throw Provisioning profile issue #2430

Closed
radyhaggag opened this issue Nov 24, 2024 · 5 comments
Assignees
Labels
platform: ios iOS is affected

Comments

@radyhaggag
Copy link

Steps to reproduce

I created a profile for the test target one for development and one for app-store, and all of them failed to build iOS app to use it with firebase test lab.

I'm using fastlane and GitHub Actions, and i used fastlane match to create the profiles.

Actual results

Always get the following error:

/Users/runner/work/taaly-staging2/taaly-staging2/ios/Runner.xcodeproj: error: Provisioning profile "match Development com.language.taaly.RunnerUITests" has app ID "com.language.taaly.RunnerUITests", which does not match the bundle ID "com.language.taaly.RunnerUITests.xctrunner". (in target 'RunnerUITests' from project 'Runner')

And i don't know what is "com.language.taaly.RunnerUITests.xctrunner" bundle-id.

How can i solve this?

Logs

Logs
[23:26:43]: All required keys, certificates and provisioning profiles are installed 🙌
[23:26:43]: Setting Provisioning Profile type to 'development'
[23:26:43]: --------------------------------------------------------------------
[23:26:43]: Step: patrol build ios --target integration_test/integration_test.dart --flavor staging --dart-define=ENVIRONMENT=staging --bundle-id=com.language.taaly.test --release -v
[23:27:34]: ▸ #6      PatrolCommandRunner.runCommand (package:patrol_cli/src/runner/patrol_command_runner.dart:366:18)
[23:27:34]: ▸ <asynchronous suspension>
[23:27:34]: ▸ #7      PatrolCommandRunner.run (package:patrol_cli/src/runner/patrol_command_runner.dart:310:18)
[23:27:34]: ▸ <asynchronous suspension>
[23:27:34]: ▸ #8      patrolCommandRunner (package:patrol_cli/src/runner/patrol_command_runner.dart:71:20)
[23:27:34]: ▸ <asynchronous suspension>
[23:27:34]: ▸ #9      main (file:///Users/runner/.pub-cache/hosted/pub.dev/patrol_cli-3.4.0/bin/main.dart:6:20)
[23:27:34]: ▸ <asynchronous suspension>
[23:27:34]: ▸ See the logs above to learn what happened. Also consider running with --verbose. If the logs still aren't useful, then it's a bug - please report it.
[23:27:34]: ▸ Error: xcodebuild exited with code 70
[23:27:34]: ▸ #0      throwToolExit (package:patrol_cli/src/base/exceptions.dart:7:3)
[23:27:34]: ▸ #1      IOSTestBackend.build.<anonymous closure> (package:patrol_cli/src/ios/ios_test_backend.dart:141:9)
[23:27:34]: ▸ <asynchronous suspension>
[23:27:34]: ▸ #2      DisposeScope.run (package:dispose_scope/src/dispose_scope.dart:46:7)
[23:27:34]: ▸ <asynchronous suspension>
[23:27:34]: ▸ #3      IOSTestBackend.build (package:patrol_cli/src/ios/ios_test_backend.dart:80:5)
[23:27:34]: ▸ <asynchronous suspension>
[23:27:34]: ▸ #4      BuildIOSCommand.run (package:patrol_cli/src/commands/build_ios.dart:164:7)
[23:27:34]: ▸ <asynchronous suspension>
[23:27:34]: ▸ #5      CommandRunner.runCommand (package:args/command_runner.dart:212:13)
[23:27:34]: ▸ <asynchronous suspension>
[23:27:34]: ▸ #6      PatrolCommandRunner.runCommand (package:patrol_cli/src/runner/patrol_command_runner.dart:366:18)
[23:27:34]: ▸ <asynchronous suspension>
[23:27:34]: ▸ #7      PatrolCommandRunner.run (package:patrol_cli/src/runner/patrol_command_runner.dart:310:18)
[23:27:34]: ▸ <asynchronous suspension>
[23:27:34]: ▸ #8      patrolCommandRunner (package:patrol_cli/src/runner/patrol_command_runner.dart:71:20)
[23:27:34]: ▸ <asynchronous suspension>
[23:27:34]: ▸ #9      main (file:///Users/runner/.pub-cache/hosted/pub.dev/patrol_cli-3.4.0/bin/main.dart:6:20)
[23:27:34]: ▸ <asynchronous suspension>
+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|                                                                                                                                                                                                                                Lane Context                                                                                                                                                                                                                                 |
+------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| DEFAULT_PLATFORM                   | ios                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| PLATFORM_NAME                      | ios                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| LANE_NAME                          | ios sync_code_for_dev_test_runner_and_build_tests                                                                                                                                                                                                                                                                                                                                                                                      |
| KEYCHAIN_PATH                      | ~/Library/Keychains/fastlane_tmp_keychain                                                                                                                                                                                                                                                                                                                                                                                              |
| ORIGINAL_DEFAULT_KEYCHAIN          | "/Users/runner/Library/Keychains/login.keychain-db"                                                                                                                                                                                                                                                                                                                                                                                    |
| SIGH_PROFILE_TYPE                  | development                                                                                                                                                                                                                                                                                                                                                                                                                            |
| MATCH_PROVISIONING_PROFILE_MAPPING | {"com.language.taaly.test"=>"match AppStore com.language.taaly.test", "com.language.taaly.test.taalynotifications"=>"match AppStore com.language.taaly.test.taalynotifications", "com.language.taaly"=>"match AppStore com.language.taaly", "com.language.taaly.taalynotifications"=>"match AppStore com.language.taaly.taalynotifications", "com.language.taaly.RunnerUITests"=>"match Development com.language.taaly.RunnerUITests"} |
+------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
[23:27:34]: Called from Fastfile at line 122
[23:27:34]: ```
[23:27:34]:     120:	    )
[23:27:34]:     121:	
[23:27:34]:  => 122:	    sh "patrol build ios --target integration_test/integration_test.dart --flavor staging --dart-define=ENVIRONMENT=staging --bundle-id=com.language.taaly.test --release -v"
[23:27:34]:     123:	  end
[23:27:34]:     124:	end
[23:27:34]: ```
[23:27:34]: Exit status of command 'patrol build ios --target integration_test/integration_test.dart --flavor staging --dart-define=ENVIRONMENT=staging --bundle-id=com.language.taaly.test --release -v' was 1 instead of 0.

Patrol version

patrol: ^3.13.0-dev.4

Patrol Doctor output

Patrol Doctor output
patrol doctor
Patrol doctor:
Patrol CLI version: 3.4.0
Flutter command: flutter 
  Flutter 3.24.5 • channel stable
Android: 
• Program adb found in /Users/radyhaggag/Library/Android/sdk/platform-tools/adb
• Env var $ANDROID_HOME set to /Users/radyhaggag/Library/Android/sdk
iOS / macOS: 
• Program xcodebuild found in /usr/bin/xcodebuild
• Program ideviceinstaller found in /opt/homebrew/bin/ideviceinstaller```

</details>


### Flutter Doctor output

<details>
<summary>Flutter Doctor output</summary>

patrol doctor --verbose
Verbose mode enabled. More logs will be printed.
Patrol doctor:
Patrol CLI version: 3.4.0
Flutter command: flutter
Flutter 3.24.5 • channel stable
Android:
• Program adb found in /Users/radyhaggag/Library/Android/sdk/platform-tools/adb
• Env var $ANDROID_HOME set to /Users/radyhaggag/Library/Android/sdk
iOS / macOS:
• Program xcodebuild found in /usr/bin/xcodebuild
• Program ideviceinstaller found in /opt/homebrew/bin/ideviceinstaller```

@radyhaggag
Copy link
Author

/Users/runner/work/taaly-staging2/taaly-staging2/ios/Runner.xcodeproj: error: Provisioning profile "match Development com.language.taaly.RunnerUITests" has app ID "com.language.taaly.RunnerUITests", which does not match the bundle ID "com.language.taaly.RunnerUITests.xctrunner". (in target 'RunnerUITests' from project 'Runner')

@radyhaggag
Copy link
Author

I noted that there are some old issues here related to this problem.

But it closed and they suggested to enable automatic code signing.

But i need it with ci/cd and fastlane & github actions.

@Kendru98 Kendru98 added the platform: ios iOS is affected label Nov 25, 2024
@Kendru98
Copy link
Contributor

Kendru98 commented Nov 26, 2024

Hi @radyhaggag, there is closed issue, with some explanation and (hope so) solution for your problem #1596 (comment). Let us know if you solved the problem and if you have any questions, cheers.

@Kendru98 Kendru98 added the waiting for response Waiting for user's response label Nov 26, 2024
@radyhaggag
Copy link
Author

Hi @Kendru98, I solved it by selecting a profile with "xctrunner" suffix, and set the bundle-id without the "xctrunner".

@github-actions github-actions bot removed the waiting for response Waiting for user's response label Nov 26, 2024
@Kendru98
Copy link
Contributor

Great, I will close the issue then. Don't hesitate to create any other issues or features ideas in the future ^^,
Cheers Kendru

@Kendru98 Kendru98 self-assigned this Nov 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
platform: ios iOS is affected
Projects
None yet
Development

No branches or pull requests

2 participants