Skip to content

Fix: refactor postman with viem#2617

Open
VGau wants to merge 20 commits intomainfrom
fix/refactor-postman-with-viem
Open

Fix: refactor postman with viem#2617
VGau wants to merge 20 commits intomainfrom
fix/refactor-postman-with-viem

Conversation

@VGau
Copy link
Contributor

@VGau VGau commented Mar 18, 2026

This PR implements issue(s) #

Checklist

  • I wrote new tests for my new core changes.
  • I have successfully ran tests, style checker and build against my new changes locally.
  • If this change is deployed to any environment (including Devnet), E2E test coverage exists or is included in this
    PR.
  • I have informed the team of any breaking changes if there are any.

Note

High Risk
Large refactor of the Postman service wiring/entrypoint, configuration parsing, and blockchain interaction stack (moving from linea-sdk/ethers to Viem) which can affect message claiming/anchoring behavior and production runtime. Docker/CI changes also alter how the service is built and started, increasing integration risk.

Overview
Refactors the Postman service to a new Viem-based application structure: introduces PostmanApp plus L1ToL2App/L2ToL1App and a DI-style PostmanContainer, and removes the legacy PostmanServiceClient/scripts/runPostman.ts startup path.

Switches Postman dependencies from @consensys/linea-sdk/ethers (and better-sqlite3) to @consensys/linea-sdk-core, @consensys/linea-sdk-viem, viem, and zod, and updates config handling to Zod-validated schemas with a new envLoader (including web3signer/TLS signer support and additional claiming retry controls like MAX_BUMPS_PER_CYCLE/MAX_RETRY_CYCLES).

Updates runtime and tooling: Docker image now builds sdk-core/sdk-viem and runs dist/src/main.js, GitHub workflow builds @consensys/linea-postman^... and runs sdk-viem tests, docker-compose postman depends on l2-node-besu, and Postman CLI scripts are rewritten to use Viem clients/ABI encoding. Adds/updates Jest coverage ignores and introduces new unit tests for the new app/config wiring.

Written by Cursor Bugbot for commit b07f30b. This will update automatically on new commits. Configure here.

@codecov-commenter
Copy link

codecov-commenter commented Mar 18, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 58.88%. Comparing base (f23c478) to head (b07f30b).
⚠️ Report is 3 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff              @@
##              main    #2617       +/-   ##
============================================
+ Coverage     9.70%   58.88%   +49.18%     
- Complexity       0     1620     +1620     
============================================
  Files          454      453        -1     
  Lines        18530    18528        -2     
  Branches      2014     2014               
============================================
+ Hits          1799    10911     +9112     
+ Misses       16731     6948     -9783     
- Partials         0      669      +669     
Flag Coverage Δ *Carryforward flag
hardhat 96.63% <ø> (+0.10%) ⬆️ Carriedforward from 111ab53
kotlin 54.71% <ø> (+54.61%) ⬆️

*This pull request uses carry forward flags. Click here to find out more.
see 294 files with indirect coverage changes

🚀 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.

alainncls
alainncls previously approved these changes Mar 18, 2026
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

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.

4 participants