Cua Core Library

0.1.19 · active · verified Sun Apr 12

cua-core is a Python library providing core utilities and telemetry functionality for the Cua ecosystem. It includes shared components for configuration, logging, versioning, and OpenTelemetry integration. Currently at version 0.1.19, it is designed primarily as a dependency for other Cua-related libraries and is explicitly not intended for direct end-user applications. Its release cadence is likely tied to the development cycles of other Cua projects.

Warnings

Install

Imports

Quickstart

Demonstrates a basic interaction with `cua-core` by retrieving its version, highlighting its utility-centric nature. It also provides a commented example for `TelemetryClient` with a reminder about its dependency role and GCP requirements.

from cua_core.utils import get_library_version

# Retrieve the version of the cua-core library itself.
# This function provides a simple, direct interaction with the library's utilities.
library_version = get_library_version()
print(f"Cua Core Library Version: {library_version}")

# Further utilities exist in cua_core.utils and cua_core.telemetry,
# but their direct usage is generally discouraged as cua-core is primarily a dependency.
# For example, to instantiate a TelemetryClient:
# from cua_core.telemetry import TelemetryClient
# tele_client = TelemetryClient(project_id=os.environ.get('GCP_PROJECT_ID', 'your-gcp-project-id'), service_name="my-app")
# However, this requires a valid GCP project ID and is usually handled by higher-level Cua libraries.

view raw JSON →