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
import pybit | |
import time | |
import bybitconfig | |
class CustomWS(pybit.WebSocket): | |
def _on_message(self, klass, message, *args, **kwargs): | |
return super(CustomWS, self)._on_message(message) | |
def _on_close(self, *args, **kwargs): |
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
from time import sleep | |
import pybit | |
class CustomWS(pybit.WebSocket): | |
def _on_message(self, klass, message, *args, **kwargs): | |
return super(CustomWS, self)._on_message(message) |
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
('ohlc4', '(close+open+low)/3', 6, 11) ===========> 2 | |
('ohlc4', '(high+open+low)/3', 13, 5) ===========> 2 | |
('ohlc4', 'open', 3, 2) ===========> 2 | |
('low', 'ohlc4', 9, 9) ===========> 2 | |
('ohlc4', '(high+open)/2', 12, 13) ===========> 2 | |
('ohlc4', '(high+open)/2', 5, 13) ===========> 2 | |
('ohlc4', 'open', 5, 5) ===========> 2 | |
('low', 'ohlc4', 7, 13) ===========> 2 | |
('ohlc4', 'high', 6, 13) ===========> 2 | |
('close', 'ohlc4', 8, 12) ===========> 2 |
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
[{'delay_between_function_start_and_event': '0:00:00.127088', | |
'func_run_delay': '0:01:41.860350', | |
'function_start': '2017-01-11T13:46:09.372088Z', | |
'last_modified': '2017-01-11T13:46:09.000000Z', | |
'run_count': 47, | |
'time_since_uploaded': '0:00:00.372088'}, | |
{'delay_between_function_start_and_event': '0:00:00.127942', | |
'func_run_delay': '0:01:29.650204', | |
'function_start': '2017-01-11T13:45:57.161942Z', | |
'last_modified': '2017-01-11T13:45:57.000000Z', |
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
[{'delay_between_function_start_and_event': '0:00:00.656663', | |
'func_run_delay': '0:00:00.105621', | |
'function_start': '2017-01-11T13:45:17.945663Z', | |
'last_modified': '2017-01-11T13:45:17.000000Z', | |
'run_count': 0, | |
'time_since_uploaded': '0:00:00.945663'}, | |
{'delay_between_function_start_and_event': '0:00:01.031817', | |
'func_run_delay': '0:00:49.438079', | |
'function_start': '2017-01-11T13:45:16.949817Z', | |
'last_modified': '2017-01-11T13:45:16.000000Z', |
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
[{'delay_between_function_start_and_event': '0:00:00.911491', | |
'func_run_delay': '0:00:00.100352', | |
'function_start': '2017-01-11T13:45:17.396491Z', | |
'last_modified': '2017-01-11T13:45:17.000000Z', | |
'run_count': 0, | |
'time_since_uploaded': '0:00:00.396491'}, | |
{'delay_between_function_start_and_event': '0:00:00.656663', | |
'func_run_delay': '0:00:00.105621', | |
'function_start': '2017-01-11T13:45:17.945663Z', | |
'last_modified': '2017-01-11T13:45:17.000000Z', |
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
'image_info': { | |
'oneOf': [ | |
{ | |
'type': 'object', | |
'properties': { | |
'height': { | |
'type': 'integer', | |
'minimum': 1 | |
}, | |
'width': { |
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
{ | |
"result": [ | |
{ | |
"company_id": 10231426, | |
"data": { | |
"columns": [ | |
{ | |
"technical_operations": [ | |
55, | |
55, |
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
import urllib.request | |
from bs4 import BeautifulSoup | |
def get_hmtl(url): | |
response = urllib.request.urlopen(url) | |
return response.read() | |
def parse(html): |
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
Environment: | |
Request Method: GET | |
Request URL: http://127.0.0.1:8000/declar/company/1/w/ | |
Django Version: 1.8.4 | |
Python Version: 2.7.6 | |
Installed Applications: | |
(u'django.contrib.admin', |
NewerOlder