Skip to content

'Foreman' object has no attribute 'lifecycle_environments' #98

Description

@achevalet

I'm trying to manage lifecycle environments from katello plugins and I'm not sure what's going wrong.. The 'lifecycle_environments' is present in the definitions retrieved from the running foreman instance but there is no attribute for it:

>>> from foreman.client import Foreman
>>> fm = Foreman('https://foreman.com', ('admin','password'), api_version=2, use_cache=False, strict_cache=True)
>>> defs = fm._get_remote_defs()
>>> print defs["docs"]["resources"]["lifecycle_environments"]
{u'api_url': u'/api', u'deprecated': False, u'metadata': None, u'full_description': u'\n<p># Description</p>\n\n<p>An environment is a basic organization structure that groups hosts,\nproducts, repositories, etc.
.....

>>> fm.lifecycle_environments
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'Foreman' object has no attribute 'lifecycle_environments'

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions