hyperledger / hyperledger/fabric-x-common
[flaky test] TestBFTDeliverer_NoBlocks
- Dominant language
- Go
- Stars
- 21
- Forks
- 15
- Avg merge
- 2d 19h
- Merged PRs (30d)
- 20
Description
```
make: *** [Makefile:63: test-cover] Error 1
=== Failed
=== FAIL: common/deliverclient/blocksprovider TestBFTDeliverer_NoBlocks (unknown)
2026-08-16 21:00:17.704 UTC 0034 INFO [BFTHeaderReceiver] Stop -> [testchannel][orderer-address-2] Already stopped
2026-08-16 21:00:17.704 UTC 0035 INFO [BFTHeaderReceiver] Stop -> [testchannel][orderer-address-1] Already stopped
2026-08-16 21:00:17.704 UTC 0036 INFO [BFTHeaderReceiver] Stop -> [testchannel][orderer-address-1] Stopping
panic: close of closed channel
goroutine 472 [running]:
github.com/hyperledger/fabric-x-common/common/deliverclient/blocksprovider_test.TestBFTCensorshipMonitor_FaultySourceRecovery.func1.4()
/home/runner/work/fabric-x-common/fabric-x-common/common/deliverclient/blocksprovider/bft_censorship_monitor_test.go:640 +0x2c
github.com/hyperledger/fabric-x-common/common/deliverclient/blocksprovider/fake.(*DeliverClient).CloseSend(0x13cb79f71608)
/home/runner/work/fabric-x-common/fabric-x-common/common/deliverclient/blocksprovider/fake/ab_deliver_client.go:115 +0x190
github.com/hyperledger/fabric-x-common/common/deliverclient/blocksprovider.(*BFTHeaderReceiver).Stop(0x13cb7a21e820)
/home/runner/work/fabric-x-common/fabric-x-common/common/deliverclient/blocksprovider/bft_header_receiver.go:190 +0x259
github.com/hyperledger/fabric-x-common/common/deliverclient/blocksprovider.(*BFTHeaderReceiver).DeliverHeaders.func1()
/home/runner/work/fabric-x-common/fabric-x-common/common/deliverclient/blocksprovider/bft_header_receiver.go:88 +0xc5
github.com/hyperledger/fabric-x-common/common/deliverclient/blocksprovider.(*BFTHeaderReceiver).DeliverHeaders(0x13cb7a21e820)
/home/runner/work/fabric-x-common/fabric-x-common/common/deliverclient/blocksprovider/bft_header_receiver.go:99 +0xdce
created by github.com/hyperledger/fabric-x-common/common/deliverclient/blocksprovider.(*BFTCensorshipMonitor).launchHeaderReceivers in goroutine 346
/home/runner/work/fabric-x-common/fabric-x-common/common/deliverclient/blocksprovider/bft_censorship_monitor.go:375 +0xd85
DONE 1475 tests, 1 failure in 36.728s
Error: Process completed with exit code 2.
```
Contributor guide
No contributing guide indexed for this repository
Research direction
Reproduce common/deliverclient/blocksprovider TestBFTDeliverer_NoBlocks and inspect the panic path at bft_censorship_monitor_test.go:640, fake/ab_deliver_client.go:115, and bft_header_receiver.go:88-190. Trace the shutdown sequence and run the package tests repeatedly; done means the flaky test completes without a close-of-closed-channel panic and the suite passes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- testing
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 50/100