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

CI builds are slow #638

Closed
mjackson opened this issue Jul 3, 2020 · 3 comments
Closed

CI builds are slow #638

mjackson opened this issue Jul 3, 2020 · 3 comments
Labels
Resolution: Stale Type: Enhancement General improvements or suggestions

Comments

@mjackson
Copy link
Member

mjackson commented Jul 3, 2020

🐛 Bug report

Current Behavior

yarn build currently takes about 9 minutes to complete in CI. See e.g. https://travis-ci.com/github/reach/reach-ui/jobs/357412345

Expected behavior

I'd expect to be able to run the tests in under a minute.

Reproducible example

N/A

Suggested solution(s)

I'm not sure what could be slowing it down, but I've heard from some folks that ts-node is kinda slow. Are we invoking it to build each individual test?

@chaance
Copy link
Member

chaance commented Jul 17, 2020

Agreed, it's kind of painful. I'm using Github actions in another repo and it seems much faster, but I haven't investigated it too deeply. I think creating a fork and removing TS from the build scripts altogether would be a good test though.

@chaance chaance added the Type: Enhancement General improvements or suggestions label Jul 17, 2020
@chaance
Copy link
Member

chaance commented Jul 23, 2020

BTW @mjackson I did manage to get the build time reduced a bit by using Node directly, but it's not really significant. Any insight from your work on the new React Router v6 build scripts?

@mjackson
Copy link
Member Author

One of the main things I did in the router repo to speed up testing and builds was to ditch lerna workspace run (or whatever it's called, can't remember). All the build + test infrastructure is able to work with the monorepo format, so e.g. I only have a single instance of Jest/Rollup running when I need to test/build. This eliminates startup time for spinning up individual processes, which can be significant in a repo with many packages.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: Stale Type: Enhancement General improvements or suggestions
Projects
None yet
Development

No branches or pull requests

2 participants