-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
web: Upgrade Rest Hooks to v5 #1907
Conversation
Looking into making compatibility with super old v2 line of estlint parser |
I'm still trying to figure out the eslint parser problem so no need to review yet. |
@ntucker we can't currently merge your PR. I tried once and faced some problems during CI so I have to revert the changes. There is a draft PR based on your changes that includes some fixes for problems I faced after increasing react-scripts and rest-hooks version. |
Oh can you link that pr and issues? |
My goal is to make this work with older versions of react-scripts and typescript. This will help others upgrade as well. 5.0.2 should have typescript 3.7+ support restored, but there's some kind of eslint parse issue with the 2-line from react-scripts that I'm trying to figure out. |
The weird thing is, I can't reproduce this simply by running old react scripts version and the resource files from the project on its own. ( |
facebook/create-react-app#9515 is the tracking |
Found out the issue has to do with babel runtime and this change: babel/babel#10853. Some import compatibility changes going on |
Reverted all tooling upgrades, and instead hoisted |
reactive/data-client#513 should make upgrades run smoother for legacy tooling situations like this |
Eliminated need to force new runtime version with release of 5.0.3. Build and dev run work |
@ntucker Is it correct, that we do not need to update our runtime and you have some changes that address that problem within new rest-hooks released version? |
Yes, this branch has now been updated to use the latest rest-hooks which has been tested to be backwards compatible with all the tooling including:
You can observe now in the package-lock.json that only rest-hooks packages were changed/added. |
I have tested locally by both building a production and running dev mode (npm start) with the docker running and a small sample project. It's by no means comprehensive but ensures that
|
Wow! @ntucker Thank you so much for making sure that upgrade will go fine. That is really awesome as I am pretty packed for the next sprint and was not sure when I have time to check the issue. Let's try and merge it and see how CI goes. Just to make sure there are no lint errors anymore? As actually the problem we had was that |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank's a lot for all the work! I understand that it could have taken a significant amount of time as you have to change some things not only here, but in rest-hooks
lib too.
Lint passes. Oddly enough the linting issue was related to @babel/runtime being installed as a nested dependency. (Joys of packaging) |
I tend to obsessively keep packages up to date, so this was a good opportunity to ensure smooth upgrades for all users of Rest Hooks. I suspect many people are stuck on react-scripts v3 as well. |
What
Updating the RH upgrade pr with
How
Was able to get docker running locally and do all the tests. (It's fun to run webapp in dev mode and use redux devtools too :)).
It seems to be working, but not sure how to run integration tests locally. If this only runs on your CI - is there a way I can look at the failures to help debug?
Pre-merge Checklist