Problem with shotgun after adding proxy.

Hi
we added proxy for our shotgun and even after updating the proxy tab in the event options it gives this error after I execute a simple script for getting data from shotgun with the API:

Traceback (most recent call last):
File “DeadlineUI/Commands/ScriptCommands.py”, line 109, in InnerExecute
PythonNetException: AttributeError : ‘NoneType’ object has no attribute ‘PROXY_TYPE_HTTP’
File “\mothership\DeadlineRepository8\scripts\Slaves\asd.py”, line 17, in
print sg.find_one(“Project”,filter,)
File “C:\Users\vgyurov\AppData\Local\Thinkbox\Deadline8\pythonAPIs\10122016 205503\shotgun_api3\shotgun.py”, line 690, in find_one
additional_filter_presets=additional_filter_presets)
File “C:\Users\vgyurov\AppData\Local\Thinkbox\Deadline8\pythonAPIs\10122016 205503\shotgun_api3\shotgun.py”, line 821, in find
if self.server_caps.version and self.server_caps.version >= (3, 3, 0):
File “C:\Users\vgyurov\AppData\Local\Thinkbox\Deadline8\pythonAPIs\10122016 205503\shotgun_api3\shotgun.py”, line 607, in server_caps
self.info())
File “C:\Users\vgyurov\AppData\Local\Thinkbox\Deadline8\pythonAPIs\10122016 205503\shotgun_api3\shotgun.py”, line 640, in info
return self._call_rpc(“info”, None, include_auth_params=False)
File “C:\Users\vgyurov\AppData\Local\Thinkbox\Deadline8\pythonAPIs\10122016 205503\shotgun_api3\shotgun.py”, line 2812, in _call_rpc
self.config.api_path, encoded_payload, req_headers)
File “C:\Users\vgyurov\AppData\Local\Thinkbox\Deadline8\pythonAPIs\10122016 205503\shotgun_api3\shotgun.py”, line 2953, in _make_call
return self._http_request(verb, path, body, req_headers)
File “C:\Users\vgyurov\AppData\Local\Thinkbox\Deadline8\pythonAPIs\10122016 205503\shotgun_api3\shotgun.py”, line 3002, in _http_request
conn = self._get_connection()
File “C:\Users\vgyurov\AppData\Local\Thinkbox\Deadline8\pythonAPIs\10122016 205503\shotgun_api3\shotgun.py”, line 3223, in _get_connection
pi = ProxyInfo(socks.PROXY_TYPE_HTTP, self.config.proxy_server,self.config.proxy_port,
proxy_user=self.config.proxy_user,proxy_pass=self.config.proxy_pass)

If I execute it outside of deadline its ok.

It looks like the “asd.py” script is not catching a case where “socks” could be NULL. I’m assuming some kind of connection problem came up…

Are you working on asd.py? I can’t find it in our internal Git repo. Want to send it along for this one? I need to see how you’re creating your instance of “socks”.

Hi,
Im not doing anything fancy with it.Im just calling sg.find_one() for test :>.

import shotgun_api3
key=""
script=""
proxy=""

sg=shotgun_api3.Shotgun("",script,key,True,proxy,connect=False)
filter=[[“id”,“is”,102]]
print sg.find_one(“Project”,filter,)

Just an update for all here. I’ve got a working scenario now without a proxy. Next step is to start up some kind of web-forward for testing. We’re going to try for Squid here and see if I get any problems. I’m expecting something could go wrong if the SSL outbound rule isn’t passed as normal, but we’ll have to see.

Okay! Well, I’ve absolutely reproduced this via Deadline (our IT guy Darren works fast :smiley:)

How are you setting things up to run it outside of Deadline? I should try to replicate that as best I can.

Hi,
really sry for the late replay :>.The test script is not bind to deadline in any way at the moment.It simply sends request with the API through the proxy.

import shotgun_api3
key=""
script=""
proxy=""

sg=shotgun_api3.Shotgun("",script,key,True,proxy,connect=False)
filter=[[“id”,“is”,102]]
print sg.find_one(“Project”,filter,)

If I execute this in lets say Nuke or 3ds max or anywhere using python it gives me the right result,however when I make it to be in lets say General script in the general folder then run it through Deadline Monitor->Scripts it refuses the access T_T.

Got it! Okay, I’ll pass this over to the integration team since I can pretty clearly reproduce.

Thank you for the fast replays and help.

Welcome! Do you have any workarounds at the moment, or should I try and bump this up in priority for the dev team?

At the moment we are submitting through RV so its ok-ish ,but we will need it as soon as possible :>.