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

No error if asar file cannot be written to disk? #256

Open
Nantris opened this issue Dec 8, 2022 · 4 comments
Open

No error if asar file cannot be written to disk? #256

Nantris opened this issue Dec 8, 2022 · 4 comments

Comments

@Nantris
Copy link

Nantris commented Dec 8, 2022

For example, if there's insufficient disk space, there doesn't seem to be any error?

This is the case whether the file is written incompletely or not at all. I'd expect an error.

@Nantris
Copy link
Author

Nantris commented Dec 8, 2022

@zcbenz @MarshallOfSound is this an intentional behavior? If so can you clue me into the rationale?

Is there any way you can suggest that one could gracefully handle errors during programmatic use?

Right now the only method that occurs me to me is to wait XX seconds for an operation to finish, and to assume that it failed if the time exceeds XX seconds, but that's pretty brittle.

It would be wonderful is asar threw an error when the file write failed in some capacity!

@Nantris
Copy link
Author

Nantris commented Dec 12, 2022

In lieu of an error, is there any way to verify the integrity of the entire file?

@Nantris
Copy link
Author

Nantris commented Dec 14, 2022

To clarify, I know the README says no errors are provided, but the reason I find this particular lack of error unexpected is that errors do seem to be provided upon failure to extract the archive in the same scenario (full disk.)

Actually, this is the only operation I've come across that actually adheres to the README - granted I'm not using half the functions.

@zcbenz
Copy link
Contributor

zcbenz commented Jan 5, 2023

Sorry for the late response. The project was initially only intended to be used as CLI tool so there was lack of error handling, but it is definitely not a good thing. Contributions to add error handling would be very welcomed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants