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

ENH: tqdm - use leave=True instead of explicit clean call to avoid spurious new lines #1372

Merged
merged 3 commits into from
Mar 16, 2017

Conversation

yarikoptic
Copy link
Member

@yarikoptic yarikoptic commented Mar 15, 2017

There is still seems to be some spurious new lines, but otherwise output
seems to behave better

Example:

before:

$> datalad install -g -J3 sub001/anatomy
[INFO   ] Getting 1 items of dataset <Dataset path=/tmp/raiders> ...
[INFO   ] Actually getting 10 files

1 installed item is available at
<Dataset path=/tmp/raiders>

after:

$> datalad install -g -J3 sub001/anatomy
[INFO   ] Getting 1 items of dataset <Dataset path=/tmp/raiders> ...
[INFO   ] Actually getting 10 files
1 installed item is available at
<Dataset path=/tmp/raiders>

TODO

  • just disable "interactive" progress bars by default while running tests, make them "optional" so we could still smoke test them. This is to avoid destroying output such as names of the tests being printed out... and there is still some spurious newline in some cases which extends output

…appearance

There is still seems to be some spurious new lines, but otherwise output
seems to behave better

Example:

before:

$> datalad install -g -J3 sub001/anatomy
[INFO   ] Getting 1 items of dataset <Dataset path=/tmp/raiders> ...
[INFO   ] Actually getting 10 files

1 installed item is available at
<Dataset path=/tmp/raiders>

                                                                                                           after:
                                                                                                           $> datalad install -g -J3 sub001/anatomy
[INFO   ] Getting 1 items of dataset <Dataset path=/tmp/raiders> ...
[INFO   ] Actually getting 10 files
1 installed item is available at
<Dataset path=/tmp/raiders>

;-)
@yarikoptic yarikoptic added enhancement UX user experience WIP work in progress needs-review and removed WIP work in progress labels Mar 15, 2017
@codecov-io
Copy link

codecov-io commented Mar 16, 2017

Codecov Report

Merging #1372 into master will decrease coverage by 55.68%.
The diff coverage is 75%.

Impacted file tree graph

@@             Coverage Diff             @@
##           master    #1372       +/-   ##
===========================================
- Coverage    89.4%   33.72%   -55.69%     
===========================================
  Files         236      236               
  Lines       24682    24683        +1     
===========================================
- Hits        22068     8325    -13743     
- Misses       2614    16358    +13744
Impacted Files Coverage Δ
datalad/ui/progressbars.py 82.6% <75%> (-14.46%) ⬇️
datalad/interface/tests/test_docs.py 0% <0%> (-100%) ⬇️
datalad/distribution/tests/test_add_sibling.py 0% <0%> (-100%) ⬇️
datalad/export/tests/__init__.py 0% <0%> (-100%) ⬇️
datalad/crawler/pipelines/__init__.py 0% <0%> (-100%) ⬇️
...ata/parsers/tests/test_frictionless_datapackage.py 0% <0%> (-100%) ⬇️
datalad/customremotes/tests/__init__.py 0% <0%> (-100%) ⬇️
datalad/interface/tests/test_utils.py 0% <0%> (-100%) ⬇️
datalad/metadata/parsers/tests/test_aggregate.py 0% <0%> (-100%) ⬇️
datalad/crawler/base.py 0% <0%> (-100%) ⬇️
... and 180 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 5d34376...64473b1. Read the comment docs.

@mih
Copy link
Member

mih commented Mar 16, 2017

Great. Much appreciated!

@mih mih merged commit 5bca660 into datalad:master Mar 16, 2017
@yarikoptic yarikoptic deleted the enh-pbars branch April 2, 2017 01:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement UX user experience
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants