Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce fs_err as a replacement for fs #94

Merged
merged 4 commits into from
Oct 30, 2021
Merged

Introduce fs_err as a replacement for fs #94

merged 4 commits into from
Oct 30, 2021

Conversation

GabrielSimonetto
Copy link
Collaborator

@GabrielSimonetto GabrielSimonetto commented Oct 14, 2021

Resolves #56

I tried reproducing some errors and see if I can see the difference between before and after, but most errors just look the

  • - Erase a file that was already checked to exist
// On command.rs, and removing the .zip while it sleeps:
        Command::Decompress { files, output_folder } => {
            std::thread::sleep(std::time::Duration::from_secs(10));
$ cargo run d test_dir.zip
thread 'main' panicked at 'failed to open file `/home/gabriel/programas/ouch/test_dir.zip`', src/error.rs:177:45
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
  • - Change the permission of something
// This one doesn't require sleep
$ chmod 333 test_dir.zip

$ cargo run d test_dir.zip
thread 'main' panicked at 'not yet implemented', src/error.rs:159:40
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
  • - Delete something while writing

I was not able to reproduce this one

src/archive/zip.rs Outdated Show resolved Hide resolved
src/archive/tar.rs Outdated Show resolved Hide resolved
@marcospb19 marcospb19 marked this pull request as ready for review October 29, 2021 21:02
@marcospb19 marcospb19 added the hacktoberfest-accepted Tag PR as accepted for the hacktoberfest event label Oct 30, 2021
@marcospb19 marcospb19 merged commit 54cd148 into master Oct 30, 2021
@marcospb19 marcospb19 deleted the issue-56 branch November 2, 2021 21:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hacktoberfest-accepted Tag PR as accepted for the hacktoberfest event
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use fs-err crate instead of std::fs
2 participants