hackedteam/vector-edk

View on GitHub

Showing 9,525 of 13,510 total issues

Avoid deeply nested control flow statements.
Open

                    if m:  # unquoted value
                        text = unmatched(m)
                        value = m.group(1)
                        value = value.rstrip()
                    else:
Severity: Major
Found in vector-uefi/fd/efi/StdLib/lib/python.27/cookielib.py - About 45 mins to fix

    Avoid deeply nested control flow statements.
    Open

                        if this in (None, "\n"):
                            break
                    continue
    Severity: Major
    Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix

      Avoid deeply nested control flow statements.
      Open

                          if not source.next in FLAGS:
                              raise error, "unexpected end of pattern"
                          while source.next in FLAGS:
      Severity: Major
      Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix

        Function __init__ has 6 arguments (exceeds 4 allowed). Consider refactoring.
        Open

            def __init__(self, message, category, filename, lineno, file=None,
        Severity: Minor
        Found in vector-uefi/fd/efi/StdLib/lib/python.27/warnings.py - About 45 mins to fix

          Avoid deeply nested control flow statements.
          Open

                              while 1:
                                  if source.next is None or source.next == ")":
                                      break
                                  sourceget()
                              if not sourcematch(")"):
          Severity: Major
          Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix

            Avoid deeply nested control flow statements.
            Open

                                if isname(condname):
                                    condgroup = state.groupdict.get(condname)
                                    if condgroup is None:
                                        raise error, "unknown group name"
                                else:
            Severity: Major
            Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix

              Avoid deeply nested control flow statements.
              Open

                                  while source.next in FLAGS:
                                      state.flags = state.flags | FLAGS[sourceget()]
                          if group:
              Severity: Major
              Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix

                Avoid deeply nested control flow statements.
                Open

                                    if char == ")":
                                        break
                                    raise error, "unknown extension"
                Severity: Major
                Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix

                  Function filterwarnings has 6 arguments (exceeds 4 allowed). Consider refactoring.
                  Open

                  def filterwarnings(action, message="", category=Warning, module="", lineno=0,
                  Severity: Minor
                  Found in vector-uefi/fd/efi/StdLib/lib/python.27/warnings.py - About 45 mins to fix

                    Function py_encode_basestring_ascii has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                    Open

                    def py_encode_basestring_ascii(s):
                        """Return an ASCII-only JSON representation of a Python string
                    
                        """
                        if isinstance(s, str) and HAS_UTF8.search(s) is not None:
                    Severity: Minor
                    Found in vector-uefi/fd/efi/StdLib/lib/python.27/json/encoder.py - About 45 mins to fix

                    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

                    Avoid deeply nested control flow statements.
                    Open

                                        if char == "<":
                                            if source.next not in LOOKBEHINDASSERTCHARS:
                                                raise error, "syntax error"
                                            dir = -1 # lookbehind
                                            char = sourceget()
                    Severity: Major
                    Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix

                      Avoid deeply nested control flow statements.
                      Open

                                          if code1[0] is IN:
                                              code1 = code1[1][0]
                                          setappend(code1)
                      Severity: Major
                      Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix

                        Avoid deeply nested control flow statements.
                        Open

                                            while source.next in DIGITS:
                                                hi = hi + sourceget()
                                        else:
                        Severity: Major
                        Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix

                          Avoid deeply nested control flow statements.
                          Open

                                              if not sourcematch(")"):
                                                  raise error, "unbalanced parenthesis"
                                              if char == "=":
                          Severity: Major
                          Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix

                            Avoid deeply nested control flow statements.
                            Open

                                                while 1:
                                                    char = sourceget()
                                                    if char is None:
                                                        raise error, "unterminated name"
                                                    if char == ")":
                            Severity: Major
                            Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix

                              Function _show_warning has 6 arguments (exceeds 4 allowed). Consider refactoring.
                              Open

                              def _show_warning(message, category, filename, lineno, file=None, line=None):
                              Severity: Minor
                              Found in vector-uefi/fd/efi/StdLib/lib/python.27/warnings.py - About 45 mins to fix

                                Avoid deeply nested control flow statements.
                                Open

                                                        if not nl: print
                                                        a.dump(level+1); nl = 1
                                Severity: Major
                                Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix

                                  Avoid deeply nested control flow statements.
                                  Open

                                                      if not sourcematch(")"):
                                                          raise error, "unbalanced parenthesis"
                                                      continue
                                  Severity: Major
                                  Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix

                                    Avoid deeply nested control flow statements.
                                    Open

                                                        if char is None:
                                                            raise error, "unexpected end of pattern"
                                                        if char == ")":
                                    Severity: Major
                                    Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix

                                      Avoid deeply nested control flow statements.
                                      Open

                                                          while 1:
                                                              char = sget()
                                                              if char is None:
                                                                  raise error, "unterminated group name"
                                                              if char == ">":
                                      Severity: Major
                                      Found in vector-uefi/fd/efi/StdLib/lib/python.27/sre_parse.py - About 45 mins to fix
                                        Severity
                                        Category
                                        Status
                                        Source
                                        Language