iron-io/iron_core_python

'IronClient' object has no attribute 'path_prefix'

shawnps opened this issue · 0 comments

Hello,

We use the iron mq python client installed via pip, and it's been failing recently with:

  File "/home/travis/virtualenv/python2.7.8/lib/python2.7/site-packages/iron_mq.py", line 252, in __init__
    version=IronMQ.VERSION, product="iron_mq", **kwargs)
  File "/home/travis/virtualenv/python2.7.8/lib/python2.7/site-packages/iron_core.py", line 175, in __init__
    self.base_url = "%s://%s%s/%s/" % (self.protocol, self.host, self.path_prefix, self.api_version)
AttributeError: 'IronClient' object has no attribute 'path_prefix'

I noticed that path_prefix was added recently to iron_core and it seems like it might not be set in this if statement on line 175:

if self.protocol == "https" and self.port == 443:
    self.base_url = "%s://%s%s/%s/" % (self.protocol, self.host, self.path_prefix, self.api_version)