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

chore(ci): migrate engine size dashboard to pure bash and GH Actions #5095

Merged
merged 1 commit into from
Dec 19, 2024

Conversation

aqrln
Copy link
Member

@aqrln aqrln commented Dec 19, 2024

Due to the lack of Nix buy-in from the team and with most of Nix users leaving, and given the increased overhead of keeping multiple separate build systems and workflows in sync after the introduction of the WebAssembly tooling and difficulties in making changes in Nix code for team members who don't use it, it was previously decided to decrease our reliance on Nix and stop using it on CI, leaving it as optional and only for local development, which mostly happened in February. However, the engines size dashboard was still powered by Nix because we ran out of the allocated time for the tech debt task.

After the Nix flake was updated last time, the workflow was broken because wasm-bindgen-cli in the flake was at 0.2.95 while we are currently pinned to 0.2.93 and are blocked from upgrading to a newer version at the moment. Rather than pinning wasm-bindgen-cli to 0.2.93 in the flake by taking it from a different nixpkgs commit, it's a good opportunity to start using the same infrastructure we use for other GitHub Actions jobs instead.

With that, and given the fact that our workflows and build scripts are heavily dependent on rustup and we even used rustup within the dev shell instead of the toolchain from rust-overlay, there's not much benefit for the local dev shell for Nix users to be a flake, a classic shell.nix is more appropriate: pinning the state of the environment in flake.lock is no longer useful and only gets in the way. As an added bonus, classic Nix doesn't require copying the sources to the store, which makes the shell startup a bit faster.

Fixes: https://github.com/prisma/team-orm/issues/1444
Closes: #5072

@aqrln aqrln requested a review from a team as a code owner December 19, 2024 13:32
@aqrln aqrln requested review from jacek-prisma and removed request for a team December 19, 2024 13:32
@aqrln aqrln added this to the 6.2.0 milestone Dec 19, 2024
@aqrln aqrln force-pushed the fix-publish-engines-size-v2 branch from 825850b to c06dd38 Compare December 19, 2024 13:34
Copy link

codspeed-hq bot commented Dec 19, 2024

CodSpeed Performance Report

Merging #5095 will not alter performance

Comparing fix-publish-engines-size-v2 (b5afa14) with main (3aa9260)

Summary

✅ 11 untouched benchmarks

Copy link
Contributor

github-actions bot commented Dec 19, 2024

WASM Query Engine file Size

Engine This PR Base branch Diff
Postgres 2.084MiB 2.084MiB 0.000B
Postgres (gzip) 837.761KiB 837.764KiB -3.000B
Mysql 2.049MiB 2.049MiB 0.000B
Mysql (gzip) 824.667KiB 824.670KiB -3.000B
Sqlite 1.962MiB 1.962MiB 0.000B
Sqlite (gzip) 788.645KiB 788.646KiB -1.000B

Due to the lack of Nix buy-in from the team and with most of Nix users
leaving, and given the increased overhead of keeping multiple separate
build systems and workflows in sync after the introduction of the
WebAssembly tooling and difficulties in making changes in Nix code for
team members who don't use it, it was previously decided to decrease our
reliance on Nix and stop using it on CI, leaving it as optional and only
for local development, which mostly happened [in
February](#4713). However,
the engines size dashboard was still powered by Nix because we ran out
of the allocated time for the tech debt task.

After the Nix flake was updated last time, the workflow was broken
because `wasm-bindgen-cli` in the flake was at 0.2.95 while we are
currently pinned to 0.2.93 and are blocked from upgrading to a newer
version at the moment. Rather than pinning `wasm-bindgen-cli` to 0.2.93
in the flake by taking it from a different nixpkgs commit, it's a good
opportunity to start using the same infrastructure we use for other
GitHub Actions jobs instead.

With that, and given the fact that our workflows and build scripts are
heavily dependent on rustup and we even used rustup within the dev shell
instead of the toolchain from `rust-overlay`, there's not much benefit
for the local dev shell for Nix users to be a flake, a classic
`shell.nix` is more appropriate: pinning the state of the environment in
`flake.lock` is no longer useful and only gets in the way. As an added
bonus, classic Nix doesn't require copying the sources to the store,
which makes the shell startup a bit faster.

Fixes: prisma/team-orm#1444
Closes: #5072
@aqrln aqrln force-pushed the fix-publish-engines-size-v2 branch from c06dd38 to b5afa14 Compare December 19, 2024 13:52
@aqrln
Copy link
Member Author

aqrln commented Dec 19, 2024

@aqrln
Copy link
Member Author

aqrln commented Dec 19, 2024

And you can see the new entries here: https://prisma.github.io/prisma-engines/engines-size/

@aqrln aqrln merged commit 59c39b6 into main Dec 19, 2024
368 checks passed
@aqrln aqrln deleted the fix-publish-engines-size-v2 branch December 19, 2024 14:12
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