Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Panic in processBroadcasts

Open
#142 0 comments 0 reactions 1 assignee View on GitHub

@peterbroadhurst is already working on this.

Since Sep 1, 2021.

Assessment

This issue has not been assessed yet.

Description

FireFly e2e has been failing in the Github actions, and I just tried it locally… I found that ethconnect was failing with:

ethconnect_0_1  | [2021-09-01T21:18:51.134Z] DEBUG WS/d6949896-7c43-4e51-6483-dc37de68f424: Received: {Type:listenreplies Topic: Message:}
ethconnect_0_1  | panic: runtime error: index out of range [1] with length 1
ethconnect_0_1  | 
ethconnect_0_1  | goroutine 26 [running]:
ethconnect_0_1  | github.com/kaleido-io/ethconnect/internal/ws.(*webSocketServer).processBroadcasts.func1(0xc000308000, 0x1, 0x1)
ethconnect_0_1  | 	/ethconnect/internal/ws/wsserver.go:170 +0x569
ethconnect_0_1  | github.com/kaleido-io/ethconnect/internal/ws.(*webSocketServer).processBroadcasts(0xc000146ff0)
ethconnect_0_1  | 	/ethconnect/internal/ws/wsserver.go:186 +0x1fd
ethconnect_0_1  | created by github.com/kaleido-io/ethconnect/internal/ws.NewWebSocketServer
ethconnect_0_1  | 	/ethconnect/internal/ws/wsserver.go:77 +0x165

Quick look at the code suggests it's a lack of synchronization on the s.topics between these lines, will investigate more:
https://github.com/hyperledger-labs/firefly-ethconnect/blob/2e28ec415a4c3098624d7898cc58ec43af7b5f4a/internal/ws/wsserver.go#L165-L166

Dominant language
Go
Stars
76
Forks
31
PR merge metrics
No merged PRs in 30d

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from hyperledger-firefly/ethconnect

All issues in hyperledger-firefly/ethconnect

Similar issues

More Go issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.