• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

hyperledger / fabric-x-common
82%
main: 82%

Build:
Build:
LAST BUILD BRANCH: issue-231-checktxid
DEFAULT BRANCH: main
Repo Added 08 Feb 2026 08:56AM UTC
Files 200
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

LAST BUILD ON BRANCH issue-231-checktxid
branch: SELECT
CHANGE BRANCH
x
  • No branch selected
  • add-system-tx-status
  • agents-init
  • allow_OUs
  • arma_known_certs_support
  • asn1-message-to-sign
  • asn1-unmarshal
  • batch-block-hash
  • blk-itr-ctx
  • blkstorage/skip-unused-tx-index-info
  • bump-fabric-lib-go
  • bump-go-1.27.3-vulns
  • copilot/fix-data-race-logger
  • coveralls
  • cryptogen-org-folder-domain
  • cryptogen-recreate
  • cryptogen/arma-adoption
  • defer-signature-verification
  • dep-cheap-cleanup
  • dep-drop-gorilla
  • dependabot/go_modules/go_modules-9c5197dcb8
  • dependabot/go_modules/go_modules-a135cde889
  • dependabot/go_modules/go_modules-c93f3641e6
  • doc-stale-meta-namespace-key
  • expose-ledger-api
  • fabric-lib-go-v1.1.3
  • feat/add_string_render_msp_policy
  • feat/add_user_admin_creation_in_cryptogen
  • fix-acl
  • fix-block-verification-policy-orderer
  • fix-data-hash
  • fix-fileledger-newest-empty
  • fix-flaky-bft-deliverer-tests
  • fix-gpl
  • follow_compare_blocks_by_header_and_data
  • fxadmin_cli_skeleton
  • fxadmin_cli_skeleton_fix_review_comments
  • fxadmin_compute_update_command
  • fxadmin_decode_command
  • fxadmin_follow_command
  • fxadmin_follow_returns_the_config_block
  • fxadmin_improve
  • fxadmin_ledger_command_address_comments
  • fxadmin_ledger_commands
  • fxadmin_modify_app_add
  • fxadmin_modify_party_node
  • fxadmin_require_enough_resp_in_submit
  • fxadmin_set_tx_id_in_env
  • fxadmin_tx_command_merge_and_endorse
  • fxadmin_tx_command_prepare
  • fxadmin_tx_command_send
  • fxadmin_tx_command_submit
  • go-1.27
  • grpc-logger
  • guide-for-configtx.md
  • hash-tls-cert
  • hold-halt
  • hotfix/allow_cryptogen_custom_admin_users
  • hyphen-key
  • idemix-update
  • issue-231-checktxid
  • json_manipulation_automation_skeleton
  • load-config-material
  • main
  • move-serve-connection-retry
  • msp-factory-idemix-versions
  • new-status
  • no-capabilities-usage
  • notify-header
  • notify-include-metadata
  • notify-new-api
  • operation_endpoints
  • ordererpb_Extract_the_common_Arma_node_fields_into_a_NodeConfig_message
  • oreder_shared_config_ext
  • protoutil-envelope-signature-header
  • quick-asn1-marshal
  • remove-non-maintained-pkg
  • remove-spew
  • remove-tx-status-batch
  • rename-all-tx
  • replace-govaluate
  • return-not-found-blk-store
  • rm-para-config-block
  • routerAsmSignCert
  • sampleconfig-committer-acls
  • sidecar-notify-reject
  • smartbft-migrate
  • snapshot-abort
  • snapshot-checkpoint-hash
  • snapshot-checkpoint-policy
  • snapshot-proto
  • snapshot-reject-status
  • testcrypto-auth-peer
  • testcrypto-prepare-block-in-place
  • tx-metadata
  • tx-metadata-fix
  • unify-sidecar-service
  • unique-genesis-default
  • update-dependencies-4
  • verifier-test

25 Oct 2026 08:16PM UTC coverage: 82.197% (+0.009%) from 82.188%
40230048789

Pull #232

github

tock-ibm
[protoutil] Avoid allocations and the echoed TxID in CheckTxID

#### Type of change

- Improvement (improvement to code, performance, etc)

#### Description

- `ComputeTxID` and `CheckTxID` hash and hex-encode into stack buffers. `ComputeTxID` keeps its signature, and the returned string is its only allocation. `CheckTxID` no longer allocates.
- `CheckTxID` rejects a TxID that isn't `2*sha256.Size` characters long before hashing.
- On mismatch, `CheckTxID` returns the new sentinel `protoutil.ErrInvalidTxID` ("invalid txid"). The error no longer includes the received or expected TxID, so callers that matched on the old message should use `errors.Is` instead.
- `proputils.go` now uses `github.com/cockroachdb/errors` instead of `github.com/pkg/errors`.

#### Additional details (Optional)

Benchmarks added in `proputils_test.go`, with a 24-byte nonce and a 1,000-byte creator (before → after):

| case | before | after |
|---|---|---|
| `ComputeTxID` | 2,990 ns, 160 B, 3 allocs | 2,880 ns, 64 B, 1 alloc |
| `CheckTxID`, valid TxID | 3,040 ns, 160 B, 3 allocs | 2,830 ns, 0 B, 0 allocs |
| `CheckTxID`, wrong TxID, 64 chars | 3,950 ns, 672 B, 9 allocs | 2,830 ns, 0 B, 0 allocs |
| `CheckTxID`, wrong TxID, 1 MB | 744 µs, 2.1 MB, 12 allocs | 2.8 ns, 0 B, 0 allocs |

#### Related issues

- resolves #231

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Yoav Tock <TOCK@il.ibm.com>
Pull Request #232: [protoutil] Avoid allocations and the echoed TxID in CheckTxID

16 of 16 new or added lines in 1 file covered. (100.0%)

1 existing line in 1 file now uncovered.

13837 of 16834 relevant lines covered (82.2%)

0.82 hits per line

Relevant lines Covered
Build:
Build:
16834 RELEVANT LINES 13837 COVERED LINES
0.82 HITS PER LINE
Source Files on main
  • Tree
  • List 200
  • Changed 3
  • Source Changed 0
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line

Recent builds

Builds Branch Commit Type Ran Committer Via Coverage
40230048789 issue-231-checktxid [protoutil] Avoid allocations and the echoed TxID in CheckTxID #### Type of change - Improvement (improvement to code, performance, etc) #### Description - `ComputeTxID` and `CheckTxID` hash and hex-encode into stack buffers. `ComputeTxID` kee... Pull #232 25 Oct 2026 08:18PM UTC tock-ibm github
82.2
40211462926 ordererpb_Extract_the_common_Arma_node_fields_into_a_NodeConfig_message [BREAKING] [ordererpb] Extract the common Arma node fields into a NodeConfig message Signed-off-by: May.Buzaglo <May.Buzaglo@ibm.com> Pull #214 25 Oct 2026 04:24PM UTC tock-ibm github
82.19
40179238657 fxadmin_modify_party_node deterministic marshal Signed-off-by: May.Buzaglo <May.Buzaglo@ibm.com> Pull #212 25 Oct 2026 09:07AM UTC MayRosenbaum github
82.07
39950840754 main [msp] Support all MSP versions for Idemix and add factory test coverage (#229) #### Type of change - Bug fix - Test update #### Description - `New` now accepts `MSPv1_0`..`MSPv3_0` for `*IdemixNewOpts`, matching the versions already supported ... push 23 Oct 2026 12:07PM UTC web-flow github
82.19
39932363281 msp-factory-idemix-versions [msp] Support all MSP versions for Idemix and add factory test coverage #### Type of change - Bug fix - Test update #### Description - `New` now accepts `MSPv1_0`..`MSPv3_0` for `*IdemixNewOpts`, matching the versions already supported for `... Pull #229 23 Oct 2026 09:31AM UTC adecaro github
82.2
39793857722 fix-flaky-bft-deliverer-tests [blocksprovider] Fix BFT censorship monitor stop race and flaky deliverer test #### Type of change - Bug fix - Test update #### Description - `BFTCensorshipMonitor.launchHeaderReceivers()` does nothing once the monitor is stopped, so `Monitor(... Pull #228 22 Oct 2026 02:14PM UTC tock-ibm github
82.14
39776640765 fix-flaky-bft-deliverer-tests [blocksprovider] Fix BFT censorship monitor stop race and flaky deliverer test #### Type of change - Bug fix - Test update #### Description - `BFTCensorshipMonitor.launchHeaderReceivers()` does nothing once the monitor is stopped, so `Monitor(... Pull #228 22 Oct 2026 12:15PM UTC liran-funaro github
82.14
39776363375 fix-flaky-bft-deliverer-tests [blocksprovider] Fix BFT censorship monitor stop race and flaky deliverer test #### Type of change - Bug fix - Test update #### Description - `BFTCensorshipMonitor.launchHeaderReceivers()` does nothing once the monitor is stopped, so `Monitor(... Pull #228 22 Oct 2026 12:13PM UTC liran-funaro github
82.14
39776386156 fix-flaky-bft-deliverer-tests [blocksprovider] Fix BFT censorship monitor stop race and flaky deliverer test #### Type of change - Bug fix - Test update #### Description - `BFTCensorshipMonitor.launchHeaderReceivers()` does nothing once the monitor is stopped, so `Monitor(... Pull #228 22 Oct 2026 12:13PM UTC liran-funaro github
82.15
39773948939 main [configtxlator] Replace gorilla/mux and gorilla/handlers (#226) #### Type of change - Dependency update #### Description - The REST router is an `http.ServeMux` with method+path patterns, and handlers read the message name with `r.PathValue`. ... push 22 Oct 2026 11:55AM UTC web-flow github
82.14
See All Builds (389)
  • Repo on GitHub
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc