Skip to content

Conversation

@mydea
Copy link
Member

@mydea mydea commented Aug 2, 2024

This PR updates the way we detect changed packages to rely on Nx under the hood, which should always be in sync.

Previously, we hard-coded paths in the GH workflow to determine which packages have been changed, so we can make sure to run tests accordingly.

Now, we use Nx to detect this for PRs - this takes the dependency graph into consideration and should always be up-to-date. We just need to make sure to have correct dependencies defined, also for dev packages like node-integration-tests (see addition I made there).

Note: For profiling-node, we still check the old way, because we want to avoid re-running this every time a dependency of profiling-node changes - because that depends on e.g. core and utils, and we don't want to/need to re-run this all the time.

This PR does two other things:

  1. Enable global yarn cache - this may help us reduce install time on CI
  2. Merge the install & build CI steps - these were run in parallel, which in reality only ate up about 50s, because this is how long it takes to restore the dependency cache, which had to happen in the build step. By merging this, min. time for install + build for a fully cached scenario is down to ~1:15 minutes, where previously it was >2 minutes across the two steps.

Example runs:

@mydea mydea force-pushed the fn/node-integration-tests-auto branch from 93784ea to bf45cbf Compare August 2, 2024 13:03
@mydea mydea self-assigned this Aug 2, 2024
@mydea mydea changed the title ci: Better affected check (WIP) ci: Improve CI dependency checks Aug 2, 2024
@mydea mydea marked this pull request as ready for review August 2, 2024 13:14
Copy link
Member

@AbhiPrasad AbhiPrasad left a comment

@mydea mydea force-pushed the fn/node-integration-tests-auto branch 2 times, most recently from e48b528 to d3a5bf5 Compare August 5, 2024 11:21
@github-actions
Copy link
Contributor

github-actions bot commented Aug 5, 2024

size-limit report 📦

Path Size
@sentry/browser 22.46 KB (0%)
@sentry/browser (incl. Tracing) 34.24 KB (0%)
@sentry/browser (incl. Tracing, Replay) 70.29 KB (0%)
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 63.63 KB (+0.01% 🔺)
@sentry/browser (incl. Tracing, Replay with Canvas) 74.69 KB (0%)
@sentry/browser (incl. Tracing, Replay, Feedback) 87.29 KB (0%)
@sentry/browser (incl. Tracing, Replay, Feedback, metrics) 89.13 KB (0%)
@sentry/browser (incl. metrics) 26.76 KB (0%)
@sentry/browser (incl. Feedback) 39.39 KB (0%)
@sentry/browser (incl. sendFeedback) 27.08 KB (0%)
@sentry/browser (incl. FeedbackAsync) 31.72 KB (0%)
@sentry/react 25.22 KB (0%)
@sentry/react (incl. Tracing) 37.23 KB (0%)
@sentry/vue 26.6 KB (0%)
@sentry/vue (incl. Tracing) 36.08 KB (+0.01% 🔺)
@sentry/svelte 22.59 KB (0%)
CDN Bundle 23.65 KB (0%)
CDN Bundle (incl. Tracing) 35.89 KB (0%)
CDN Bundle (incl. Tracing, Replay) 70.32 KB (0%)
CDN Bundle (incl. Tracing, Replay, Feedback) 75.59 KB (0%)
CDN Bundle - uncompressed 69.4 KB (0%)
CDN Bundle (incl. Tracing) - uncompressed 106.32 KB (0%)
CDN Bundle (incl. Tracing, Replay) - uncompressed 218.17 KB (0%)
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed 231.08 KB (0%)
@sentry/nextjs (client) 37.08 KB (0%)
@sentry/sveltekit (client) 34.81 KB (0%)
@sentry/node 114.77 KB (+0.01% 🔺)
@sentry/node - without tracing 89.33 KB (+0.01% 🔺)
@sentry/aws-serverless 98.5 KB (+0.01% 🔺)

mydea added 4 commits August 5, 2024 16:25
Also enabled global yarn cache, and streamlines some jobs to avoid unnecessary cache restoration.
@mydea mydea force-pushed the fn/node-integration-tests-auto branch from d3a5bf5 to 18080ce Compare August 5, 2024 14:28
@mydea mydea merged commit c71177b into develop Aug 5, 2024
@mydea mydea deleted the fn/node-integration-tests-auto branch August 5, 2024 15:23
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 this pull request may close these issues.

3 participants