managend pickhardt_pay verbosity with two optional arguments #17#21
Open
sebulino wants to merge 8 commits into
Open
managend pickhardt_pay verbosity with two optional arguments #17#21sebulino wants to merge 8 commits into
sebulino wants to merge 8 commits into
Conversation
first stub of a method as described in renepickhardt#16 Still needs to be tested
… routed successfully
statistics (round_verbosity) can be added for each round of payment attempts and/or can be added as a final summary (summary).
statistics (round_verbosity) can be added for each round of payment attempts and/or can be added as a final summary (summary).
Owner
|
While I think this is very much needed I was more thinking of using https://docs.python.org/3/howto/logging.html#logging-basic-tutorial. sorry should have linked this in #17 |
Contributor
Author
|
The idea is to record the current statistics for payment rounds as well as the final one as |
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.
currently statistical summaries are printed in
pickhardt_payin each round of payment attempts and in the end.I added two flags to
pickhardt_paymethod as optional arguments:summary(default:False) for the final statistics.round_verbosity(default:False) for the statistics on the payment attempts in each loop.Statistics for each loop have their own method,
_evaluate_attempts, where I added the optional argument as well (default:False)._evaluate_attemptswill receive the optional argument frompickhardt_pay.My initial thought was to make the whole call of
_evaluate_attemptsdependent on the verbosity choice in thepickhardt_paycall. However, this would not work, as thepickhardt_paycall needs to receive the return values from_evaluate_attemptsfor its final summary.All statistics are printed to console.