question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Fails to install on windows

See original GitHub issue

Description

I am just running the install script in the readme and it fails:

$ curl -L https://aka.ms/InstallAzureCli | bash

Environment summary

Install Method: How did you install the CLI? (e.g. pip, interactive script, apt-get, Docker, MSI, nightly)
Answer here:

I am running the latest version of Git Bash and I just ran the curl script from the README.

CLI Version: What version of the CLI and modules are installed? (Use az --version)
Answer here:

I don’t know because I can’t install it.

OS Version: What OS and version are you using?
Answer here:

Windows 10.

Shell Type: What shell are you using? (e.g. bash, cmd.exe, Bash on Windows)
Answer here:

Git Bash (aka bash)

Extra Info: I have python27 already installed on my machine because nodejs requires it. I see in the output its trying to install python and pip:

Already using interpreter C:\Python27\python.exe
New python executable in E:\azure\Scripts\python.exe
Installing setuptools, pip, wheel...done.

When I look in my bin folder it is empty: 2017-10-03

But python is in the azure scripts folder: 2017-10-03 1

But the error states the path its trying to exectute pip at is in the bin folder:

-- Executing: ['E:\\azure\\bin\\pip', 'install', '--cache-dir', 'c:\\users\\justin\\appdata\\local\\temp\\tmp3v1zxj', 'azure-cli', '--upgrade']

I believe the path should be E:\\azure\\Scripts\\pip. Interestingly E:\\azure\\bin\\ does not exist at all.

Full Error:

$ curl -L https://aka.ms/InstallAzureCli | bash
100   167  100   167    0     0    167      0  0:00:01 --:--:--  0:00:01   594
100  1367  100  1367    0     0   1367      0  0:00:01 --:--:--  0:00:01  6733
Downloading Azure CLI install script from https://azurecliprod.blob.core.windows.net/install.py to /tmp/azure_cli_install_tmp_1Nrb.
######################################################################## 100.0%
/tmp/azure_cli_install_tmp_1Nrb: OK
Running install script.
-- Verifying Python version.
-- Python version 2.7.6 okay.

===> In what directory would you like to place the install? (leave blank to use 'C:\Users\justin\lib\azure-cli'): E:\azure
-- Creating directory 'E:\azure'.
-- We will install at 'E:\azure'.

===> In what directory would you like to place the 'az' executable? (leave blank to use 'C:\Users\justin\bin'): E:\bin
-- Creating directory 'E:\bin'.
-- The executable will be in 'E:\bin'.
-- Downloading virtualenv package from https://pypi.python.org/packages/source/v/virtualenv/virtualenv-15.0.0.tar.gz.
-- Downloaded virtualenv package to c:\users\justin\appdata\local\temp\tmp3v1zxj\virtualenv-15.0.0.tar.gz.
-- Checksum of c:\users\justin\appdata\local\temp\tmp3v1zxj\virtualenv-15.0.0.tar.gz OK.
-- Extracting 'c:\users\justin\appdata\local\temp\tmp3v1zxj\virtualenv-15.0.0.tar.gz' to 'c:\users\justin\appdata\local\temp\tmp3v1zxj'.
-- Executing: ['C:\\Python27\\python.exe', 'virtualenv.py', '--python', 'C:\\Python27\\python.exe', 'E:\\azure']
Already using interpreter C:\Python27\python.exe
New python executable in E:\azure\Scripts\python.exe
Installing setuptools, pip, wheel...done.
-- Executing: ['E:\\azure\\bin\\pip', 'install', '--cache-dir', 'c:\\users\\justin\\appdata\\local\\temp\\tmp3v1zxj', 'azure-cli', '--upgrade']
Traceback (most recent call last):
  File "C:/Users/justin/AppData/Local/Temp/azure_cli_install_tmp_1Nrb", line 370, in <module>
    main()
  File "C:/Users/justin/AppData/Local/Temp/azure_cli_install_tmp_1Nrb", line 356, in main
    install_cli(install_dir, tmp_dir)
  File "C:/Users/justin/AppData/Local/Temp/azure_cli_install_tmp_1Nrb", line 140, in install_cli
    exec_command(cmd)
  File "C:/Users/justin/AppData/Local/Temp/azure_cli_install_tmp_1Nrb", line 100, in exec_command
    subprocess.check_call(command_list, cwd=cwd, env=env)
  File "C:\Python27\lib\subprocess.py", line 535, in check_call
    retcode = call(*popenargs, **kwargs)
  File "C:\Python27\lib\subprocess.py", line 522, in call
    return Popen(*popenargs, **kwargs).wait()
  File "C:\Python27\lib\subprocess.py", line 709, in __init__
    errread, errwrite)
  File "C:\Python27\lib\subprocess.py", line 957, in _execute_child
    startupinfo)
WindowsError: [Error 2] The system cannot find the file specified

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
sptramercommented, Oct 3, 2017

@derekbekoe Should the README just link to the install page on docs rather than containing its own install instructions? There are so many different recommended installation methods depending on the user system that I would be worried about drift.

EDIT Just saw this was already done. 👍

0reactions
justinmchasecommented, Oct 3, 2017

On second thought I guess I can just run everything through the subsystem… I have been using VS Code to do this but it looks like there may be a solution: https://github.com/Microsoft/vscode-cpptools/blob/master/Documentation/Debugger/gdb/Windows Subsystem for Linux.md

And if not I guess I can live with just doing it all through the subsystem. I’ll play around with it thanks.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Get help with Windows upgrade and installation errors
Make sure that your device has enough space. · Run Windows Update a few times. · Check third-party drivers and download any updates....
Read more >
[SOLVED] Windows 10 Installation Has Failed - Driver Easy
[SOLVED] Windows 10 Installation Has Failed · Try these fixes… · Fix 1: Remove the peripheral devices · Fix 2: Clear an attribute...
Read more >
4 Solutions to Fix Windows 10/11 Installation Has Failed
4 Solutions to Fix the "Windows 10/11 installation has failed" Error · Solution 1: Run a Clean Boot Installation · Solution 2: Create...
Read more >
How to Fix "Windows 10 Installation has Failed" Error? - Appuals
One potential reason you might see the error message “Windows 10 Installation has Failed” is if a key system dependency, process, or service...
Read more >
Windows 10 Installation Has Failed [Easily FIXED]
How do I fix Windows 10 installation failed? · 1. Unplug all peripheral devices · 2. Uninstall the language pack · 3. Uninstall...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found