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

android-studio fails to run after install #186774

Closed
6 tasks done
walterheck opened this issue Sep 27, 2024 · 2 comments
Closed
6 tasks done

android-studio fails to run after install #186774

walterheck opened this issue Sep 27, 2024 · 2 comments
Labels
stale Issue which has not received any feedback for some time.

Comments

@walterheck
Copy link

Verification

Description of issue

brew install android-studio on my Sonoma m3 mac doesn't deliver a working android studio:

walterheck in ~ on master
> studio
2024-09-27 06:12:05.352 studio[85085:13719454] allVms required (null)
2024-09-27 06:12:05.353 studio[85085:13719454] Can't find bundled java.The folder doesn't exist: /opt/homebrew/bin/Contents/jbr
2024-09-27 06:12:05.353 studio[85085:13719454] Can't get bundled java version. It is probably corrupted.
2024-09-27 06:12:05.354 studio[85085:13719454] Info.plist is corrupted, Absent JVMOptions key.

I have tried to also install zulu@11 but no dice, same error.

Command that failed

studio

Output of command with --verbose --debug

(venv) walterheck in ~/source/helixiora/helixiora-lorelai on feature/newgoogleloader using helixiora-sandbox-walter
> brew reinstall android-studio --verbose --debug
/opt/homebrew/Library/Homebrew/brew.rb (Formulary::NullLoader): loading android-studio
/opt/homebrew/Library/Homebrew/brew.rb (Formulary::NullLoader): loading android-studio
/opt/homebrew/Library/Homebrew/brew.rb (Formulary::NullLoader): loading android-studio
/opt/homebrew/Library/Homebrew/brew.rb (Cask::CaskLoader::FromAPILoader): loading android-studio
==> Cask::Installer#install
==> Printing caveats
==> Cask::Installer#fetch
==> Downloading https://redirector.gvt1.com/edgedl/android/studio/install/2024.1.2.13/android-studio-2024.1.2.13-mac_arm.dmg
/usr/bin/env /opt/homebrew/Library/Homebrew/shims/shared/curl --disable --cookie /dev/null --globoff --show-error --user-agent Homebrew/4.3.24\ \(Macintosh\;\ arm64\ Mac\ OS\ X\ 14.6.1\)\ curl/8.7.1 --header Accept-Language:\ en --retry 3 --fail --location --silent --head https://redirector.gvt1.com/edgedl/android/studio/install/2024.1.2.13/android-studio-2024.1.2.13-mac_arm.dmg
Already downloaded: /Users/walterheck/Library/Caches/Homebrew/downloads/a3de2b7bb37ab60b9746f4693f25c3131059beacd3e4cc27d236dc6f635676c0--android-studio-2024.1.2.13-mac_arm.dmg
==> Checking quarantine support
/usr/bin/env /usr/bin/xattr -h
/usr/bin/env /Library/Developer/CommandLineTools/usr/bin/swift -target arm64-apple-macosx14 /opt/homebrew/Library/Homebrew/cask/utils/quarantine.swift
==> Quarantine is available.
==> Verifying Gatekeeper status of /Users/walterheck/Library/Caches/Homebrew/downloads/a3de2b7bb37ab60b9746f4693f25c3131059beacd3e4cc27d236dc6f635676c0--android-studio-2024.1.2.13-mac_arm.dmg
/usr/bin/env /usr/bin/xattr -p com.apple.quarantine /Users/walterheck/Library/Caches/Homebrew/downloads/a3de2b7bb37ab60b9746f4693f25c3131059beacd3e4cc27d236dc6f635676c0--android-studio-2024.1.2.13-mac_arm.dmg
==> /Users/walterheck/Library/Caches/Homebrew/downloads/a3de2b7bb37ab60b9746f4693f25c3131059beacd3e4cc27d236dc6f635676c0--android-studio-2024.1.2.13-mac_arm.dmg is quarantined
==> Verifying checksum for 'a3de2b7bb37ab60b9746f4693f25c3131059beacd3e4cc27d236dc6f635676c0--android-studio-2024.1.2.13-mac_arm.dmg'
/usr/bin/env hdiutil imageinfo -format /Users/walterheck/Library/Caches/Homebrew/downloads/a3de2b7bb37ab60b9746f4693f25c3131059beacd3e4cc27d236dc6f635676c0--android-studio-2024.1.2.13-mac_arm.dmg
/opt/homebrew/Library/Homebrew/brew.rb (Cask::CaskLoader::FromPathLoader): loading /opt/homebrew/Caskroom/android-studio/.metadata/2024.1.2.13/20240927041135.018/Casks/android-studio.json
==> Uninstalling Cask android-studio
==> Uninstalling artifacts
==> 3 artifacts defined
#<Cask::ArtifactSet: {#<Cask::Artifact::App:0x00000001367d8250 @cask=#<Cask android-studio /opt/homebrew/Caskroom/android-studio/.metadata/2024.1.2.13/20240927041135.018/Casks/android-studio.json>, @dsl_args=["Android Studio.app"], @source_string="Android Studio.app", @target_string="">, #<Cask::Artifact::Binary:0x00000001367d7fd0 @cask=#<Cask android-studio /opt/homebrew/Caskroom/android-studio/.metadata/2024.1.2.13/20240927041135.018/Casks/android-studio.json>, @dsl_args=["/Applications/Android Studio.app/Contents/MacOS/studio"], @source_string="/Applications/Android Studio.app/Contents/MacOS/studio", @target_string="">, #<Cask::Artifact::Zap:0x00000001367f4518 @cask=#<Cask android-studio /opt/homebrew/Caskroom/android-studio/.metadata/2024.1.2.13/20240927041135.018/Casks/android-studio.json>, @dsl_args=[{:trash=>["~/.android", "~/Library/Android/sdk", "~/Library/Application Support/Google/AndroidStudio2024.1", "~/Library/Caches/Google/AndroidStudio2024.1", "~/Library/Logs/Google/AndroidStudio2024.1", "~/Library/Preferences/com.android.Emulator.plist", "~/Library/Preferences/com.google.android.studio.plist", "~/Library/Saved Application State/com.google.android.studio.savedState"], :rmdir=>["~/AndroidStudioProjects", "~/Library/Android"]}], @directives={:trash=>["~/.android", "~/Library/Android/sdk", "~/Library/Application Support/Google/AndroidStudio2024.1", "~/Library/Caches/Google/AndroidStudio2024.1", "~/Library/Logs/Google/AndroidStudio2024.1", "~/Library/Preferences/com.android.Emulator.plist", "~/Library/Preferences/com.google.android.studio.plist", "~/Library/Saved Application State/com.google.android.studio.savedState"], :rmdir=>["~/AndroidStudioProjects", "~/Library/Android"], :signal=>[]}>}>
==> Uninstalling artifact of class Cask::Artifact::App
==> Backing App 'Android Studio.app' up to '/opt/homebrew/Caskroom/android-studio/2024.1.2.13/Android Studio.app'
/usr/bin/env /bin/cp -pR /Applications/Android\ Studio.app /opt/homebrew/Caskroom/android-studio/2024.1.2.13/Android\ Studio.app
==> Removing App '/Applications/Android Studio.app'
==> Uninstalling artifact of class Cask::Artifact::Binary
==> Unlinking Binary '/opt/homebrew/bin/studio'
==> Purging files for version 2024.1.2.13 of Cask android-studio
==> Purging all staged versions of Cask android-studio
==> Installing Cask android-studio
==> Cask::Installer#stage
==> Extracting primary container
==> Using container class UnpackStrategy::Dmg for /Users/walterheck/Library/Caches/Homebrew/downloads/a3de2b7bb37ab60b9746f4693f25c3131059beacd3e4cc27d236dc6f635676c0--android-studio-2024.1.2.13-mac_arm.dmg
/usr/bin/env hdiutil attach -plist -nobrowse -readonly -mountrandom /private/tmp/homebrew-dmg20240927-85546-j7xkc4 /Users/walterheck/Library/Caches/Homebrew/downloads/a3de2b7bb37ab60b9746f4693f25c3131059beacd3e4cc27d236dc6f635676c0--android-studio-2024.1.2.13-mac_arm.dmg
/usr/bin/env find . -print0
/usr/bin/env mkbom -s -i /private/tmp/20240927-85546-vs6yu1.list -- /private/tmp/20240927-85546-emq7dx.bom
/usr/bin/env ditto --bom /private/tmp/20240927-85546-emq7dx.bom -- /private/tmp/homebrew-dmg20240927-85546-j7xkc4/dmg.H2SPTd /private/tmp/homebrew-unpack20240927-85546-stbxx0
/usr/bin/env diskutil info -plist /private/tmp/homebrew-dmg20240927-85546-j7xkc4/dmg.H2SPTd
/usr/bin/env diskutil eject /private/tmp/homebrew-dmg20240927-85546-j7xkc4/dmg.H2SPTd
/usr/bin/env cp -pR /private/tmp/homebrew-unpack20240927-85546-stbxx0/.back/. /opt/homebrew/Caskroom/android-studio/2024.1.2.13/.back
/usr/bin/env cp -pR /private/tmp/homebrew-unpack20240927-85546-stbxx0/Android\ Studio.app/. /opt/homebrew/Caskroom/android-studio/2024.1.2.13/Android\ Studio.app
==> Verifying Gatekeeper status of /Users/walterheck/Library/Caches/Homebrew/downloads/a3de2b7bb37ab60b9746f4693f25c3131059beacd3e4cc27d236dc6f635676c0--android-studio-2024.1.2.13-mac_arm.dmg
/usr/bin/env /usr/bin/xattr -p com.apple.quarantine /Users/walterheck/Library/Caches/Homebrew/downloads/a3de2b7bb37ab60b9746f4693f25c3131059beacd3e4cc27d236dc6f635676c0--android-studio-2024.1.2.13-mac_arm.dmg
==> /Users/walterheck/Library/Caches/Homebrew/downloads/a3de2b7bb37ab60b9746f4693f25c3131059beacd3e4cc27d236dc6f635676c0--android-studio-2024.1.2.13-mac_arm.dmg is quarantined
==> Propagating quarantine from /Users/walterheck/Library/Caches/Homebrew/downloads/a3de2b7bb37ab60b9746f4693f25c3131059beacd3e4cc27d236dc6f635676c0--android-studio-2024.1.2.13-mac_arm.dmg to /opt/homebrew/Caskroom/android-studio/2024.1.2.13
/usr/bin/env /usr/bin/xattr -p com.apple.quarantine /Users/walterheck/Library/Caches/Homebrew/downloads/a3de2b7bb37ab60b9746f4693f25c3131059beacd3e4cc27d236dc6f635676c0--android-studio-2024.1.2.13-mac_arm.dmg
/usr/bin/env /usr/bin/xargs -0 -- /bin/chmod -h u+w
/usr/bin/env /usr/bin/xargs -0 -- /usr/bin/xattr -w com.apple.quarantine 0381\;66f62be2\;\;26DB06BF-54CE-4EBF-B322-050FE3C69855
==> Creating metadata directory: /opt/homebrew/Caskroom/android-studio/.metadata/2024.1.2.13/20240927041446.447
==> Creating metadata subdirectory: /opt/homebrew/Caskroom/android-studio/.metadata/2024.1.2.13/20240927041446.447/Casks
==> Installing artifacts
==> Installing artifact of class Cask::Artifact::App
==> Moving App 'Android Studio.app' to '/Applications/Android Studio.app'
==> Copying xattrs from /opt/homebrew/Caskroom/android-studio/2024.1.2.13/Android Studio.app to /Applications/Android Studio.app
/usr/bin/env /Library/Developer/CommandLineTools/usr/bin/swift -target arm64-apple-macosx14 /opt/homebrew/Library/Homebrew/cask/utils/copy-xattrs.swift /opt/homebrew/Caskroom/android-studio/2024.1.2.13/Android\ Studio.app /Applications/Android\ Studio.app
==> Installing artifact of class Cask::Artifact::Binary
==> Linking Binary 'studio' to '/opt/homebrew/bin/studio'
/usr/bin/env /bin/ln -h -f -s -- /Applications/Android\ Studio.app/Contents/MacOS/studio /opt/homebrew/bin/studio
🍺  android-studio was successfully installed!

Output of brew doctor and brew config

(venv) walterheck in ~/source/helixiora/helixiora-lorelai on feature/newgoogleloader using helixiora-sandbox-walter
> brew doctor
Your system is ready to brew.

> brew config
HOMEBREW_VERSION: 4.3.24
ORIGIN: https://github.com/Homebrew/brew
HEAD: 916044581862c32fc2365e8e9ff0b1507a98925e
Last commit: 5 days ago
Core tap JSON: 27 Sep 04:11 UTC
Core cask tap JSON: 27 Sep 04:11 UTC
HOMEBREW_PREFIX: /opt/homebrew
HOMEBREW_CASK_OPTS: []
HOMEBREW_MAKE_JOBS: 12
Homebrew Ruby: 3.3.4 => /opt/homebrew/Library/Homebrew/vendor/portable-ruby/3.3.4_1/bin/ruby
CPU: dodeca-core 64-bit arm_lobos
Clang: 15.0.0 build 1500
Git: 2.39.3 => /Library/Developer/CommandLineTools/usr/bin/git
Curl: 8.7.1 => /usr/bin/curl
macOS: 14.6.1-arm64
CLT: 15.3.0.0.1.1708646388
Xcode: N/A
Rosetta 2: false

Output of brew tap

> brew tap
aws/tap
azure/functions
homebrew/bundle
homebrew/services
minamijoyo/hcledit
tylerbrock/saw
@daeho-ro
Copy link
Member

daeho-ro commented Sep 28, 2024

I think this will happen only in cli environment, right?

The binary studio is originally located /Applications/Android Studio.app/Contents/MacOS/studio and brew just symlink it from /opt/homebrew/bin/studio to the origin. However, the binary is looking for the java path somehow relative and so the path doesn't exist. I think the upstream may fix to use the absolute path or config.

Copy link

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@github-actions github-actions bot added the stale Issue which has not received any feedback for some time. label Oct 20, 2024
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Oct 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stale Issue which has not received any feedback for some time.
Projects
None yet
Development

No branches or pull requests

2 participants