-
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
Haste module overrides for react-native-windows resolution failures #19953
Comments
Thanks for reporting this. This is indeed a breaking change for plugins. In order to prevent having to override the Meanwhile, we're going to work in a long-term solution for overriding core components from plugins, as the current approach is pretty hacky. |
@rubennorte - definitely agree that a less hacky long term solution is ideal. I've never liked the "special case" of react-native-windows in the metro / react-native repos. That being said, my parameters for an ideal solution would be one that allows me to install react-native-windows and have it "just work" without changes to the rn-cli.config.js. We have a precedent for plugging into the |
this => Unable to resolve module |
I got the same issue on Windows 10 :( |
Same issue here! Trying to compile RN 0.56.0 for Android.
|
I followed the same steps in this issue and then
Which is normal because This isn't related to this issue, as the hasteImpl/providesModule thing has been solved for react-native-windows. |
@rubennorte according to the other issue I linked (#20015) the error |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
I would like to suggest that the issue detail be updated to reflect the fact that the same issue is happening on Windows 10 when compiling for Android. I spent two days troubleshooting as this happened during my very first react native project setup :(
|
@rubennorte Please, this is still an issue and it's becoming really frustrating. I had to downgrade to 0.55.4, it worked but there are vulnerabilities that npm suggests npm install react-native @0.56.0 will fix. Going back to that version will return the same "AccessibilityInfo" bug. |
This comment has been minimized.
This comment has been minimized.
downgrading isnt really resolving a issue, the originale issue stated that everything worked prior to 0.56 |
Everything working with 0.55 upgraded to 0.56 and babel it fails :/ I need 0.56 for some bug fixes :/ |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
0.56 is broken on windows. Hopefully, this gets fixed soon! |
Same error here, it's okay to have bugs sometimes, but what can we do about it ? |
I'm locking this since the comments are all but useful in helping with solving this issue. Aside from that, a commit landed in master with a fix: 3ac86c3 and we'll make sure to cherry pick it and release a 0.56.1 release asap. EDIT: since there are reports that the commit is not enough to fix the issue completely, this issue prob can't be closed yet. |
Update: the TLDR is that the original issue causing this was nested into a dependency of Babel. After having tested various workarounds in the past weeks, in collaboration with the Metro team we agreed that (sadly) it's really complex to backport the "true fix" to 0.56. We are cutting a 0.57 rc0 in these hours in order to make a new version available to everyone asap, and test that in fact 0.57 will solve this (related: 583cb13 ). I'll try to update everyone as soon as we have better info related to this. We are also trying to avoid situations like this in the future by integrating a some Windows tests in the CI, you can follow along and help and provide feedback about that here: #20260 EDIT: we created a more general issue to keep track on the whole Windows situation over here: #20353 |
Environment
Run
react-native info
in your terminal and paste its contents here.Description
Describe your issue in detail. Include screenshots if needed. If this is a regression, let us know.
react-native-windows
overrides haste modules inreact-native
, currently using the@providesModule
attribute. For example, theScrollView
module inreact-native
has behavior that limits it to iOS and Android, we we override the module inreact-native-windows
here.Prior to
react-native
0.56.0 RC (which moved tometro
0.38), this behavior worked as expected. Now, the haste module overrides for windows no longer seem to get resolved. Specifically, I get the following error:Please note - the
AccessibiltyInfo
module just happens to be the first module in the dependency graph that we provide a*.windows.js
override for, so it has nothing to do with that module specifically.Reproducible Demo
Let us know how to reproduce the issue. Include a code sample, share a project, or share an app that reproduces the issue using https://snack.expo.io/. Please follow the guidelines for providing a MCVE: https://stackoverflow.com/help/mcve
A very simple test that repos (on both Windows and Mac):
The text was updated successfully, but these errors were encountered: