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

Avoid report erroring out if there is no data to show #203

Merged
merged 2 commits into from
Jul 29, 2023

Conversation

devdanzin
Copy link
Collaborator

When running wily report --changes, it's possible to end up with no data to show, which results in an IndexError from tabulate. In this PR the same guard-clause strategy of #197 is used to avoid that, while logging an error explaining why no output is generated.

This fixes an error that surfaced in #201, but I can't see why it would be triggered by that change.

@codecov-commenter
Copy link

codecov-commenter commented Jul 28, 2023

Codecov Report

Merging #203 (19e2b81) into master (578e361) will increase coverage by 0.01%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master     #203      +/-   ##
==========================================
+ Coverage   95.32%   95.33%   +0.01%     
==========================================
  Files          24       24              
  Lines        1241     1244       +3     
  Branches      278      279       +1     
==========================================
+ Hits         1183     1186       +3     
  Misses         33       33              
  Partials       25       25              
Files Changed Coverage Δ
src/wily/commands/report.py 97.16% <100.00%> (+0.08%) ⬆️

@tonybaloney tonybaloney merged commit b0411ae into tonybaloney:master Jul 29, 2023
19 checks passed
@devdanzin devdanzin deleted the fix_empty_report branch August 26, 2023 21:55
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.

None yet

3 participants