Showing 670 of 670 total issues

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

describe("EssexPoliceCaseSource", () => {

  const testCase = new class extends DatasourceTestCase<EssexPoliceCaseSummary> {
    constructor(mapping: RR0CaseMapping<EssexPoliceCaseSummary>, sourceCases: EssexPoliceCaseSummary[]) {
      super(mapping, sourceCases)
Severity: Major
Found in time/datasource/essex-police/EssexPoliceDatasource.test.ts and 5 other locations - About 1 day to fix
org/eu/fr/cnes/geipan/GeipanDatasource.test.ts on lines 11..42
time/datasource/baseovnifrance/BaseOvniFranceDatasource.test.ts on lines 11..42
time/datasource/fufora/FuforaDatasource.test.ts on lines 11..42
time/datasource/nuforc/NuforcDatasource.test.ts on lines 11..42
time/datasource/ufo-search/UfoSearchDatasource.test.ts on lines 11..42

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

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

describe("FuforaCaseSource", () => {

  const testCase = new class extends DatasourceTestCase<FuforaCaseSummary> {
    constructor(mapping: RR0CaseMapping<FuforaCaseSummary>, sourceCases: FuforaCaseSummary[]) {
      super(mapping, sourceCases)
Severity: Major
Found in time/datasource/fufora/FuforaDatasource.test.ts and 5 other locations - About 1 day to fix
org/eu/fr/cnes/geipan/GeipanDatasource.test.ts on lines 11..42
time/datasource/baseovnifrance/BaseOvniFranceDatasource.test.ts on lines 11..42
time/datasource/essex-police/EssexPoliceDatasource.test.ts on lines 11..42
time/datasource/nuforc/NuforcDatasource.test.ts on lines 11..42
time/datasource/ufo-search/UfoSearchDatasource.test.ts on lines 11..42

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

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

describe("GeipanCaseSource", () => {

  const testCase = new class extends DatasourceTestCase<GeipanCaseSummary> {
    constructor(mapping: RR0CaseMapping<GeipanCaseSummary>, sourceCases: GeipanCaseSummary[]) {
      super(mapping, sourceCases)
Severity: Major
Found in org/eu/fr/cnes/geipan/GeipanDatasource.test.ts and 5 other locations - About 1 day to fix
time/datasource/baseovnifrance/BaseOvniFranceDatasource.test.ts on lines 11..42
time/datasource/essex-police/EssexPoliceDatasource.test.ts on lines 11..42
time/datasource/fufora/FuforaDatasource.test.ts on lines 11..42
time/datasource/nuforc/NuforcDatasource.test.ts on lines 11..42
time/datasource/ufo-search/UfoSearchDatasource.test.ts on lines 11..42

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

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

describe("NuforcCaseSource", () => {

  const testCase = new class extends DatasourceTestCase<NuforcCaseSummary> {
    constructor(mapping: RR0CaseMapping<NuforcCaseSummary>, sourceCases: NuforcCaseSummary[]) {
      super(mapping, sourceCases)
Severity: Major
Found in time/datasource/nuforc/NuforcDatasource.test.ts and 5 other locations - About 1 day to fix
org/eu/fr/cnes/geipan/GeipanDatasource.test.ts on lines 11..42
time/datasource/baseovnifrance/BaseOvniFranceDatasource.test.ts on lines 11..42
time/datasource/essex-police/EssexPoliceDatasource.test.ts on lines 11..42
time/datasource/fufora/FuforaDatasource.test.ts on lines 11..42
time/datasource/ufo-search/UfoSearchDatasource.test.ts on lines 11..42

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

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

peopleMessages_en has 84 functions (exceeds 20 allowed). Consider refactoring.
Open

  occupation: {
    abductee: (_gender: Gender) => "abductee",
    actor: (gender: Gender) => gender === Gender.male ? "actor" : "actress",
    anthropologist: (_gender: Gender) => "anthropologist",
    archeologist: (_gender: Gender) => "archeologist",
Severity: Major
Found in people/PeopleMessages_en.ts - About 1 day to fix

    peopleMessages_fr has 84 functions (exceeds 20 allowed). Consider refactoring.
    Open

      occupation: {
        abductee: (gender: Gender) => gender === Gender.male ? "enlevé" : "enlevée",
        actor: (gender: Gender) => gender === Gender.male ? "acteur" : "actrice",
        anthropologist: (_gender: Gender) => "anthropologue",
        archeologist: (_gender: Gender) => "archéologue",
    Severity: Major
    Found in people/PeopleMessages_fr.ts - About 1 day to fix

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

          test("with hour interval", async () => {
            const currentContext = rr0TestUtil.newHtmlContext("time/1/9/9/0/08/index.html", "")
            currentContext.time.setYear(2005)
            currentContext.time.setMonth(8)
            const context = currentContext.clone()
      Severity: Major
      Found in time/TimeReplacer.test.ts and 1 other location - About 1 day to fix
      time/TimeReplacer.test.ts on lines 148..164

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

      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

          test("from current date with hour", async () => {
            const currentContext = rr0TestUtil.newHtmlContext("time/1/9/9/0/08/index.html", "")
            currentContext.time.setYear(2005)
            currentContext.time.setMonth(8)
            const context = currentContext.clone()
      Severity: Major
      Found in time/TimeReplacer.test.ts and 1 other location - About 1 day to fix
      time/TimeReplacer.test.ts on lines 166..182

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

      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

        function graphBiasToSoftmaxArrows(data) {
      
          var inputToBiasLines = this.neuralNetworkG.selectAll(this.svgElement + " .bias-to-softmax-line")
            .data(data)
      
      
      Severity: Major
      Found in people/a/AlammarJay/js/nn_calc.js and 1 other location - About 1 day to fix
      people/a/AlammarJay/js/shallow_nn_grapher.js on lines 429..472

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

      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

      shallowNeuralNetworkGrapher.prototype.graphBiasToSoftmaxArrows = function (data) {
        var inputToBiasLines = this.neuralNetworkG.selectAll(this.svgElement + " .bias-to-softmax-line")
          .data(data);
      
        inputToBiasLines.exit()
      Severity: Major
      Found in people/a/AlammarJay/js/shallow_nn_grapher.js and 1 other location - About 1 day to fix
      people/a/AlammarJay/js/nn_calc.js on lines 1031..1076

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

      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

      Function build has a Cognitive Complexity of 70 (exceeds 5 allowed). Consider refactoring.
      Open

        build(oldContext: RR0SsgContext, newContext: RR0SsgContext): string {
          const previousTime = oldContext?.time;
          if (!previousTime?.isDefined()) {
            return this.timeTextBuilder.build(newContext)
          }
      Severity: Minor
      Found in time/RelativeTimeTextBuilder.ts - About 1 day 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

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

      export const usa_fr = CountryMessages.create<UsaRegionMessagesList>("USA", {
        ak: arkansas_fr,
        al: alabama_fr,
        ca: california_fr,
        co: colorado_fr,
      Severity: Major
      Found in org/us/Usa_fr.ts and 1 other location - About 1 day to fix
      org/us/Usa_en.ts on lines 46..89

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

      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

      export const usa_en = CountryMessages.create<UsaRegionMessagesList>("USA", {
        ak: arkansas_en,
        al: alabama_en,
        ca: california_en,
        co: colorado_en,
      Severity: Major
      Found in org/us/Usa_en.ts and 1 other location - About 1 day to fix
      org/us/Usa_fr.ts on lines 46..89

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

      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

          {
            const timeEl = context.file.document.createElement("time")
            timeEl.textContent = "2003"
            const replacement = await replacer.replacement(context, timeEl)
            expect(replacement.outerHTML).toBe(`<a href="/time/2/0/0/3/"><time datetime="2003">2003</time></a>`)
      Severity: Major
      Found in time/TimeReplacer.test.ts and 1 other location - About 1 day to fix
      time/TimeReplacer.test.ts on lines 31..42

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

      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

          {
            const timeEl = context.file.document.createElement("time")
            timeEl.innerHTML = "2003\n      "
            const replacement = await replacer.replacement(context, timeEl)
            expect(replacement.outerHTML).toBe(`<a href="/time/2/0/0/3/"><time datetime="2003">2003</time></a>`)
      Severity: Major
      Found in time/TimeReplacer.test.ts and 1 other location - About 1 day to fix
      time/TimeReplacer.test.ts on lines 19..30

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

      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

      File simple_nn.js has 583 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      /**
       * Created by alammar on 11/16/16.
       */
      
      
      
      Severity: Major
      Found in people/a/AlammarJay/js/simple_nn.js - About 1 day to fix

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

              {
                let previousContext = new RR0SsgContextImpl("fr", new TimeContext(), config)
                const context = previousContext.clone()
                context.time.setYear(2003)
                context.time.setMonth(9)
        Severity: Major
        Found in time/RelativeTimeTextBuilder.test.ts and 1 other location - About 1 day to fix
        time/RelativeTimeTextBuilder.test.ts on lines 114..127

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

        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

              {
                let previousContext = new RR0SsgContextImpl("en", new TimeContext(), config)
                const context = previousContext.clone()
                context.time.setYear(2003)
                context.time.setMonth(9)
        Severity: Major
        Found in time/RelativeTimeTextBuilder.test.ts and 1 other location - About 1 day to fix
        time/RelativeTimeTextBuilder.test.ts on lines 100..113

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

        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

        NN_trainer.prototype.batchAddErrorPoint = function (valuesArray) {
        
          this.error_history = this.error_history.concat(valuesArray);
        
        
        
        Severity: Major
        Found in people/a/AlammarJay/js/simple_nn.js and 1 other location - About 1 day to fix
        people/a/AlammarJay/js/two_variable_nn.js on lines 224..243

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

        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

        multiVariableNeuralNetworkTrainer.prototype.batchAddErrorPoint = function (valuesArray) {
        
          this.error_history = this.error_history.concat(valuesArray);
        
          // Cut the needed number of elements to be within our specified error_chart_history_x
        Severity: Major
        Found in people/a/AlammarJay/js/two_variable_nn.js and 1 other location - About 1 day to fix
        people/a/AlammarJay/js/simple_nn.js on lines 289..310

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

        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