[openstack-dev] AttributeError: 'StackManager' object has no attribute 'event'

Heenashree Khandelwal heenashree2010 at gmail.com
Fri May 26 08:23:11 UTC 2017


Hi Team,

I am trying below code but the moment I run the code I am getting error.

try:
evntsdata = hc.stacks.event.list(stack_name=stack_name)

#evntsdata = hc.stacks.events.list(stack_name)

if evntsdata[-1] == 'UPDATE_IN_PROGRESS':
loopcontinue = True
while loopcontinue:
  evntsdata = (hc.stacks.event.list(stack_name)[0]).split(" ")
  if (evntsdata[-1] == 'UPDATE_COMPLETE'):
loopcontinue = False
print(str(timestamp()) + " " + "Stack Update is Completed!" + ' - ' +
evntsdata[-3] + ' = ' + evntsdata[-1])
  else:
print(str(timestamp()) + " " + "Stack Update in Progress!" + ' - ' +
evntsdata[-3] + ' = ' + evntsdata[-1])
time.sleep(10)
elif error_state == 'No updates are to be performed':
  exit(0)

except AttributeError as e:
  print(str(timestamp()) + " " + "ERROR: Stack Update Failure")
  raise


ERROR: Traceback (most recent call last):
  File
"C:/Users/hekh0517/PycharmProjects/untitled1/testingBotoStackUpdate.py",
line 86, in <module>
    evntsdata = hc.stacks.event.list(stack_name=stack_name)
AttributeError: 'StackManager' object has no attribute 'event'

I dont know why this error occurs
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20170526/4947373f/attachment.html>


More information about the OpenStack-dev mailing list