Skip to content

Conversation

@kylejuliandev
Copy link
Contributor

This PR

With the release of v2.9.0 and the new Hosting library, we should no longer be publishing new versions of the Dependency Injection package. This package will need to be flagged as deprecated directly in NuGet. This PR removes the unused code and unit tests, and fixes a reference in the AotCompatiability project with a Hosting reference.

Related Issues

Fixes #539

Notes

Follow-up Tasks

How to test

@kylejuliandev kylejuliandev requested a review from a team as a code owner November 2, 2025 16:02
@gemini-code-assist
Copy link

Summary of Changes

Hello @kylejuliandev, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request focuses on a significant refactoring effort to remove the deprecated Dependency Injection package. This change is a direct consequence of the introduction of the new Hosting library in v2.9.0, which supersedes the functionality of the old DI package. By eliminating this obsolete component, the codebase becomes leaner, easier to maintain, and aligns with the updated architectural direction of the project.

Highlights

  • Deprecation Removal: The deprecated Dependency Injection package and all its associated code, including classes, interfaces, and extension methods, have been completely removed from the codebase.
  • Project File Clean-up: References to the removed Dependency Injection project and its corresponding test project have been eliminated from the solution file (OpenFeature.slnx) and the AOT Compatibility project file.
  • AOT Compatibility Update: The OpenFeature.AotCompatibility.csproj file has been updated to reference the new OpenFeature.Hosting.csproj instead of the removed OpenFeature.DependencyInjection.csproj.
  • Test Code Removal: All unit tests specifically written for the Dependency Injection package have been removed, ensuring that the test suite remains relevant and free of obsolete tests.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@codecov
Copy link

codecov bot commented Nov 2, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 92.89%. Comparing base (dcb4c17) to head (24d5a6b).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #626      +/-   ##
==========================================
+ Coverage   89.89%   92.89%   +2.99%     
==========================================
  Files          77       67      -10     
  Lines        3168     2857     -311     
  Branches      364      338      -26     
==========================================
- Hits         2848     2654     -194     
+ Misses        251      143     -108     
+ Partials       69       60       -9     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request effectively removes the deprecated OpenFeature.DependencyInjection project and its corresponding tests. The changes are primarily file deletions and updates to the solution and project files to remove references to the deprecated project. A key change is in test/OpenFeature.AotCompatibility/OpenFeature.AotCompatibility.csproj, where the project reference has been correctly updated to OpenFeature.Hosting, which is the replacement for the removed dependency injection functionality. The pull request is well-executed and achieves its goal of cleaning up the codebase by removing deprecated code. The changes are correct and I have no further suggestions.

Copy link
Member

@askpt askpt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for doing this.

I already deprecated the DI library here: https://www.nuget.org/packages/OpenFeature.DependencyInjection

Please keep the readme and just keep a notice with the deprecation to look for the Hosting package.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Remove deprecated Dependency Injection library code

2 participants