zobov.py - fix bug that moves all files if handle is empty#8
Open
broukema wants to merge 1 commit intoseshnadathur:mainfrom
Open
zobov.py - fix bug that moves all files if handle is empty#8broukema wants to merge 1 commit intoseshnadathur:mainfrom
broukema wants to merge 1 commit intoseshnadathur:mainfrom
Conversation
An empty value of `handle` in `parameters/params.py` can cause zobov to shift all files from the Revolver/ main directory into a subsubdirectory and then crash due to recursiveness. This commit fixes the bug by setting a default handle "myhandle" if handle is an empty string. Side effect: this commit also solves a bug that I haven't posted: if `output_folder` does not have a trailing slash, then the zobov directory handling strategies are again unlikely to do what is expected by the user. It's easy to use a python library function to add a trailing slash in an OS-independent way, so that is done in this commit too.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
An empty value of
handleinparameters/params.pycan causezobov to shift all files from the Revolver/ main directory into a
subsubdirectory and then crash due to recursiveness. This is
listed as a bug at #7 .
This commit fixes the bug by setting a default handle "myhandle"
if handle is an empty string.
Side effect: this commit also solves a bug that I haven't posted: if
output_folderdoes not have a trailing slash, then the zobovdirectory handling strategies are again unlikely to do what is
expected by the user. It's easy to use a python library function to
add a trailing slash in an OS-independent way, so that is done
in this commit too.