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

Added prerequisite models #78

Merged
merged 2 commits into from
Jan 21, 2023
Merged

Added prerequisite models #78

merged 2 commits into from
Jan 21, 2023

Conversation

abhi1693
Copy link
Member

Pull Request

Related Issue

Fixes #77

New Behavior

...

Contrast to Current Behavior

...

Discussion: Benefits and Drawbacks

...

Changes to the Documentation

...

Proposed Release Note Entry

...

Double Check

  • I have explained my PR according to the information in the comments
    or in a linked issue.
  • My PR targets the dev branch.

@abhi1693 abhi1693 added the enhancement New feature or request label Jan 20, 2023
@abhi1693 abhi1693 self-assigned this Jan 20, 2023
@sourcery-ai
Copy link

sourcery-ai bot commented Jan 20, 2023

Sourcery Code Quality Report

✅  Merging this PR will increase code quality in the affected files by 1.67%.

Quality metrics Before After Change
Complexity 8.67 🙂 8.28 ⭐ -0.39 👍
Method Length 61.56 🙂 55.68 ⭐ -5.88 👍
Working memory 8.81 🙂 8.55 🙂 -0.26 👍
Quality 61.59% 🙂 63.26% 🙂 1.67% 👍
Other metrics Before After Change
Lines 492 505 13
Changed files Quality Before Quality After Quality Change
setup.py 92.37% ⭐ 92.42% ⭐ 0.05% 👍
.devcontainer/configuration/plugins.py 99.50% ⭐ 99.50% ⭐ 0.00%
netbox_acls/forms/models.py 51.85% 🙂 51.85% 🙂 0.00%
netbox_acls/models/access_list_rules.py 97.74% ⭐ 98.16% ⭐ 0.42% 👍
netbox_acls/models/access_lists.py 93.52% ⭐ 94.10% ⭐ 0.58% 👍

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

File Function Complexity Length Working Memory Quality Recommendation
netbox_acls/forms/models.py ACLInterfaceAssignmentForm.clean 12 🙂 289 ⛔ 15 😞 34.21% 😞 Try splitting into smaller methods. Extract out complex expressions
netbox_acls/forms/models.py AccessListForm.clean 19 😞 226 ⛔ 13 😞 34.25% 😞 Refactor to reduce nesting. Try splitting into smaller methods. Extract out complex expressions
netbox_acls/forms/models.py ACLExtendedRuleForm.clean 15 🙂 121 😞 6 ⭐ 61.28% 🙂 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!

@sonarcloud
Copy link

sonarcloud bot commented Jan 20, 2023

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

@ryanmerolle
Copy link
Collaborator

Thanks @abhi1693 Looks good to me. I will work on cleaning up the Actions, my attempt to have the pipeline highlight simple lint and other code quality items looks to have gone overboard. I also have no clue why the SonarCloud token is not taking.

@ryanmerolle ryanmerolle merged commit d241755 into netbox-community:dev Jan 21, 2023
@abhi1693 abhi1693 deleted the feat/77-prerequisite-models branch January 21, 2023 07:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature]: Add prerequisite models
2 participants