Skip to content

add proxy capability - #74

Merged
whisk3y merged 1 commit into
dyninc:masterfrom
drewrothstein:master
Mar 18, 2016
Merged

add proxy capability#74
whisk3y merged 1 commit into
dyninc:masterfrom
drewrothstein:master

Conversation

@drewrothstein

Copy link
Copy Markdown
Contributor

This adds proxy capability to the connection logic. It is backwards compatible. It works with proxies that require authentication and ones that do not.

Attempted running tox but there were endless PEP8 errors that are unrelated to this change.

Local testing:

$ python setup.py install
>>> from dyn.tm.session import DynectSession
>>> s = DynectSession('company', 'user', 'pass', history=True)
>>> s.history
[('2016-03-18T00:05:37.941333', '/REST/Session/', 'POST', {'password': '*****', 'user_name': 'user', 'customer_name': 'company'}, u'success')]
>>> s = DynectSession.new_session('company', 'user', 'pass', history=True, proxy_host='localhost', proxy_port=8888)
>>> s.history
[('2016-03-18T00:06:30.882102', '/REST/Session/', 'POST', {'password': '*****', 'user_name': 'user', 'customer_name': 'customer'}, u'success')]
>>> s = DynectSession.new_session('company', 'user', 'pass', history=True, proxy_host='localhost', proxy_port=8888, proxy_user='user', proxy_pass='pass')
>>> s.history
[('2016-03-18T00:07:44.728913', '/REST/Session/', 'POST', {'password': '*****', 'user_name': 'user', 'customer_name': 'company'}, u'success')]

whisk3y added a commit that referenced this pull request Mar 18, 2016
@whisk3y
whisk3y merged commit a487185 into dyninc:master Mar 18, 2016
@whisk3y

whisk3y commented Mar 18, 2016

Copy link
Copy Markdown
Contributor

Hi Drew, looks good thanks for the commit!

@drewrothstein

Copy link
Copy Markdown
Contributor Author

Any chance of cutting a release? Looks like the last release was in 2014. :)

@whisk3y

whisk3y commented Mar 20, 2016

Copy link
Copy Markdown
Contributor

Hi Drew, there have actually been several releases in pip but they haven't been tagged on the repo. We plan on doing a release on Monday 3/21 and tagging the repo as well as updating pip. This release will be 1.6.3 and will include the proxy change and a new helper function to replace one or all rulesets on a TD.

@drewrothstein

Copy link
Copy Markdown
Contributor Author

Ah, most excellent, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants