-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
fix: tempo e2e #4188
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
fix: tempo e2e #4188
Conversation
🦋 Changeset detectedLatest commit: fce446c The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
commit: |
src/tempo/Formatters.ts
Outdated
| const keyAuthorization = rpc.keyAuthorization | ||
| ? (() => { | ||
| const keyAuthorization = { | ||
| ...rpc.keyAuthorization, | ||
| // FIXME(ox): chainId not serialized in nested object | ||
| chainId: | ||
| rpc.keyAuthorization.chainId === '0x' || | ||
| rpc.keyAuthorization.chainId === '0x0' | ||
| ? 0 | ||
| : parseInt(rpc.keyAuthorization.chainId || '0x0', 16), | ||
| } | ||
| // FIXME(ox): expects `preHash` not `prehash` | ||
| if ( | ||
| keyAuthorization.signature && | ||
| keyAuthorization.signature.type === 'p256' && | ||
| 'prehash' in keyAuthorization.signature | ||
| ) { | ||
| const { prehash, ...rest } = keyAuthorization.signature | ||
| keyAuthorization.signature = { | ||
| ...rest, | ||
| // @ts-expect-error | ||
| preHash: prehash, | ||
| } | ||
| } | ||
| return keyAuthorization | ||
| })() | ||
| : undefined |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to fix this upstream in Ox
…/update-devnet-url
src/tempo/Formatters.ts
Outdated
| ? 0 | ||
| : parseInt(rpc.keyAuthorization.chainId || '0x0', 16), | ||
| } | ||
| // FIXME(ox): expects `preHash` not `prehash` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not true
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lol well tests only pass with this probably because it gets omitted then 😓
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
spec says preHash and tempo codebase uses pre_hash (which maps to camelized preHash, not lowercase prehash, assuming the same behavior as other fields)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All good, I read it as "ox expects preHash", not "rpc expects preHash" :P
src/tempo/Formatters.ts
Outdated
| chainId: | ||
| rpc.keyAuthorization.chainId === '0x' || | ||
| rpc.keyAuthorization.chainId === '0x0' | ||
| ? 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The RPC doesn’t serialize chain ids?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tests fail without it
src/tempo/Formatters.ts
Outdated
| : undefined | ||
| const keyAuthorization = rpc.keyAuthorization | ||
| ? (() => { | ||
| const keyAuthorization = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don’t think we need to coerce this at all as TransactionRequest.toRpc already handles key auths. My question is that does the RPC expect a different format for chain ids and prehash naming? Guess we can update the prehash naming in Ox though
|
Just updated Ox for the |
b3409d2 to
fce446c
Compare
we made recent changes in the gas schedule for access keys, and therefore this test fails
this PR adds 2 new fields for gas estimate
running tests tempo e2e tests locally works