polkadot-js/api

View on GitHub

Showing 2,427 of 2,612 total issues

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

  PalletNftFractionalizationCall: {
    _enum: {
      fractionalize: {
        nftCollectionId: 'u32',
        nftId: 'u32',
Severity: Major
Found in packages/types-augment/src/lookup/substrate.ts and 1 other location - About 1 hr to fix
packages/types-augment/src/lookup/substrate.ts on lines 1910..1926

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

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

  interface PalletBagsListListNode extends Struct {
    readonly id: AccountId32;
    readonly prev: Option<AccountId32>;
    readonly next: Option<AccountId32>;
    readonly bagUpper: u64;
Severity: Major
Found in packages/types-augment/src/lookup/types-substrate.ts and 1 other location - About 1 hr to fix
packages/types-augment/src/lookup/types-substrate.ts on lines 7443..7449

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

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

  [
    13272363,
    9320,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/westend.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    12301871,
    9280,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/westend.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    12532644,
    9291,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/polkadot.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    15048375,
    9300,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/kusama.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    15912007,
    9360,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/kusama.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    14188833,
    9360,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/polkadot.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    14543918,
    9370,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/polkadot.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    13128237,
    9310,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/westend.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    13761100,
    9350,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/westend.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    12604343,
    9290,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/westend.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    13483497,
    9330,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/westend.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    15426015,
    9320,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/kusama.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    14645900,
    9291,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/kusama.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    12876189,
    9300,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/polkadot.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    15680713,
    9340,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/kusama.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    15756296,
    9350,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/kusama.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    16356547,
    9370,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/kusama.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3600..3669
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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

  [
    12841034,
    9300,
    [
      [
Severity: Major
Found in packages/types-known/src/upgrades/e2e/westend.ts and 24 other locations - About 1 hr to fix
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3762..3831
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3832..3901
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3902..3971
packages/types-known/src/upgrades/e2e/kusama.ts on lines 3972..4041
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4042..4111
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4112..4181
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4182..4251
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4252..4321
packages/types-known/src/upgrades/e2e/kusama.ts on lines 4322..4391
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2492..2561
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2562..2631
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2632..2701
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2702..2771
packages/types-known/src/upgrades/e2e/polkadot.ts on lines 2772..2841
packages/types-known/src/upgrades/e2e/westend.ts on lines 3460..3529
packages/types-known/src/upgrades/e2e/westend.ts on lines 3530..3599
packages/types-known/src/upgrades/e2e/westend.ts on lines 3670..3739
packages/types-known/src/upgrades/e2e/westend.ts on lines 3740..3809
packages/types-known/src/upgrades/e2e/westend.ts on lines 3810..3879
packages/types-known/src/upgrades/e2e/westend.ts on lines 3880..3949
packages/types-known/src/upgrades/e2e/westend.ts on lines 3950..4019
packages/types-known/src/upgrades/e2e/westend.ts on lines 4020..4089
packages/types-known/src/upgrades/e2e/westend.ts on lines 4090..4159
packages/types-known/src/upgrades/e2e/westend.ts on lines 4160..4229

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

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