Skip to content

Conversation

@sohw400
Copy link

@sohw400 sohw400 commented Oct 13, 2025

What changed

Replaced several unwrap() and expect() calls in pipeline/src/main.rs with proper error handling using match expressions. The changes provide clearer error messages and prevent unexpected panics during normal operation.

Why

The pipeline binary is a core component for enclave communication, and users shouldn't see panic backtraces when things like config file issues occur. Better to give them a clean error message and exit code 1.

Changes

  • Config file loading now reports specific errors (file not found vs parse errors)
  • All subcommand argument parsing has explicit error handling
  • Command execution failures provide context about what went wrong
  • Exit codes are preserved throughout the flow

Tested the changes and confirmed that error messages are now user-friendly while maintaining the same exit behavior.

- Update outdated dependencies: clap 3.2.25→4.5, nix 0.26→0.29, byteorder 1.3→1.5, num 0.2→0.4
- Normalize serde version constraints from '>=1.0' to '1.0'
- Add comprehensive package metadata to all Cargo.toml files:
  - Add missing authors, descriptions, and license information
  - Fix repository URLs pointing to correct GitHub organization
  - Add relevant keywords and categories for Rust package discovery
  - Set homepage links to main repository
- Establish workspace-level metadata inheritance
- Add accessibility improvements to README.md banner image
- Set rust-version metadata to 1.80 for toolchain consistency

This improves package discoverability, maintainability, and follows Rust ecosystem best practices.
Replaced panicking unwrap/expect calls with proper error handling.
Now gives cleaner error messages when config file is missing or invalid,
and when command execution fails. Exit codes are preserved.
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.

1 participant