Skip to content

Conversation

@linw1995
Copy link
Owner

Closes #140

Summary

This PR improves error handling and logging for external command notifications, making it easier to troubleshoot configuration issues.

Changes

  • Added warn level logs when external command execution fails at any stage (spawn, write to stdin, wait, exit status)
  • Added structured logging with relevant context (executable path, args, exit status)
  • Added normalize_executable_path function to expand tilde (~) in executable paths using HOME environment variable
  • Improved error handling with explicit match statements instead of silent failures
  • Added unit test for tilde expansion in executable paths

@codecov-commenter
Copy link

Codecov Report

❌ Patch coverage is 42.22222% with 26 lines in your changes missing coverage. Please review.
✅ Project coverage is 48.85%. Comparing base (a46f02c) to head (1f0dbf6).
⚠️ Report is 5 commits behind head on dev.

Files with missing lines Patch % Lines
crates/coco-tui/src/notifications.rs 42.22% 26 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##              dev     #142      +/-   ##
==========================================
- Coverage   50.22%   48.85%   -1.38%     
==========================================
  Files          93       95       +2     
  Lines       25033    26112    +1079     
==========================================
+ Hits        12574    12756     +182     
- Misses      12459    13356     +897     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@linw1995 linw1995 merged commit 405141b into dev Jan 24, 2026
3 checks passed
@linw1995 linw1995 added the enhancement New feature or request label Jan 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug: External command notification fails without error logs

3 participants