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

Issue #54 - User story 3.6 - Scheduling audits #233

Merged
merged 51 commits into from
Jan 31, 2021
Merged

Conversation

RobertBeaudenon
Copy link
Contributor

@RobertBeaudenon RobertBeaudenon commented Jan 28, 2021

Issue #54

This PR adds the functionality to schedule an audit template. When an inventory managers create an audit template, at the bottom they will see a new section named Scheduling. In this section they have the option to trigger an audit at a scheduled time specified. There are 2 ways to trigger: One time trigger, or at a recurrence time by expanding the recurrence tab and specifying the available option.

On the server end, you can see in the console output when the scheduled audit starts.

Neeham and others added 26 commits January 9, 2021 00:05
@codecov-io
Copy link

codecov-io commented Jan 28, 2021

Codecov Report

Merging #233 (2c937ac) into master (589ea60) will decrease coverage by 2.28%.
The diff coverage is 65.42%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #233      +/-   ##
==========================================
- Coverage   93.03%   90.75%   -2.29%     
==========================================
  Files          36       38       +2     
  Lines        1077     1168      +91     
==========================================
+ Hits         1002     1060      +58     
- Misses         75      108      +33     
Impacted Files Coverage Δ
server/audit_template/migrations/0001_initial.py 100.00% <ø> (ø)
server/inventory_item/migrations/0001_initial.py 100.00% <ø> (ø)
server/organization/migrations/0001_initial.py 100.00% <ø> (ø)
server/user_account/migrations/0001_initial.py 100.00% <ø> (ø)
server/audit/utils.py 20.00% <20.00%> (ø)
server/inventory_item/updater.py 78.31% <73.91%> (+3.31%) ⬆️
server/audit_template/views.py 97.61% <90.00%> (-2.39%) ⬇️
server/audit/migrations/0002_audit_template_id.py 100.00% <100.00%> (ø)
server/audit/models.py 100.00% <100.00%> (ø)
server/audit_template/models.py 100.00% <100.00%> (ø)
... and 6 more

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 589ea60...2c937ac. Read the comment docs.

@github-actions
Copy link

NG Lint Report

@github-actions
Copy link

NG Lint Report

@RobertBeaudenon RobertBeaudenon changed the title Old state 3 Issue #54 - User story 3.6 - Scheduling audits Jan 29, 2021
@github-actions
Copy link

Pylint Report

'+ ######ALL JOBS#######
'+ Jobstore default:
'+ No scheduled jobs
'+ #####################
'+ ************* Module audit.utils
'+ audit/utils.py:8:4: W0622: Redefining built-in 'dict' (redefined-builtin)
'+ audit/utils.py:25:0: R1721: Unnecessary use of a comprehension (unnecessary-comprehension)
'+ audit/utils.py:39:8: C0200: Consider using enumerate instead of iterating with range and len (consider-using-enumerate)
'+ audit/utils.py:40:44: W0212: Access to a protected member _id of a client class (protected-access)
'+ ************* Module audit_template.views
'+ audit_template/views.py:37:0: C0301: Line too long (111/100) (line-too-long)
'+ audit_template/views.py:48:0: C0301: Line too long (112/100) (line-too-long)
'+ audit_template/views.py:3:0: W0611: Unused itertools imported as it (unused-import)
'+ audit_template/views.py:4:0: W0611: Unused chain imported from itertools (unused-import)
'+ audit_template/views.py:14:0: W0611: Unused Item imported from inventory_item.models (unused-import)
'+ audit_template/views.py:15:0: W0611: Unused Audit imported from audit.models (unused-import)
'+ audit_template/views.py:3:0: C0411: standard import "import itertools as it" should be placed before "import numpy as np" (wrong-import-order)
'+ audit_template/views.py:4:0: C0411: standard import "from itertools import chain" should be placed before "import numpy as np" (wrong-import-order)
'+ audit_template/views.py:14:0: C0411: first party import "from inventory_item.models import Item" should be placed before "from .permissions import IsInventoryManagerTemplate" (wrong-import-order)
'+ audit_template/views.py:15:0: C0411: first party import "from audit.models import Audit" should be placed before "from .permissions import IsInventoryManagerTemplate" (wrong-import-order)
'+ audit_template/views.py:16:0: C0411: first party import "from inventory_item.updater import start_new_cron_job, start_new_job_once_at_specific_date" should be placed before "from .permissions import IsInventoryManagerTemplate" (wrong-import-order)
'+ audit_template/views.py:16:0: C0412: Imports from package inventory_item are not grouped (ungrouped-imports)
'+ ************* Module inventory_item.models
'+ inventory_item/models.py:21:0: C0301: Line too long (117/100) (line-too-long)
'+ inventory_item/updater.py:98:0: C0301: Line too long (102/100) (line-too-long)
'- inventory_item/updater.py:43:4: R0201: Method could be a function (no-self-use)
'? ^
'+ inventory_item/updater.py:47:4: R0201: Method could be a function (no-self-use)
'? ^
'- inventory_item/updater.py:20:0: R0903: Too few public methods (1/2) (too-few-public-methods)
'? ^
'+ inventory_item/updater.py:24:0: R0903: Too few public methods (1/2) (too-few-public-methods)
'? ^
'+ inventory_item/updater.py:133:8: C0103: Variable name "m" doesn't conform to snake_case naming style (invalid-name)
'- -----------------------------------
'- Your code has been rated at 9.91/10+ ------------------------------------------------------------------
'+ Your code has been rated at 9.68/10 (previous run: 9.91/10, -0.24)

@github-actions
Copy link

NG Lint Report

@github-actions
Copy link

Pylint Report

'+ ######ALL JOBS#######
'+ Jobstore default:
'+ No scheduled jobs
'+ #####################
'+ ************* Module audit.utils
'+ audit/utils.py:8:4: W0622: Redefining built-in 'dict' (redefined-builtin)
'+ audit/utils.py:25:0: R1721: Unnecessary use of a comprehension (unnecessary-comprehension)
'+ audit/utils.py:39:8: C0200: Consider using enumerate instead of iterating with range and len (consider-using-enumerate)
'+ audit/utils.py:40:44: W0212: Access to a protected member _id of a client class (protected-access)
'+ ************* Module audit_template.views
'+ audit_template/views.py:37:0: C0301: Line too long (111/100) (line-too-long)
'+ audit_template/views.py:48:0: C0301: Line too long (112/100) (line-too-long)
'+ audit_template/views.py:3:0: W0611: Unused itertools imported as it (unused-import)
'+ audit_template/views.py:4:0: W0611: Unused chain imported from itertools (unused-import)
'+ audit_template/views.py:14:0: W0611: Unused Item imported from inventory_item.models (unused-import)
'+ audit_template/views.py:15:0: W0611: Unused Audit imported from audit.models (unused-import)
'+ audit_template/views.py:3:0: C0411: standard import "import itertools as it" should be placed before "import numpy as np" (wrong-import-order)
'+ audit_template/views.py:4:0: C0411: standard import "from itertools import chain" should be placed before "import numpy as np" (wrong-import-order)
'+ audit_template/views.py:14:0: C0411: first party import "from inventory_item.models import Item" should be placed before "from .permissions import IsInventoryManagerTemplate" (wrong-import-order)
'+ audit_template/views.py:15:0: C0411: first party import "from audit.models import Audit" should be placed before "from .permissions import IsInventoryManagerTemplate" (wrong-import-order)
'+ audit_template/views.py:16:0: C0411: first party import "from inventory_item.updater import start_new_cron_job, start_new_job_once_at_specific_date" should be placed before "from .permissions import IsInventoryManagerTemplate" (wrong-import-order)
'+ audit_template/views.py:16:0: C0412: Imports from package inventory_item are not grouped (ungrouped-imports)
'+ ************* Module inventory_item.models
'+ inventory_item/models.py:21:0: C0301: Line too long (117/100) (line-too-long)
'+ inventory_item/updater.py:98:0: C0301: Line too long (102/100) (line-too-long)
'- inventory_item/updater.py:43:4: R0201: Method could be a function (no-self-use)
'? ^
'+ inventory_item/updater.py:47:4: R0201: Method could be a function (no-self-use)
'? ^
'- inventory_item/updater.py:20:0: R0903: Too few public methods (1/2) (too-few-public-methods)
'? ^
'+ inventory_item/updater.py:24:0: R0903: Too few public methods (1/2) (too-few-public-methods)
'? ^
'+ inventory_item/updater.py:133:8: C0103: Variable name "m" doesn't conform to snake_case naming style (invalid-name)
'- -----------------------------------
'- Your code has been rated at 9.91/10+ ------------------------------------------------------------------
'+ Your code has been rated at 9.68/10 (previous run: 9.91/10, -0.24)

@github-actions
Copy link

NG Lint Report

@github-actions
Copy link

Pylint Report

'+ ######ALL JOBS#######
'+ Jobstore default:
'+ No scheduled jobs
'+ #####################
'+ ************* Module audit.utils
'+ audit/utils.py:8:4: W0622: Redefining built-in 'dict' (redefined-builtin)
'+ audit/utils.py:25:0: R1721: Unnecessary use of a comprehension (unnecessary-comprehension)
'+ audit/utils.py:39:8: C0200: Consider using enumerate instead of iterating with range and len (consider-using-enumerate)
'+ audit/utils.py:40:44: W0212: Access to a protected member _id of a client class (protected-access)
'+ ************* Module audit_template.views
'+ audit_template/views.py:37:0: C0301: Line too long (111/100) (line-too-long)
'+ audit_template/views.py:48:0: C0301: Line too long (112/100) (line-too-long)
'+ audit_template/views.py:3:0: W0611: Unused itertools imported as it (unused-import)
'+ audit_template/views.py:4:0: W0611: Unused chain imported from itertools (unused-import)
'+ audit_template/views.py:14:0: W0611: Unused Item imported from inventory_item.models (unused-import)
'+ audit_template/views.py:15:0: W0611: Unused Audit imported from audit.models (unused-import)
'+ audit_template/views.py:3:0: C0411: standard import "import itertools as it" should be placed before "import numpy as np" (wrong-import-order)
'+ audit_template/views.py:4:0: C0411: standard import "from itertools import chain" should be placed before "import numpy as np" (wrong-import-order)
'+ audit_template/views.py:14:0: C0411: first party import "from inventory_item.models import Item" should be placed before "from .permissions import IsInventoryManagerTemplate" (wrong-import-order)
'+ audit_template/views.py:15:0: C0411: first party import "from audit.models import Audit" should be placed before "from .permissions import IsInventoryManagerTemplate" (wrong-import-order)
'+ audit_template/views.py:16:0: C0411: first party import "from inventory_item.updater import start_new_cron_job, start_new_job_once_at_specific_date" should be placed before "from .permissions import IsInventoryManagerTemplate" (wrong-import-order)
'+ audit_template/views.py:16:0: C0412: Imports from package inventory_item are not grouped (ungrouped-imports)
'+ ************* Module inventory_item.models
'+ inventory_item/models.py:21:0: C0301: Line too long (117/100) (line-too-long)
'+ inventory_item/updater.py:98:0: C0301: Line too long (102/100) (line-too-long)
'- inventory_item/updater.py:43:4: R0201: Method could be a function (no-self-use)
'? ^
'+ inventory_item/updater.py:47:4: R0201: Method could be a function (no-self-use)
'? ^
'- inventory_item/updater.py:20:0: R0903: Too few public methods (1/2) (too-few-public-methods)
'? ^
'+ inventory_item/updater.py:24:0: R0903: Too few public methods (1/2) (too-few-public-methods)
'? ^
'+ inventory_item/updater.py:133:8: C0103: Variable name "m" doesn't conform to snake_case naming style (invalid-name)
'- -----------------------------------
'- Your code has been rated at 9.91/10+ ------------------------------------------------------------------
'+ Your code has been rated at 9.68/10 (previous run: 9.91/10, -0.24)

@github-actions
Copy link

NG Lint Report

Copy link
Member

@NicholasNagy NicholasNagy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Everything looks good in general, please have a look at my comments

Comment on lines 78 to 93
::ng-deep .mat-checkbox-checked.mat-accent .mat-checkbox-ripple .mat-ripple-element {
opacity: 0.03 !important;
background-color: map-get($alta-primary, A100);
}

::ng-deep .mat-checkbox-checked.mat-accent .mat-checkbox-background, .mat-checkbox-indeterminate.mat-accent .mat-checkbox-background {
background-color: map-get($alta-primary, A100);
}

.button-padding {
margin: 5px;
}

::ng-deep .mat-checkbox-label {
padding-top: 5px;
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we not use ng-deep here.
Last time we tried to use this, it ended up modifying the scss for the entire material library and it ended up messing up other components

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I also tend to avoid it but unfortunately for checkbox specifically, I have no choice but to use ng-deep in order to force the style down to the child as it won't overwrite the CSS.

Comment on lines 158 to 170
updateAllCheckbox(type: string): void {
if (type === 'dayCheckbox') {
this.allDaysChecked =
this.recurrenceDay.subCheckBox != null &&
this.recurrenceDay.subCheckBox.every((t) => t.checked);
this.errorMessageCheckboxDay = ' ';
} else if (type === 'monthCheckbox') {
this.allMonthsChecked =
this.recurrenceMonth.subCheckBox != null &&
this.recurrenceMonth.subCheckBox.every((t) => t.checked);
this.errorMessageCheckboxMonth = ' ';
}
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't check to see if this would work, with the HTML, but I was wondering, could you split this into 2 functions and avoid having to pass in a string?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

updateAllCheckbox has now been split into two function named: updateCheckboxDay and updateCheckboxMonth.

Comment on lines 173 to 191
someCheckbox(type: string): boolean {
if (type === 'dayCheckbox') {
if (this.recurrenceDay.subCheckBox == null) {
return false;
}
return (
this.recurrenceDay.subCheckBox.filter((t) => t.checked).length > 0 &&
!this.allDaysChecked
);
} else if (type === 'monthCheckbox') {
if (this.recurrenceMonth.subCheckBox == null) {
return false;
}
return (
this.recurrenceMonth.subCheckBox.filter((t) => t.checked).length > 0 &&
!this.allMonthsChecked
);
}
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same applies here, I'm not sure if this would fit with the HTML, but if yes, moving this into 2 functions would make more sense to avoid having to check.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

someCheckbox has now been split into two function named: someCheckboxDay and someCheckboxMonth.

Comment on lines 193 to 208
setAllCheckbox(checked: boolean, type: string): void {
if (type === 'dayCheckbox') {
this.allDaysChecked = checked;
if (this.recurrenceDay.subCheckBox == null) {
return;
}
this.recurrenceDay.subCheckBox.forEach((t) => (t.checked = checked));
} else if (type === 'monthCheckbox') {
this.allMonthsChecked = checked;
if (this.recurrenceMonth.subCheckBox == null) {
return;
}
this.recurrenceMonth.subCheckBox.forEach((t) => (t.checked = checked));
}
}

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same concept as previous 2 comments

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

setAllCheckbox has now been split into two function named: setAllCheckboxDay and setAllCheckboxMonth.

Comment on lines 43 to 50
const year = this.startDate.getFullYear();
const month = ((this.startDate.getMonth() + 1).toString().length === 1) ?
('0' + (this.startDate.getMonth() + 1)) : ((this.startDate.getMonth() + 1));
const day = (this.startDate.getDate().toString().length === 1) ? ('0' + (this.startDate.getDate())) : (this.startDate.getDate());
const hour = (parseInt(this.startTime.split(':')[0], 10).toString().length === 1) ?
('0' + (parseInt(this.startTime.split(':')[0], 10))) : (parseInt(this.startTime.split(':')[0], 10));
const minute = (parseInt(this.startTime.split(':')[1], 10).toString().length === 1) ?
('0' + (parseInt(this.startTime.split(':')[1], 10))) : (parseInt(this.startTime.split(':')[1], 10));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This gives me a headache to look at and try to understand. Can we take each of these statements and inline them with a function instead? This would make them much more readable if the function names are properly defined.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This has been fixed

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see what you did, but I would prefer each of these assignments were done with their own function instead of dumping the functionality into an already long function.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops, I see what you meant! Sorry I misunderstood earlier. This has been fixed now 😄

});
});
}

formTemplate(temp: { [s: string]: unknown; } | ArrayLike<unknown>): any {
const createdTemplate: any = {};
Object.entries(temp).forEach(([key, value]) => {
console.log(key);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please remove this

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This has been removed.

@github-actions
Copy link

Pylint Report

'+ ######ALL JOBS#######
'+ Jobstore default:
'+ No scheduled jobs
'+ #####################
'+ ************* Module audit.utils
'+ audit/utils.py:8:4: W0622: Redefining built-in 'dict' (redefined-builtin)
'+ audit/utils.py:25:0: R1721: Unnecessary use of a comprehension (unnecessary-comprehension)
'+ audit/utils.py:39:8: C0200: Consider using enumerate instead of iterating with range and len (consider-using-enumerate)
'+ audit/utils.py:40:44: W0212: Access to a protected member _id of a client class (protected-access)
'+ ************* Module audit_template.views
'+ audit_template/views.py:37:0: C0301: Line too long (111/100) (line-too-long)
'+ audit_template/views.py:48:0: C0301: Line too long (112/100) (line-too-long)
'+ audit_template/views.py:3:0: W0611: Unused itertools imported as it (unused-import)
'+ audit_template/views.py:4:0: W0611: Unused chain imported from itertools (unused-import)
'+ audit_template/views.py:14:0: W0611: Unused Item imported from inventory_item.models (unused-import)
'+ audit_template/views.py:15:0: W0611: Unused Audit imported from audit.models (unused-import)
'+ audit_template/views.py:3:0: C0411: standard import "import itertools as it" should be placed before "import numpy as np" (wrong-import-order)
'+ audit_template/views.py:4:0: C0411: standard import "from itertools import chain" should be placed before "import numpy as np" (wrong-import-order)
'+ audit_template/views.py:14:0: C0411: first party import "from inventory_item.models import Item" should be placed before "from .permissions import IsInventoryManagerTemplate" (wrong-import-order)
'+ audit_template/views.py:15:0: C0411: first party import "from audit.models import Audit" should be placed before "from .permissions import IsInventoryManagerTemplate" (wrong-import-order)
'+ audit_template/views.py:16:0: C0411: first party import "from inventory_item.updater import start_new_cron_job, start_new_job_once_at_specific_date" should be placed before "from .permissions import IsInventoryManagerTemplate" (wrong-import-order)
'+ audit_template/views.py:16:0: C0412: Imports from package inventory_item are not grouped (ungrouped-imports)
'+ ************* Module inventory_item.models
'+ inventory_item/models.py:21:0: C0301: Line too long (117/100) (line-too-long)
'+ inventory_item/updater.py:98:0: C0301: Line too long (102/100) (line-too-long)
'- inventory_item/updater.py:43:4: R0201: Method could be a function (no-self-use)
'? ^
'+ inventory_item/updater.py:47:4: R0201: Method could be a function (no-self-use)
'? ^
'- inventory_item/updater.py:20:0: R0903: Too few public methods (1/2) (too-few-public-methods)
'? ^
'+ inventory_item/updater.py:24:0: R0903: Too few public methods (1/2) (too-few-public-methods)
'? ^
'+ inventory_item/updater.py:133:8: C0103: Variable name "m" doesn't conform to snake_case naming style (invalid-name)
'- -----------------------------------
'- Your code has been rated at 9.91/10+ ------------------------------------------------------------------
'+ Your code has been rated at 9.68/10 (previous run: 9.91/10, -0.24)

@github-actions
Copy link

NG Lint Report

Comment on lines 29 to 42
for query in queries:
for category, value in zip(sorted_keys, query):
kwargs[category] = value

# Fetching the inventory items corresponding to the criteria selected
# for all combinations
inventory_items = Item.objects.filter(**kwargs)

# Appending the element of the Queryset object to the list
# (Didn't find a way to cast it to a list)
for i in range(len(inventory_items)):
inventory_items_to_audit.append(inventory_items[i]._id)

return inventory_items_to_audit
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add a TODO here to look further into a more efficient solution?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done 👍

@github-actions
Copy link

Pylint Report

'+ ######ALL JOBS#######
'+ Jobstore default:
'+ No scheduled jobs
'+ #####################
'+ ************* Module audit.utils
'+ audit/utils.py:8:4: W0622: Redefining built-in 'dict' (redefined-builtin)
'+ audit/utils.py:25:0: R1721: Unnecessary use of a comprehension (unnecessary-comprehension)
'+ audit/utils.py:39:8: C0200: Consider using enumerate instead of iterating with range and len (consider-using-enumerate)
'+ audit/utils.py:40:44: W0212: Access to a protected member _id of a client class (protected-access)
'- inventory_item/updater.py:43:4: R0201: Method could be a function (no-self-use)
'? ^
'+ inventory_item/updater.py:47:4: R0201: Method could be a function (no-self-use)
'? ^
'- inventory_item/updater.py:20:0: R0903: Too few public methods (1/2) (too-few-public-methods)
'? ^
'+ inventory_item/updater.py:24:0: R0903: Too few public methods (1/2) (too-few-public-methods)
'? ^
'+ inventory_item/updater.py:133:8: C0103: Variable name "m" doesn't conform to snake_case naming style (invalid-name)
'- -----------------------------------
'- Your code has been rated at 9.92/10+ ------------------------------------------------------------------
'+ Your code has been rated at 9.86/10 (previous run: 9.92/10, -0.05)

@github-actions
Copy link

NG Lint Report

@github-actions
Copy link

Pylint Report

'+ ######ALL JOBS#######
'+ Jobstore default:
'+ No scheduled jobs
'+ #####################
'+ ************* Module audit.utils
'+ audit/utils.py:29:2: W0511: TODO To be further looked into for a more efficient solution (fixme)
'+ audit/utils.py:8:4: W0622: Redefining built-in 'dict' (redefined-builtin)
'+ audit/utils.py:25:0: R1721: Unnecessary use of a comprehension (unnecessary-comprehension)
'+ audit/utils.py:40:8: C0200: Consider using enumerate instead of iterating with range and len (consider-using-enumerate)
'+ audit/utils.py:41:44: W0212: Access to a protected member _id of a client class (protected-access)
'- inventory_item/updater.py:43:4: R0201: Method could be a function (no-self-use)
'? ^
'+ inventory_item/updater.py:47:4: R0201: Method could be a function (no-self-use)
'? ^
'- inventory_item/updater.py:20:0: R0903: Too few public methods (1/2) (too-few-public-methods)
'? ^
'+ inventory_item/updater.py:24:0: R0903: Too few public methods (1/2) (too-few-public-methods)
'? ^
'+ inventory_item/updater.py:133:8: C0103: Variable name "m" doesn't conform to snake_case naming style (invalid-name)
'- -----------------------------------
'- Your code has been rated at 9.92/10+ ------------------------------------------------------------------
'+ Your code has been rated at 9.85/10 (previous run: 9.92/10, -0.07)

@github-actions
Copy link

NG Lint Report

@github-actions
Copy link

Pylint Report

'+ ######ALL JOBS#######
'+ Jobstore default:
'+ No scheduled jobs
'+ #####################
'+ ************* Module audit.utils
'+ audit/utils.py:29:2: W0511: TODO To be further looked into for a more efficient solution (fixme)
'- inventory_item/updater.py:43:4: R0201: Method could be a function (no-self-use)
'- inventory_item/updater.py:20:0: R0903: Too few public methods (1/2) (too-few-public-methods)
'? ^^ ^
'+ inventory_item/updater.py:39:0: R0903: Too few public methods (0/2) (too-few-public-methods)
'? ^^ ^
'- -----------------------------------
'- Your code has been rated at 9.92/10+ ------------------------------------------------------------------
'+ Your code has been rated at 9.92/10 (previous run: 9.92/10, +0.01)

@github-actions
Copy link

NG Lint Report

@sonarcloud
Copy link

sonarcloud bot commented Jan 31, 2021

Kudos, SonarCloud Quality Gate passed!

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

No Coverage information No Coverage information
0.0% 0.0% Duplication

Copy link
Member

@NicholasNagy NicholasNagy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Everything looks good now, thank you for the changes!

@NicholasNagy NicholasNagy merged commit 616f379 into master Jan 31, 2021
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.

5 participants