vscode-azure-account icon indicating copy to clipboard operation
vscode-azure-account copied to clipboard

Open Bash in Cloud Shell Hangs

Open doherty100 opened this issue 6 years ago • 34 comments

VS Code Version 1.30.2 Azure Account Extension Version: 0.8.0

The "Azure: Open Bash in Cloud Shell" command is hanging. All I see in the terminal is "Requesting a Cloud Shell...".

Note that I am able to log into shell.azure.com, which I set up previously via a web browser.

Steps to Repro:

  1. Launch vscode
  2. Open command palette with Ctrl-Shift-P
  3. Select "Azure: Sign In"
  4. Redirected to AAD "Sign in to your account" AAD page
  5. Pick my credentials
  6. Redirected to Visual Studio Code Page that states "You are signed in now and can close this page"
  7. Change focus back to vscode
  8. Open command palette with Ctrl-Shift-P
  9. Select "Azure: Open Bash in Cloud Shell"
  10. New "2: Bash in Cloud Shell" terminal is opened with message "Requesting a Cloud Shell..."

At this point nothing happens.

doherty100 avatar Jan 19 '19 15:01 doherty100

One other thing to note, when I sign into shell.azure.com on a browser, I have to pick from multiple identities. There is my work identity , then two other identities associated with AAD tenants that my work identity has been B2B guested into. I pick the work identity associated with my companies AAD tenant when I sign in.

doherty100 avatar Jan 19 '19 16:01 doherty100

@doherty100 Could you check if there are any errors in the console (Help > Toggle Developer Tools)?

chrmarti avatar Jan 27 '19 13:01 chrmarti

@chrmarti negative, just hangs at "Requesting a Cloud Shell....". Nothing new shows up in Developer Tools console.

doherty100 avatar Jan 29 '19 19:01 doherty100

@doherty100 Are you behind a network proxy? Does the PowerShell in Cloud Shell work?

chrmarti avatar Feb 01 '19 07:02 chrmarti

@chrmarti I am not behind a network proxy, and PowerShell in Cloud Shell does work.

doherty100 avatar Feb 04 '19 19:02 doherty100

@doherty100 Does bash work on https://shell.azure.com/?

chrmarti avatar Feb 05 '19 08:02 chrmarti

@chrmarti yes it does.

doherty100 avatar Feb 05 '19 16:02 doherty100

Mine is broken too. It says 'Select directory...' in the terminal even though I already selected it up top. It never progresses beyond that. I uninstalled VS Code and deleted the .vscode folder to kill all extensions. I updated to the latest version of Node. Reinstalled everything and I still have the same problem.

scottstout avatar Feb 07 '19 15:02 scottstout

Update: I also performed and 'clouddrive unmount' to start from a fresh cloud drive. This didn't help.

scottstout avatar Feb 07 '19 15:02 scottstout

@jluk Do you know if anything has changed on the CloudShell's side that would explain that for @doherty100 bash no longer works while PowerShell still does in VS Code?

@scottstout Could you open a new issue for that? Seems like it is a different problem.

chrmarti avatar Feb 08 '19 09:02 chrmarti

@chrmarti correction Open Bash in Cloud Shell never worked, and Open PowerShell in Cloud Shell does work.

doherty100 avatar Feb 08 '19 16:02 doherty100

@chrmarti it eventually started working (initially only with one Directory (not Microsoft btw)). Eventually it started working with all. Maybe it was just taking a really long time and I wasn’t patient enough. If it is a problem it will show up again.

scottstout avatar Feb 09 '19 18:02 scottstout

@chrmarti it just started working for me now, I didn't change a thing so I'm assuming some kind of backend change.

doherty100 avatar Feb 11 '19 14:02 doherty100

Closing, since it's working again. Thanks.

chrmarti avatar Mar 13 '19 15:03 chrmarti

I have the same issue. My Microsoft account is linked to several tenants. After I run "Azure: Open Bash in Cloud Shell" I'm presented text Select directory… on terminal with list of tenants on top and after selecting it just hangs with text Select directory… remaining on Terminal. PowerShell works fine. My VSCode is 1.32.3 and Azure Account extension 0.8.0

mes007 avatar Mar 19 '19 19:03 mes007

Looks like a Cloud Shell issue. Reopening as "upstream" to track here. /cc @jluk

chrmarti avatar Mar 20 '19 08:03 chrmarti

@maertendMSFT to take this as I no longer own the service

jluk avatar Mar 20 '19 14:03 jluk

I'm having the same issue. I did Azure Sign In. Then Azure : Open Bash in Cloud Shell. It prompts for Directory. When I select the 1 desired, nothing happen. Ref below:- image

Please help.

safwanmasarik avatar Sep 22 '19 05:09 safwanmasarik

I have the same issue. It helps to start Azure Bash very quick after opening VSC. It seems to be a problem with other modules. Before there are completly loaded, for me it is possible to get a working bash terminal. So be quick ;-)

yavastark avatar Oct 15 '19 09:10 yavastark

Incredible but @yavastark advice works perfect! 😅

diegofmole avatar May 10 '20 23:05 diegofmole

It's not working for me. It seems It's get stuck on "Select Directory" my setup is WSL2 with Azure Account + Azure Terraform

rodrigorras avatar Sep 03 '20 17:09 rodrigorras

OS: openSUSE Leap 15.2 vscode: 1.48.2 Azure Account extension: v0.9.2 Not working for me too. Get stuck on "Select Directory" But there is nothing to select.

2020-09-05 00-37-06 的螢幕擷圖

I try to input something but bad luck

https://shell.azure.com work

sakanamax avatar Sep 04 '20 16:09 sakanamax

Try setting the "azure.tenant" setting and open a new issue if that doesn't work. Thanks.

chrmarti avatar Sep 07 '20 07:09 chrmarti

@chrmarti Cloud you give example -- setting azure.tenant with directory? Thanks 螢幕快照 2020-09-07 下午4 04 40

I try Azure Account extension in Mac It doesn't work and show empty option too

sakanamax avatar Sep 07 '20 08:09 sakanamax

The Azure Portal (https://portal.azure.com) shows you all directories (= tenants) when you click on your account in the top right, then click Switch directory and then All Directories. You can use the GUID or name of the directory/tenant (could be something like yourcompany.onmicrosoft.com) for the setting.

chrmarti avatar Sep 07 '20 08:09 chrmarti

Hi @chrmarti Thanks for the quick reply Still Bad luck after setting mycompany.onmicrosoft.com in Azure: Tenant

sakanamax avatar Sep 07 '20 08:09 sakanamax

@sakanamax Please open a new issue for us to investigate. Thanks!

chrmarti avatar Sep 07 '20 09:09 chrmarti

@chrmarti thanks, already open https://github.com/microsoft/vscode-azure-account/issues/220

sakanamax avatar Sep 07 '20 11:09 sakanamax

In my case issue resolved by reverting Azure Account extension version to 0.8.11. Look like some issue with Azure Account extension version 0.9.0 and above

pradeepmore12 avatar Sep 16 '20 13:09 pradeepmore12

@pradeepmore12 , me too I had to revert to an old version to make it work :(

ouartil avatar Oct 05 '20 14:10 ouartil