Skip to content

fix(transaction): resolve three critical issues in transaction lifecycle#19

Merged
qj0r9j0vc2 merged 1 commit into
mainfrom
fix/tx-signature-concurrency-memo
Jan 25, 2026
Merged

fix(transaction): resolve three critical issues in transaction lifecycle#19
qj0r9j0vc2 merged 1 commit into
mainfrom
fix/tx-signature-concurrency-memo

Conversation

@qj0r9j0vc2

@qj0r9j0vc2 qj0r9j0vc2 commented Jan 25, 2026

Copy link
Copy Markdown
Member

Summary

Fixes three critical bugs in transaction processing:

  1. EVM signature encoding - Signatures weren't embedded in transaction bytes
  2. Concurrency issues - Race conditions in cache access, missing context checks
  3. Memo field loss - Memo accepted at API but not passed to builder

Changes

EVM Signature Fix (pkg/network/evm/txbuilder.go)

  • Use types.SignTx() to properly embed signature into transaction
  • Re-encode signed transaction with RLP
  • Added test verification

Concurrency Safety (internal/daemon/controller/transaction.go)

  • Added sync.RWMutex for thread-safe cache operations
  • Added context deadline checks in reconciliation phases
  • Added 4 concurrency/context tests

Memo Propagation (types, server, controller)

  • Added Memo field to TransactionSpec
  • Updated service to copy memo from request
  • Updated controller to pass memo to builder
  • Added end-to-end test

Testing

All tests pass with race detector:

go test -race ./internal/daemon/controller/

…ropagation bugs

Fixed three critical issues in transaction processing:

1. EVM signature encoding - signatures now properly embedded in tx bytes
2. Concurrency safety - added mutex protection and context deadline checks
3. Memo field propagation - memo now flows from API to builder

All tests pass with race detector enabled.
@qj0r9j0vc2 qj0r9j0vc2 force-pushed the fix/tx-signature-concurrency-memo branch from 61cacd9 to e09b713 Compare January 25, 2026 10:37
@qj0r9j0vc2 qj0r9j0vc2 self-assigned this Jan 25, 2026
@qj0r9j0vc2 qj0r9j0vc2 merged commit 1f3096e into main Jan 25, 2026
12 checks passed
qj0r9j0vc2 added a commit that referenced this pull request Jan 26, 2026
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.

1 participant