Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

`transaction build` queries the node twice

Đang mở
#1,472 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
56/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
haskell
Lĩnh vực
backend, cli

Hướng nghiên cứu

Read cardano-cli/src/Cardano/CLI/EraBased/Transaction/Run.hs, especially runTransactionBuildCmd and runTxBuild at the linked locations. Trace how the query results feed balancing, treasury values, and the --calculate-plutus-script-cost branch. The issue is done when the command queries once with certificates and passes that result to runTxBuild, preserving the needed values across those paths.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

transaction build runs queryStateForBalancedTx twice per invocation, each time over a new local state query connection:

queryCurrentEra is also called twice, in runTransactionBuildCmd and in runTxBuild.

runTxBuild balances with the result of its own query only.
runTransactionBuildCmd uses the first result for two things:

On a plain build --out-file without the treasury value, the first query's result is not used at all.

Effects:

  • Every build opens two extra node connections and repeats the whole query set, including UTxO by TxIn and the stake pool set.
  • The two queries acquire the volatile tip separately, so the treasury value can come from a different ledger state than the UTxO and protocol parameters used for balancing.

Suggested fix: query once in runTransactionBuildCmd, with the certificates, and pass the result to runTxBuild.

Ngôn ngữ chính
Haskell
Star
72
Fork
25
Merge trung bình
3 ngày
Pull request đã merge (30 ngày)
19

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của IntersectMBO/cardano-cli

Tất cả issue của IntersectMBO/cardano-cli

Issue tương tự

Thêm issue về Haskell

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.