Status Update
Comments
xi...@google.com <xi...@google.com>
ac...@google.com <ac...@google.com> #2
2023-12-20 09:43:46,870 [1999497] INFO - #com.android.ddmlib - Uploading APK /Users/wojciech.kalicinski/ApkProjects/tata-sky-16-0 (1)/tata-sky-16-0 (1).apk to session 607174025
2023-12-20 09:43:46,943 [1999570] WARN - #com.android.ddmlib - Error while uploading tata-sky-16-0 (1).apk : Unknown failure: Error: Unable to open file: (1).apk
Consider using a file under /data/local/tmp/
Seems like the ddmlib uploadAPK method needs to deal with escaping spaces.
sa...@google.com <sa...@google.com> #3
The problem comes from the package manager parser. If the filename has a space in it, we send:
pm install-write -S SIZE SESSION tata-sky-16-0 (1).apk -
Because of the space, pm
thinks this is a local-filesystem install-write, using name tata-sky-16-0
and targeting (1).apk
. The parser never reaches the -
at the end.
The solution is to replace
with _
when we install-write
.
ac...@google.com <ac...@google.com> #4
You mean pm
needs its own parser? I would assume the shell would have split the arguments of it and the fix would have been something like:
pm install-write -S SIZE SESSION "tata-sky-16-0 (1).apk" -
or pm install-write -S SIZE SESSION tata-sky-16-0\ (1).apk -
`
sa...@google.com <sa...@google.com> #5
We are going to switch to adblib
to install which properly support ABB invocation (which uses '\0'
instead of ' '
as separator). It will fix this issue.
The switch should happen this month.
no...@google.com <no...@google.com> #6
This is causing a lot of issues. Bumping to P1.
Deployment failure bug reports related to APK spaces
sa...@google.com <sa...@google.com> #7
These bug will be resolved when we switch to installing with adblib
(which uses abb and handles spaces properly). This has been enabled since Jellyfish Canary 11.
ac...@google.com <ac...@google.com> #8
Jellyfish Canary 11.
Is the fix worth patching to Iguana?
sa...@google.com <sa...@google.com> #9
Now, this is a big change (ddmlib -> adblib) with subsequent bug fixes.
ac...@google.com <ac...@google.com> #10
I believe there isn't much we need / can do.
Please report back if you are seeing this after Jellyfish Canary 11
sa...@google.com <sa...@google.com> #11
ag/26788330 it the fix (being reviewed)
an...@google.com <an...@google.com> #12
Thank you for your patience while our engineering team worked to resolve this issue. A fix for this issue is now available in:
- Android Studio Koala | 2024.1.1 Canary 4
- Android Gradle Plugin 8.5.0-alpha04
We encourage you to try the latest update.
If you notice further issues or have questions, please file a new bug report.
Thank you for taking the time to submit feedback — we really appreciate it!
Description
When using Profile/debug APK on macOS, trying to run the APK on the device / emulator fails when the APK name has spaces in it. I verified it works correctly when I renamed the APK to a simple name without spaces or " (1)".
In case it matters, I set up profiling on startup first, but I think regular Run also fails.
Log: