-
Notifications
You must be signed in to change notification settings - Fork 761
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
16 additions
and
122 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -26,4 +26,4 @@ | |
from ._logging import * | ||
from ._socket import * | ||
|
||
__version__ = "0.50.0" | ||
__version__ = "0.51.0" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -127,16 +127,16 @@ def __init__(self, url, header=None, | |
self.header = header if header is not None else [] | ||
self.cookie = cookie | ||
|
||
self.on_open = on_open or getattr(self, 'on_open', None) | ||
self.on_message = on_message or getattr(self, 'on_message', None) | ||
self.on_data = on_data or getattr(self, 'on_data', None) | ||
self.on_error = on_error or getattr(self, 'on_error', None) | ||
self.on_close = on_close or getattr(self, 'on_close', None) | ||
self.on_ping = on_ping or getattr(self, 'on_ping', None) | ||
self.on_pong = on_pong or getattr(self, 'on_pong', None) | ||
self.on_cont_message = on_cont_message or getattr(self, 'on_cont_message', None) | ||
self.get_mask_key = get_mask_key or getattr(self, 'get_mask_key', None) | ||
self.on_open = on_open | ||
self.on_message = on_message | ||
self.on_data = on_data | ||
self.on_error = on_error | ||
self.on_close = on_close | ||
self.on_ping = on_ping | ||
self.on_pong = on_pong | ||
self.on_cont_message = on_cont_message | ||
self.keep_running = False | ||
self.get_mask_key = get_mask_key | ||
self.sock = None | ||
self.last_ping_tm = 0 | ||
self.last_pong_tm = 0 | ||
|
@@ -311,7 +311,6 @@ def create_dispatcher(self, ping_timeout): | |
def _get_close_args(self, data): | ||
""" this functions extracts the code, reason from the close body | ||
if they exists, and if the self.on_close except three arguments """ | ||
import inspect | ||
# if the on_close callback is "old", just return empty list | ||
if sys.version_info < (3, 0): | ||
if not self.on_close or len(inspect.getargspec(self.on_close).args) != 3: | ||
|
@@ -330,7 +329,7 @@ def _get_close_args(self, data): | |
def _callback(self, callback, *args): | ||
if callback: | ||
try: | ||
if inspect.ismethod(callback) and isinstance(callback.__self__, WebSocketApp): | ||
if inspect.ismethod(callback): | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
engn33r
Collaborator
|
||
callback(*args) | ||
else: | ||
callback(self, *args) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Looks like the revert isn't done cleanly.
ismethod
shouldn't be here.