feat!: remove python-inject dependency#752
Merged
Merged
Conversation
This is a breaking change. ahb_context is now required on all evaluation entry points. The inject-based API has been removed. See the v1.3.0 release notes for migration instructions. BREAKING CHANGE: python-inject is no longer a dependency. All functions that previously used inject now require an explicit AhbContext parameter. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Execute all notebook cells with outputs captured (inject-free) - Format notebook with black - Add Quick Start code example to README showing AhbContext usage Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…ADME Quick Start Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
injectfrompyproject.tomldependencies and all source/test codeahb_context: AhbContexta required parameter on all evaluation entry points (evaluate_ahb_expression_tree,requirement_constraint_evaluation,format_constraint_evaluation,ConditionNodeBuilder, etc.)EvaluatableDataProviderclass,create_and_inject_hardcoded_evaluatorsfunction, all@inject.paramsdecorators, and theinject.InjectorExceptioncatch inEvaluator.__init__AhbContextdirectly instead ofinject.configure/inject.cleartest_warning_when_using_inject_attr.py(no longer relevant)minimal_working_example.ipynbto use onlyAhbContext-based APIThis is PR 12 in the AhbContext migration series. All previous PRs added dual-path support (inject fallback + AhbContext). This PR removes the fallback entirely.
BREAKING CHANGE
python-injectis no longer a dependency. All functions that previously used inject now require an explicitAhbContextparameter. See the v1.3.0 release notes for migration instructions.Functions where
ahb_contextremainsOptional[AhbContext] = None:parse_expression_including_unresolved_subexpressions(only needed whenresolve_packages=True)extract_categorized_keys(only needed whenresolve_packages=True)expand_packagesTest plan
pytest unittests/ -q)pylint src/ahbicht)--check)injectis not importable in the clean venv (removed from deps)🤖 Generated with Claude Code