Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gevent
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gevent
Commits
4e76c410
Commit
4e76c410
authored
Oct 10, 2016
by
Jason Madden
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
One more stab at fixing test__signal.
It appears the gevent.signal module is not the source of the problem.
parent
a8ad3b7e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
18 deletions
+12
-18
src/gevent/__init__.py
src/gevent/__init__.py
+1
-16
src/greentest/test__signal.py
src/greentest/test__signal.py
+11
-2
No files found.
src/gevent/__init__.py
View file @
4e76c410
...
...
@@ -82,24 +82,9 @@ from gevent import signal as _signal_module
class
_signal_metaclass
(
type
):
def
__getattr__
(
cls
,
name
):
val
=
getattr
(
_signal_module
,
name
)
if
name
==
'__cached__'
and
val
is
None
:
# In 3.6b1 on Travis, the signal module's
# __cached__ is somehow None, which breaks
# reloading because os.path.abspath blows up on None.
# It gracefully handles an AttributeError, though.
raise
AttributeError
(
name
)
if
name
==
'__cached__'
:
print
(
"Returning"
,
val
,
'for __cached__ on'
,
_signal_module
)
return
val
return
getattr
(
_signal_module
,
name
)
def
__setattr__
(
cls
,
name
,
value
):
# For symmetry with getattr and dir, pass all
# attribute setting on to the module. (This makes
# reloading work, see issue #805)
if
name
in
(
'__cached__'
,
'__file__'
):
# Py 3.6 issue
return
setattr
(
_signal_module
,
name
,
value
)
def
__instancecheck__
(
cls
,
instance
):
...
...
src/greentest/test__signal.py
View file @
4e76c410
...
...
@@ -67,8 +67,17 @@ if hasattr(signal, 'SIGALRM'):
# builtin on py2
reload_module
=
reload
# pylint:disable=undefined-variable
reload_module
(
site
)
try
:
reload_module
(
site
)
except
TypeError
:
assert
greentest
.
PY36
assert
greentest
.
RUNNING_ON_CI
for
m
in
set
(
sys
.
modules
.
values
()):
try
:
if
m
.
__cached__
is
None
:
print
(
"Module has None __cached__"
,
m
)
except
AttributeError
:
continue
if
__name__
==
'__main__'
:
greentest
.
main
()
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment