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

[MRG] Remove --traverse-directory from commands & make default #1178

Merged
merged 10 commits into from
Aug 19, 2020

Conversation

ctb
Copy link
Contributor

@ctb ctb commented Aug 19, 2020

Old behavior in 2.x and 3.x: when the user wants to load all signatures from under a directory, they must specify --traverse-directory to the command.

New behavior: if a directory is provided on the command line, it is automatically traversed for signatures (*.sig). -f still forces loading filenames that do not end with .sig.

This PR also modifies sourmash_args.load_dbs_sigs(...), .load_file_as_index(...), and load_file_as_signatures(...) to no longer take a traverseargument.

Fixes #836
Fixes #1061

  • Is it mergeable?
  • make test Did it pass the tests?
  • make coverage Is the new code covered?
  • Did it change the command-line interface? Only additions are allowed
    without a major version increment. Changing file formats also requires a
    major version number increment.
  • Was a spellchecker run on the source code and documentation after
    changes were made?

@ctb ctb changed the title Make it so that --traverse-directory is no longer explicitly required [WIP] Make it so that --traverse-directory is no longer explicitly required Aug 19, 2020
@codecov
Copy link

codecov bot commented Aug 19, 2020

Codecov Report

Merging #1178 into latest will increase coverage by 9.13%.
The diff coverage is 92.59%.

Impacted file tree graph

@@            Coverage Diff             @@
##           latest    #1178      +/-   ##
==========================================
+ Coverage   84.10%   93.24%   +9.13%     
==========================================
  Files          99       75      -24     
  Lines        9224     5906    -3318     
==========================================
- Hits         7758     5507    -2251     
+ Misses       1466      399    -1067     
Flag Coverage Δ
#rusttests ?

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
sourmash/cli/categorize.py 100.00% <ø> (ø)
sourmash/cli/compare.py 100.00% <ø> (ø)
sourmash/cli/gather.py 100.00% <ø> (ø)
sourmash/cli/index.py 100.00% <ø> (ø)
sourmash/cli/lca/classify.py 100.00% <ø> (ø)
sourmash/cli/lca/index.py 100.00% <ø> (ø)
sourmash/cli/lca/summarize.py 100.00% <ø> (ø)
sourmash/cli/multigather.py 100.00% <ø> (ø)
sourmash/cli/search.py 100.00% <ø> (ø)
sourmash/lca/command_classify.py 88.75% <ø> (ø)
... and 29 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1546d18...f0913fb. Read the comment docs.

@ctb ctb changed the title [WIP] Make it so that --traverse-directory is no longer explicitly required [MRG] Remove --traverse-directory from commands & make default Aug 19, 2020
sourmash/cli/index.py Outdated Show resolved Hide resolved
Copy link
Contributor

@bluegenes bluegenes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm!

@ctb ctb merged commit 0a15553 into latest Aug 19, 2020
@ctb ctb deleted the traverse_is_default branch August 19, 2020 16:01
@ctb ctb mentioned this pull request Feb 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

turn --traverse-directories on by default in 4.0 --traverse-directory behavior is counterintuitive
2 participants