The address-token view showed no transactions for ERC-20 tokens even when transactions existed.
Root Cause
In fetchRecentTransactions, the transaction merger used tx hash as the sole map key. A single transaction (e.g. a DEX swap) produces multiple ERC-20 token transfers (one per token involved), but only the last one survived in the map. When the address-token view filtered by contract address, it often found nothing.
Fix
Use a composite key (hash:contractAddress) for token transfers so all transfers from a single transaction are preserved. Also clean up the bare normal-tx entry when token transfers replace it to avoid duplicates.
## Problem
The address-token view showed no transactions for ERC-20 tokens even when transactions existed.
## Root Cause
In `fetchRecentTransactions`, the transaction merger used tx hash as the sole map key. A single transaction (e.g. a DEX swap) produces multiple ERC-20 token transfers (one per token involved), but only the last one survived in the map. When the address-token view filtered by contract address, it often found nothing.
## Fix
Use a composite key (`hash:contractAddress`) for token transfers so all transfers from a single transaction are preserved. Also clean up the bare normal-tx entry when token transfers replace it to avoid duplicates.
Closes #72
sneak
was assigned by clawbot2026-02-28 21:08:58 +01:00
A single transaction (e.g. a DEX swap) can produce multiple ERC-20
token transfers. The transaction merger was keyed by tx hash alone,
so only the last token transfer survived. This meant the address-token
view's contract-address filter often matched nothing.
Use a composite key (hash + contract address) so all token transfers
are preserved. Also remove the bare normal-tx entry when it gets
replaced by token transfers to avoid duplicates.
Closes#72
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Problem
The address-token view showed no transactions for ERC-20 tokens even when transactions existed.
Root Cause
In
fetchRecentTransactions, the transaction merger used tx hash as the sole map key. A single transaction (e.g. a DEX swap) produces multiple ERC-20 token transfers (one per token involved), but only the last one survived in the map. When the address-token view filtered by contract address, it often found nothing.Fix
Use a composite key (
hash:contractAddress) for token transfers so all transfers from a single transaction are preserved. Also clean up the bare normal-tx entry when token transfers replace it to avoid duplicates.Closes #72