Packaging & Dependencies
Relevant source files
The following files were used as context for generating this wiki page:
Introduction
The flext-tap-oracle-oic project is a Singer Tap designed for Oracle Integration Cloud (OIC). It is built using the FLEXT framework, which enforces a standardized structure for dependency management, project metadata, and module exports. The project utilizes a modern Python toolchain centered around hatchling for builds and uv for workspace management, targeting Python 3.13 as its primary runtime environment.
The packaging architecture is designed to support both standard execution and integration within the Meltano ecosystem. It leverages lazy-loading mechanisms to optimize startup performance and maintains strict versioning through a centralized metadata system derived from the core FLEXT infrastructure.
Project Metadata and Build System
The project's foundational configuration is defined in pyproject.toml. It specifies the build backend and essential project identity information.
Build Configuration
- Build Backend:
hatchling.build - Requires:
hatchling - Python Version Support:
>=3.13,<3.14 - License: MIT
Sources: pyproject.toml:9-12, pyproject.toml:34-36
Project Identity
| Field | Value |
|---|---|
| Name | flext-tap-oracle-oic |
| Version | 0.12.0-dev |
| Author | FLEXT Team (team@flext.sh) |
| Description | Singer Tap for Oracle Integration Cloud |
Sources: pyproject.toml:29-38, src/flext_tap_oracle_oic/version.py:22-30
Dependency Management
The project categorizes dependencies into core runtime requirements and optional development groups. It specifically relies on the FLEXT ecosystem for its CLI, core logic, and Meltano integration capabilities.
Core Dependencies
The following packages are required for the tap to function:
flext-cli: Provides the command-line interface framework.flext-core: Contains the base logic and lazy-loading utilities.flext-meltano: Enables integration with Meltano.flext-oracle-oic: Provides OIC-specific domain logic.pydantic>=2.13.3: Used for data validation and settings management.requests>=2.33.1: Facilitates HTTP communication with the OIC API.
Sources: pyproject.toml:39-48
Development Dependencies
The dev optional dependency group includes tools for linting, testing, and documentation:
- Linting/Formatting:
black,ruff,isort,mypy. - Testing:
pytest,pytest-cov,hypothesis,factory-boy. - Documentation:
mkdocs,mkdocs-material,mkdocstrings. - Security:
bandit,pip-audit.
Sources: pyproject.toml:52-125
Module Exports and Lazy Loading
To maintain a clean public API while optimizing performance, the project implements a lazy export system. The __init__.py file utilizes install_lazy_exports to defer the loading of heavy modules until they are accessed.
The diagram shows how the package root manages its public surface area through a centralized lazy import map.
Sources: src/flext_tap_oracle_oic/init.py:17-84, src/flext_tap_oracle_oic/_exports_lazy_part_01.py:10-50
Package Data Models
The project defines specific entities to handle OIC-specific metadata, such as the OicPackageEntity. This model tracks integration packages and their internal dependencies.
OicPackageEntity Schema
| Field | Type | Description |
|---|---|---|
package_id | str | Unique package identifier |
name | str | Name of the package |
api_version | str | Version from OIC API |
dependencies | t.StrSequence | List of dependent package IDs |
status | OicIntegrationStatus | Current lifecycle state |
Sources: src/flext_tap_oracle_oic/_models/_package.py:38-95
Command Line Scripts
The package exposes two primary entry points through the project.scripts configuration in pyproject.toml:
flext-tap-oracle-oic: Callsflext_tap_oracle_oic.tap:TapOracleOic.clitap-oracle-oic: Alias for the same CLI entry point.
Sources: pyproject.toml:132-134, src/flext_tap_oracle_oic/tap.py:321-340
Summary
The flext-tap-oracle-oic package is a strictly typed, Python 3.13+ integration tool that adheres to the FLEXT architectural standards. By utilizing hatchling for builds and a robust set of dependencies including pydantic and flext-core, it ensures data integrity and performance through lazy-loading. Its dependency structure is managed via pyproject.toml, facilitating easy development and deployment within standard Python and Singer-based environments.