Skip to content

Releases: Emasoft/apias

v0.1.26 - Cost Estimation & Documentation

02 Dec 18:45

Choose a tag to compare

What's New in v0.1.26

New Features

  • Cost Estimation: New --estimate-cost CLI flag to preview API costs before processing
  • 3-Tier Cost Scenarios: Conservative (P50), Average (Mean), and Worst Case (P95) estimates
  • Model Comparison: View cost estimates across all 5 supported GPT-5 models

Documentation

  • API.md: Comprehensive programmatic API documentation (978 lines)
  • README: Fixed Python API examples, added missing CLI flags
  • Version Sync: All version references now consistent at 0.1.26

CLI Flags Added

  • --estimate-cost: Estimate costs before processing
  • --resume: Resume previous scraping session
  • --scrape-only: Scrape without AI processing
  • --whitelist / --blacklist: URL filtering patterns
  • --force-retry-count: Force specific retry count

Full Changelog

See CHANGELOG.md

v0.1.25: DRY Compliance - Terminal Utilities

02 Dec 01:43

Choose a tag to compare

DRY Principle Compliance (Terminal Utilities)

  • Add get_safe_terminal_width() and get_safe_terminal_height() - Centralized terminal size detection with platform-safe fallbacks
  • Update apias.py - Uses centralized terminal width detection (2 call sites consolidated)
  • Add quiet_print() wrapper - Helper function for quiet-mode-aware printing

Code Quality

  • Eliminate duplicate try/except patterns for terminal size detection
  • Centralize platform-safe fallbacks for headless/CI environments

Testing

  • All 351 tests pass (72.45% coverage)

Installation

pip install apias==0.1.25

v0.1.24: DRY Compliance - Status History Helper

02 Dec 01:36

Choose a tag to compare

DRY Principle Compliance (Continued)

  • Add URLTask.add_status_history() helper method - Consistent status tracking with automatic size limiting
  • Update status_pipeline.py - Uses helper instead of duplicated append/pop logic (2 call sites consolidated)

Documentation

  • Platform limitation comments for os.replace() - Documents Windows file locking and cross-device move limitations

Testing

  • All 351 tests pass (72.58% coverage)

Installation

pip install apias==0.1.24

v0.1.23 - DRY Compliance and Platform Compatibility

01 Dec 23:52

Choose a tag to compare

DRY Principle Compliance (Code Deduplication)

  • ErrorCategory enum consolidated into single source in event_system.py
  • RECOVERABLE_CATEGORIES consolidated into event_system.py
  • Removed duplicate format_size() from batch_tui.py - now imports from terminal_utils.py
  • Added centralized config constants:
    • EVENT_DISPATCH_TIMEOUT (50ms for standard event processing)
    • EVENT_DISPATCH_FAST_TIMEOUT (10ms for tight loop processing)
    • HTML_CHUNK_SIZE (80K chars default)
    • HTML_MAX_CHUNK_SIZE (200K chars max)
  • Updated apias.py, event_system.py, status_pipeline.py to use centralized constants

Platform Compatibility

  • Fixed terminal size detection in apias.py with try/except fallback for headless/CI environments
  • Added DEFAULT_TERMINAL_WIDTH fallback in _clear_line() and create_summary_box()

Documentation

  • Added comprehensive WHY/DO NOT comments explaining DRY consolidation decisions
  • Updated docstrings to reference centralized config constants

Test Results

  • All 351 tests pass
  • Coverage: 72.53% (above 72% threshold)

Full Changelog: v0.1.22...v0.1.23

v0.1.22 - Comprehensive Codebase Audit

01 Dec 23:20

Choose a tag to compare

Comprehensive Codebase Audit Fixes

This release addresses 8 critical and high-priority issues discovered during a comprehensive audit of the entire codebase.

Critical Fixes

Issue File Fix
Race condition in event dispatch event_system.py Make defensive copy of handlers list under lock
Terminal not restored terminal_utils.py Catch ALL exceptions, not just specific ones
Silent emit() failure logger_interceptor.py Track failures and report to stderr
TUI exception handling gaps batch_tui.py Add try-except with fallback to no-TUI mode
wait_for_start() infinite loop batch_tui.py Add should_stop check to loop condition
TOCTOU race condition dialog_manager.py Use while True with exception-based exit
Error collector documentation error_collector.py Document fail-fast consideration
os._exit() documentation apias.py Document intentional emergency exit behavior

Design Philosophy

All fixes include comprehensive WHY/DO NOT comments explaining:

  • Why the fix was necessary
  • What not to do in the future
  • Design decisions and trade-offs

Quality Assurance

  • All 351 tests pass
  • 72.35% code coverage (above 72% threshold)
  • mypy: no issues in 13 source files
  • ruff: all checks passed

Installation

pip install apias==0.1.22

Or upgrade:

pip install --upgrade apias

v0.1.21 - Critical Retry Loop Fixes

01 Dec 22:57

Choose a tag to compare

Critical Fixes (Retry Loop Audit)

This release addresses 6 critical and high-priority issues discovered during a comprehensive audit of the retry loop implementation from v0.1.20.

Fixes

  1. CRITICAL: Add missing circuit breaker check in retry loop

    • Retry loop was ignoring rate limits during retries
    • Now properly checks error_collector.is_tripped after each wait
  2. CRITICAL: Capture critical flag from wait_for_update()

    • Flag indicates circuit breaker events
    • Required for proper shutdown detection during retries
  3. HIGH: Remove double state update causing stats double-counting

    • Previously updated both status_pipeline AND batch_tui
    • Now only updates status_pipeline (render_snapshot syncs to TUI)
  4. HIGH: Update progress_tracker after each retry completes

    • Was missing, causing --resume to not see retry results
  5. MEDIUM: Save progress file after retry round completes

    • Ensures --resume has accurate state
  6. Add clarifying comment about cost tracking during retries

    • Cost is intentionally NOT subtracted on retry (tracks total spending)

Quality Assurance

  • All 351 tests pass
  • 72.62% code coverage
  • mypy: no issues in 13 source files
  • ruff: all checks passed

Installation

pip install apias==0.1.21

Or upgrade:

pip install --upgrade apias

v0.1.20 - Critical TUI Bug Fixes

30 Nov 18:25

Choose a tag to compare

Bug Fixes

  • Fix duration timers running forever after task completion (green 100% tasks)

    • Duration now freezes on first transition to COMPLETE/FAILED state
    • Prevents recalculation on subsequent render_snapshot() calls
  • Fix retry prompt not actually retrying failed tasks

    • When user presses "Y", failed tasks are now reprocessed immediately
    • Creates new ThreadPoolExecutor for retry processing
    • Properly resets task states and runs processing loop
  • Clarify mock mode cost estimates

    • Changed misleading "(no token costs)" to explain GPT-4 pricing simulation
    • Mock mode simulates costs to help estimate real API spending
  • Fix stats not updating correctly when retrying (FAILED -> PENDING)

  • Reset task duration/start_time when retrying for accurate tracking

Installation

Using uv (Recommended)

# Fresh install
uv tool install apias --python=3.10

# Upgrade existing installation
uv tool upgrade apias

Using pip

pip install apias==0.1.20

Full Changelog: v0.1.19...v0.1.20

v0.1.19 - Type Safety Improvements

30 Nov 17:03

Choose a tag to compare

Type Safety

  • Resolve all 17 mypy type errors for strict type checking
  • Add TypeVar for generic EventBus.subscribe() method
  • Unify URLState enum (import from batch_tui instead of duplicate)
  • Fix Callable type annotations in logger_interceptor.py
  • Add proper type annotations to context manager methods

Installation

Using uv (Recommended)

The fastest way to install APIAS is using uv:

uv tool install apias --python=3.10

Using pip

pip install apias==0.1.19

Full Changelog: v0.1.18...v0.1.19

v0.1.18 - Test Coverage Improvements

30 Nov 16:31

Choose a tag to compare

Test Coverage Improvements

This release significantly improves test coverage from 60% to 73%.

Testing

  • Add 105 new tests for TUI components
  • Add comprehensive test_batch_tui.py with 70 tests covering URLState, URLTask, BatchStats, BatchTUIManager
  • Extend test_tui.py with 35 new tests for terminal detection, spinners, keyboard handling
  • Add comprehensive test_retry.py with 23 tests for retry functionality and exponential backoff

Configuration

  • Adjust coverage threshold to 72% (TUI code requires extensive terminal mocking)

Documentation

  • Add child-friendly configuration guide to README explaining num_threads, max_retries, chunk_size

Stats

  • Total tests: 351 (up from 246)
  • Coverage: 72.98%

v0.1.17

30 Nov 12:59

Choose a tag to compare

Changelog

All notable changes to APIAS (API Auto Scraper) will be documented in this file.

The format is based on Keep a Changelog,
and this project adheres to Semantic Versioning.

[0.1.17] - 2025-11-30

Bug Fixes

  • Critical CI/CD and publishing infrastructure audit by @Emasoft

Documentation

  • Update documentation for Python 3.10+ requirement by @Emasoft
  • Add uv installation recommendation and update PyPI workflow to Python 3.10 by @Emasoft

Generated by git-cliff