optional_plugins/varianter_pict/avocado_varianter_pict/varianter_pict.py
Function call with shell=True parameter identified, possible security issue. Open
Open
return process.run(cmd, shell=True).stdout_text
- Exclude checks
Use of insecure MD2, MD4, MD5, or SHA1 hash function. Open
Open
base_id + "-" + hashlib.sha1(base_id.encode()).hexdigest()[:4]
- Exclude checks
Function to_str
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
Open
def to_str(self, summary, variants, **kwargs):
"""
Return human readable representation
The summary/variants accepts verbosity where 0 means silent and
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function initialize
has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring. Open
Open
def initialize(self, config):
self.variants = None # pylint: disable=W0201
error = False
subcommand = config.get("subcommand", "run")
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"