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

Create dir before creating log file #210

Merged
merged 2 commits into from
Apr 20, 2022
Merged

Create dir before creating log file #210

merged 2 commits into from
Apr 20, 2022

Conversation

JoostBuitink
Copy link
Contributor

Fix the No such file or directory error when Wflow tries to write a log file in a (not yet) existing directory (see #209). Now, the directory is created before trying to create the log file.

@JoostBuitink JoostBuitink linked an issue Apr 20, 2022 that may be closed by this pull request
@visr
Copy link
Member

visr commented Apr 20, 2022

Thanks! we missed this, we do this for other output files as well.

Side note, seeing #209, do you think there is an added benefit of creating issues in cases like this, where you'll also directly work on the fix? I'd say issues are only useful to keep track of things that must be fixed later, or to discuss what is the problem or how to solve it.

@JoostBuitink
Copy link
Contributor Author

I was doubting whether it was necessary to create an issue, but considered it might be useful to both flag that the issue has been found, and to keep track of the fixed issues for future releases (while writing this; I realize I should update the changelog as well). However, especially since the fix for this issue is rather straightforward and harmless, I agree it might be a bit "overkill".

@visr visr added the bug Something isn't working label Apr 20, 2022
@visr
Copy link
Member

visr commented Apr 20, 2022

Yeah we can also use labels on PRs to indicate that they fix a bug. In the auto generated release notes, https://github.com/Deltares/Wflow.jl/releases/tag/v0.6.0, both issues and PRs are listed.

It's good to have this in the changelog, but it would have also been fine to leave out, since it's only meant for notable changes (for some definition of notable).

@JoostBuitink
Copy link
Contributor Author

Thanks for the explanation - good to know. Will keep this in mind for future bugfixes!

@JoostBuitink JoostBuitink merged commit f5fa889 into master Apr 20, 2022
@JoostBuitink JoostBuitink deleted the log_dir_fix branch April 20, 2022 11:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Error when creating log in new directory
2 participants