trufflesuite/truffle

View on GitHub

Showing 716 of 1,401 total issues

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

    const savedRecordById = savedRecords
      .filter((savedRecord): savedRecord is SavedRecord<T> => !!savedRecord)
      .map(savedRecord => ({
        [savedRecord._id]: savedRecord
      }))
Severity: Major
Found in packages/db/src/meta/pouch/adapters/base.ts and 1 other location - About 3 hrs to fix
packages/db/src/meta/pouch/adapters/base.ts on lines 154..161

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

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

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

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

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

Refactorings

Further Reading

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

  return (
    <Flex direction="column" className={classes.breakpointsContainer}>
      <div className={classes.sectionHeader}>Breakpoints</div>
      <div className={classes.breakpoints}>
        <pre className={classes.breakpointsContent}>{breakpointsList}</pre>
packages/dashboard/src/components/composed/Debugger/Stack.tsx on lines 91..98
packages/dashboard/src/components/composed/Debugger/Variables.tsx on lines 139..146

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

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

  {
    type: "codec-interface",
    name: "Format.Values.BoolValue",
    content: (
      <>
Severity: Major
Found in packages/codec-components/src/docs/content.tsx and 9 other locations - About 3 hrs to fix
packages/codec-components/src/docs/content.tsx on lines 13..24
packages/codec-components/src/docs/content.tsx on lines 127..138
packages/codec-components/src/docs/content.tsx on lines 161..172
packages/codec-components/src/docs/content.tsx on lines 245..256
packages/codec-components/src/docs/content.tsx on lines 257..268
packages/codec-components/src/docs/content.tsx on lines 291..302
packages/codec-components/src/docs/content.tsx on lines 414..425
packages/codec-components/src/docs/content.tsx on lines 436..447
packages/codec-components/src/docs/content.tsx on lines 448..459

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

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

  {
    type: "codec-interface",
    name: "Format.Values.UintValue",
    content: (
      <>
Severity: Major
Found in packages/codec-components/src/docs/content.tsx and 9 other locations - About 3 hrs to fix
packages/codec-components/src/docs/content.tsx on lines 13..24
packages/codec-components/src/docs/content.tsx on lines 127..138
packages/codec-components/src/docs/content.tsx on lines 161..172
packages/codec-components/src/docs/content.tsx on lines 245..256
packages/codec-components/src/docs/content.tsx on lines 257..268
packages/codec-components/src/docs/content.tsx on lines 291..302
packages/codec-components/src/docs/content.tsx on lines 321..332
packages/codec-components/src/docs/content.tsx on lines 414..425
packages/codec-components/src/docs/content.tsx on lines 448..459

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

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

  {
    type: "codec-interface",
    name: "Options",
    content: (
      <>
Severity: Major
Found in packages/codec-components/src/docs/content.tsx and 9 other locations - About 3 hrs to fix
packages/codec-components/src/docs/content.tsx on lines 13..24
packages/codec-components/src/docs/content.tsx on lines 127..138
packages/codec-components/src/docs/content.tsx on lines 161..172
packages/codec-components/src/docs/content.tsx on lines 245..256
packages/codec-components/src/docs/content.tsx on lines 257..268
packages/codec-components/src/docs/content.tsx on lines 291..302
packages/codec-components/src/docs/content.tsx on lines 321..332
packages/codec-components/src/docs/content.tsx on lines 414..425
packages/codec-components/src/docs/content.tsx on lines 436..447

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

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

  {
    type: "codec-interface",
    name: "ReturnDecoding",
    content: (
      <>
Severity: Major
Found in packages/codec-components/src/docs/content.tsx and 9 other locations - About 3 hrs to fix
packages/codec-components/src/docs/content.tsx on lines 13..24
packages/codec-components/src/docs/content.tsx on lines 161..172
packages/codec-components/src/docs/content.tsx on lines 245..256
packages/codec-components/src/docs/content.tsx on lines 257..268
packages/codec-components/src/docs/content.tsx on lines 291..302
packages/codec-components/src/docs/content.tsx on lines 321..332
packages/codec-components/src/docs/content.tsx on lines 414..425
packages/codec-components/src/docs/content.tsx on lines 436..447
packages/codec-components/src/docs/content.tsx on lines 448..459

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

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

  {
    type: "codec-interface",
    name: "StateVariable",
    content: (
      <>
Severity: Major
Found in packages/codec-components/src/docs/content.tsx and 9 other locations - About 3 hrs to fix
packages/codec-components/src/docs/content.tsx on lines 13..24
packages/codec-components/src/docs/content.tsx on lines 127..138
packages/codec-components/src/docs/content.tsx on lines 245..256
packages/codec-components/src/docs/content.tsx on lines 257..268
packages/codec-components/src/docs/content.tsx on lines 291..302
packages/codec-components/src/docs/content.tsx on lines 321..332
packages/codec-components/src/docs/content.tsx on lines 414..425
packages/codec-components/src/docs/content.tsx on lines 436..447
packages/codec-components/src/docs/content.tsx on lines 448..459

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

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

  {
    type: "codec-interface",
    name: "Format.Values.StructValue",
    content: (
      <>
Severity: Major
Found in packages/codec-components/src/docs/content.tsx and 9 other locations - About 3 hrs to fix
packages/codec-components/src/docs/content.tsx on lines 13..24
packages/codec-components/src/docs/content.tsx on lines 127..138
packages/codec-components/src/docs/content.tsx on lines 161..172
packages/codec-components/src/docs/content.tsx on lines 257..268
packages/codec-components/src/docs/content.tsx on lines 291..302
packages/codec-components/src/docs/content.tsx on lines 321..332
packages/codec-components/src/docs/content.tsx on lines 414..425
packages/codec-components/src/docs/content.tsx on lines 436..447
packages/codec-components/src/docs/content.tsx on lines 448..459

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

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

  {
    type: "codec-interface",
    name: "AbiArgument",
    content: (
      <>
Severity: Major
Found in packages/codec-components/src/docs/content.tsx and 9 other locations - About 3 hrs to fix
packages/codec-components/src/docs/content.tsx on lines 127..138
packages/codec-components/src/docs/content.tsx on lines 161..172
packages/codec-components/src/docs/content.tsx on lines 245..256
packages/codec-components/src/docs/content.tsx on lines 257..268
packages/codec-components/src/docs/content.tsx on lines 291..302
packages/codec-components/src/docs/content.tsx on lines 321..332
packages/codec-components/src/docs/content.tsx on lines 414..425
packages/codec-components/src/docs/content.tsx on lines 436..447
packages/codec-components/src/docs/content.tsx on lines 448..459

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

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

  {
    type: "codec-interface",
    name: "Format.Values.OptionallyNamedValue",
    content: (
      <>
Severity: Major
Found in packages/codec-components/src/docs/content.tsx and 9 other locations - About 3 hrs to fix
packages/codec-components/src/docs/content.tsx on lines 13..24
packages/codec-components/src/docs/content.tsx on lines 127..138
packages/codec-components/src/docs/content.tsx on lines 161..172
packages/codec-components/src/docs/content.tsx on lines 245..256
packages/codec-components/src/docs/content.tsx on lines 257..268
packages/codec-components/src/docs/content.tsx on lines 321..332
packages/codec-components/src/docs/content.tsx on lines 414..425
packages/codec-components/src/docs/content.tsx on lines 436..447
packages/codec-components/src/docs/content.tsx on lines 448..459

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

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

  {
    type: "codec-interface",
    name: "Format.Values.TupleValue",
    content: (
      <>
Severity: Major
Found in packages/codec-components/src/docs/content.tsx and 9 other locations - About 3 hrs to fix
packages/codec-components/src/docs/content.tsx on lines 13..24
packages/codec-components/src/docs/content.tsx on lines 127..138
packages/codec-components/src/docs/content.tsx on lines 161..172
packages/codec-components/src/docs/content.tsx on lines 245..256
packages/codec-components/src/docs/content.tsx on lines 291..302
packages/codec-components/src/docs/content.tsx on lines 321..332
packages/codec-components/src/docs/content.tsx on lines 414..425
packages/codec-components/src/docs/content.tsx on lines 436..447
packages/codec-components/src/docs/content.tsx on lines 448..459

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

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

  ({ value, name }: Codec.AbiArgument) => (
    <InjectedNode
      value={{
        ...useInjectedNode(),
        prefix: {
packages/codec-components/src/react/components/codec/format.values.optionally-named-value.tsx on lines 11..27

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

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

  {
    type: "codec-interface",
    name: "Format.Values.StringValue",
    content: (
      <>
Severity: Major
Found in packages/codec-components/src/docs/content.tsx and 9 other locations - About 3 hrs to fix
packages/codec-components/src/docs/content.tsx on lines 13..24
packages/codec-components/src/docs/content.tsx on lines 127..138
packages/codec-components/src/docs/content.tsx on lines 161..172
packages/codec-components/src/docs/content.tsx on lines 245..256
packages/codec-components/src/docs/content.tsx on lines 257..268
packages/codec-components/src/docs/content.tsx on lines 291..302
packages/codec-components/src/docs/content.tsx on lines 321..332
packages/codec-components/src/docs/content.tsx on lines 436..447
packages/codec-components/src/docs/content.tsx on lines 448..459

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

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

  ({ name, value }: Format.Values.OptionallyNamedValue) => (
    <InjectedNode
      value={{
        ...useInjectedNode(),
        prefix: {
packages/codec-components/src/react/components/codec/abi-argument.tsx on lines 11..27

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

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

    ...(!transactionHash || receipt
      ? []
      : [
          <Box key="receipt">
            <Box paddingLeft={1} paddingRight={1}>
Severity: Major
Found in packages/db-kit/src/cli/decodeTransaction/Inputs.tsx and 1 other location - About 3 hrs to fix
packages/db-kit/src/cli/decodeTransaction/Inputs.tsx on lines 39..50

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

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

    ...(!transactionHash || transaction
      ? []
      : [
          <Box key="transaction">
            <Box paddingLeft={1} paddingRight={1}>
Severity: Major
Found in packages/db-kit/src/cli/decodeTransaction/Inputs.tsx and 1 other location - About 3 hrs to fix
packages/db-kit/src/cli/decodeTransaction/Inputs.tsx on lines 51..62

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

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

  @validStates([State.Active])
  @transitionToState(State.Done)
  async *resolve({ resolution, payload }: Options.Resolve = {}) {
    yield this.emit<Events.Resolve>({
      type: "resolve",
packages/preserve/lib/control/controllers/StepsController.ts on lines 74..82

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

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

        inputs: fc.array(Parameter(), { maxLength: 10 }).filter(inputs => {
          // names that are not blank should be unique
          const names = inputs
            .map(({ name }) => name)
            .filter(name => name !== "");
Severity: Major
Found in packages/abi-utils/lib/arbitrary.ts and 1 other location - About 3 hrs to fix
packages/abi-utils/lib/arbitrary.ts on lines 48..52

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

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

  @validStates([State.Active])
  @transitionToState(State.Done)
  async *succeed({ result, message }: Options.Succeed = {}) {
    yield this.emit<Events.Succeed>({
      type: "succeed",
Severity: Major
Found in packages/preserve/lib/control/controllers/StepsController.ts and 1 other location - About 3 hrs to fix
packages/preserve/lib/control/controllers/ValueResolutionController.ts on lines 53..61

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

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

    inputs: fc.array(Parameter(), { maxLength: 10 }).filter(inputs => {
      // names that are not blank should be unique
      const names = inputs.map(({ name }) => name).filter(name => name !== "");
      return names.length === new Set(names).size;
    })
Severity: Major
Found in packages/abi-utils/lib/arbitrary.ts and 1 other location - About 3 hrs to fix
packages/abi-utils/lib/arbitrary.ts on lines 148..154

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

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