- Full English API/class/method documentation for core CherryPick classes:
* Binding<T>
* BindingResolver<T>
* CycleDetector and CycleDetectionMixin
* GlobalCycleDetector and GlobalCycleDetectionMixin
* Factory<T>
* Module
* Scope
- Each public and private method is now documented in clear DartDoc style with usages
- Added code samples for modules, scope, subscopes, DI resolve/async, cycle detection
- Russian comments completely replaced with English for consistency
- NO logic or API changes, documentation and devex improvement only
Also updated: pubspec.lock for workspace/example folders (auto by dependency changes)
- Call observer.onInstanceDisposed for every removed/cleaned-up instance in Scope lifecycle
- Makes instance disposal fully observable outside of cache events
- Ensures analytics/logging frameworks get notified of each object removal from memory
Part of complete CherryPickObserver integration for transparent diagnostics and monitoring of DI container.
BREAKING CHANGE:
- Removed the deprecated CherryPickLogger interface from cherrypick
- Logger/adapters (e.g., talker_cherrypick_logger) must now implement CherryPickObserver
- talker_cherrypick_logger: replace TalkerCherryPickLogger with TalkerCherryPickObserver
- All usages, docs, tests migrated to observer API
- Improved test mocks and integration tests for observer pattern
- Removed obsolete files: cherrypick/src/logger.dart, talker_cherrypick_logger/src/talker_cherrypick_logger.dart
- Updated README and example usages for new CherryPickObserver model
This refactor introduces a unified observer pattern (CherryPickObserver) to handle all DI lifecycle events, replacing the limited info/warn/error logger pattern.
All external logging adapters and integrations must migrate to use CherryPickObserver.
- Introduce an 'Additional Modules' section before 'Contributing'
- Document cherrypick_annotations, cherrypick_generator, and cherrypick_flutter with pub.dev and README links
- Move and consolidate 'Advanced Features' sections, including Logging, Circular Dependency Detection, Hierarchical Subscopes, and Performance Improvements
- Reword and reorganize 'Disposable' and 'Dependency Resolution API' sections
- Clean up list styling and table of contents for accuracy
- Add clarity to documentation links and info blocks
- Added 'Using Annotations & Code Generation' section explaining DI annotations flow.
- Included full table of supported annotations, practical usage examples, setup steps, troubleshooting, and references.
- Improves onboarding for CherryPick users using @injectable, @module, @provide, @named, @scope, @params and related features.
See doc/annotations_en.md and generator/module READMEs for extended docs.
BREAKING CHANGE: closeRootScope is now async (returns Future<void> and must be awaited). This change improves resource lifecycle management by allowing asynchronous cleanup when disposing the root Scope. All usages of closeRootScope should be updated to use await.
- Change closeRootScope from void to Future<void> and add async keyword
- Await _rootScopefor correct async disposal
- Ensures proper disposal and better future extensibility for async resources
Closes #xxx (replace if issue exists)
- Added FAQ section in documentation (README and tutorials, EN + RU) recommending always using await when calling CherryPick.closeRootScope, scope.closeScope, or scope.dispose, even if no services implement Disposable.
- Clarifies future-proof resource management for all users.
- Added FAQ section in documentation (README and tutorials, EN + RU) recommending always using await when calling CherryPick.closeRootScope, scope.closeScope, or scope.dispose, even if no services implement Disposable.
- Clarifies future-proof resource management for all users.
feat(core,doc): unified async dispose mechanism for resource cleanup
BREAKING CHANGE:
- Added full support for asynchronous resource cleanup via a unified FutureOr<void> dispose() method in the Disposable interface.
- The Scope now provides only Future<void> dispose() for disposing all tracked resources and child scopes (sync-only dispose() was removed).
- All calls to cleanup in code and tests (scope itself, subscopes, and custom modules) now require await ...dispose().
- Documentation and all examples updated: resource management is always async and must be awaited; Disposable implementers may use both sync and async cleanup.
- Old-style, synchronous cleanup methods have been completely removed (API is now consistently async for all DI lifecycle management).
- Example and tutorial code now demonstrate async resource disposal patterns.
- Introduce CherryPickLogger interface, PrintLogger and SilentLogger implementations
- Add setGlobalLogger() to CherryPick API for custom DI logging
- Log key events (scope, module, error) via logger throughout DI lifecycle
- Comprehensive comments and code documentation in both English and Russian
- Document usage of logging system in quick_start and full_tutorial documentation (EN/RU)
- Provide usage examples in docs and code comments
- No logging inside GlobalCycleDetectionMixin (design choice: exceptions handled at Scope, not detector/mixin level) and detailed architectural reasoning
- Update helper.dart, logger.dart: comments, examples, API doc improvements
BREAKING CHANGE: Projects can now inject any logger via CherryPick.setGlobalLogger; default log behavior clarified and docstrings/usage examples enhanced