Skip to content

fix(proto)!: Change execution API to use primitive RollupId#1291

Merged
ethanoroshiba merged 15 commits intomainfrom
eoroshiba/exec_api_use_primitive
Jul 25, 2024
Merged

fix(proto)!: Change execution API to use primitive RollupId#1291
ethanoroshiba merged 15 commits intomainfrom
eoroshiba/exec_api_use_primitive

Conversation

@ethanoroshiba
Copy link
Contributor

@ethanoroshiba ethanoroshiba commented Jul 23, 2024

Summary

Changed execution API rollup_id to use primitive RollupId instead of bytes.

Background

RollupId is defined in primitives protobuf specs, but astria.execution.v1alpha2.GenesisInfo.rollup_id was still using type bytes instead of the primitive type.

Changes

  • Changed execution rollup_id to be of type RollupId.
  • Regenerated Rust sources with protobuf compiler.
  • Changed affected conductor functions to utilize RollupId instead of bytes.
  • Updated evm-stack and evm-rollup versions.

Testing

With changes in astria-geth, passes smoke-test.

Breaking Changelist

  • Execution API changed, requires corresponding astria-geth changes to function properly.
  • Will require followup PR to update geth devTag to latest once geth PR is merged.

Related Issues

With astria-geth #38, closes #1287

@github-actions github-actions bot added conductor pertaining to the astria-conductor crate proto pertaining to the Astria Protobuf spec labels Jul 23, 2024
@ethanoroshiba ethanoroshiba marked this pull request as ready for review July 24, 2024 14:51
@ethanoroshiba ethanoroshiba requested review from a team as code owners July 24, 2024 14:51
@ethanoroshiba ethanoroshiba requested review from aajimal and noot July 24, 2024 14:51
repo: ghcr.io/astriaorg/astria-geth
tag: 0.13.0
devTag: latest
devTag: pr-38
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just double-checking -- is this tag for all of development intentional?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was intentional since this PR is dependent on astria-geth #38. @joroshiba suggested waiting until this PR merges, updating geth PR with latest protos and merging, then making a monorepo cleanup PR to update devTag to latest.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, because we have proto changes here that needs geth update, it gets a little weird here:

  1. get this pr submitted which pushes prod proto changes
  2. update pr-38 of geth to utilize new main proto libraries, update and submit.
  3. update mono repo back to latest.

A bit of chicken/egg problem here. My preference is to keep astria-geth main from relying on non-main protos. We should wait to submit PR here until pr-38 is reviewed and approved though so we don't end up out of sync.

@joroshiba joroshiba requested review from SuperFluffy and removed request for noot July 24, 2024 21:13
Co-authored-by: Jordan Oroshiba <jordan@astria.org>
Co-authored-by: Jordan Oroshiba <jordan@astria.org>
Copy link
Contributor

@SuperFluffy SuperFluffy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great. Nothing to add to @joroshiba's review. Just a small nit in an error message.

);
Self::Raw {
rollup_id: Bytes::copy_from_slice(rollup_id.as_ref()),
rollup_id: Some(rollup_id.to_raw()),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note that there is also into_raw. They do the same thing here, so it doesn't matter. But sometimes taking owernship allows some optimizations (like avoiding another allocation... if one remembers to implement it that way).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Got it! So for future reference if something is not a shared object then into_raw() may be a better choice?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll note that this is within a to_raw function. I have generally tried to keep the to_raw calling other to_raw and vice versa.

Co-authored-by: Richard Janis Goldschmidt <github@aberrat.io>
@ethanoroshiba ethanoroshiba added this pull request to the merge queue Jul 25, 2024
Merged via the queue into main with commit 4b014f7 Jul 25, 2024
@ethanoroshiba ethanoroshiba deleted the eoroshiba/exec_api_use_primitive branch July 25, 2024 20:53
ethanoroshiba added a commit to astriaorg/astria-geth that referenced this pull request Jul 25, 2024
## Summary
PR in tandem with astriaorg/astria#1291. Adjusts
`GetGenesisInfo` to utilize primitive type `RollupId` instead of
`bytes`.

## Changes
- Updated grpc and protobuf SDKs.
- Changed `GetGenesisInfo` to use primitive `RollupId`.
- Updated sever tests to run correctly with `RollupId`.
github-merge-queue bot pushed a commit that referenced this pull request Jul 25, 2024
## Summary
Update EVM-Rollup Geth `devTag` after #1291 and astria-geth
[#38](astriaorg/astria-geth#38).

## Background
#1291 relied on astria-geth PR
[#38](astriaorg/astria-geth#38) for `evm-rollup`
chart. Now that both PRs have been merged, the `devTag` can be updated
to `latest`.

## Changes
- Updated geth `devTag` to `latest` in `evm-rollup` `values.yaml`. 
- Updated `evm-rollup` and `evm-stack` versions.

## Testing
Passing e2e tests.
steezeburger added a commit that referenced this pull request Jul 29, 2024
* main:
  release: cut bridge withdrawer release (#1303)
  release: version cuts for dusk-9 (#1299)
  chore(core): remove ed25519_consensus from public API (#1277)
  chore: remove spurious entry in gitignore (#1276)
  chore(chart): Update EVM-Rollup Geth devTag (#1300)
  fix(proto)!: Change execution API to use primitive RollupId (#1291)
  refactor(core, proto)!: define bridge memos in proto (#1285)
  chore(sequencer-relayer)!: minimize resubmissions to Celestia (#1234)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cd conductor pertaining to the astria-conductor crate proto pertaining to the Astria Protobuf spec

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Execution API should use the RollupId primitive

4 participants