Skip to content

fix: add @NonNull value type annotations on collection-based signals#23557

Merged
Artur- merged 5 commits intomainfrom
fix-listsignal-nullable
Feb 17, 2026
Merged

fix: add @NonNull value type annotations on collection-based signals#23557
Artur- merged 5 commits intomainfrom
fix-listsignal-nullable

Conversation

@Artur-
Copy link
Member

@Artur- Artur- commented Feb 17, 2026

In a @NullMarked package, type parameters are implicitly @nullable, making peek() return @nullable for ListSignal, SharedListSignal, and SharedMapSignal even though their collection values are never null. Add @nonnull to the type arguments to correctly express this contract.

In a @NullMarked package, type parameters are implicitly @nullable,
making peek() return @nullable for ListSignal, SharedListSignal, and
SharedMapSignal even though their collection values are never null.
Add @nonnull to the type arguments to correctly express this contract.

Also add toString() to ListSignal and ValueSignal with corresponding
tests, matching the pattern used in shared signal classes.
@Artur- Artur- requested a review from Legioth February 17, 2026 09:28
@github-actions
Copy link

github-actions bot commented Feb 17, 2026

Test Results

 1 356 files  ± 0  1 356 suites  ±0   1h 24m 8s ⏱️ -1s
 9 613 tests ± 0  9 546 ✅ ± 0  67 💤 ±0  0 ❌ ±0 
10 058 runs  +13  9 982 ✅ +12  76 💤 +1  0 ❌ ±0 

Results for commit ba9d190. ± Comparison against base commit 00710af.

♻️ This comment has been updated with latest results.

@Legioth
Copy link
Member

Legioth commented Feb 17, 2026

Please do separate PRs for nullability annotations in one subset of signal types and toString of a different subset of signal types.

These will be handled separately in the localSignalToString branch.
@Artur-
Copy link
Member Author

Artur- commented Feb 17, 2026

Removed toString and tests

@sonarqubecloud
Copy link

@Artur- Artur- requested a review from mshabarov February 17, 2026 12:41
@Artur- Artur- enabled auto-merge (squash) February 17, 2026 12:42
@Artur- Artur- merged commit f521e7d into main Feb 17, 2026
31 checks passed
@Artur- Artur- deleted the fix-listsignal-nullable branch February 17, 2026 13:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Comments