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

fix: shorebird release ios flutter build step takes a long time #2598

Open
zhanglijie5997 opened this issue Oct 31, 2024 · 13 comments
Open

fix: shorebird release ios flutter build step takes a long time #2598

zhanglijie5997 opened this issue Oct 31, 2024 · 13 comments
Labels
bug Something isn't working

Comments

@zhanglijie5997
Copy link

➜ flutter_fpg git:(feature/Init_Project) ✗ yes | shorebird release ios --export-method ad-hoc
✓ Fetching apps (1.3s)
⠧ Building ipa with Flutter 3.24.4 (de629bcb9c)... (867.8s)

Stuck here, unable to continue execution

@zhanglijie5997 zhanglijie5997 added the bug Something isn't working label Oct 31, 2024
@bryanoltman
Copy link
Contributor

Could you run the same command with the --verbose flag and share the result? That will give us better insight into what is taking so long.

@eseidel
Copy link
Contributor

eseidel commented Oct 31, 2024

Felix also improved the output for iOS builds yesterday in Shorebird 1.4.8, so shorebird upgrade might improve the output.

@MohiuddinM
Copy link

I am facing the same problem, when building ios in Github actions. It gets stuck at the Building ipa with Flutter 3.24.4 (de629bcb9c)...[Process.run] /Users/runner/.shorebird/bin/cache/flutter/de629bcb9c96360eb3ca20fcc045263c19b1a33d/bin/flutter build ipa --release.

@MohiuddinM
Copy link

@eseidel Can the team add ability to use an older version of shorebird (as a quick fix)? The current release is completely broken for IOS releases in Github actions.

@bryanoltman
Copy link
Contributor

I think it's more likely something to do with a change in flutter version than it is with shorebird, so downgrading shorebird wouldn't fix the issue. You can pass --flutter-version=1.2.3 to the release command to pick a different version of flutter.

@MohiuddinM
Copy link

@bryanoltman It can also be helpful if you increase logging in the step it gets stuck on. I can then post the logs here so you can reproduce the issue.

@MohiuddinM
Copy link

From the current logs, it looks like it gets stuck on

final result = await processWrapper.run(

@bryanoltman
Copy link
Contributor

@MohiuddinM that's the function our CLI uses to launch any kind of external process, so I think you're correct re: that being the last thing the shorebird CLI does before hanging, but also why I don't think the shorebird CLI itself is the problem, but rather something else that the shorebird CLI is interfacing with.

Can you try running this locally with the following?

FLUTTER_STORAGE_BASE_URL=https://download.shorebird.dev /path/to/shorebird/bin/cache/de629bcb9c96360eb3ca20fcc045263c19b1a33d/bin/flutter build ipa --release

@bryanoltman bryanoltman changed the title fix: build ios fix: shorebird release ios flutter build step takes a long time Nov 5, 2024
@MohiuddinM
Copy link

Can you change Process.run to Process.start (like the android ones), so the inner logs from the process will also get printed in "realtime", instead of being printed at the end of the process.

@MohiuddinM
Copy link

@MohiuddinM that's the function our CLI uses to launch any kind of external process, so I think you're correct re: that being the last thing the shorebird CLI does before hanging, but also why I don't think the shorebird CLI itself is the problem, but rather something else that the shorebird CLI is interfacing with.

Can you try running this locally with the following?

FLUTTER_STORAGE_BASE_URL=https://download.shorebird.dev /path/to/shorebird/bin/cache/de629bcb9c96360eb3ca20fcc045263c19b1a33d/bin/flutter build ipa --release

I ran this cmd locally, and it finishes normally

@bryanoltman
Copy link
Contributor

Hmm, so that suggests it might be an issue with the CI machine. Is it running the same version of macOS and Xcode as you're using locally to successfully build?

@MohiuddinM
Copy link

MohiuddinM commented Nov 5, 2024

Hmm, so that suggests it might be an issue with the CI machine. Is it running the same version of macOS and Xcode as you're using locally to successfully build?

I am using macos-latest-xlarge on Github actions. Both local machine and action runner use xcode 16

@bryanoltman
Copy link
Contributor

FWIW, I locally compared stock Flutter to Shorebird's Flutter on a build that was taking a while, and, at least for me, there's no appreciable difference in performance:

Flutter: build ipa --release 32.17s user 11.48s system 26% cpu 2:47.37 total
Shorebird flutter: build ipa --release 32.33s user 9.47s system 24% cpu 2:47.28 total

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants