-
Notifications
You must be signed in to change notification settings - Fork 24.4k
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
Bail on hiPri render on missing layout data before checking priority #41270
Closed
Conversation
This file contains 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
facebook-github-bot
added
the
CLA Signed
This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
label
Oct 31, 2023
This pull request was exported from Phabricator. Differential Revision: D50791506 |
…acebook#41270) Summary: `scheduleCellsToRenderUpdate()` is called in response to new measurements, or component changes. It has logic to decide whether to immediately calculate new state, or to defer it until a later batched period. It will not immediately update state if we don't yet have measurements for cells, but this condition is after another which calculates priority, relying on these measurements. These are garbage if we don't yet have measurements, and trigger an invariant violation in horizontal RTL. This switches around the conditions, to avoid offset resolution if we don't yet have valid measurements. I suspect some "hiPri" renders where cells shift are bugged right now when we update state in response to content size change, before we have new corresponding cell layouts. Changelog: [General][Fixed] - Bail on hiPri render on missing layout data before checking priority Reviewed By: yungsters Differential Revision: D50791506
NickGerleman
force-pushed
the
export-D50791506
branch
from
October 31, 2023 21:42
3b496b0
to
e222808
Compare
This pull request was exported from Phabricator. Differential Revision: D50791506 |
This pull request has been merged in 817fedb. |
lunaleaps
pushed a commit
that referenced
this pull request
Nov 3, 2023
…41270) Summary: Pull Request resolved: #41270 `scheduleCellsToRenderUpdate()` is called in response to new measurements, or component changes. It has logic to decide whether to immediately calculate new state, or to defer it until a later batched period. It will not immediately update state if we don't yet have measurements for cells, but this condition is after another which calculates priority, relying on these measurements. These are garbage if we don't yet have measurements, and trigger an invariant violation in horizontal RTL. This switches around the conditions, to avoid offset resolution if we don't yet have valid measurements. I suspect some "hiPri" renders where cells shift are bugged right now when we update state in response to content size change, before we have new corresponding cell layouts. Changelog: [General][Fixed] - Bail on hiPri render on missing layout data before checking priority Reviewed By: yungsters Differential Revision: D50791506 fbshipit-source-id: 8dbffc37edd2a42f7842c0090d344dcd6f3e3c6d
This was referenced Nov 23, 2023
Othinn
pushed a commit
to Othinn/react-native
that referenced
this pull request
Jan 9, 2024
…acebook#41270) Summary: Pull Request resolved: facebook#41270 `scheduleCellsToRenderUpdate()` is called in response to new measurements, or component changes. It has logic to decide whether to immediately calculate new state, or to defer it until a later batched period. It will not immediately update state if we don't yet have measurements for cells, but this condition is after another which calculates priority, relying on these measurements. These are garbage if we don't yet have measurements, and trigger an invariant violation in horizontal RTL. This switches around the conditions, to avoid offset resolution if we don't yet have valid measurements. I suspect some "hiPri" renders where cells shift are bugged right now when we update state in response to content size change, before we have new corresponding cell layouts. Changelog: [General][Fixed] - Bail on hiPri render on missing layout data before checking priority Reviewed By: yungsters Differential Revision: D50791506 fbshipit-source-id: 8dbffc37edd2a42f7842c0090d344dcd6f3e3c6d
This was referenced Feb 29, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
CLA Signed
This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
fb-exported
Merged
This PR has been merged.
p: Facebook
Partner: Facebook
Partner
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.
Summary:
scheduleCellsToRenderUpdate()
is called in response to new measurements, or component changes. It has logic to decide whether to immediately calculate new state, or to defer it until a later batched period.It will not immediately update state if we don't yet have measurements for cells, but this condition is after another which calculates priority, relying on these measurements. These are garbage if we don't yet have measurements, and trigger an invariant violation in horizontal RTL.
This switches around the conditions, to avoid offset resolution if we don't yet have valid measurements.
I suspect some "hiPri" renders where cells shift are bugged right now when we update state in response to content size change, before we have new corresponding cell layouts.
Changelog:
[General][Fixed] - Bail on hiPri render on missing layout data before checking priority
Reviewed By: yungsters
Differential Revision: D50791506