Skip to content

feat: Add evaluation details to finally hook stage #1246 - #1262

Merged
toddbaert merged 2 commits into
open-feature:mainfrom
chrfwow:Add-evaluation-details-to-finally-hook-stage
Jan 9, 2025
Merged

feat: Add evaluation details to finally hook stage #1246#1262
toddbaert merged 2 commits into
open-feature:mainfrom
chrfwow:Add-evaluation-details-to-finally-hook-stage

Conversation

@chrfwow

@chrfwow chrfwow commented Dec 23, 2024

Copy link
Copy Markdown
Contributor

This PR

Add flag evaluation details to finally hook stage

  • adds this new feature

Related Issues

Fixes #1246

@codecov

codecov Bot commented Dec 23, 2024

Copy link
Copy Markdown

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 93.69%. Comparing base (3c97b7b) to head (0064822).
Report is 1 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff              @@
##               main    #1262      +/-   ##
============================================
+ Coverage     93.51%   93.69%   +0.18%     
- Complexity      463      464       +1     
============================================
  Files            43       43              
  Lines          1110     1110              
  Branches         89       89              
============================================
+ Hits           1038     1040       +2     
+ Misses           44       43       -1     
+ Partials         28       27       -1     
Flag Coverage Δ
unittests 93.69% <100.00%> (+0.18%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

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

@chrfwow
chrfwow marked this pull request as ready for review December 23, 2024 10:58
@chrfwow
chrfwow requested a review from a team as a code owner December 23, 2024 10:58

assertThat(details.getErrorCode()).isEqualTo(ErrorCode.PROVIDER_NOT_READY);
}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Was this just unused? 😅

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes, a leftover from a previous PR

@toddbaert toddbaert left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

No notes!

Thanks!

Will wait for more reviews since this is an SDK change.

⚠️

I'll also note that this is technically a breaking change, but I suggest that we mark it otherwise, just as we did in JS since:

  • according to our spec, experimental (hooks are still experimental) features are subject to breaking changes
  • the change is very easy to absorb (just add a parameter which can otherwise be ignored)
  • it probably won't impact many hooks (very few use the finally stage (only 1 hook in the contribs is impacted)

@aepfli aepfli left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM, thank you!


import static org.assertj.core.api.Assertions.assertThatCode;
import static org.assertj.core.api.Assertions.fail;
import static org.assertj.core.api.Assertions.*;

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

We should avoid star imports

@toddbaert

Copy link
Copy Markdown
Member

Will merge/release this next week unless I hear objections. We'll have to do some manual release notes as well when we do, as we did with JS: https://github.com/open-feature/js-sdk/releases/tag/web-sdk-v1.4.0

See also, same change in .NET: open-feature/dotnet-sdk#335

christian.lutnik and others added 2 commits January 8, 2025 12:58
@sonarqubecloud

sonarqubecloud Bot commented Jan 9, 2025

Copy link
Copy Markdown

@toddbaert
toddbaert merged commit ae85278 into open-feature:main Jan 9, 2025
@chrfwow
chrfwow deleted the Add-evaluation-details-to-finally-hook-stage branch January 13, 2025 14:35
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.

Add evaluation details to finally hook stage

5 participants