-
Notifications
You must be signed in to change notification settings - Fork 445
Add support for the oAuth flag #115
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
@hugoboos thank you for the submission! We'll need a few things before we can review:
|
|
Hi,
|
|
Thank you @hugoboos ! I checked and the CLA stuff is all in motion. Once it's in I'll officially review the code. For the 3rd item, I think just making a WorkbookItem and calling the method |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some small requests
(And we've confirmed the CLA is good to go!)
| """ | ||
|
|
||
| def __init__(self, name, password, embed=True): | ||
| def __init__(self, name, password, embed=True, oauth=True): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this should default to 'false' since most connections don't need an oAuth parameter (and I'm not sure what they'll do if both are present)
| credentials_element.attrib['name'] = connection_credentials.name | ||
| credentials_element.attrib['password'] = connection_credentials.password | ||
| credentials_element.attrib['embed'] = 'true' if connection_credentials.embed else 'false' | ||
| credentials_element.attrib['oAuth'] = 'true' if connection_credentials.oauth else 'false' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Even with my above comment, this would be including the oauth parameter in all requests, even if it's not an oauth enabled connection... Can you test and see if that causes a problem? If it does I suggest defaulting to None and then doing something like:
if connection_credentials.oauth is not None:
redentials_element.attrib['oAuth'] = 'true'There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will check for that.
|
I have looked up the REST API documentation and only when the connection is oAuth, you should set it to true. So adding |
t8y8
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚀
Looks great!
|
🚀 |

No description provided.