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

improve stats summary in cat_plot (Sourcery refactored) #35

Closed
wants to merge 2 commits into from

Conversation

sourcery-ai[bot]
Copy link
Contributor

@sourcery-ai sourcery-ai bot commented Sep 22, 2022

Pull Request #34 refactored by Sourcery.

Since the original Pull Request was opened as a fork in a contributor's
repository, we are unable to create a Pull Request branching from it.

To incorporate these changes, you can either:

  1. Merge this Pull Request instead of the original, or

  2. Ask your contributor to locally incorporate these commits and push them to
    the original Pull Request

    Incorporate changes via command line
    git fetch https://github.com/akanz1/klib pull/34/head
    git merge --ff-only FETCH_HEAD
    git push

NOTE: As code is pushed to the original Pull Request, Sourcery will
re-run and update (force-push) this Pull Request with new refactorings as
necessary. If Sourcery finds no refactorings at any point, this Pull Request
will be closed automatically.

See our documentation here.

Run Sourcery locally

Reduce the feedback loop during development by using the Sourcery editor plugin:

Help us improve this pull request!

@sourcery-ai
Copy link
Contributor Author

sourcery-ai bot commented Sep 22, 2022

Sourcery Code Quality Report

❌  Merging this PR will decrease code quality in the affected files by 1.06%.

Quality metrics Before After Change
Complexity 8.61 🙂 9.86 🙂 1.25 👎
Method Length 482.50 ⛔ 484.83 ⛔ 2.33 👎
Working memory 16.91 ⛔ 16.93 ⛔ 0.02 👎
Quality 32.94% 😞 31.88% 😞 -1.06% 👎
Other metrics Before After Change
Lines 774 775 1
Changed files Quality Before Quality After Quality Change
src/klib/describe.py 32.94% 😞 31.88% 😞 -1.06% 👎

Here are some functions in these files that still need a tune-up:

File Function Complexity Length Working Memory Quality Recommendation
src/klib/describe.py cat_plot 17 🙂 694 ⛔ 21 ⛔ 21.28% ⛔ Try splitting into smaller methods. Extract out complex expressions
src/klib/describe.py missingval_plot 6 ⭐ 822 ⛔ 19 ⛔ 32.20% 😞 Try splitting into smaller methods. Extract out complex expressions
src/klib/describe.py dist_plot 9 🙂 798 ⛔ 15 😞 33.10% 😞 Try splitting into smaller methods. Extract out complex expressions
src/klib/describe.py corr_plot 2 ⭐ 270 ⛔ 22 ⛔ 38.99% 😞 Try splitting into smaller methods. Extract out complex expressions
src/klib/describe.py corr_mat 8 ⭐ 199 😞 51.35% 🙂 Try splitting into smaller methods

Legend and Explanation

The emojis denote the absolute quality of the code:

  • ⭐ excellent
  • 🙂 good
  • 😞 poor
  • ⛔ very poor

The 👍 and 👎 indicate whether the quality has improved or gotten worse with this pull request.


Please see our documentation here for details on how these metrics are calculated.

We are actively working on this report - lots more documentation and extra metrics to come!

Help us improve this quality report!

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 1 Code Smell

No Coverage information No Coverage information
0.0% 0.0% Duplication

@codecov
Copy link

codecov bot commented Sep 22, 2022

Codecov Report

Merging #35 (e0d7e6e) into main (698010b) will decrease coverage by 0.11%.
The diff coverage is 0.00%.

@@            Coverage Diff             @@
##             main      #35      +/-   ##
==========================================
- Coverage   53.43%   53.31%   -0.12%     
==========================================
  Files           3        3              
  Lines         466      467       +1     
  Branches       64       64              
==========================================
  Hits          249      249              
- Misses        210      211       +1     
  Partials        7        7              
Impacted Files Coverage Δ
src/klib/describe.py 19.57% <0.00%> (-0.09%) ⬇️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@sourcery-ai sourcery-ai bot closed this Sep 23, 2022
@sourcery-ai sourcery-ai bot deleted the sourcery/pull-34 branch September 23, 2022 07:34
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.

1 participant