Repository navigation
Fix redundant sync/4 fallback on Elixir 1.20 - #7
Merged
Merged
Conversation
__using__ and @before_compile both defined catch-all sync/4, so a LiveView with only sync/3 got two; 1.20 flags the second as redundant. Keep only the @before_compile fallbacks. impl_for! in opts/1 and subscription_key/1. Bump to 0.1.13, Elixir 1.20.4 / OTP 29.1.2. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Caution Review failedThe pull request is closed. Walkthrough
Merge Risk:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
use LiveSyncdefined catch-allsync/3/sync/4in__using__and again via@before_compile. A LiveView defining onlysync/3kept the__using__sync/4and got a second from@before_compile; Elixir 1.20 warns "the following clause is redundant", failing--warnings-as-errorsin consumers (12 LiveViews in Devhub).__using__defaults anddefoverridable;@before_compilefallbacks cover every case (nosupercallers)opts/1,subscription_key/1:impl_for!instead of calling on a possibly-nil impl (1.20 warning).tool-versions→ Elixir 1.20.4 / OTP 29.1.2Tested: clean
compile --warnings-as-errors+ 11 tests on 1.20 and 1.19; Devhub app compiles warning-free and passes 5721 tests against this.🤖 Generated with Claude Code
Summary by CodeRabbit