Showing 2,859 of 2,859 total issues

Consider simplifying this complex logical expression.
Open

    if type == Type.START_BLOCK:
      self._block_depth += 1

      # Subclasses need to handle block start very differently because
      # whether a block is a CODE or OBJECT_LITERAL block varies significantly
Severity: Major
Found in tools/closure_linter/closure_linter/statetracker.py - About 1 hr to fix

    Consider simplifying this complex logical expression.
    Open

          if (self._last_code.type in (TokenType.END_PAREN,
                                       TokenType.END_PARAMETERS) or
              self._last_code.IsKeyword('else') or
              self._last_code.IsKeyword('do') or
              self._last_code.IsKeyword('try') or
    Severity: Major
    Found in tools/closure_linter/closure_linter/ecmametadatapass.py - About 1 hr to fix

      Function WriteSourcesForArch has 8 arguments (exceeds 4 allowed). Consider refactoring.
      Open

        def WriteSourcesForArch(self, ninja_file, config_name, config, sources,
      Severity: Major
      Found in tools/gyp/pylib/gyp/generator/ninja.py - About 1 hr to fix

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

          def __init__(self, path, name = None, dependencies = None, guid = None,
        Severity: Major
        Found in tools/gyp/pylib/gyp/MSVSNew.py - About 1 hr to fix

          Function _AddMSBuildAction has 8 arguments (exceeds 4 allowed). Consider refactoring.
          Open

          def _AddMSBuildAction(spec, primary_input, inputs, outputs, cmd, description,
          Severity: Major
          Found in tools/gyp/pylib/gyp/generator/msvs.py - About 1 hr to fix

            Function LoadTargetBuildFilesParallel has 8 arguments (exceeds 4 allowed). Consider refactoring.
            Open

            def LoadTargetBuildFilesParallel(build_files, data, aux_data,
            Severity: Major
            Found in tools/gyp/pylib/gyp/input.py - About 1 hr to fix

              Function LoadTargetBuildFile has 8 arguments (exceeds 4 allowed). Consider refactoring.
              Open

              def LoadTargetBuildFile(build_file_path, data, aux_data, variables, includes,
              Severity: Major
              Found in tools/gyp/pylib/gyp/input.py - About 1 hr to fix

                Function GetLdflags has 8 arguments (exceeds 4 allowed). Consider refactoring.
                Open

                  def GetLdflags(self, config, gyp_to_build_path, expand_special,
                Severity: Major
                Found in tools/gyp/pylib/gyp/msvs_emulation.py - About 1 hr to fix

                  Consider simplifying this complex logical expression.
                  Open

                    if (cleansed_line.count(';') > 1 and
                        # for loops are allowed two ;'s (and may run over two lines).
                        cleansed_line.find('for') == -1 and
                        (GetPreviousNonBlankLine(clean_lines, linenum)[0].find('for') == -1 or
                         GetPreviousNonBlankLine(clean_lines, linenum)[0].find(';') != -1) and
                  Severity: Major
                  Found in tools/cpplint.py - About 1 hr to fix

                    Function Load has 8 arguments (exceeds 4 allowed). Consider refactoring.
                    Open

                    def Load(build_files, format, default_variables={},
                    Severity: Major
                    Found in tools/gyp/pylib/gyp/__init__.py - About 1 hr to fix

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

                        def __init__(self, workspace, buildspace, verbose, vm, timeout, processor, suppress_dialogs, store_unexpected_output):
                      Severity: Major
                      Found in tools/test.py - About 1 hr to fix

                        Function ProcessLine has 8 arguments (exceeds 4 allowed). Consider refactoring.
                        Open

                        def ProcessLine(filename, file_extension,
                        Severity: Major
                        Found in tools/cpplint.py - About 1 hr to fix

                          Similar blocks of code found in 3 locations. Consider refactoring.
                          Open

                            this.stderr = stdio.length >= 3 && !util.isUndefined(stdio[2].socket) ?
                                stdio[2].socket : null;
                          Severity: Major
                          Found in lib/child_process.js and 2 other locations - About 1 hr to fix
                          lib/child_process.js on lines 1191..1192
                          lib/child_process.js on lines 1193..1194

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 55.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Similar blocks of code found in 3 locations. Consider refactoring.
                          Open

                            this.stdin = stdio.length >= 1 && !util.isUndefined(stdio[0].socket) ?
                                stdio[0].socket : null;
                          Severity: Major
                          Found in lib/child_process.js and 2 other locations - About 1 hr to fix
                          lib/child_process.js on lines 1193..1194
                          lib/child_process.js on lines 1195..1196

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 55.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Similar blocks of code found in 3 locations. Consider refactoring.
                          Open

                          fs.fsync = function(fd, callback) {
                            var req = new FSReqWrap();
                            req.oncomplete = makeCallback(callback);
                            binding.fsync(fd, req);
                          };
                          Severity: Major
                          Found in lib/fs.js and 2 other locations - About 1 hr to fix
                          lib/fs.js on lines 720..724
                          lib/fs.js on lines 770..774

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 55.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Similar blocks of code found in 3 locations. Consider refactoring.
                          Open

                          fs.fdatasync = function(fd, callback) {
                            var req = new FSReqWrap();
                            req.oncomplete = makeCallback(callback);
                            binding.fdatasync(fd, req);
                          };
                          Severity: Major
                          Found in lib/fs.js and 2 other locations - About 1 hr to fix
                          lib/fs.js on lines 730..734
                          lib/fs.js on lines 770..774

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 55.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Similar blocks of code found in 3 locations. Consider refactoring.
                          Open

                            this.stdout = stdio.length >= 2 && !util.isUndefined(stdio[1].socket) ?
                                stdio[1].socket : null;
                          Severity: Major
                          Found in lib/child_process.js and 2 other locations - About 1 hr to fix
                          lib/child_process.js on lines 1191..1192
                          lib/child_process.js on lines 1195..1196

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 55.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Similar blocks of code found in 3 locations. Consider refactoring.
                          Open

                          fs.fstat = function(fd, callback) {
                            var req = new FSReqWrap();
                            req.oncomplete = makeCallback(callback);
                            binding.fstat(fd, req);
                          };
                          Severity: Major
                          Found in lib/fs.js and 2 other locations - About 1 hr to fix
                          lib/fs.js on lines 720..724
                          lib/fs.js on lines 730..734

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 55.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Similar blocks of code found in 2 locations. Consider refactoring.
                          Open

                              for (var i = 0; i < 40; i++) {
                                s57a[i].replace(re14, '');
                                s57a[i].replace(re15, '');
                              }
                          Severity: Major
                          Found in deps/v8/benchmarks/regexp.js and 1 other location - About 1 hr to fix
                          deps/v8/benchmarks/regexp.js on lines 414..417

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 55.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Similar blocks of code found in 2 locations. Consider refactoring.
                          Open

                              for (var i = 0; i < 23; i++) {
                                s68[i].replace(re27, '');
                                s69[i].replace(re27, '');
                              }
                          Severity: Major
                          Found in deps/v8/benchmarks/regexp.js and 1 other location - About 1 hr to fix
                          deps/v8/benchmarks/regexp.js on lines 317..320

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 55.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Severity
                          Category
                          Status
                          Source
                          Language