<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic [acitoolkit] AttributeError: 'Tenant' object has no attribute 'has_event' in Controllers</title>
    <link>https://community.cisco.com/t5/controllers/acitoolkit-attributeerror-tenant-object-has-no-attribute-has/m-p/3562458#M3071</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm presently going through the acitoolkit docs (&lt;A href="https://acitoolkit.readthedocs.io/en/latest/subscriptions.html" title="https://acitoolkit.readthedocs.io/en/latest/subscriptions.html"&gt;https://acitoolkit.readthedocs.io/en/latest/subscriptions.html&lt;/A&gt;) and I've worked up to the subscriptions section.&amp;nbsp;&amp;nbsp; The particular problem that I'm getting is from the Instance subscription example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;bob = Tenant('Bob')&lt;/P&gt;&lt;P&gt;bob.subscribe(session)&lt;/P&gt;&lt;P&gt;while True:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if bob.has_event(session):&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; bobs_event = bob.get_event(session)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if bobs_event.is_deleted():&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; print 'Bob was deleted'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I created a different tenant than bob and changed my script to reflect that.&amp;nbsp; I verified at the APIC that the tenant was there; but when I go to run the code I get:&amp;nbsp; AttributeError: 'Tenant' object ahs not attribute 'has_event'.&amp;nbsp;&amp;nbsp;&amp;nbsp; A quick google search didn't really turn up anything and I don't see a section in the documentation for common errors.&amp;nbsp; There are also no similar posts here.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 13 Feb 2017 15:30:26 GMT</pubDate>
    <dc:creator>aapclark12</dc:creator>
    <dc:date>2017-02-13T15:30:26Z</dc:date>
    <item>
      <title>[acitoolkit] AttributeError: 'Tenant' object has no attribute 'has_event'</title>
      <link>https://community.cisco.com/t5/controllers/acitoolkit-attributeerror-tenant-object-has-no-attribute-has/m-p/3562458#M3071</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm presently going through the acitoolkit docs (&lt;A href="https://acitoolkit.readthedocs.io/en/latest/subscriptions.html" title="https://acitoolkit.readthedocs.io/en/latest/subscriptions.html"&gt;https://acitoolkit.readthedocs.io/en/latest/subscriptions.html&lt;/A&gt;) and I've worked up to the subscriptions section.&amp;nbsp;&amp;nbsp; The particular problem that I'm getting is from the Instance subscription example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;bob = Tenant('Bob')&lt;/P&gt;&lt;P&gt;bob.subscribe(session)&lt;/P&gt;&lt;P&gt;while True:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if bob.has_event(session):&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; bobs_event = bob.get_event(session)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if bobs_event.is_deleted():&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; print 'Bob was deleted'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I created a different tenant than bob and changed my script to reflect that.&amp;nbsp; I verified at the APIC that the tenant was there; but when I go to run the code I get:&amp;nbsp; AttributeError: 'Tenant' object ahs not attribute 'has_event'.&amp;nbsp;&amp;nbsp;&amp;nbsp; A quick google search didn't really turn up anything and I don't see a section in the documentation for common errors.&amp;nbsp; There are also no similar posts here.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 Feb 2017 15:30:26 GMT</pubDate>
      <guid>https://community.cisco.com/t5/controllers/acitoolkit-attributeerror-tenant-object-has-no-attribute-has/m-p/3562458#M3071</guid>
      <dc:creator>aapclark12</dc:creator>
      <dc:date>2017-02-13T15:30:26Z</dc:date>
    </item>
  </channel>
</rss>

