Skip to content

Use error on invalid UTF-8 output#323

Open
janhencic wants to merge 1 commit intozhaofengli:mainfrom
janhencic:use-bad-output-error
Open

Use error on invalid UTF-8 output#323
janhencic wants to merge 1 commit intozhaofengli:mainfrom
janhencic:use-bad-output-error

Conversation

@janhencic
Copy link
Copy Markdown
Contributor

This update returns ColmenaError::BadOutput instead of unwrapping when capturing a command’s output. I used from_utf8_lossy to keep the output readable with replacement characters for invalid sequences, avoiding a panic on non-UTF-8 bytes.

This update returns ColmenaError::BadOutput instead of unwrapping when
capturing a command’s output. I used from_utf8_lossy to keep the output
readable with replacement characters for invalid sequences, avoiding a
panic on non-UTF-8 bytes.
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