antsibull-core

3.5.0 · active · verified Thu Apr 16

antsibull-core is a foundational Python library providing core tools for building various components of the Ansible Distribution. It adheres to semantic versioning (1.0.0+), aiming for backward compatibility within major release cycles, though exceptions may occur for critical security fixes. The library is actively maintained, with the current development version being 3.x.y.

Common errors

Warnings

Install

Imports

Quickstart

Initialize basic contexts provided by antsibull-core. These contexts are typically used by other antsibull projects to manage application state, configuration, and interactions with the underlying Ansible environment.

from antsibull_core.context import LibContext, AppContext

# Example of initializing a library context (often used internally by other antsibull tools)
lib_ctx = LibContext()
print(f"Initialized LibContext: {lib_ctx}")

# Example of initializing an application context (often used internally by other antsibull tools)
app_ctx = AppContext(lib_context=lib_ctx, cwd="/tmp")
print(f"Initialized AppContext: {app_ctx}")

view raw JSON →