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

After the update, when running the tests it is asking to inform the operating system and version #1845

Open
1 task done
AnaLuisaFav opened this issue Jul 29, 2024 · 16 comments
Labels
host: windows-wsl Running tests on Windows (WSL) hosts is affected

Comments

@AnaLuisaFav
Copy link

Is there an existing issue for this?

  • I have searched the existing issues and didn't find mine.

Steps to reproduce

  1. Get the new version curl -Ls "https://get.maestro.mobile.dev" | bash
  2. Run tests

Actual results

Everything was working ok with the emulator configured before the update. But now, when I run my tests it is asking to inform the operating system and version, even with the emulator already open.

------------------ Shard 1 ------------------ 
Please specify a device platform [android, ios, web]: 
android 
Please specify Android version [34, 33, 31, 30, 29, 28]: Press ENTER for default (30)

Expected results

For the tests to run normally without a manual entry.

About app

It's a confidential flutter app available in Android and iOS, but I'm using the Android version.

About environment

I'm on a DELL Notebook 15" Windows 11 (WSL Ubuntu)

Logs

Logs
<!-- Replace this line with your logs. *DO NOT* remove the backticks! -->

Maestro version

1.37.0

How did you install Maestro?

install script (https://get.maestro.mobile.dev)

Anything else?

No response

@nson22
Copy link

nson22 commented Jul 29, 2024

Same issue, I downgrade

@bartekpacia
Copy link
Member

Hey @AnaLuisaFav and @nson22, sorry about the problem.

  1. Run tests

Can you tell me more about:

  • What (and how many) device do you have running?
  • What does the command you're running look like, exactly?

@partparsh
Copy link

Hi @bartekpacia I am also facing the same issue,

I am using WSL2 on Windows 11

What (and how many) device do you have running?

1 Android emulator device on Windows

Steps to reproduce

  1. Install the app on Android emulator, run adb devices to get device identifier emulator-5554
  2. run adb -a -P 5037 nodaemon server on Windows Powershell to start adb server
  3. run maestro --host $WSL_HOST test run-tests.yaml where $WSL_HOST is ip address of windows 11

Actual results

The flow does not start and shard configuration is being asked

------------------ Shard 1 ------------------

Please specify a device platform [android, ios, web]:

Expected Result

Maestro should recognise the running emulator and start the test against it.

Observations:

I was able to make the tests run against the running emulator by specifying the --udid
Following command worked for me:
maestro --udid=emulator-5554 --host $WSL_HOST test run-tests.yaml

@curaserkan
Copy link

curaserkan commented Jul 30, 2024

Also, we don't choose the iPhone version; we choose only the iOS platform and iOS version. It's created only iPhone11 version

Old version:
Screenshot 2024-07-30 at 08 39 30
Screenshot 2024-07-30 at 08 39 50

New Version:

Screenshot 2024-07-30 at 08 45 43

@nson22
Copy link

nson22 commented Jul 30, 2024

Hey @AnaLuisaFav and @nson22, sorry about the problem.

  1. Run tests

Can you tell me more about:

  • What (and how many) device do you have running?
  • What does the command you're running look like, exactly?

I can't tell what went wrong yesterday but now is working fine
I also update to version https://github.com/mobile-dev-inc/maestro/releases/tag/cli-1.37.4

@AnaLuisaFav
Copy link
Author

@bartekpacia @nson22 hey!

  • I was running on 1 emulator device (Pixel 4 API Android VanillaIceCream)
  • The steps was same as @partparsh:
  1. Install the app on Android emulator, run adb devices to get device identifier emulator-5554
  2. run adb -a -P 5037 nodaemon server on Windows Powershell to start adb server
  3. run maestro --host $WSL_HOST test run-tests.yaml where $WSL_HOST is ip address of windows 11

@nson22
Copy link

nson22 commented Jul 30, 2024

@bartekpacia @nson22 hey!

  • I was running on 1 emulator device (Pixel 4 API Android VanillaIceCream)
  • The steps was same as @partparsh:
  1. Install the app on Android emulator, run adb devices to get device identifier emulator-5554
  2. run adb -a -P 5037 nodaemon server on Windows Powershell to start adb server
  3. run maestro --host $WSL_HOST test run-tests.yaml where $WSL_HOST is ip address of windows 11

@AnaLuisaFav I'm using a Linux machine, but I downgrade my Java version to 11 and upgrade mastro to the latest CLI
Maybe you can try the same on your wsl env

@bartekpacia
Copy link
Member

Does this only occur on Windows (WSL) hosts? Did someone experience this on Linux and/or macOS?

This might be related to #1851 and #1799.

@bartekpacia bartekpacia added the host: windows-wsl Running tests on Windows (WSL) hosts is affected label Jul 31, 2024
@AnaLuisaFav
Copy link
Author

@nson22 I downgrade maestro and it started working again. But I wanted to use a feature that is in the new version, so I need this to be adjusted. xD

@AnaLuisaFav
Copy link
Author

@bartekpacia Yes, in WSL host. I don't know if anyone has had the same experience with Linux and/or macOS

@nson22
Copy link

nson22 commented Aug 1, 2024

Does this only occur on Windows (WSL) hosts? Did someone experience this on Linux and/or macOS?

This might be related to #1851 and #1799.

Linux working fine

@mobile-dev-inc mobile-dev-inc deleted a comment from avdao Aug 2, 2024
@bartekpacia
Copy link
Member

bartekpacia commented Aug 2, 2024

It seems to me that the actual problem is this:

After v1.37.x, Maestro does not detect running devices on WSL, and always asks to create a new device

then it may be similar to #1863

@AnaLuisaFav
Copy link
Author

@bartekpacia Yeah, that's it. Any news here? I would really like to use the new features of the new version, and this case is blocking me :')

It seems to me that the actual problem is this:

After v1.37.x, Maestro does not detect running devices on WSL, and always asks to create a new device

then it may be similar to #1863

@dannmf

This comment has been minimized.

@ggetorres

This comment was marked as off-topic.

@curlycrow

This comment has been minimized.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
host: windows-wsl Running tests on Windows (WSL) hosts is affected
Projects
None yet
Development

No branches or pull requests

8 participants