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

make assets ends with error #3892

Closed
roastiek opened this issue Mar 6, 2021 · 4 comments · Fixed by #3906
Closed

make assets ends with error #3892

roastiek opened this issue Mar 6, 2021 · 4 comments · Fixed by #3906

Comments

@roastiek
Copy link
Contributor

roastiek commented Mar 6, 2021

Thanos, Prometheus and Golang version used:
main, 0.19.0rc0

What happened:
make assets fails with

rm -rf pkg/ui/react-app/node_modules/
make assets
.
.
.
$ react-scripts build
Creating an optimized production build...
Failed to compile.

./src/utils/index.ts
  Line 0:  Parsing error: Cannot read property 'map' of undefined


error Command failed with exit code 1.

Anything else we need to know:
make assets builds on 0.18.0 or older versions in the same enviroment.
I didn't find usage of make assets in any parts of ci build. So I cannot check if it should work or not.

make react-app-test works on all versions

@saswatamcode
Copy link
Member

I was able to replicate the issue. This is due to a react-scripts and TypeScript version issue, see here. Thus, will possibly need to upgrade react-scripts to the latest version. This would however force us to bump eslint to v7 as well and will require a few refactors.

@onprem
Copy link
Member

onprem commented Mar 9, 2021

I was able to replicate the issue. This is due to a react-scripts and TypeScript version issue, see here. Thus, will possibly need to upgrade react-scripts to the latest version. This would however force us to bump eslint to v7 as well and will require a few refactors.

Thanks for digging this up. It'd be great if you can come up with a PR with the required changes. :)

@saswatamcode
Copy link
Member

Sure! Will be raising a PR shortly.

@saswatamcode
Copy link
Member

@prmsrswt I managed to fix the issue. Would be great if you could review!

@onprem onprem linked a pull request Mar 10, 2021 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants