# Changelog

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog (https://keepachangelog.com/en/1.0.0/),
and this project adheres to Semantic Versioning (https://semver.org/spec/v2.0.0.html).

---

## [0.2.0] - 2025-11-25

### Added
- **Pico-Stack Auto-Discovery**: Added the standard `entry_point` definition (`pico_stack.modules`). Now, when using `pico-stack`, this library is automatically discovered and loaded without needing to manually add `"pico_celery"` to your modules list.

### Changed
- **Core Upgrade**: Bumped minimum requirement to `pico-ioc >= 2.1.3`. This aligns `pico-celery` with the latest memory management improvements in the IoC container (specifically the removal of LRU eviction in Scopes), ensuring greater stability for long-running worker processes.

---

## [0.1.1] - 2025-11-18

### Fixed
- **Critical:** `CeleryClientInterceptor` is now synchronous. Previously, it was `async def`, which caused a `RuntimeError` when intercepting synchronous client methods (`def create_task(...)`). It now correctly handles both sync and async execution contexts via `pico-ioc`.
- **Worker Stability:** The task wrapper generated by `PicoTaskRegistrar` now robustly handles existing event loops. If an event loop is already running in the worker thread (e.g., specific pool configurations), it delegates execution to a thread pool to avoid `RuntimeError: Cannot run the event loop while another loop is running`.

### Changed
- **Configuration Safety:** Removed default values (`redis://localhost...`) for `broker_url` and `backend_url` in `CelerySettings`. The application will now raise a clear `ConfigurationError` at startup if these values are not provided, preventing silent connection failures to phantom local services.

---

## [0.1.0] - 2025-11-16

### Added

- Initial pico-celery integration library for Pico-IoC and Celery.
- Async task decorator for component methods.
- Celery app factory based on Pico-IoC configuration.
- Automatic task discovery and registration through the Pico-IoC container.
- Basic tests and documentation.
