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 preview for iOS fails if no Flutter commands have previously run #1795

Closed
bryanoltman opened this issue Mar 15, 2024 · 0 comments · Fixed by #1812
Closed

fix: shorebird preview for iOS fails if no Flutter commands have previously run #1795

bryanoltman opened this issue Mar 15, 2024 · 0 comments · Fixed by #1812
Labels
bug Something isn't working

Comments

@bryanoltman
Copy link
Contributor

Because Flutter downloads artifacts on demand, and because shorebird preview does not execute any Flutter commands but relies on the existence of Flutter artifacts (specifically libimobiledevice for iOS), preview fails when those artifacts are not present.

This can be fixed by running a shorebird release command or any other command that causes Shorebird's Flutter to download artifacts, but this shouldn't be necessary.

The command and error output:

bryanoltman@moltman ~/Documents/sandbox/smoke (main) ✗
⑆ shorebird preview
✓ Fetching releases (0.2s)
Which release would you like to preview?
❯ ◉  1.0.0+21
  ◯  1.0.0+20
  ◯  1.0.0+18
  ◯  1.0.0+17
  ◯  1.0.0+16
  ◯  1.0.0+15
  ◯  1.0.0+13
  ◯  1.0.0+12
  ◯  1.0.0+11
  ◯  1.0.0+10
  ◯  1.0.0+9
  ◯  1.0.0+8
  ◯  1.0.0+7
Which release would you like to preview? 1.0.0+21
✓ Using production track (12ms)
✓ Using device Bryan Oltman’s iPhone (1.2s)
Unhandled exception:
ProcessException: No such file or directory
  Command: /Users/bryanoltman/shorebirdtech/_shorebird/shorebird/bin/cache/flutter/a6d1747d7f573b2ba2e2b96db1b76ed2f3f024da/bin/cache/artifacts/libimobiledevice/idevicesyslog -u 00008110-000265A10E92801E --network
#0      _ProcessImpl._start (dart:io-patch/process_patch.dart:402:33)
#1      Process.start (dart:io-patch/process_patch.dart:38:20)
#2      ProcessWrapper.start (package:shorebird_cli/src/shorebird_process.dart:289:20)
#3      ShorebirdProcess.start (package:shorebird_cli/src/shorebird_process.dart:132:27)
#4      IDeviceSysLog.startLogger (package:shorebird_cli/src/executables/idevicesyslog.dart:79:41)
#5      Devicectl.installAndLaunchApp (package:shorebird_cli/src/executables/devicectl/devicectl.dart:180:48)
#6      PreviewCommand.installAndLaunchIos (package:shorebird_cli/src/commands/preview_command.dart:379:43)
<asynchronous suspension>
#7      CommandRunner.runCommand (package:args/command_runner.dart:212:13)
<asynchronous suspension>
#8      ShorebirdCliCommandRunner.runCommand (package:shorebird_cli/src/command_runner.dart:208:18)
<asynchronous suspension>
#9      ShorebirdCliCommandRunner.run (package:shorebird_cli/src/command_runner.dart:124:14)
<asynchronous suspension>
#10     main (file:///Users/bryanoltman/shorebirdtech/_shorebird/shorebird/packages/shorebird_cli/bin/shorebird.dart:28:5)
<asynchronous suspension>
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
1 participant