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

setup.py install cryptic error when cmake is missing #436

Closed
bhargav-95 opened this issue May 2, 2019 · 25 comments
Closed

setup.py install cryptic error when cmake is missing #436

bhargav-95 opened this issue May 2, 2019 · 25 comments
Assignees
Labels
build wontfix This will not be worked on

Comments

@bhargav-95
Copy link

Traceback (most recent call last):
File "setup.py", line 57, in

File "C:\ProgramData\Anaconda3\lib\runpy.py", line 263, in run_path
pkg_name=pkg_name, script_name=fname)
File "C:\ProgramData\Anaconda3\lib\runpy.py", line 96, in _run_module_code
mod_name, mod_spec, pkg_name, script_name)
File "C:\ProgramData\Anaconda3\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Users\I0000847\Documents\Time series Anomaly detection packages\nupic
.cpp-master\bindings\py\packaging\setup.py", line 226, in
getExtensionFiles(platform)
File "C:\Users\I0000847\Documents\Time series Anomaly detection packages\nupic
.cpp-master\bindings\py\packaging\setup.py", line 182, in getExtensionFiles
generateExtensions()
File "C:\Users\I0000847\Documents\Time series Anomaly detection packages\nupic
.cpp-master\bindings\py\packaging\setup.py", line 211, in generateExtensions
subprocess.check_call(["cmake", PY_VER, REPO_DIR])
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 286, in check_call
retcode = call(*popenargs, **kwargs)
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 267, in call
with Popen(*popenargs, **kwargs) as p:
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 707, in init
restore_signals, start_new_session)
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 990, in _execute_child

startupinfo)

FileNotFoundError: [WinError 2] The system cannot find the file specified

@bhargav-95
Copy link
Author

python setup.py install --user --force

This is how i try to install (pretty basic) from the root directory of the folder

@dkeeney
Copy link

dkeeney commented May 2, 2019

We don't currently support Anaconda although other people in the blog have been able to get it to work.

@breznak breznak added the build label May 2, 2019
@breznak breznak changed the title Issue with installing Nupic.cpp update via setup option Issue with installing Nupic.cpp with Anaconda python May 2, 2019
@breznak
Copy link
Member

breznak commented May 2, 2019

Thank you both for looking into this!
We don't currently have resources and motivation to support Anaconda python builds (this is documented in the Readme), so I'm marking this as won't fix.
On the other hand, if @bhargav-95 or someone can put a PR with the support, I'll be open to merging that.

@breznak breznak closed this as completed May 2, 2019
@breznak breznak added the wontfix This will not be worked on label May 2, 2019
@bhargav-95
Copy link
Author

bhargav-95 commented May 2, 2019 via email

@breznak
Copy link
Member

breznak commented May 2, 2019

I'm trying to do a pip install . This is not on anaconda . It is for Python 3.7

pip install nupic.cpp is not supported yet, python setup.py install is.
Can you post the command you use to install and the output setup.py should print?

@breznak breznak reopened this May 2, 2019
@bhargav-95 bhargav-95 changed the title Issue with installing Nupic.cpp with Anaconda python Issue with installing Nupic.cpp with python setup.py install May 6, 2019
@bhargav-95
Copy link
Author

I navigate to the directory where setup.py is located.
Then , type this command..

python setup.py install

@bhargav-95
Copy link
Author

python setup.py install --user --force

This is how i try to install (pretty basic) from the root directory of the folder

@breznak
Copy link
Member

breznak commented May 6, 2019

ok, that seems correct.

and the output setup.py should print?

@bhargav-95
Copy link
Author

It should say nupic-cpp is successfully installed.

But I get the following error.

python setup.py install

**setup.py: Calling C:\Users\I0000847\Documents\Time series Anomaly detection pack
ages\nupic.cpp-master\bindings\py\packaging\setup.py

****Traceback (most recent call last):
File "setup.py", line 57, in

File "C:\ProgramData\Anaconda3\lib\runpy.py", line 263, in run_path
pkg_name=pkg_name, script_name=fname)
File "C:\ProgramData\Anaconda3\lib\runpy.py", line 96, in _run_module_code
mod_name, mod_spec, pkg_name, script_name)
File "C:\ProgramData\Anaconda3\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Users\I0000847\Documents\Time series Anomaly detection packages\nupic
.cpp-master\bindings\py\packaging\setup.py", line 226, in
getExtensionFiles(platform)
File "C:\Users\I0000847\Documents\Time series Anomaly detection packages\nupic
.cpp-master\bindings\py\packaging\setup.py", line 182, in getExtensionFiles
generateExtensions()**
File "C:\Users\I0000847\Documents\Time series Anomaly detection packages\nupic
.cpp-master\bindings\py\packaging\setup.py", line 211, in generateExtensions
subprocess.check_call(["cmake", PY_VER, REPO_DIR])
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 286, in check_call
retcode = call(*popenargs, **kwargs)
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 267, in call
with Popen(*popenargs, **kwargs) as p:
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 707, in init
restore_signals, start_new_session)
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 990, in _execute_child

startupinfo)

FileNotFoundError: [WinError 2] The system cannot find the file specified****

@breznak
Copy link
Member

breznak commented May 6, 2019

C:\Users\I0000847\Documents\Time series Anomaly detection pack
ages\nupic.cpp-master\bindings\py\packaging\setup.py

can you verify the file exists actually?
if it does, can you please try moving nupic.cpp-master to a path without spaces?

@bhargav-95
Copy link
Author

Yes it does.
PFA screenshot.

@bhargav-95
Copy link
Author

I renamed the path and tried ..
python setup.py install
github

@bhargav-95
Copy link
Author

Still the same issue

@breznak
Copy link
Member

breznak commented May 6, 2019

Yes it does.

no, that is the 1st one, setup.py, the other is in bindings\py\packaging\
...but I expect it'd exist unless you've manually deleted it

@bhargav-95
Copy link
Author

Yes that exists
too

@bhargav-95
Copy link
Author

github2

@breznak
Copy link
Member

breznak commented May 6, 2019

Can you test with #449 please? or wait once it's merged to master.

@bhargav-95
Copy link
Author

JUst tested with #449

....

C:\Users\I0000847\Documents\ts_ad_packages\nupic.cpp-master_new\nupic.cpp-master

python setup.py install

setup.py: Calling C:\Users\I0000847\Documents\ts_ad_packages\nupic.cpp-master_ne
w\nupic.cpp-master\bindings\py\packaging\setup.py

Traceback (most recent call last):
File "setup.py", line 57, in

File "C:\ProgramData\Anaconda3\lib\runpy.py", line 263, in run_path
pkg_name=pkg_name, script_name=fname)
File "C:\ProgramData\Anaconda3\lib\runpy.py", line 96, in _run_module_code
mod_name, mod_spec, pkg_name, script_name)
File "C:\ProgramData\Anaconda3\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Users\I0000847\Documents\ts_ad_packages\nupic.cpp-master_new\nupic.cp
p-master\bindings\py\packaging\setup.py", line 226, in
getExtensionFiles(platform)
File "C:\Users\I0000847\Documents\ts_ad_packages\nupic.cpp-master_new\nupic.cp
p-master\bindings\py\packaging\setup.py", line 182, in getExtensionFiles
generateExtensions()
File "C:\Users\I0000847\Documents\ts_ad_packages\nupic.cpp-master_new\nupic.cp
p-master\bindings\py\packaging\setup.py", line 211, in generateExtensions
subprocess.check_call(["cmake", PY_VER, REPO_DIR])
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 286, in check_call
retcode = call(*popenargs, **kwargs)
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 267, in call
with Popen(*popenargs, **kwargs) as p:
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 707, in init
restore_signals, start_new_session)
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 990, in _execute_child

startupinfo)

FileNotFoundError: [WinError 2] The system cannot find the file specified

@breznak
Copy link
Member

breznak commented May 6, 2019

File "C:\Users\I0000847\Documents\ts_ad_packages\nupic.cpp-master_new\nupic.cp
p-master\bindings\py\packaging\setup.py", line 211, in generateExtensions
subprocess.check_call(["cmake", PY_VER, REPO_DIR])

seems setup.py (even the one in packaging/) is running.

  • do you have cmake installed? what's output of command line: cmake --version ?
  • can you edit the script to print PY_VER, REPO_DIR before the line 211?

@bhargav-95
Copy link
Author

Nope cmake is not installed

@bhargav-95
Copy link
Author

PY_VER : -DBINDING_BUILD=Python3
REPO_DIR : /home
not
/home/bindings/py/packaging/
where the other setup.py resides

@breznak
Copy link
Member

breznak commented May 6, 2019

Nope cmake is not installed

well, if you see README, cmake is a requirement!
Once you install it, this should run fine

@breznak
Copy link
Member

breznak commented May 6, 2019

@dkeeney to avoid problems like this, can we check in setup.py that the cmake binary exists and give a clearer error message if not?

@breznak breznak changed the title Issue with installing Nupic.cpp with python setup.py install setup.py install cryptic error when cmake is missing May 6, 2019
@dkeeney
Copy link

dkeeney commented May 6, 2019

Sounds like a reasonable thing to do.

@breznak
Copy link
Member

breznak commented Jun 2, 2020

We do (maybe) support anaconda python and cmake is a part of pip dependencies.

@breznak breznak closed this as completed Jun 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

3 participants