Skip to content

fix: allow exiting a running measurement#182

Merged
MartinKolarik merged 1 commit intojsdelivr:masterfrom
radulucut:fix-exit
Dec 16, 2025
Merged

fix: allow exiting a running measurement#182
MartinKolarik merged 1 commit intojsdelivr:masterfrom
radulucut:fix-exit

Conversation

@radulucut
Copy link
Collaborator

Closes #181

@coderabbitai
Copy link

coderabbitai bot commented Dec 16, 2025

Walkthrough

Signal handling for SIGINT and SIGTERM is redistributed across commands. The centralized signal handling previously in root.go—which imported os/signal and syscall—is removed. Signal registration is now implemented independently in auth.go and ping.go, allowing each command to manage cancellation of its respective flow upon receiving OS signals.

Pre-merge checks and finishing touches

✅ Passed checks (5 passed)
Check name Status Explanation
Description check ✅ Passed The description references the linked issue #181, which relates to the changeset's objective of enabling interruption of running measurements.
Linked Issues check ✅ Passed The changes implement OS signal handling (SIGINT/SIGTERM) in auth.go and ping.go to enable measurement cancellation, directly addressing issue #181's requirement for Ctrl+C interruption.
Out of Scope Changes check ✅ Passed Removal of signal handling from root.go is necessary to avoid duplicate signal registration, making it an in-scope refactoring supporting the signal handling consolidation in auth.go and ping.go.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Title check ✅ Passed The title accurately describes the main objective of the PR: enabling users to exit running measurements via Ctrl+C by adding OS signal handling.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Comment @coderabbitai help to get the list of available commands and usage tips.

@MartinKolarik MartinKolarik changed the title fix: can't exit a running measurement fix: allow exiting a running measurement Dec 16, 2025
@MartinKolarik MartinKolarik merged commit e2a36c6 into jsdelivr:master Dec 16, 2025
4 checks passed
@radulucut radulucut deleted the fix-exit branch December 16, 2025 13:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cant exit a running measurement

2 participants