fix(swap): copy simulate tx bytes into a plain ArrayBuffer #1363

Merged
PlasticDigits merged 1 commit from fix/simulate-tx-bytes into main 2026-09-27 13:20:40 +00:00

Summary

The frontend image build failed tsc -b after #1361 / #1362. TypeScript 5.9 types protobuf toBinary() as Uint8Array<ArrayBufferLike>, and the simulate tx fields want Uint8Array<ArrayBuffer>.

The encoder now copies those bytes into a plain ArrayBuffer before they are placed on the pubkey and the tx body.

Test plan

  • tsc -b in frontend-dapp
  • terraSimulateTx and swapAutoGas unit tests
## Summary The frontend image build failed `tsc -b` after #1361 / #1362. TypeScript 5.9 types protobuf `toBinary()` as `Uint8Array<ArrayBufferLike>`, and the simulate tx fields want `Uint8Array<ArrayBuffer>`. The encoder now copies those bytes into a plain `ArrayBuffer` before they are placed on the pubkey and the tx body. ## Test plan - [x] `tsc -b` in `frontend-dapp` - [x] `terraSimulateTx` and `swapAutoGas` unit tests
fix(swap): copy simulate tx bytes into a plain ArrayBuffer
All checks were successful
ci/woodpecker/pr/woodpecker Pipeline was successful
0c793588c4
tsc -b on TypeScript 5.9 rejects protobuf toBinary() Uint8Array values when the field wants ArrayBuffer, which failed the frontend image build.
Author
Owner

drain skip: no occupying job for rebase/fix-pr/CI-wait; remaining continue

drain skip: no occupying job for rebase/fix-pr/CI-wait; remaining continue
Author
Owner

drain skip: default autoland requires tip ACCEPT (#77)

drain skip: default autoland requires tip ACCEPT (#77)
PlasticDigits deleted branch fix/simulate-tx-bytes 2026-09-27 13:20:40 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
code/cl8y-dex-terraclassic!1363
No description provided.