Showing 555 of 555 total issues

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

        if (prevFile) {
          const text = Time.titleFromFile(context, prevFile);
          if (text) {
            return {type: LinkType.prev, text, url: '/' + prevFile};
          }
Severity: Minor
Found in time/TimeLinkDefaultHandler.ts and 1 other location - About 55 mins to fix
time/TimeLinkDefaultHandler.ts on lines 19..24

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

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 findPeople has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
Open

window.findPeople = (_e) => {
  const textInput = form.querySelector('input[type=\'search\']')

  function normalize (str) {
    return str.toLowerCase().normalize('NFD').replace(/[\u0300-\u036f]/g, '').trim()
Severity: Minor
Found in people/index.js - About 55 mins to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function contents has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
Open

  contents(context: HtmlRR0SsgContext): Link | undefined {
    const prevLink = this.prev(context);
    if (prevLink) {
      let contentUrl = prevLink.url.substring(1);
      do {
Severity: Minor
Found in time/TimeLinkDefaultHandler.ts - About 55 mins to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function gradientDescentStep has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
Open

NN_trainer.prototype.gradientDescentStep = function (number_of_steps) {

  // I probably shouldn't do this. I started doing feature normalization so we can keep to one learning rate.
  // I decided to do it this way to maintain narrative continuity.
  this.learningRate = 0.00000001;
Severity: Minor
Found in people/a/AlammarJay/js/simple_nn.js - About 55 mins to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function drawText has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
Open

  protected drawText(canvasCtx: CanvasRenderingContext2D, text: string, margin: number, lineHeight: number,
                     font: string) {
    canvasCtx.font = font
    let lineText = text
    let remainingText = lineText
Severity: Minor
Found in OpenGraphCommand.ts - About 55 mins to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function handleInternal has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
Open

  protected async handleInternal(context: HtmlRR0SsgContext, a: HTMLAnchorElement, url: URL) {
    if (url.protocol.startsWith("http")) {
      const pathname = url.pathname
      const pathToSearch = pathname.substring(1)
      if (pathToSearch) {
Severity: Minor
Found in anchor/AnchorReplacer.ts - About 55 mins to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function read has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
Open

  protected async read(context: RR0SsgContext, dirName: string, fileNames: string[]): Promise<RR0Data[]> {
    const dataList: RR0Data[] = []
    const p = dirName + "/*(" + fileNames.join("|") + ")"
    const files = glob(p)
    for (const file of files) {
Severity: Minor
Found in DataService.ts - About 55 mins to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

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

        var sum_term = viz.layerValues[1].map(function (d) {
          return 'e^{' + numberFormatter(d, 2) + '}'
        }).join(" + ")
Severity: Minor
Found in people/a/AlammarJay/js/nn_calc.js and 1 other location - About 55 mins to fix
people/a/AlammarJay/js/nn_calc.js on lines 795..797

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

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

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

        var sum_term = viz.layerValues[1].map(function (d) {
          return 'e^{' + numberFormatter(d, 2) + '}'
        }).join(" + ")
Severity: Minor
Found in people/a/AlammarJay/js/nn_calc.js and 1 other location - About 55 mins to fix
people/a/AlammarJay/js/nn_calc.js on lines 582..584

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

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

export const loireMessages = DepartmentMessages.create<LoireMessages>("Loire", {
  [LoireCityCode.Montbrison]: montbrison42Messages,
  [LoireCityCode.Roanne]: roanneMessages,
  [LoireCityCode.StEtienne]: stEtienne42Messages
})
Severity: Major
Found in org/eu/fr/region/ara/42/LoireMessages.ts and 8 other locations - About 55 mins to fix
org/eu/fr/region/ara/63/PuyDeDomeMessages.ts on lines 9..13
org/eu/fr/region/bre/29/FinistereMessages.ts on lines 9..13
org/eu/fr/region/ges/55/MeuseMessages.ts on lines 9..13
org/eu/fr/region/idf/92/HautsDeSeineMessages.ts on lines 9..13
org/eu/fr/region/occ/32/GersMessages.ts on lines 9..13
org/eu/fr/region/occ/66/PyreneesOrientalesMessages.ts on lines 9..13
org/eu/fr/region/pac/04/AlpesDeHauteProvenceMessages.ts on lines 9..13
org/eu/fr/region/pdl/44/LoireAtlantiqueMessages.ts on lines 9..14

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

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

export const alpesDeHauteProvenceMessages = DepartmentMessages.create<DepMessages>("Alpes-de-Haute-Provence", {
  [AlpesDeHauteProvenceCityCode.Barcelonnette]: barcelonnetteMessages,
  [AlpesDeHauteProvenceCityCode.Entrevaux]: entrevauxMessages,
  [AlpesDeHauteProvenceCityCode.LauzetUbaye]: lauzetUbayeMessages
})
Severity: Major
Found in org/eu/fr/region/pac/04/AlpesDeHauteProvenceMessages.ts and 8 other locations - About 55 mins to fix
org/eu/fr/region/ara/42/LoireMessages.ts on lines 9..13
org/eu/fr/region/ara/63/PuyDeDomeMessages.ts on lines 9..13
org/eu/fr/region/bre/29/FinistereMessages.ts on lines 9..13
org/eu/fr/region/ges/55/MeuseMessages.ts on lines 9..13
org/eu/fr/region/idf/92/HautsDeSeineMessages.ts on lines 9..13
org/eu/fr/region/occ/32/GersMessages.ts on lines 9..13
org/eu/fr/region/occ/66/PyreneesOrientalesMessages.ts on lines 9..13
org/eu/fr/region/pdl/44/LoireAtlantiqueMessages.ts on lines 9..14

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

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

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

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

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

Refactorings

Further Reading

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

    for (var p = 0; p < this.numberOfInputNodes; p++)
      newWeights[p] = this.weights[p] - weightAdjustments[p];
Severity: Minor
Found in people/a/AlammarJay/js/two_variable_nn.js and 1 other location - About 55 mins to fix
people/a/AlammarJay/js/two_variable_nn.js on lines 471..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 53.

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

export const puyDeDomeMessages = DepartmentMessages.create<DepCityMessages>("Puy-de-Dôme", {
  [PuyDeDomeCityCode.Riom]: riomMessages,
  [PuyDeDomeCityCode.Billom]: billomMessages,
  [PuyDeDomeCityCode.ChatelGuyon]: chatelGuyonMessages
})
Severity: Major
Found in org/eu/fr/region/ara/63/PuyDeDomeMessages.ts and 8 other locations - About 55 mins to fix
org/eu/fr/region/ara/42/LoireMessages.ts on lines 9..13
org/eu/fr/region/bre/29/FinistereMessages.ts on lines 9..13
org/eu/fr/region/ges/55/MeuseMessages.ts on lines 9..13
org/eu/fr/region/idf/92/HautsDeSeineMessages.ts on lines 9..13
org/eu/fr/region/occ/32/GersMessages.ts on lines 9..13
org/eu/fr/region/occ/66/PyreneesOrientalesMessages.ts on lines 9..13
org/eu/fr/region/pac/04/AlpesDeHauteProvenceMessages.ts on lines 9..13
org/eu/fr/region/pdl/44/LoireAtlantiqueMessages.ts on lines 9..14

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

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

export const hautsDeSeineMessages = DepartmentMessages.create<HautDeSeineCityMessagesList>("Hauts-de-Seine", {
  [HautsDeSeineCityCode.BoisColombes]: boisColombesMessages,
  [HautsDeSeineCityCode.Colombes]: colombesMessages,
  [HautsDeSeineCityCode.Nanterre]: nanterreMessages
})
Severity: Major
Found in org/eu/fr/region/idf/92/HautsDeSeineMessages.ts and 8 other locations - About 55 mins to fix
org/eu/fr/region/ara/42/LoireMessages.ts on lines 9..13
org/eu/fr/region/ara/63/PuyDeDomeMessages.ts on lines 9..13
org/eu/fr/region/bre/29/FinistereMessages.ts on lines 9..13
org/eu/fr/region/ges/55/MeuseMessages.ts on lines 9..13
org/eu/fr/region/occ/32/GersMessages.ts on lines 9..13
org/eu/fr/region/occ/66/PyreneesOrientalesMessages.ts on lines 9..13
org/eu/fr/region/pac/04/AlpesDeHauteProvenceMessages.ts on lines 9..13
org/eu/fr/region/pdl/44/LoireAtlantiqueMessages.ts on lines 9..14

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

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

export const loireAtlantiqueMessages = DepartmentMessages.create<LoireAtlantiqueCityMessagesList>("Loire-Atlantique",
  {
    [LoireAtlantiqueCityCode.LeCroisic]: leCroisicMessages,
    [LoireAtlantiqueCityCode.LorouxBottereau]: lorouxBottereauMessages,
    [LoireAtlantiqueCityCode.Reze]: rezeMessages
Severity: Major
Found in org/eu/fr/region/pdl/44/LoireAtlantiqueMessages.ts and 8 other locations - About 55 mins to fix
org/eu/fr/region/ara/42/LoireMessages.ts on lines 9..13
org/eu/fr/region/ara/63/PuyDeDomeMessages.ts on lines 9..13
org/eu/fr/region/bre/29/FinistereMessages.ts on lines 9..13
org/eu/fr/region/ges/55/MeuseMessages.ts on lines 9..13
org/eu/fr/region/idf/92/HautsDeSeineMessages.ts on lines 9..13
org/eu/fr/region/occ/32/GersMessages.ts on lines 9..13
org/eu/fr/region/occ/66/PyreneesOrientalesMessages.ts on lines 9..13
org/eu/fr/region/pac/04/AlpesDeHauteProvenceMessages.ts on lines 9..13

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

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

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

  const config: SsgConfig = {
    getOutputPath(context: SsgContext): string {
      return path.join(outDir, context.file.name)
    }
  }
Severity: Minor
Found in science/crypto/ufo/enquete/dossier/CaseDirectoryStep.test.ts and 1 other location - About 55 mins to fix
build.ts on lines 129..133

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

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

export const finistereMessages = DepartmentMessages.create<CotesDArmorCityMessagesList>("Finistère", {
  [FinistereCityCode.Brest]: brestMessages,
  [FinistereCityCode.Concarneau]: concarneauMessages,
  [FinistereCityCode.Fouesnant]: fouesnantMessages
})
Severity: Major
Found in org/eu/fr/region/bre/29/FinistereMessages.ts and 8 other locations - About 55 mins to fix
org/eu/fr/region/ara/42/LoireMessages.ts on lines 9..13
org/eu/fr/region/ara/63/PuyDeDomeMessages.ts on lines 9..13
org/eu/fr/region/ges/55/MeuseMessages.ts on lines 9..13
org/eu/fr/region/idf/92/HautsDeSeineMessages.ts on lines 9..13
org/eu/fr/region/occ/32/GersMessages.ts on lines 9..13
org/eu/fr/region/occ/66/PyreneesOrientalesMessages.ts on lines 9..13
org/eu/fr/region/pac/04/AlpesDeHauteProvenceMessages.ts on lines 9..13
org/eu/fr/region/pdl/44/LoireAtlantiqueMessages.ts on lines 9..14

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

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

export const gersMessages = DepartmentMessages.create<GersCityMessages>("Gers", {
  [GersCityCode.Condom]: condomMessages,
  [GersCityCode.Estang]: estang33Messages,
  [GersCityCode.MiramontDAstarac]: miramontDAstaracMessages
})
Severity: Major
Found in org/eu/fr/region/occ/32/GersMessages.ts and 8 other locations - About 55 mins to fix
org/eu/fr/region/ara/42/LoireMessages.ts on lines 9..13
org/eu/fr/region/ara/63/PuyDeDomeMessages.ts on lines 9..13
org/eu/fr/region/bre/29/FinistereMessages.ts on lines 9..13
org/eu/fr/region/ges/55/MeuseMessages.ts on lines 9..13
org/eu/fr/region/idf/92/HautsDeSeineMessages.ts on lines 9..13
org/eu/fr/region/occ/66/PyreneesOrientalesMessages.ts on lines 9..13
org/eu/fr/region/pac/04/AlpesDeHauteProvenceMessages.ts on lines 9..13
org/eu/fr/region/pdl/44/LoireAtlantiqueMessages.ts on lines 9..14

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

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

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

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

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

Refactorings

Further Reading

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

    for (var m = 0; m < this.numberOfInputNodes; m++)
      weightAdjustments[m] = this.weightLearningRates[m] * weightsMeans[m];
Severity: Minor
Found in people/a/AlammarJay/js/two_variable_nn.js and 1 other location - About 55 mins to fix
people/a/AlammarJay/js/two_variable_nn.js on lines 476..477

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

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

export const meuseMessages = DepartmentMessages.create<DepMessages>("Meuse", {
  [MeuseCityCode.GondrecourtLeChateau]: gondrecourtLeChateauMessages,
  [MeuseCityCode.Vaucouleurs]: vaucouleursMessages,
  [MeuseCityCode.VoidVacon]: voidVaconMessages
})
Severity: Major
Found in org/eu/fr/region/ges/55/MeuseMessages.ts and 8 other locations - About 55 mins to fix
org/eu/fr/region/ara/42/LoireMessages.ts on lines 9..13
org/eu/fr/region/ara/63/PuyDeDomeMessages.ts on lines 9..13
org/eu/fr/region/bre/29/FinistereMessages.ts on lines 9..13
org/eu/fr/region/idf/92/HautsDeSeineMessages.ts on lines 9..13
org/eu/fr/region/occ/32/GersMessages.ts on lines 9..13
org/eu/fr/region/occ/66/PyreneesOrientalesMessages.ts on lines 9..13
org/eu/fr/region/pac/04/AlpesDeHauteProvenceMessages.ts on lines 9..13
org/eu/fr/region/pdl/44/LoireAtlantiqueMessages.ts on lines 9..14

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

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