File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change 36
36
from cgi import parse_qs , parse_qsl
37
37
38
38
39
- VERSION = '1.0' # Hi Blaine!
39
+ import _version
40
+
41
+ __version__ = _version .__version__
42
+
43
+ OAUTH_VERSION = '1.0' # Hi Blaine!
40
44
HTTP_METHOD = 'GET'
41
45
SIGNATURE_METHOD = 'PLAINTEXT'
42
46
@@ -266,7 +270,7 @@ class Request(dict):
266
270
267
271
"""
268
272
269
- version = VERSION
273
+ version = OAUTH_VERSION
270
274
271
275
def __init__ (self , method = HTTP_METHOD , url = None , parameters = None ):
272
276
self .method = method
@@ -585,7 +589,7 @@ class Server(object):
585
589
"""
586
590
587
591
timestamp_threshold = 300 # In seconds, five minutes.
588
- version = VERSION
592
+ version = OAUTH_VERSION
589
593
signature_methods = None
590
594
591
595
def __init__ (self , signature_methods = None ):
@@ -612,7 +616,7 @@ def _get_version(self, request):
612
616
try :
613
617
version = request .get_parameter ('oauth_version' )
614
618
except :
615
- version = VERSION
619
+ version = OAUTH_VERSION
616
620
617
621
if version and version != self .version :
618
622
raise Error ('OAuth version %s not supported.' % str (version ))
You can’t perform that action at this time.
0 commit comments