mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-08 06:12:51 +00:00
Fix ziploader for the cornercase of ansible invoking ansible.
* Make ziploader's ansible and ansible.module_utils libraries into namespace packages. * Move __version__ and __author__ from ansible/__init__ to ansible/release.py. This is because namespace packages only load one __init__.py. If that is not the __init__.py with the author and version info then those won't be available. * In ziplaoder, move the version ito ANSIBLE_CONSTANTS. * Change PluginLoader to properly construct the path to the plugins even when namespace packages are present.
This commit is contained in:
@@ -19,5 +19,10 @@
|
||||
from __future__ import (absolute_import, division, print_function)
|
||||
__metaclass__ = type
|
||||
|
||||
__version__ = '2.2.0'
|
||||
__author__ = 'Ansible, Inc.'
|
||||
# Note: Do not add any code to this file. The ansible module may be
|
||||
# a namespace package when using Ansible-2.1+ Anything in this file may not be
|
||||
# available if one of the other packages in the namespace is loaded first.
|
||||
#
|
||||
# This is for backwards compat. Code should be ported to get these from
|
||||
# ansible.release instead of from here.
|
||||
from ansible.release import __version__, __author__
|
||||
|
||||
Reference in New Issue
Block a user