ontohub/ontohub-backend

View on GitHub
app/graphql/types/query_type.rb

Summary

Maintainability
B
5 hrs
Test Coverage

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

  field :generatedAxiom, Types::GeneratedAxiomType do
    description 'A GeneratedAxiom'

    argument :id, !types.Int do
      description 'The id of the GeneratedAxiom'
Severity: Major
Found in app/graphql/types/query_type.rb and 5 other locations - About 35 mins to fix
app/graphql/types/query_type.rb on lines 157..172
app/graphql/types/query_type.rb on lines 175..190
app/graphql/types/query_type.rb on lines 193..208
app/graphql/types/query_type.rb on lines 223..238
app/graphql/types/query_type.rb on lines 259..274

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

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

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

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

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

Refactorings

Further Reading

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

  field :signature, Types::SignatureType do
    description 'A Signature'

    argument :id, !types.Int do
      description 'The id of the Signature'
Severity: Major
Found in app/graphql/types/query_type.rb and 5 other locations - About 35 mins to fix
app/graphql/types/query_type.rb on lines 175..190
app/graphql/types/query_type.rb on lines 193..208
app/graphql/types/query_type.rb on lines 223..238
app/graphql/types/query_type.rb on lines 241..256
app/graphql/types/query_type.rb on lines 259..274

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

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

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

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

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

Refactorings

Further Reading

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

  field :reasonerConfiguration, Types::ReasonerConfigurationType do
    description 'A ReasonerConfiguration'

    argument :id, !types.Int do
      description 'The id of the ReasonerConfiguration'
Severity: Major
Found in app/graphql/types/query_type.rb and 5 other locations - About 35 mins to fix
app/graphql/types/query_type.rb on lines 157..172
app/graphql/types/query_type.rb on lines 175..190
app/graphql/types/query_type.rb on lines 193..208
app/graphql/types/query_type.rb on lines 241..256
app/graphql/types/query_type.rb on lines 259..274

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

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

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

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

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

Refactorings

Further Reading

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

  field :signatureMorphism, Types::SignatureMorphismType do
    description 'A SignatureMorphism'

    argument :id, !types.Int do
      description 'The id of the SignatureMorphism'
Severity: Major
Found in app/graphql/types/query_type.rb and 5 other locations - About 35 mins to fix
app/graphql/types/query_type.rb on lines 157..172
app/graphql/types/query_type.rb on lines 193..208
app/graphql/types/query_type.rb on lines 223..238
app/graphql/types/query_type.rb on lines 241..256
app/graphql/types/query_type.rb on lines 259..274

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

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

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

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

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

Refactorings

Further Reading

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

  field :premiseSelection, Types::PremiseSelectionType do
    description 'A PremiseSelection'

    argument :id, !types.Int do
      description 'The id of the PremiseSelection'
Severity: Major
Found in app/graphql/types/query_type.rb and 5 other locations - About 35 mins to fix
app/graphql/types/query_type.rb on lines 157..172
app/graphql/types/query_type.rb on lines 175..190
app/graphql/types/query_type.rb on lines 193..208
app/graphql/types/query_type.rb on lines 223..238
app/graphql/types/query_type.rb on lines 241..256

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

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

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

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

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

Refactorings

Further Reading

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

  field :reasoningAttempt, Types::ReasoningAttemptType do
    description 'A ReasoningAttempt'

    argument :id, !types.Int do
      description 'The id of the ReasoningAttempt'
Severity: Major
Found in app/graphql/types/query_type.rb and 5 other locations - About 35 mins to fix
app/graphql/types/query_type.rb on lines 157..172
app/graphql/types/query_type.rb on lines 175..190
app/graphql/types/query_type.rb on lines 223..238
app/graphql/types/query_type.rb on lines 241..256
app/graphql/types/query_type.rb on lines 259..274

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

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

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

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

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

Refactorings

Further Reading

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

  field :serialization, Types::SerializationType do
    description 'A Serialization for the given ID'

    argument :id, !types.ID do
      description 'The ID of the Serialization'
Severity: Minor
Found in app/graphql/types/query_type.rb and 5 other locations - About 20 mins to fix
app/graphql/types/query_type.rb on lines 97..105
app/graphql/types/query_type.rb on lines 109..117
app/graphql/types/query_type.rb on lines 121..129
app/graphql/types/query_type.rb on lines 133..141
app/graphql/types/query_type.rb on lines 211..219

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

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

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

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

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

Refactorings

Further Reading

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

  field :logic, Types::LogicType do
    description 'A Logic for the given ID'

    argument :id, !types.ID do
      description 'The ID of the Langauge'
Severity: Minor
Found in app/graphql/types/query_type.rb and 5 other locations - About 20 mins to fix
app/graphql/types/query_type.rb on lines 97..105
app/graphql/types/query_type.rb on lines 109..117
app/graphql/types/query_type.rb on lines 133..141
app/graphql/types/query_type.rb on lines 145..153
app/graphql/types/query_type.rb on lines 211..219

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

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

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

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

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

Refactorings

Further Reading

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

  field :logicMapping, Types::LogicMappingType do
    description 'A LogicMapping for the given ID'

    argument :id, !types.ID do
      description 'The ID of the LogicMapping'
Severity: Minor
Found in app/graphql/types/query_type.rb and 5 other locations - About 20 mins to fix
app/graphql/types/query_type.rb on lines 97..105
app/graphql/types/query_type.rb on lines 109..117
app/graphql/types/query_type.rb on lines 121..129
app/graphql/types/query_type.rb on lines 145..153
app/graphql/types/query_type.rb on lines 211..219

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

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

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

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

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

Refactorings

Further Reading

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

  field :reasoner, Types::ReasonerType do
    description 'A Reasoner'

    argument :id, !types.ID do
      description 'The id of the Reasoner'
Severity: Minor
Found in app/graphql/types/query_type.rb and 5 other locations - About 20 mins to fix
app/graphql/types/query_type.rb on lines 97..105
app/graphql/types/query_type.rb on lines 109..117
app/graphql/types/query_type.rb on lines 121..129
app/graphql/types/query_type.rb on lines 133..141
app/graphql/types/query_type.rb on lines 145..153

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

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

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

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

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

Refactorings

Further Reading

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

  field :language, Types::LanguageType do
    description 'A Language for the given ID'

    argument :id, !types.ID do
      description 'The ID of the Langauge'
Severity: Minor
Found in app/graphql/types/query_type.rb and 5 other locations - About 20 mins to fix
app/graphql/types/query_type.rb on lines 109..117
app/graphql/types/query_type.rb on lines 121..129
app/graphql/types/query_type.rb on lines 133..141
app/graphql/types/query_type.rb on lines 145..153
app/graphql/types/query_type.rb on lines 211..219

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

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

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

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

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

Refactorings

Further Reading

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

  field :languageMapping, Types::LanguageMappingType do
    description 'A LanguageMapping for the given ID'

    argument :id, !types.Int do
      description 'The ID of the LangaugeMapping'
Severity: Minor
Found in app/graphql/types/query_type.rb and 5 other locations - About 20 mins to fix
app/graphql/types/query_type.rb on lines 97..105
app/graphql/types/query_type.rb on lines 121..129
app/graphql/types/query_type.rb on lines 133..141
app/graphql/types/query_type.rb on lines 145..153
app/graphql/types/query_type.rb on lines 211..219

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

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

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

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

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

Refactorings

Further Reading

There are no issues that match your filters.

Category
Status