Skip to content

refactor(rpc): extract feeder transaction trace adapters - #4066

Open
danielntmd wants to merge 1 commit into
danielntmd/trace-cache-primitivesfrom
danielntmd/feeder-trace-adapters
Open

danielntmd wants to merge 1 commit into
danielntmd/trace-cache-primitivesfrom
danielntmd/feeder-trace-adapters

Conversation

@danielntmd

@danielntmd danielntmd commented Sep 14, 2026

Copy link
Copy Markdown
Contributor

User description

User description

User description

Refactor feeder adapter into a helper to be used downstream.


@danielntmd
danielntmd added this pull request to stack #4068 September 14, 2026 07:49
@codecov

codecov Bot commented Sep 14, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 97.18310% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 79.43%. Comparing base (df96cef) to head (266898c).

Files with missing lines Patch % Lines
rpc/v10/adapt_trace.go 96.00% 1 Missing ⚠️
rpc/v9/adapters.go 95.83% 1 Missing ⚠️
Additional details and impacted files
@@                          Coverage Diff                          @@
##           danielntmd/trace-cache-primitives    #4066      +/-   ##
=====================================================================
+ Coverage                              79.40%   79.43%   +0.02%     
=====================================================================
  Files                                    469      469              
  Lines                                  36147    36153       +6     
=====================================================================
+ Hits                                   28703    28718      +15     
+ Misses                                  7435     7426       -9     
  Partials                                   9        9              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@danielntmd
danielntmd force-pushed the danielntmd/feeder-trace-adapters branch from 03ae73c to d7b9154 Compare September 15, 2026 07:25
@danielntmd
danielntmd marked this pull request as ready for review September 15, 2026 07:36
@github-actions

github-actions Bot commented Sep 15, 2026

Copy link
Copy Markdown
Contributor

Claude finished @danielntmd's task in 3m 47s —— View job


Review: refactor(rpc): extract feeder transaction trace adapters

  • Gather context (diff, changed files, CLAUDE.md)
  • Understand request (code review)
  • Review rpc/v8/adapters.go
  • Review rpc/v9/adapters.go
  • Review rpc/v10/adapt_trace.go
  • Post findings

Summary: This is a clean, purely mechanical refactor. In each of rpc/v8/adapters.go, rpc/v9/adapters.go, and rpc/v10/adapt_trace.go, the inline transaction-trace-adaptation block inside AdaptFeederBlockTrace's loop was lifted verbatim into a new adaptFeederTransactionTrace(kind, feederTrace) helper, with no logic changes — diffed the extracted body against the original inline code line-by-line and it's identical in all three files (including the v8-specific TxnL1Handler variant that differs slightly from v9/v10, which was preserved as-is, not "fixed" — correct, since fixing it wasn't in scope here).

Verified:

  • go build ./rpc/... — passes
  • go vet ./rpc/v8/... ./rpc/v9/... ./rpc/v10/... — passes
  • gofmt -l on the three changed files — clean
  • Existing TestAdaptFeederBlockTrace tests in each package already exercise these code paths and don't need updates, since the extraction doesn't change any exported signatures or behavior.

No blockers, no important issues, no nits. This PR is clean and ready as-is.
· Branch: danielntmd/feeder-trace-adapters

@danielntmd
danielntmd force-pushed the danielntmd/feeder-trace-adapters branch from d7b9154 to 8dc6d3e Compare September 15, 2026 18:58
@github-actions

github-actions Bot commented Sep 15, 2026

Copy link
Copy Markdown
Contributor

Claude finished @danielntmd's task in 1m 39s —— View job


Review: refactor(rpc): extract feeder transaction trace adapters

  • Gather context (diff, changed files, CLAUDE.md)
  • Review rpc/v8/adapters.go
  • Review rpc/v9/adapters.go
  • Review rpc/v10/adapt_trace.go
  • Post findings

Summary: Clean, purely mechanical refactor. In each of rpc/v8/adapters.go, rpc/v9/adapters.go, and rpc/v10/adapt_trace.go, the inline transaction-trace-adaptation block inside AdaptFeederBlockTrace's loop was lifted verbatim into a new adaptFeederTransactionTrace(kind, feederTrace) helper. Diffed the extracted body against the original inline code line-by-line in all three files — identical, including the v8-specific TxnL1Handler variant (trace.FunctionInvocation = fnInvocation, no ExecuteInvocation wrapper) that differs from v9/v10's revert-aware handling; that pre-existing inconsistency was preserved as-is, not altered, which is correct since fixing it is out of scope for this PR.

Verified go build ./rpc/... passes. No exported signatures changed, so existing TestAdaptFeederBlockTrace coverage in each package continues to exercise these paths.

No blockers, no important issues, no nits.
· Branch: danielntmd/feeder-trace-adapters

@danielntmd
danielntmd force-pushed the danielntmd/feeder-trace-adapters branch from 8dc6d3e to 98dd849 Compare September 15, 2026 21:46
@github-actions

github-actions Bot commented Sep 15, 2026

Copy link
Copy Markdown
Contributor

Claude finished @danielntmd's task in 1m 55s —— View job


Review: refactor(rpc): extract feeder transaction trace adapters

  • Gather context (diff, changed files, CLAUDE.md)
  • Review rpc/v8/adapters.go
  • Review rpc/v9/adapters.go
  • Review rpc/v10/adapt_trace.go
  • Post findings

Summary: Clean, purely mechanical refactor — no logic changes. In each of rpc/v8/adapters.go, rpc/v9/adapters.go, and rpc/v10/adapt_trace.go, the inline transaction-trace-adaptation block inside AdaptFeederBlockTrace's loop was lifted verbatim into a new adaptFeederTransactionTrace(kind, feederTrace) helper. Diffed the extracted body against the original inline code line-by-line in all three files — identical statement-for-statement, including the v8-specific TxnL1Handler branch (trace.FunctionInvocation = fnInvocation, no ExecuteInvocation/revert wrapper) which differs from v9/v10's revert-aware handling. That pre-existing inconsistency between v8 and v9/v10 was preserved as-is, which is correct since resolving it is out of scope here.

go build ./rpc/... passes. No exported signatures changed, so existing TestAdaptFeederBlockTrace coverage in each package continues to exercise these paths without modification.

No blockers, no important issues, no nits.
· Branch: danielntmd/feeder-trace-adapters

@danielntmd
danielntmd force-pushed the danielntmd/feeder-trace-adapters branch from 98dd849 to 266898c Compare September 18, 2026 06:58
@github-actions

github-actions Bot commented Sep 18, 2026

Copy link
Copy Markdown
Contributor

Claude finished @danielntmd's task in 2m 56s —— View job


Review: refactor(rpc): extract feeder transaction trace adapters

  • Gather context (diff, changed files, CLAUDE.md)
  • Review rpc/v8/adapters.go
  • Review rpc/v9/adapters.go
  • Review rpc/v10/adapt_trace.go
  • Post findings

Summary: Clean, purely mechanical refactor. Diffed the new adaptFeederTransactionTrace(kind, feederTrace) helper body against the code it replaced in all three files (rpc/v8/adapters.go, rpc/v9/adapters.go, rpc/v10/adapt_trace.go) — statement-for-statement identical, including the pre-existing v8-specific TxnL1Handler variant (trace.FunctionInvocation = fnInvocation, no ExecuteInvocation/revert wrapper) that differs from v9/v10's revert-aware handling. That inconsistency is preserved as-is, correctly, since resolving it is out of scope here.

go build ./rpc/... passes. No exported signatures changed, so existing TestAdaptFeederBlockTrace coverage in each package continues to exercise the extracted code through the public API without modification.

No blockers, no important issues, no nits.
· Branch: danielntmd/feeder-trace-adapters

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.

2 participants