Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
itminedu
kamaki
Commits
0d79eb23
Commit
0d79eb23
authored
Nov 30, 2012
by
Stavros Sachtouris
Browse files
Update comment docs for astakos client
parent
cb69a058
Changes
1
Hide whitespace changes
Inline
Side-by-side
kamaki/clients/astakos.py
View file @
0d79eb23
...
...
@@ -40,15 +40,12 @@ class AstakosClient(Client):
def
__init__
(
self
,
base_url
,
token
):
super
(
AstakosClient
,
self
).
__init__
(
base_url
,
token
)
def
raise_for_status
(
self
,
r
):
msg
=
r
.
text
.
strip
()
if
msg
:
raise
ClientError
(
msg
,
r
.
status_code
)
else
:
# Fallback to the default
super
(
AstakosClient
,
self
).
raise_for_status
(
r
)
def
authenticate
(
self
,
token
=
None
):
"""
:param token: (str) custom token to authenticate
:returns: (dict) authentication information
"""
if
token
:
self
.
token
=
token
r
=
self
.
get
(
'/im/authenticate'
)
...
...
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