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

error: device offline #55

Closed
stefan-niedermann opened this issue Apr 18, 2020 · 3 comments
Closed

error: device offline #55

stefan-niedermann opened this issue Apr 18, 2020 · 3 comments

Comments

@stefan-niedermann
Copy link

Hi,

i just found your GitHub action and wanted to use it for instrumented tests.

Unfortunately i don't get it working. Every run ends in an endless-loop, like this:

2020-04-18T10:50:38.3709819Z Do you wish to create a custom hardware profile? [no] Starting emulator.
2020-04-18T10:50:38.3710947Z [command]sh -c \/usr/local/lib/android/sdk/emulator/emulator -avd test -no-window -gpu swiftshader_indirect -no-snapshot -noaudio -no-boot-anim -accel off &
2020-04-18T10:50:38.5434456Z emulator: ERROR: AdbHostServer.cpp:102: Unable to connect to adb daemon on port: 5037
2020-04-18T10:50:38.8611089Z emulator: WARNING: x86 emulation may not work without hardware acceleration!
2020-04-18T10:50:38.8611715Z emulator: Cold boot: requested by the user
2020-04-18T10:50:48.0223424Z Your emulator is out of date, please update by launching Android Studio:
2020-04-18T10:50:48.0224339Z  - Start Android Studio
2020-04-18T10:50:48.0224850Z  - Select menu "Tools > Android > SDK Manager"
2020-04-18T10:50:48.0225247Z  - Click "SDK Tools" tab
2020-04-18T10:50:48.0225575Z  - Check "Android Emulator" checkbox
2020-04-18T10:50:48.0225857Z  - Click "OK"
2020-04-18T10:50:48.0225987Z 
2020-04-18T10:50:48.0226140Z [command]adb shell getprop sys.boot_completed
2020-04-18T10:50:48.0287652Z * daemon not running; starting now at tcp:5037
2020-04-18T10:50:48.1271823Z * daemon started successfully
2020-04-18T10:50:48.1279811Z The process 'adb' failed with exit code 1
2020-04-18T10:50:48.1280228Z error: device offline
2020-04-18T10:50:50.1297670Z [command]adb shell getprop sys.boot_completed
2020-04-18T10:50:50.1334241Z error: device offline
2020-04-18T10:50:50.1343910Z The process 'adb' failed with exit code 1
2020-04-18T10:50:52.1376072Z [command]adb shell getprop sys.boot_completed
2020-04-18T10:50:52.1414803Z error: device offline
2020-04-18T10:50:52.1423024Z The process 'adb' failed with exit code 1
2020-04-18T10:50:54.1452862Z [command]adb shell getprop sys.boot_completed
2020-04-18T10:50:54.1494499Z error: device offline
2020-04-18T10:50:54.1509088Z The process 'adb' failed with exit code 1
2020-04-18T10:50:56.1540131Z [command]adb shell getprop sys.boot_completed
2020-04-18T10:50:56.1581878Z error: device offline
2020-04-18T10:50:56.1591998Z The process 'adb' failed with exit code 1
2020-04-18T10:50:58.1622531Z [command]adb shell getprop sys.boot_completed
2020-04-18T10:50:58.1657872Z error: device offline
2020-04-18T10:50:58.1667429Z The process 'adb' failed with exit code 1
2020-04-18T10:51:00.1692766Z [command]adb shell getprop sys.boot_completed
2020-04-18T10:51:00.1728925Z error: device offline
2020-04-18T10:51:00.1736781Z The process 'adb' failed with exit code 1
2020-04-18T10:51:02.1767240Z [command]adb shell getprop sys.boot_completed

You can find my configuration here: https://github.com/stefan-niedermann/nextcloud-deck/blob/instrumented-tests-ci/.github/workflows/android.yml#L25-L39 and the full log output here: https://github.com/stefan-niedermann/nextcloud-deck/runs/597664917 (raw)

Do you have any clue what i am doing wrong?

Thank you in advance

@stefan-niedermann
Copy link
Author

I just switched to api-level: 27 after reading #45 and i don't get the error: device offline error any more. Maybe i just haven't been patient enough.

I will try it further and close this issue when i get one successful build :)

@ychescale9
Copy link
Member

ychescale9 commented Apr 18, 2020

Hi. It's not an endless loop, just the emulator being incredibly slow without hardware acceleration especially on the later API levels. Please read this issue for why Linux VMs are expected to be slow and that you probably shouldn't run the action with ubuntu VMs. If your project's opensource, definitely use the macos-latest VM instead.

@stefan-niedermann
Copy link
Author

My dear, i am such an idiot. I read about the slow Linux VMs, and i was so sure, i explicitly set macos-latest, but i just double-checked it and i really set a linux vm.

Sorry and thanks for the quick response. 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants