code4game/libgltf

View on GitHub
tools/jsonschematoc11/jsonschematoc11.py

Summary

Maintainability
F
2 wks
Test Coverage

Function generate has a Cognitive Complexity of 125 (exceeds 5 allowed). Consider refactoring.
Open

    def generate(self, codeFileName, outputHeaderPath=None, outputSourcePath=None, nameSpace=None, config=None):
        header_file_path = u'%s.h.cmakein' % codeFileName
        source_file_path = u'%s.cpp' % codeFileName
        if outputHeaderPath is not None:
            header_file_path = os.path.join(outputHeaderPath, header_file_path)
Severity: Minor
Found in tools/jsonschematoc11/jsonschematoc11.py - About 2 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 jsonschematoc11.py has 550 lines of code (exceeds 250 allowed). Consider refactoring.
Open

import sys
import os
import argparse
from configparser import SafeConfigParser
import logging
Severity: Major
Found in tools/jsonschematoc11/jsonschematoc11.py - About 1 day to fix

    Function addSchema has a Cognitive Complexity of 19 (exceeds 5 allowed). Consider refactoring.
    Open

        def addSchema(self, rootPath, schemaFileName, config=None):
            schema_file_path = os.path.join(rootPath, schemaFileName)
            with open(schema_file_path, u'r') as schema_file:
                schema = json.load(schema_file)
                if schema is None:
    Severity: Minor
    Found in tools/jsonschematoc11/jsonschematoc11.py - About 2 hrs 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 JSONSchemaToC11 has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring.
    Open

    def JSONSchemaToC11(argv):
        parser = argparse.ArgumentParser(description=u'Generate c11 code by json schema.')
        parser.add_argument(u'configFile', metavar=u'config_file', type=open, help=u'The configuration file')
        args = parser.parse_args(argv)
    
    
    Severity: Minor
    Found in tools/jsonschematoc11/jsonschematoc11.py - About 1 hr 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 JSONSchemaToC11 has 31 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    def JSONSchemaToC11(argv):
        parser = argparse.ArgumentParser(description=u'Generate c11 code by json schema.')
        parser.add_argument(u'configFile', metavar=u'config_file', type=open, help=u'The configuration file')
        args = parser.parse_args(argv)
    
    
    Severity: Minor
    Found in tools/jsonschematoc11/jsonschematoc11.py - About 1 hr to fix

      Function addSchemaDirectory has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
      Open

          def addSchemaDirectory(self, schemaDirectory, config=None):
              schema_directory = os.path.normpath(schemaDirectory)
              if not os.path.isdir(schema_directory):
                  return (1, u'The schema directory (%s) is not a valid directory' % schema_directory)
      
      
      Severity: Minor
      Found in tools/jsonschematoc11/jsonschematoc11.py - About 1 hr 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

                              for code_header_extra_line in code_header_extra_lines:
                                  header_file.write(code_header_extra_line)
                              header_file.write(u'\n')
      Severity: Major
      Found in tools/jsonschematoc11/jsonschematoc11.py - About 45 mins to fix

        Avoid deeply nested control flow statements.
        Open

                                for code_file_line in code_file_lines:
                                    header_file.write(u' * ' + code_file_line)
                                header_file.write(u' */\n')
        Severity: Major
        Found in tools/jsonschematoc11/jsonschematoc11.py - About 45 mins to fix

          Avoid deeply nested control flow statements.
          Open

                                  for code_header_extra_line in code_header_extra_lines:
                                      header_file.write(code_header_extra_line)
                                  header_file.write(u'\n')
          Severity: Major
          Found in tools/jsonschematoc11/jsonschematoc11.py - About 45 mins to fix

            Avoid deeply nested control flow statements.
            Open

                                    for code_file_line in code_file_lines:
                                        header_file.write(u' * ' + code_file_line)
                                    header_file.write(u' */\n')
            Severity: Major
            Found in tools/jsonschematoc11/jsonschematoc11.py - About 45 mins to fix

              Avoid deeply nested control flow statements.
              Open

                                      for code_file_line in code_file_lines:
                                          source_file.write(u' * ' + code_file_line)
                                      source_file.write(u' */')
              Severity: Major
              Found in tools/jsonschematoc11/jsonschematoc11.py - About 45 mins to fix

                Avoid deeply nested control flow statements.
                Open

                                        for code_header_extra_line in code_header_extra_lines:
                                            header_file.write(code_header_extra_line)
                                        header_file.write(u'\n')
                Severity: Major
                Found in tools/jsonschematoc11/jsonschematoc11.py - About 45 mins to fix

                  Avoid deeply nested control flow statements.
                  Open

                                          for code_header_extra_line in code_header_extra_lines:
                                              header_file.write(code_header_extra_line)
                                          header_file.write(u'\n')
                  Severity: Major
                  Found in tools/jsonschematoc11/jsonschematoc11.py - About 45 mins to fix

                    Avoid deeply nested control flow statements.
                    Open

                                            for code_file_line in code_file_lines:
                                                source_file.write(u' * ' + code_file_line)
                                            source_file.write(u' */\n')
                    Severity: Major
                    Found in tools/jsonschematoc11/jsonschematoc11.py - About 45 mins to fix

                      Avoid deeply nested control flow statements.
                      Open

                                              for code_header_extra_line in code_header_extra_lines:
                                                  header_file.write(code_header_extra_line)
                                              header_file.write(u'\n')
                      Severity: Major
                      Found in tools/jsonschematoc11/jsonschematoc11.py - About 45 mins to fix

                        Avoid deeply nested control flow statements.
                        Open

                                                for code_header_extra_line in code_header_extra_lines:
                                                    header_file.write(code_header_extra_line)
                                                header_file.write(u'\n')
                        Severity: Major
                        Found in tools/jsonschematoc11/jsonschematoc11.py - About 45 mins to fix

                          Function generate has 5 arguments (exceeds 4 allowed). Consider refactoring.
                          Open

                              def generate(self, codeFileName, outputHeaderPath=None, outputSourcePath=None, nameSpace=None, config=None):
                          Severity: Minor
                          Found in tools/jsonschematoc11/jsonschematoc11.py - About 35 mins to fix

                            Avoid too many return statements within this function.
                            Open

                                        return (error_code, error_message)
                            Severity: Major
                            Found in tools/jsonschematoc11/jsonschematoc11.py - About 30 mins to fix

                              Avoid too many return statements within this function.
                              Open

                                      return (error_code, error_message)
                              Severity: Major
                              Found in tools/jsonschematoc11/jsonschematoc11.py - About 30 mins to fix

                                Avoid too many return statements within this function.
                                Open

                                        return (error_code, error_message)
                                Severity: Major
                                Found in tools/jsonschematoc11/jsonschematoc11.py - About 30 mins to fix

                                  Avoid too many return statements within this function.
                                  Open

                                      return (0, u'')
                                  Severity: Major
                                  Found in tools/jsonschematoc11/jsonschematoc11.py - About 30 mins to fix

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

                                                for key in self.c11Types:
                                                    c11_type = self.c11Types[key]
                                                    if c11_type.codeTypeName() in parent_type_names:
                                                        continue
                                    
                                    
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 1 other location - About 1 day to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 217..232

                                    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 136.

                                    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 key in self.c11Types:
                                                    c11_type = self.c11Types[key]
                                                    if c11_type.codeTypeName() in parent_type_names:
                                                        continue
                                    
                                    
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 1 other location - About 1 day to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 284..299

                                    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 136.

                                    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

                                                if config is not None and config.has_option(u'code', u'license'):
                                                    code_file_path = config.get(u'code', u'license')
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            code_file_lines = code_file.readlines()
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 1 other location - About 7 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 256..265

                                    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 114.

                                    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

                                                if config is not None and config.has_option(u'code', u'license'):
                                                    code_file_path = config.get(u'code', u'license')
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            source_file.write(u'/*\n')
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 1 other location - About 7 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 142..151

                                    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 114.

                                    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

                                                if config is not None and config.has_option(u'code', u'license'):
                                                    code_file_path = config.get(u'code', u'license')
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            header_file.write(u'/*\n')
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 1 other location - About 7 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 372..381

                                    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 114.

                                    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

                                                if config is not None and config.has_option(u'code', u'license'):
                                                    code_file_path = config.get(u'code', u'license')
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            code_file_lines = code_file.readlines()
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 1 other location - About 7 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 311..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 114.

                                    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 key in self.c11Types:
                                                    c11_type = self.c11Types[key]
                                                    if not isinstance(c11_type, C11TypeStruct):
                                                        continue
                                    
                                    
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 1 other location - About 5 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 549..560

                                    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 95.

                                    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 key in self.c11Types:
                                                    c11_type = self.c11Types[key]
                                                    if not isinstance(c11_type, C11TypeStruct):
                                                        continue
                                    
                                    
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 1 other location - About 5 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 355..366

                                    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 95.

                                    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 6 locations. Consider refactoring.
                                    Open

                                                if config is not None and config.has_option(u'code.headers', u'header.namespace.begin'):
                                                    code_file_path = config.get(u'code.headers', u'header.namespace.begin')
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            code_header_extra_lines = code_file.readlines()
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 5 other locations - About 5 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 153..160
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 162..169
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 234..241
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 246..253
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 325..332

                                    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 90.

                                    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 6 locations. Consider refactoring.
                                    Open

                                                if config is not None and config.has_option(u'code.headers', u'header.end'):
                                                    code_file_path = config.get(u'code.headers', u'header.end')
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            code_header_extra_lines = code_file.readlines()
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 5 other locations - About 5 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 153..160
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 162..169
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 192..199
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 234..241
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 325..332

                                    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 90.

                                    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 6 locations. Consider refactoring.
                                    Open

                                                if config is not None and config.has_option(u'code.headers', u'header.include'):
                                                    code_file_path = config.get(u'code.headers', u'header.include')
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            code_header_extra_lines = code_file.readlines()
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 5 other locations - About 5 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 153..160
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 192..199
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 234..241
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 246..253
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 325..332

                                    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 90.

                                    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 6 locations. Consider refactoring.
                                    Open

                                                if config is not None and config.has_option(u'code.parser', u'header'):
                                                    code_file_path = config.get(u'code.parser', u'header')
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            code_header_extra_lines = code_file.readlines()
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 5 other locations - About 5 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 153..160
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 162..169
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 192..199
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 234..241
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 246..253

                                    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 90.

                                    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 6 locations. Consider refactoring.
                                    Open

                                                if config is not None and config.has_option(u'code.headers', u'header.begin'):
                                                    code_file_path = config.get(u'code.headers', u'header.begin')
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            code_header_extra_lines = code_file.readlines()
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 5 other locations - About 5 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 162..169
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 192..199
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 234..241
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 246..253
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 325..332

                                    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 90.

                                    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 6 locations. Consider refactoring.
                                    Open

                                                if config is not None and config.has_option(u'code.headers', u'header.namespace.end'):
                                                    code_file_path = config.get(u'code.headers', u'header.namespace.end')
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            code_header_extra_lines = code_file.readlines()
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 5 other locations - About 5 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 153..160
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 162..169
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 192..199
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 246..253
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 325..332

                                    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 90.

                                    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 5 locations. Consider refactoring.
                                    Open

                                                if config is not None and config.has_option(u'code.headers', schemaFileName):
                                                    code_file_path = config.get(u'code.headers', schemaFileName)
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            code_headers = code_file.readlines()
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 4 other locations - About 3 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 43..47
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 49..53
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 55..59
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 61..65

                                    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 66.

                                    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 5 locations. Consider refactoring.
                                    Open

                                                if config is not None and config.has_option(u'code.sources.function', schemaFileName):
                                                    code_file_path = config.get(u'code.sources.function', schemaFileName)
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            code_sources_function = code_file.readlines()
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 4 other locations - About 3 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 37..41
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 43..47
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 55..59
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 61..65

                                    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 66.

                                    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 5 locations. Consider refactoring.
                                    Open

                                                if config is not None and config.has_option(u'code.parsers.to', schemaFileName):
                                                    code_file_path = config.get(u'code.parsers.to', schemaFileName)
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            code_parsers_to = code_file.readlines()
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 4 other locations - About 3 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 37..41
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 43..47
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 49..53
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 55..59

                                    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 66.

                                    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 5 locations. Consider refactoring.
                                    Open

                                                if config is not None and config.has_option(u'code.parsers.from', schemaFileName):
                                                    code_file_path = config.get(u'code.parsers.from', schemaFileName)
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            code_parsers_from = code_file.readlines()
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 4 other locations - About 3 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 37..41
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 43..47
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 49..53
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 61..65

                                    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 66.

                                    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 5 locations. Consider refactoring.
                                    Open

                                                if config is not None and config.has_option(u'code.sources.variable', schemaFileName):
                                                    code_file_path = config.get(u'code.sources.variable', schemaFileName)
                                                    if os.path.isfile(code_file_path):
                                                        with open(code_file_path, u'r') as code_file:
                                                            code_sources_variable = code_file.readlines()
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 4 other locations - About 3 hrs to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 37..41
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 49..53
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 55..59
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 61..65

                                    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 66.

                                    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

                                                if nameSpace != None:
                                                    header_file.write(u'namespace %s\n' % nameSpace)
                                                    header_file.write(u'{\n')
                                                    begin_space = u'    '
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 2 other locations - About 1 hr to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 271..274
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 387..390

                                    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 39.

                                    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

                                                if nameSpace != None:
                                                    source_file.write(u'namespace %s\n' % nameSpace)
                                                    source_file.write(u'{\n')
                                                    begin_space = u'    '
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 2 other locations - About 1 hr to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 271..274
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 335..338

                                    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 39.

                                    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

                                                if nameSpace != None:
                                                    source_file.write(u'namespace %s\n' % nameSpace)
                                                    source_file.write(u'{\n')
                                                    begin_space = u'    '
                                    Severity: Major
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 2 other locations - About 1 hr to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 335..338
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 387..390

                                    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 39.

                                    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

                                        if output_header_path != None and not os.path.exists(output_header_path):
                                            return (1, u'Invalid output header path')
                                    Severity: Minor
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 1 other location - About 35 mins to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 596..597

                                    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 33.

                                    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

                                        if output_source_path != None and not os.path.exists(output_source_path):
                                            return (1, u'Invalid output source path')
                                    Severity: Minor
                                    Found in tools/jsonschematoc11/jsonschematoc11.py and 1 other location - About 35 mins to fix
                                    tools/jsonschematoc11/jsonschematoc11.py on lines 594..595

                                    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 33.

                                    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

                                    There are no issues that match your filters.

                                    Category
                                    Status