Skip to content
This repository has been archived by the owner on Feb 6, 2023. It is now read-only.

Recent PR builds failing when dependencies not found #799

Closed
flarnie opened this issue Nov 22, 2016 · 5 comments
Closed

Recent PR builds failing when dependencies not found #799

flarnie opened this issue Nov 22, 2016 · 5 comments

Comments

@flarnie
Copy link
Contributor

flarnie commented Nov 22, 2016

Do you want to request a feature or report a bug?
A bug.

What is the current behavior?
The most recent PRs are getting failures in CI because ReactDOM. Required module not found and Cannot find module 'react/lib/ReactTestUtils'.

If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem. You can use this jsfiddle to get started: https://jsfiddle.net/stopachka/m6z0xn4r/.
It seems like making any PR will trigger this error.

What is the expected behavior?
The tests should not fail for reasons unrelated to the PR.

Which versions of Draft.js, and which browser / OS are affected by this issue? Did this work in previous versions of Draft.js?
This is in CI on Github.

@flarnie
Copy link
Contributor Author

flarnie commented Nov 22, 2016

Our Travis CI build runs npm update, grabbing the latest allowed version of dependencies. It looks like a new minor version of React was released around the time the builds started failing, so something may have changed that is causing this.

flarnie added a commit to flarnie/draft-js that referenced this issue Nov 22, 2016
It appears that some change in React 15.4.0 is causing builds to fail in
CI. [See issue facebookarchive#779.](facebookarchive#799)

While we figure that out, let's limit the versions that will be used.
@flarnie flarnie removed the bug label Nov 22, 2016
flarnie added a commit that referenced this issue Nov 22, 2016
It appears that some change in React 15.4.0 is causing builds to fail in
CI. [See issue #779.](#799)

While we figure that out, let's limit the versions that will be used.
@flarnie
Copy link
Contributor Author

flarnie commented Nov 22, 2016

It looks like the issue with React 15.4.0 is known and a PR is out to fix it. Just waiting for that to land, and then we can bump the supported versions back to ^15.0.0.

@gaearon
Copy link
Contributor

gaearon commented Nov 22, 2016

The issue is only related to the AMD format. Does Draft use AMD somewhere?

Cannot find module 'react/lib/ReactTestUtils'.

It looks like it is using incompatible versions of react, react-dom, and react-addons-test-utils. They must all be updated at the same time.

Can you check if bumping both to 15.4.0 fixes the issue?

@zpao
Copy link
Contributor

zpao commented Nov 22, 2016

It's a module mapping issue. Fix is up.

@flarnie
Copy link
Contributor Author

flarnie commented Nov 23, 2016

@gaearon and @zpao are correct that the issue I linked to originally is not related. The issue is that React v15.4.0 moved the ReactDOM contents out of react and some of our build system is still looking for it in the react package. The fix @zpao pushed allows Jest to find ReactTestUtils by updating the module-map file.

I'm still looking for the reason that flow is not finding the ReactDOM module. Thanks for the help and patience. Going to try and figure that out and fix it before landing the PR from @zpao.

ouchxp pushed a commit to ouchxp/draft-js that referenced this issue Apr 7, 2017
It appears that some change in React 15.4.0 is causing builds to fail in
CI. [See issue facebookarchive#779.](facebookarchive#799)

While we figure that out, let's limit the versions that will be used.
midas19910709 added a commit to midas19910709/draft-js that referenced this issue Mar 30, 2022
It appears that some change in React 15.4.0 is causing builds to fail in
CI. [See issue #779.](facebookarchive/draft-js#799)

While we figure that out, let's limit the versions that will be used.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants