Closed Bug 1794416 Opened 2 years ago Closed 1 year ago

Mozregression with Android isn't working on Windows 10

Categories

(Testing :: mozregression, defect, P2)

Other Branch
ARM
Windows 10
defect

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: mlobontiuroman, Assigned: zeid)

References

Details

(Whiteboard: [geckoview], 5.3.0)

Attachments

(2 files)

Attached image Screenshot_1.jpg

STR:

  1. I've downloaded mozregression version 5.0.0 from https://github.com/mozilla/mozregression/releases/tag/5.0.0.
  2. Installed successfully.
  3. Tried to find a range on Firefox for Android, with a device connected.
  4. Established the dates for the "bad", and "good" builds.
  5. Started the process.

Expected behavior:
The app should install a build from the established range on the connected device.

Actual behavior:
A prompt with an error is displayed. Clicking on "OK", takes me to find a different date.
After I select it, the same error is displayed.

Devices: Windows 10 (and OnePlus 5T (Android 10))

Assignee: nobody → zeid
Priority: -- → P3
Summary: Mozregression isn't working on Windows 10 → Mozregression with Android isn't working on Windows 10

I can confirm this bug, both on mozregression 5.0.0 and mozregression 4.0.18 and an arbitrary date range for bisection. Tested on Windows 10 + Pixel 3a (Android 12) with a similar error output.

The severity field is not set for this bug.
:zeid, could you have a look please?

For more information, please visit auto_nag documentation.

Flags: needinfo?(zeid)
Severity: -- → S2
Flags: needinfo?(zeid)
Priority: P3 → P2
Whiteboard: [geckoview]

This appears to be due to the way that forward slashes are escaped in mozdevice.adb.ADBDevice.

For some reason, self.command_output and self.chmod appear to handle intermediate properly, however, self.cp does not escape the forward slashes correctly.

3014                 try:
3015                     with tempfile.NamedTemporaryFile(delete=True) as tmpf:
3016                         intermediate = posixpath.join(
3017                             "/data/local/tmp", posixpath.basename(tmpf.name)
3018                         )
3019                     self.command_output(["push", local, intermediate], timeout=timeout)
3020                     self.chmod(intermediate, recursive=True, timeout=timeout)
3021                     parent_dir = posixpath.dirname(remote)
3022                     if not self.is_dir(parent_dir, timeout=timeout):
3023                         self.mkdir(parent_dir, parents=True, timeout=timeout)
3024 ->                  self.cp(intermediate, remote, recursive=True, timeout=timeout)
3025                 finally:
3026                     self.rm(intermediate, recursive=True, force=True, timeout=timeout)

(Pdb) intermediate
'/data/local/tmp/C:\\Users\\ZEIDZA~1\\AppData\\Local\\Temp\\tmp1f796na1'
(Pdb) self.exists(intermediate)
False
(Pdb) self.exists(intermediate.replace("\\", "\\\\"))
True

Replacing \\ with \\\\ when calling cp seems to make this work.

I will spawn a bug in mozbase.

Depends on: 1808621
See Also: → 1808621
Attached file GitHub Pull Request

Will be deployed with the next release.

Status: NEW → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Whiteboard: [geckoview] → [geckoview] 5.3.0
Whiteboard: [geckoview] 5.3.0 → [geckoview], 5.3.0

This should now be fixed.

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: