Hyperopt: AttributeError: module 'signal' has no attribute 'SIGHUP'

Created on 27 Oct 2017  路  4Comments  路  Source: hyperopt/hyperopt

I try to run the mongo worker on windows and get the error below. Windows does not support SIGHUP therefore hyperopt is not compatible with windows while this is here.

File "C:\Users\s\Anaconda3\lib\site-packages\hyperopt\mongoexp.py", line 1182, in main_worker_helper
signal.signal(signal.SIGHUP, sighandler_shutdown)
AttributeError: module 'signal' has no attribute 'SIGHUP'

Most helpful comment

I managed to fix this for KernelGatewayApp. I just commented the line below in the
File ".............\lib\site-packages\kernel_gateway\gatewayapp.py", line 549, in start
signal.signal(signal.SIGHUP, signal.SIG_IGN)

my changes in the file:
# signal.signal(signal.SIGHUP, signal.SIG_IGN)

All 4 comments

Hi,

I managed to get the mongod (version 3.4) to run on my windows machine. And then, I followed the example in the wiki, which it seems to work fine as the fmin locks. After that, I ran the worker mongo and got the same error as reported by simonm3.

Is there a plan to fix this issue for Windows?

Many thanks,
Ivan

I would like to know if we have fix for the error reported .

image

@jve2kor @ivan-marroquin If you can give me any hints on how this should look like on windows, we might patch this. even better yet, consider sending a PR. looks like this is just one line to catch...

sorry, not on windows. impossible for me to track down.

I managed to fix this for KernelGatewayApp. I just commented the line below in the
File ".............\lib\site-packages\kernel_gateway\gatewayapp.py", line 549, in start
signal.signal(signal.SIGHUP, signal.SIG_IGN)

my changes in the file:
# signal.signal(signal.SIGHUP, signal.SIG_IGN)

Was this page helpful?
0 / 5 - 0 ratings