Skip to content

ENH: LogProgressBar to gain "start" reporting#6756

Merged
yarikoptic merged 1 commit into
datalad:masterfrom
yarikoptic:enh-log-progress-start
Jun 14, 2022
Merged

ENH: LogProgressBar to gain "start" reporting#6756
yarikoptic merged 1 commit into
datalad:masterfrom
yarikoptic:enh-log-progress-start

Conversation

@yarikoptic
Copy link
Copy Markdown
Member

Spotted while comparing behavior of log_progress whenever it does
not log progress at all it logs initiation of specific actions while
we were reporting only at the end of the operation. This way we would be reporting
also the beginning:

$> rm -rf datalad && DATALAD_UI_PROGRESSBAR=log datalad clone https://github.com/datalad/datalad.git
[INFO   ] Start Clone attempt
[INFO   ] Start Enumerating
[INFO   ]  Enumerating done in 0.000520706 sec
[INFO   ] Start Counting
[INFO   ]  Counting 174 Objects done in 0.0136135 sec at 12781 Objects/sec
[INFO   ] Start Compressing
[INFO   ]  Compressing 93 Objects done in 0.033551 sec at 2772 Objects/sec
[INFO   ] Start Receiving
[INFO   ]  Receiving 96987 Objects done in 6 seconds at 14219 Objects/sec
[INFO   ] Start Resolving
[INFO   ]  Resolving 75566 Deltas done in 0.604427 sec at 125021 Deltas/sec
[INFO   ]  Clone attempt 2 Candidate locations done in 8 seconds at 0.246755 Candidate locations/sec
install(ok): /tmp/datalad (dataset)

This is just an idea, and depends on either LogProgressBar not to be
completely removed (see #4325 (comment))

💫 Enhancements and new features

  • "log" progress bar would not report about starting specific action as well

Spotted while comparing behavior of log_progress whenever it does
not log progress at all it logs initiation of specific actions while
we were reporting only at the end of the operation.  This way we would be reporting
also the beginning:

	$> rm -rf datalad && DATALAD_UI_PROGRESSBAR=log datalad clone https://github.com/datalad/datalad.git
	[INFO   ] Start Clone attempt
	[INFO   ] Start Enumerating
	[INFO   ]  Enumerating done in 0.000520706 sec
	[INFO   ] Start Counting
	[INFO   ]  Counting 174 Objects done in 0.0136135 sec at 12781 Objects/sec
	[INFO   ] Start Compressing
	[INFO   ]  Compressing 93 Objects done in 0.033551 sec at 2772 Objects/sec
	[INFO   ] Start Receiving
	[INFO   ]  Receiving 96987 Objects done in 6 seconds at 14219 Objects/sec
	[INFO   ] Start Resolving
	[INFO   ]  Resolving 75566 Deltas done in 0.604427 sec at 125021 Deltas/sec
	[INFO   ]  Clone attempt 2 Candidate locations done in 8 seconds at 0.246755 Candidate locations/sec
	install(ok): /tmp/datalad (dataset)

This is just an idea, and depends on either LogProgressBar not to be
completely removed (see datalad#4325 (comment))
@yarikoptic yarikoptic added the semver-minor Increment the minor version when merged label Jun 8, 2022
@qlty-cloud-legacy
Copy link
Copy Markdown

Code Climate has analyzed commit 945d8ff and detected 2 issues on this pull request.

Here's the issue category breakdown:

Category Count
Security 2

View more on Code Climate.

@codecov
Copy link
Copy Markdown

codecov Bot commented Jun 8, 2022

Codecov Report

Merging #6756 (945d8ff) into master (8e49548) will increase coverage by 1.59%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master    #6756      +/-   ##
==========================================
+ Coverage   88.82%   90.41%   +1.59%     
==========================================
  Files         353      353              
  Lines       45741    45745       +4     
==========================================
+ Hits        40631    41362     +731     
+ Misses       5110     4383     -727     
Impacted Files Coverage Δ
datalad/ui/progressbars.py 76.53% <100.00%> (+0.53%) ⬆️
datalad/__init__.py 97.95% <0.00%> (+16.32%) ⬆️
datalad/tests/utils.py 57.11% <0.00%> (+35.48%) ⬆️
datalad/tests/test_tests_utils.py 92.39% <0.00%> (+92.39%) ⬆️

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 8e49548...945d8ff. Read the comment docs.

@bpoldrack
Copy link
Copy Markdown
Member

I don't have formed an opinion re removal.

However, it's a minimal change and doesn't make removal more complicated, hence don't see a reason to object.

@yarikoptic
Copy link
Copy Markdown
Member Author

well, since not even enabled by default and no objections -- let's proceed

@yarikoptic yarikoptic merged commit 797dde3 into datalad:master Jun 14, 2022
@mih mih mentioned this pull request Jul 1, 2022
40 tasks
@yarikoptic yarikoptic deleted the enh-log-progress-start branch July 11, 2022 19:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

semver-minor Increment the minor version when merged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants