chore: constants codegen release#24728
Conversation
charlielye
left a comment
There was a problem hiding this comment.
Ostensibly looks good. When it comes to releasing changes I use the ci-release-pr label to allow publishing a PR for testing it doesn't break, and that the new package lands as expected.
We could continue to own the constants package for now if you want to land this in @Aztec org. But I also know foundation now has the @aztec-foundation npm org and are using it, so maybe we can do the right thing instead and figure out how to support publishing to more than one NPM org. We'll need to add someones (@IlyasRidhuan ?) npm creds into github and pick right creds per package.
And at the moment we need to refresh those creds every 3 months in npm. Faff...
| cd "$work_dir/consumer" | ||
| npm init --yes >/dev/null | ||
| npm install --ignore-scripts "${tarballs[0]}" >/dev/null | ||
| ./node_modules/.bin/constants-codegen --input "$input" --typescript "$output" |
There was a problem hiding this comment.
Nice. Might also be nice to sanity check other languages we support. I think C++ and Solidity right now? Maybe rust?
|
|
||
| function test_cmds { | ||
| echo "$hash cd protocol/constants-codegen && node --test dest/*.test.js" | ||
| echo "$hash cd protocol/constants-codegen && node --test dest/*.test.js && ./scripts/test-package.sh" |
There was a problem hiding this comment.
Nit, but rather than chaining tests together the idea is that tests can be emitted on own lines.
Depends though on how granular you want to go. e.g. you could have every language output test on its own line as well with arg to test-package script (but that's overkill with all the npm install faff that does).
Hooks the new package to release workflows (blocked until we decide where in npm that should live and make sure the corresponding org/scope is created)