Merged
Conversation
walker7734
pushed a commit
that referenced
this pull request
Jan 12, 2026
walker7734
pushed a commit
that referenced
this pull request
Jan 12, 2026
kevinpschaaf
added a commit
that referenced
this pull request
Jan 15, 2026
) Fixes b/475312122 When the record button is clicked, the private `#recorder` field is set, which is what changes the template from the "record" button to the "stop" button. Since `#recorder` wasn't marked as `state()`, the template wasn't re-rendered based on this assignment, and since clicking the button immediately disables it, there was no way to stop recording. Appears to have been a latent bug, exposed by #7458 (found via bisect). That PR resulted in `lit` being bumped from `3.3.1` to `3.3.2`, which included a bugfix in the lit core library: lit/lit#4999 "Fix a bug in change detection with decorated standard private accessors". The reason the fix in Lit broke Opal was because that in the same microtask that `#recorder` was being set, the `#clearValues()` method was being called which did set the `@state() #value` field to `null`. Since `null` is the initial value, this should not have triggered a re-render but did, because of the Lit bug above: Lit reading `newValue` in `requestUpdate` incorrectly returned `undefined` for a private field, hence setting to `null` always failed equality check and incorrectly triggered an update (compensating for `#recorder` not being marked as state). The fix to Lit means that nothing was triggering a re-render after the record button was clicked. Thus ensuring that the `#recorder` field was properly marked as `@state` is all that's needed.
kevinpschaaf
added a commit
that referenced
this pull request
Jan 16, 2026
) Fixes b/475312122 When the record button is clicked, the private `#recorder` field is set, which is what changes the template from the "record" button to the "stop" button. Since `#recorder` wasn't marked as `state()`, the template wasn't re-rendered based on this assignment, and since clicking the button immediately disables it, there was no way to stop recording. Appears to have been a latent bug, exposed by #7458 (found via bisect). That PR resulted in `lit` being bumped from `3.3.1` to `3.3.2`, which included a bugfix in the lit core library: lit/lit#4999 "Fix a bug in change detection with decorated standard private accessors". The reason the fix in Lit broke Opal was because that in the same microtask that `#recorder` was being set, the `#clearValues()` method was being called which did set the `@state() #value` field to `null`. Since `null` is the initial value, this should not have triggered a re-render but did, because of the Lit bug above: Lit reading `newValue` in `requestUpdate` incorrectly returned `undefined` for a private field, hence setting to `null` always failed equality check and incorrectly triggered an update (compensating for `#recorder` not being marked as state). The fix to Lit means that nothing was triggering a re-render after the record button was clicked. Thus ensuring that the `#recorder` field was properly marked as `@state` is all that's needed.
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.
No description provided.