project-everest / everest

https://project-everest.github.io/
Apache License 2.0
193 stars 29 forks source link

`./everest check` should ask to install Python2 only on Windows #85

Closed tahina-pro closed 3 years ago

tahina-pro commented 3 years ago

Reported by @nikswamy

Symptom

Running the everest script on an ubuntu VM, it fails with this:

WARNING: python not found in PATH
ERROR: python2 not found in PATH
Do you want to install a Cygwin python2?
Cygwin setup not found, downloading it
--2021-07-29 01:01:47--  https://cygwin.com/setup-x86_64.exe
Resolving cygwin.com (cygwin.com)... 8.43.85.97
Connecting to cygwin.com (cygwin.com)|8.43.85.97|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 1355283 (1.3M) [application/octet-stream]
Saving to: ‘setup-x86_64.exe’

setup-x86_64.exe            100%[=========================================>]   1.29M  --.-KB/s    in 0.05s

2021-07-29 01:01:47 (24.9 MB/s) - ‘setup-x86_64.exe’ saved [1355283/1355283]

./setup-x86_64.exe --no-desktop --no-shortcuts --no-startmenu --wait --quiet-mode --packages=python2
run-detectors: unable to find an interpreter for ./setup-x86_64.exe

Somehow it got confused into thinking that it should run Cygwin??

Solution

This check at https://github.com/project-everest/everest/blob/master/everest#L774 should be enclosed in a if is_windows