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

grid-x / ocpp-go
89%
gridx_extensions: 89%

Build:
Build:
LAST BUILD BRANCH: fix/client-dispatcher-send-on-closed-channel
DEFAULT BRANCH: gridx_extensions
Repo Added 11 May 2021 09:51AM UTC
Token mg5HGkL3hqgBwtOMVHeKdtx15Oa7fGCH0 regen
Build 79 Last
Files 111
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 fix/client-dispatcher-send-on-closed-channel
branch: SELECT
CHANGE BRANCH
x
Sync Branches
  • No branch selected
  • dependabot/go_modules/github.com/sirupsen/logrus-1.8.3
  • feat/add_bdl_extension
  • feat/add_logging_of_raw_json_msg
  • feat/create_ocpp_go_server_2.0.1_int-255
  • feat/fix_several_race_conditions
  • feat/rebase_master
  • feat/sync_with_master
  • feature/sync_upstream
  • fix/add_new_bdl_subprotocol_name-inte-547
  • fix/allow-empty-idTag-INTE-1856
  • fix/allow_change_configuration_with_empty_value
  • fix/charging_station_waiting_forever_in_SendRequest_after_stopped
  • fix/client-dispatcher-send-on-closed-channel
  • fix/close_chargingstation_channels_on_stop_ocpp2.0.1_upstream
  • fix/fix_close_nil_channel_panic_on_stop
  • fix/improve_clients_stop_function
  • fix/ocpp_onreconnect_GBX-2485
  • fix/onreconnected_dispatch
  • fix/remove_docker_publish_workflow
  • fix/remove_duplicate_reconnect
  • fix/security_issue_yaml_pkg
  • fix/stop_transaction_meter_stop
  • fix/websocket_close_race
  • gridx_extensions
  • gridx_master_ng
  • master
  • sync-fork
  • sync-gridx_extensions
  • tls

31 Mar 2026 11:55AM UTC coverage: 88.886% (-0.1%) from 88.999%
23795973618

push

github

mkrafeld
fix(ocppj): guard DefaultClientDispatcher.SendRequest against send-on-closed-channel panic

Stop() previously closed requestChannel, so a concurrent SendRequest call
racing the close would panic at 'd.requestChannel <- true'. This mirrors
the same bug the ServerDispatcher already had fixed via stoppedC.

Changes:
- Add stoppedC chan struct{} to DefaultClientDispatcher
- Start(): initialise stoppedC alongside requestChannel (under mutex)
- Stop(): close stoppedC instead of requestChannel; set requestChannel=nil
  so IsRunning() returns false immediately
- SendRequest(): capture rc/sc under RLock, return error if rc==nil, then
  use select{case rc<-true / case <-sc} so a concurrent Stop() returns
  "client stopped" instead of panicking
- messagePump(): add case <-d.stoppedC as primary exit path

22 of 29 new or added lines in 1 file covered. (75.86%)

4 existing lines in 1 file now uncovered.

6542 of 7360 relevant lines covered (88.89%)

13.5 hits per line

Relevant lines Covered
Build:
Build:
7360 RELEVANT LINES 6542 COVERED LINES
13.5 HITS PER LINE
Source Files on gridx_extensions
  • Tree
  • List 111
  • Changed 1
  • Source Changed 0
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line

Recent builds

Builds Branch Commit Type Ran Committer Via Coverage
23795973618 fix/client-dispatcher-send-on-closed-channel fix(ocppj): guard DefaultClientDispatcher.SendRequest against send-on-closed-channel panic Stop() previously closed requestChannel, so a concurrent SendRequest call racing the close would panic at 'd.requestChannel <- true'. This mirrors the same... push 31 Mar 2026 11:56AM UTC mkrafeld github
88.89
23795795276 fix/client-dispatcher-send-on-closed-channel Merge pull request #21 from grid-x/fix/fix_close_nil_channel_panic_on_stop Improve Handling of stopped channel stopping the Server push 31 Mar 2026 11:52AM UTC web-flow github
89.0
23191101621 dependabot/go_modules/github.com/sirupsen/logrus-1.8.3 chore(deps): bump github.com/sirupsen/logrus from 1.4.2 to 1.8.3 Bumps [github.com/sirupsen/logrus](https://github.com/sirupsen/logrus) from 1.4.2 to 1.8.3. - [Release notes](https://github.com/sirupsen/logrus/releases) - [Changelog](https://gith... Pull #22 17 Mar 2026 11:05AM UTC web-flow github
89.03
8750469412 gridx_extensions Merge pull request #21 from grid-x/fix/fix_close_nil_channel_panic_on_stop Improve Handling of stopped channel stopping the Server push 19 Apr 2024 08:12AM UTC web-flow github
89.0
8750366009 fix/fix_close_nil_channel_panic_on_stop feat(ocppj): improve closing "stopped" channel when server is stopping Pull #21 19 Apr 2024 08:04AM UTC tretmar github
89.0
8750318447 fix/fix_close_nil_channel_panic_on_stop feat(ocppj): improve closing "stopped" channel when server is stopping Pull #21 19 Apr 2024 08:00AM UTC tretmar github
89.0
8750301501 fix/fix_close_nil_channel_panic_on_stop feat(ocppj): improve closing "stopped" channel when server is stopping push 19 Apr 2024 07:58AM UTC tretmar github
89.0
8749519041 gridx_extensions Merge pull request #20 from grid-x/fix/fix_close_nil_channel_panic_on_stop Fix Panic when stopping Server before even started push 19 Apr 2024 06:43AM UTC web-flow github
89.03
8748620426 fix/fix_close_nil_channel_panic_on_stop fix(ocppj): initialise the stopped channel earlier than Start() Pull #20 19 Apr 2024 05:01AM UTC tretmar github
89.03
8748606415 fix/fix_close_nil_channel_panic_on_stop fix(ocppj): initialise the stopped channel earlier than Start() push 19 Apr 2024 04:58AM UTC tretmar github
89.0
See All Builds (76)

Badge your Repo: ocpp-go

We detected this repo isn’t badged! Grab the embed code to the right, add it to your repo to show off your code coverage, and when the badge is live hit the refresh button to remove this message.

Could not find badge in README.

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

Refresh
  • Settings
  • Repo on GitHub
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc