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

Fix suspense replaying forwardRefs #26420

Closed
wants to merge 5 commits into from

Conversation

hansottowirtz
Copy link
Contributor

@facebook-github-bot
Copy link

Hi @hansottowirtz!

Thank you for your pull request and welcome to our community.

Action Required

In order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you.

Process

In order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA.

Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with CLA signed. The tagging process may take up to 1 hour after signing. Please give it that time before contacting us about it.

If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks!

@facebook-github-bot
Copy link

Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Meta Open Source project. Thanks!

@facebook-github-bot
Copy link

Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Meta Open Source project. Thanks!

@hansottowirtz
Copy link
Contributor Author

@acdlite Should be good to go apart from maybe the location/name/content of the test, let me know.

@hansottowirtz
Copy link
Contributor Author

Please don't merge yet, this also caused #26419. I will update the PR.

@hansottowirtz
Copy link
Contributor Author

Gonna need some help here, replayFunctionComponent is passing context to replaySuspendedComponentWithHooks's secondArg argument. However context seems to be an empty object, and I'm not sure where to get the ref from. I added a failing test.

@eps1lon
Copy link
Collaborator

eps1lon commented Mar 29, 2023

Can you rebase that onto master? Then CI should run

@hansottowirtz
Copy link
Contributor Author

I rebased, but it seems like there's some kind of circleci config missing.

@hansottowirtz
Copy link
Contributor Author

Running the test locally still fails. The underlying issue is quite clear (suspense replay logic for ForwardRef was just not implemented) but I'm not sure how to fix it.
@acdlite sorry for pinging again, but would it be possible to take another look at this?

@hansottowirtz
Copy link
Contributor Author

I took another look at it and I think I fixed it, so it should be good to go.

@eps1lon
Copy link
Collaborator

eps1lon commented Apr 2, 2023

Try creating a branch and request a pull request from there instead of using your main branch. That may be why CircleCI is having issues.

Manually triggered the pipeline now

@hansottowirtz
Copy link
Contributor Author

Replaced by #26535

acdlite added a commit that referenced this pull request Apr 2, 2023
Continuation of #26420

Fixes #26385 and
#26419

---------

Co-authored-by: eps1lon <silbermann.sebastian@gmail.com>
Co-authored-by: Andrew Clark <git@andrewclark.io>
github-actions bot pushed a commit that referenced this pull request Apr 2, 2023
Continuation of #26420

Fixes #26385 and
#26419

---------

Co-authored-by: eps1lon <silbermann.sebastian@gmail.com>
Co-authored-by: Andrew Clark <git@andrewclark.io>

DiffTrain build for [7329ea8](7329ea8)
jerrydev0927 added a commit to jerrydev0927/react that referenced this pull request Jan 5, 2024
Continuation of facebook/react#26420

Fixes facebook/react#26385 and
facebook/react#26419

---------

Co-authored-by: eps1lon <silbermann.sebastian@gmail.com>
Co-authored-by: Andrew Clark <git@andrewclark.io>

DiffTrain build for [7329ea81c154d40800e30104be40f050e8c2af3e](facebook/react@7329ea8)
EdisonVan pushed a commit to EdisonVan/react that referenced this pull request Apr 15, 2024
Continuation of facebook#26420

Fixes facebook#26385 and
facebook#26419

---------

Co-authored-by: eps1lon <silbermann.sebastian@gmail.com>
Co-authored-by: Andrew Clark <git@andrewclark.io>
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.

Bug: Component is not a function when using Suspense and forwardRef
3 participants