hackedteam/vector-edk

View on GitHub

Showing 9,525 of 13,510 total issues

File uisample.py has 1361 lines of code (exceeds 250 allowed). Consider refactoring.
Open

import msilib,os;dirname=os.path.dirname(__file__)
AdminExecuteSequence = [
(u'InstallValidate', None, 1400),
(u'InstallInitialize', None, 1500),
(u'InstallFinalize', None, 6600),
Severity: Major
Found in AppPkg/Applications/Python/Python-2.7.2/Tools/msi/uisample.py - About 3 days to fix

    File MetaFileParser.py has 1354 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    ## @file
    # This file is used to parse meta files
    #
    # Copyright (c) 2008 - 2012, Intel Corporation. All rights reserved.<BR>
    # This program and the accompanying materials
    Severity: Major
    Found in BaseTools/Source/Python/Workspace/MetaFileParser.py - About 3 days to fix

      File urllib.py has 1347 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      """Open an arbitrary URL.
      
      See the following document for more info on URLs:
      "Names and Addresses, URIs, URLs, URNs, URCs", at
      http://www.w3.org/pub/WWW/Addressing/Overview.html
      Severity: Major
      Found in AppPkg/Applications/Python/Python-2.7.2/Lib/urllib.py - About 3 days to fix

        File urllib.py has 1347 lines of code (exceeds 250 allowed). Consider refactoring.
        Open

        """Open an arbitrary URL.
        
        See the following document for more info on URLs:
        "Names and Addresses, URIs, URLs, URNs, URCs", at
        http://www.w3.org/pub/WWW/Addressing/Overview.html
        Severity: Major
        Found in vector-uefi/fd/efi/StdLib/lib/python.27/urllib.py - About 3 days to fix

          File __init__.py has 1330 lines of code (exceeds 250 allowed). Consider refactoring.
          Open

          # Copyright 2001-2010 by Vinay Sajip. All Rights Reserved.
          #
          # Permission to use, copy, modify, and distribute this software and its
          # documentation for any purpose and without fee is hereby granted,
          # provided that the above copyright notice appear in all copies and that
          Severity: Major
          Found in AppPkg/Applications/Python/Python-2.7.2/Lib/logging/__init__.py - About 3 days to fix

            File __init__.py has 1330 lines of code (exceeds 250 allowed). Consider refactoring.
            Open

            # Copyright 2001-2010 by Vinay Sajip. All Rights Reserved.
            #
            # Permission to use, copy, modify, and distribute this software and its
            # documentation for any purpose and without fee is hereby granted,
            # provided that the above copyright notice appear in all copies and that
            Severity: Major
            Found in vector-uefi/fd/efi/StdLib/lib/python.27/logging/__init__.py - About 3 days to fix

              File MetaFileParser.py has 1319 lines of code (exceeds 250 allowed). Consider refactoring.
              Open

              ## @file
              # This file is used to parse meta files
              #
              # Copyright (c) 2008 - 2010, Intel Corporation. All rights reserved.<BR>
              # This program and the accompanying materials
              Severity: Major
              Found in BaseTools/Source/Python/Ecc/MetaFileWorkspace/MetaFileParser.py - About 3 days to fix

                Function _ExpandBuildOption has a Cognitive Complexity of 169 (exceeds 5 allowed). Consider refactoring.
                Open

                    def _ExpandBuildOption(self, Options, ModuleStyle=None):
                        BuildOptions = {}
                        FamilyMatch  = False
                        FamilyIsNull = True
                                
                Severity: Minor
                Found in BaseTools/Source/Python/AutoGen/AutoGen.py - About 3 days 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

                File LzmaEncoder.cs has 1313 lines of code (exceeds 250 allowed). Consider refactoring.
                Open

                using System;
                
                namespace SevenZip.Compression.LZMA
                {
                    using RangeCoder;
                Severity: Major
                Found in vector-uefi/insyde/7zip/CS/7zip/Compress/LZMA/LzmaEncoder.cs - About 3 days to fix

                  Function _parsegen has a Cognitive Complexity of 167 (exceeds 5 allowed). Consider refactoring.
                  Open

                      def _parsegen(self):
                          # Create a new message and start by parsing headers.
                          self._new_message()
                          headers = []
                          # Collect the headers, searching for a line that doesn't match the RFC
                  Severity: Minor
                  Found in AppPkg/Applications/Python/Python-2.7.2/Lib/email/feedparser.py - About 3 days 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

                  Function _parsegen has a Cognitive Complexity of 167 (exceeds 5 allowed). Consider refactoring.
                  Open

                      def _parsegen(self):
                          # Create a new message and start by parsing headers.
                          self._new_message()
                          headers = []
                          # Collect the headers, searching for a line that doesn't match the RFC
                  Severity: Minor
                  Found in vector-uefi/fd/efi/StdLib/lib/python.27/email/feedparser.py - About 3 days 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

                  Function external_declaration has a Cognitive Complexity of 166 (exceeds 5 allowed). Consider refactoring.
                  Open

                      def external_declaration(self, ):
                  
                          external_declaration_StartIndex = self.input.index()
                          try:
                              try:
                  Severity: Minor
                  Found in BaseTools/Source/Python/Ecc/CParser.py - About 3 days 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

                  Function external_declaration has a Cognitive Complexity of 166 (exceeds 5 allowed). Consider refactoring.
                  Open

                      def external_declaration(self, ):
                  
                          external_declaration_StartIndex = self.input.index()
                          try:
                              try:
                  Severity: Minor
                  Found in BaseTools/Source/Python/Eot/CParser.py - About 3 days 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

                  CParser has 170 functions (exceeds 20 allowed). Consider refactoring.
                  Open

                  class CParser(Parser):
                      grammarFileName = "C.g"
                      tokenNames = tokenNames
                  
                      def __init__(self, input):
                  Severity: Major
                  Found in BaseTools/Source/Python/Ecc/CParser.py - About 3 days to fix

                    CParser has 170 functions (exceeds 20 allowed). Consider refactoring.
                    Open

                    class CParser(Parser):
                        grammarFileName = "C.g"
                        tokenNames = tokenNames
                    
                        def __init__(self, input):
                    Severity: Major
                    Found in BaseTools/Source/Python/Eot/CParser.py - About 3 days to fix

                      Function goahead has a Cognitive Complexity of 163 (exceeds 5 allowed). Consider refactoring.
                      Open

                          def goahead(self, end):
                              rawdata = self.rawdata
                              i = 0
                              n = len(rawdata)
                              while i < n:
                      Severity: Minor
                      Found in AppPkg/Applications/Python/Python-2.7.2/Lib/xmllib.py - About 3 days 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

                      Function goahead has a Cognitive Complexity of 163 (exceeds 5 allowed). Consider refactoring.
                      Open

                          def goahead(self, end):
                              rawdata = self.rawdata
                              i = 0
                              n = len(rawdata)
                              while i < n:
                      Severity: Minor
                      Found in vector-uefi/fd/efi/StdLib/lib/python.27/xmllib.py - About 3 days 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

                      File pycodegen.py has 1265 lines of code (exceeds 250 allowed). Consider refactoring.
                      Open

                      import imp
                      import os
                      import marshal
                      import struct
                      import sys
                      Severity: Major
                      Found in AppPkg/Applications/Python/Python-2.7.2/Lib/compiler/pycodegen.py - About 3 days to fix

                        File pycodegen.py has 1265 lines of code (exceeds 250 allowed). Consider refactoring.
                        Open

                        import imp
                        import os
                        import marshal
                        import struct
                        import sys
                        Severity: Major
                        Found in vector-uefi/fd/efi/StdLib/lib/python.27/compiler/pycodegen.py - About 3 days to fix

                          File optparse.py has 1256 lines of code (exceeds 250 allowed). Consider refactoring.
                          Open

                          """A powerful, extensible, and easy-to-use option parser.
                          
                          By Greg Ward <gward@python.net>
                          
                          Originally distributed as Optik.
                          Severity: Major
                          Found in AppPkg/Applications/Python/Python-2.7.2/Lib/optparse.py - About 3 days to fix
                            Severity
                            Category
                            Status
                            Source
                            Language