Skip to content

What should be the getContents() behavior when a file doesn't exist? #95

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

Closed
mmoreram opened this issue Jul 7, 2021 · 2 comments
Closed
Labels
Milestone

Comments

@mmoreram
Copy link

mmoreram commented Jul 7, 2021

Right now, when a file is not found and we access to its content, the method just keeps waiting. Instead of that, we can make an exists call before it.

Is it a good behavior to let a method keep waiting until the infinite? I understand that this action is not blocking at all, but what is the point?

@SimonFrings
Copy link
Member

Hey @mmoreram, thanks for bringing this up 👍

You're right, this should not be the behavior of getContents() when a file doesn't exist! In my opinion, this should throw an exception with a message that says that the requested file is nowhere to be found.

@WyriHaximus is currently rewriting the project, you can take a look at that here: #97. After that, we need to put some work into polishing the project so I think this will be fixed in the same run.

@clue
Copy link
Member

clue commented Feb 9, 2022

@mmoreram Thanks for bringing this up! #97 has just been merged and I believe this has been answered, so I'm closing this for now. Please come back with more details if this problem persists and we can always reopen this 👍

@clue clue closed this as completed Feb 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants