Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Api: Move Provides.conditionals API. #150

Merged
merged 2 commits into from
May 10, 2024
Merged

Conversation

Jeffset
Copy link
Collaborator

@Jeffset Jeffset commented May 8, 2024

Api: Move Provides.conditionals API.

Instead of
@Provides(Conditional(..), Conditional(..))
it's now required to write @Provides @conditional(..) @conditional(..).

That is done to fix IDE's issues with OptIns,
where it could require the user to opt-in to
conditions usage, where none were used.

This also improves consistency with other parts
of the API where Conditional is a top-level annotation.

Edits in tests are necessary to separate the api
classpath, as this CL introduces a breaking change.

@Jeffset Jeffset added the api Related to introducing new API or changing existing one label May 8, 2024
@Jeffset Jeffset added this to the 2.0.0 milestone May 8, 2024
@Jeffset Jeffset force-pushed the wp/conditional-out-of-provides branch from 2e406c9 to 147940d Compare May 8, 2024 18:14
Instead of
`@Provides(Conditional(..), Conditional(..))`
it's now required to write `@Provides @conditional(..) @conditional(..)`.

That is done to fix IDE's issues with `OptIn`s,
where it could require the user to opt-in to
conditions usage, where none were used.

This also improves consistency with other parts
of the API where `Conditional` is a top-level annotation.

Edits in tests are necessary to separate the api
 classpath, as this CL introduces a breaking change.
@Jeffset Jeffset force-pushed the wp/conditional-out-of-provides branch from 147940d to 23e552e Compare May 8, 2024 18:43
@Jeffset Jeffset requested a review from byar May 8, 2024 18:51
@Jeffset Jeffset marked this pull request as ready for review May 8, 2024 18:51
Copy link

codecov bot commented May 8, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 83.87%. Comparing base (f07a196) to head (23e552e).
Report is 1 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff              @@
##               main     #150      +/-   ##
============================================
- Coverage     83.90%   83.87%   -0.04%     
- Complexity     1577     1585       +8     
============================================
  Files           191      191              
  Lines          7686     7628      -58     
  Branches       1428     1435       +7     
============================================
- Hits           6449     6398      -51     
+ Misses          732      726       -6     
+ Partials        505      504       -1     

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

@Jeffset Jeffset merged commit ccfdd05 into main May 10, 2024
4 checks passed
@Jeffset Jeffset deleted the wp/conditional-out-of-provides branch May 10, 2024 16:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Related to introducing new API or changing existing one
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants