Terralego/django-terra-utils

View on GitHub
terra_utils/management/commands/populatedata.py

Summary

Maintainability
A
25 mins
Test Coverage

Showing 2 of 2 total issues

Cyclomatic complexity is too high in method handle. (7)
Open

def handle(self, *args, **options):
self.test_mode = True if options.get('test_data') else False
 
if options.get('list', False):
self.stdout.write('Applications with populate modules:')

Function handle has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
Open

def handle(self, *args, **options):
self.test_mode = True if options.get('test_data') else False
 
if options.get('list', False):
self.stdout.write('Applications with populate modules:')
Severity: Minor
Found in terra_utils/management/commands/populatedata.py - About 25 mins to fix
Category
Status