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

feat: Use and recommend org.jspecify.annotations.NonNull instead of a custom one #3046

Merged
merged 19 commits into from
Dec 20, 2024

Conversation

Artur-
Copy link
Member

@Artur- Artur- commented Dec 18, 2024

Closes #2612.

Copy link

codecov bot commented Dec 18, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 92.57%. Comparing base (aeb9d6a) to head (3781129).
Report is 19 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3046   +/-   ##
=======================================
  Coverage   92.57%   92.57%           
=======================================
  Files          85       85           
  Lines        3166     3166           
  Branches      776      776           
=======================================
  Hits         2931     2931           
  Misses        183      183           
  Partials       52       52           
Flag Coverage Δ
unittests 92.57% <ø> (ø)

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.

@platosha platosha changed the title chore: Use and recommend org.jspecify.annotations.NonNull instead of a custom one feat: Use and recommend org.jspecify.annotations.NonNull instead of a custom one Dec 18, 2024
@Artur- Artur- force-pushed the jspecify-nonnull branch 2 times, most recently from e9c6a09 to 1bc6cb2 Compare December 18, 2024 17:31
@peholmst
Copy link
Member

I'm not in a position to review this PR, but I want to say I think this is a good move. Also FYI: spring-projects/spring-framework#28797

Copy link
Contributor

@cromoteca cromoteca left a comment

Choose a reason for hiding this comment

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

Also see #2612.

@Artur- Artur- requested a review from cromoteca December 19, 2024 13:11
@Artur-
Copy link
Member Author

Artur- commented Dec 19, 2024

For #2612, we should also add @NullMarked support but that is a whole different PR

Copy link
Contributor

@taefi taefi left a comment

Choose a reason for hiding this comment

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

Blocked for the following question:

Copy link
Contributor

@cromoteca cromoteca left a comment

Choose a reason for hiding this comment

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

I think that the deprecation of our annotations should be discussed: is it necessary to show lots of deprecations in user projects, given that the annotation are equivalent?

@Artur-
Copy link
Member Author

Artur- commented Dec 19, 2024

I think that the deprecation of our annotations should be discussed: is it necessary to show lots of deprecations in user projects, given that the annotation are equivalent?

The point of deprecation is that people should avoid using the Hilla annotations and use the jspecify ones. It also communicates that they will disappear in the future. I think that is true

@Artur-
Copy link
Member Author

Artur- commented Dec 19, 2024

For new users, it is beneficial that they don't start using the old annotations. Existing users have a very easy com.vaadin.hilla.Nonnull -> org.jspecify.annotations.NonNull && @Nonnull - >@NonNull find and replace to do, to get rid of the deprecation warnings

taefi
taefi previously approved these changes Dec 20, 2024
Copy link
Contributor

@taefi taefi left a comment

Choose a reason for hiding this comment

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

LGTM!

@Artur- Artur- enabled auto-merge (squash) December 20, 2024 08:34
cromoteca
cromoteca previously approved these changes Dec 20, 2024
@Artur- Artur- merged commit 4795fd0 into main Dec 20, 2024
13 checks passed
@Artur- Artur- deleted the jspecify-nonnull branch December 20, 2024 16:04
@vaadin-bot
Copy link
Collaborator

This ticket/PR has been released with Hilla 24.7.0.alpha4 and is also targeting the upcoming stable 24.7.0 version.

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

Successfully merging this pull request may close these issues.

Add first class support for JSpecify
5 participants