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

AttributeError: module 'signal' has no attribute 'SIGALRM' #26

Closed
seans11 opened this issue Dec 11, 2017 · 5 comments
Closed

AttributeError: module 'signal' has no attribute 'SIGALRM' #26

seans11 opened this issue Dec 11, 2017 · 5 comments

Comments

@seans11
Copy link

seans11 commented Dec 11, 2017

Error I'm receiving when running in Windows 10 with Python 3.6.2-32:

PS C:\Projects\test> python-lambda-local -t 15 -f lambda_handler .\test.py event.json
[root - INFO - 2017-12-11 10:13:42,817] Event: {'key1': 'value1', 'key2': 'value2', 'key3': 'value3'}
[root - INFO - 2017-12-11 10:13:42,817] START RequestId: 2df1ccc9-ba8a-48b8-aad4-ac41541a1e96
Process Process-1:
Traceback (most recent call last):
  File "c:\program files (x86)\python\python36-32\lib\site-packages\lambda_local\main.py", line 87, in execute
    with time_limit(context.timeout):
  File "c:\program files (x86)\python\python36-32\lib\contextlib.py", line 81, in __enter__
    return next(self.gen)
  File "c:\program files (x86)\python\python36-32\lib\site-packages\lambda_local\timeout.py", line 18, in time_limit
    signal.signal(signal.SIGALRM, signal_handler)
AttributeError: module 'signal' has no attribute 'SIGALRM'

I found the following issue raised from another project which might explain the problem:
Unity-Technologies/ml-agents#7

Looks like this is a Windows specific issue when calling signal.SIGALRM.

@yxd-hde
Copy link
Contributor

yxd-hde commented Dec 18, 2017

PR is welcomed to fix this on windows. Thanks.

@scarolan
Copy link

scarolan commented Feb 2, 2018

I'm glad someone reported this and that it's a known issue. I'm also seeing the same thing. I'll try and track down the cause.

@yxd-hde
Copy link
Contributor

yxd-hde commented Sep 3, 2018

See: #32

@freedomofkeima
Copy link
Collaborator

Implemented in #32, released via version 0.1.6.

@naveenbharadwaj19
Copy link

naveenbharadwaj19 commented May 23, 2020

Trying to get a playlist details by youtube api but getting error
signal.signal(signal.SIGALRM, self.handle_timeout) AttributeError: module 'signal' has no attribute 'SIGALRM'
python version : 3.7.7 64bit os: Windows 10

how to solve this ?
@yxd-hde i read the docs you mentioned but i couldn't understand it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants