OpenHPS/openhps-rdf

View on GitHub

Showing 207 of 207 total issues

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

const urn_comunica_default_query_result_serialize_actors_table = new (require('@comunica/actor-query-result-serialize-table').ActorQueryResultSerializeTable)({
  'columnWidth': 50,
  'mediaTypePriorities': {"table":0.6},
  'mediaTypeFormats': {"table":"https://comunica.linkeddatafragments.org/#results_table"},
  'name': 'urn:comunica:default:query-result-serialize/actors#table',
Severity: Major
Found in src/service/engine-default.js and 1 other location - About 1 hr to fix
src/service/engine-minimal.js on lines 158..164

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 57.

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

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

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

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

Refactorings

Further Reading

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

const urn_comunica_default_query_result_serialize_actors_stats = new (require('@comunica/actor-query-result-serialize-stats').ActorQueryResultSerializeStats)({
  'httpObserver': https___linkedsoftwaredependencies_org_bundles_npm__comunica_actor_query_result_serialize_stats__2_0_0_components_ActorQueryResultSerializeStats_jsonld_ActorQueryResultSerializeStats_default_observer,
  'mediaTypePriorities': {"stats":0.5},
  'mediaTypeFormats': {"stats":"https://comunica.linkeddatafragments.org/#results_stats"},
  'name': 'urn:comunica:default:query-result-serialize/actors#stats',
Severity: Major
Found in src/service/engine-default.js and 1 other location - About 1 hr to fix
src/service/engine-minimal.js on lines 918..924

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

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

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

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

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

Refactorings

Further Reading

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

const urn_comunica_default_query_result_serialize_actors_table = new (require('@comunica/actor-query-result-serialize-table').ActorQueryResultSerializeTable)({
  'columnWidth': 50,
  'mediaTypePriorities': {"table":0.6},
  'mediaTypeFormats': {"table":"https://comunica.linkeddatafragments.org/#results_table"},
  'name': 'urn:comunica:default:query-result-serialize/actors#table',
Severity: Major
Found in src/service/engine-minimal.js and 1 other location - About 1 hr to fix
src/service/engine-default.js on lines 158..164

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 57.

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

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

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

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

Refactorings

Further Reading

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

const urn_comunica_default_rdf_parse_actors_rdfxml = new (require('@comunica/actor-rdf-parse-rdfxml').ActorRdfParseRdfXml)({
  'mediaTypePriorities': {"application/rdf+xml":1},
  'mediaTypeFormats': {"application/rdf+xml":"http://www.w3.org/ns/formats/RDF_XML"},
  'priorityScale': 0.5,
  'name': 'urn:comunica:default:rdf-parse/actors#rdfxml',
Severity: Major
Found in src/service/engine-minimal.js and 1 other location - About 1 hr to fix
src/service/engine-default.js on lines 287..293

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

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

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

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

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

Refactorings

Further Reading

Function regexPatterns has 26 lines of code (exceeds 25 allowed). Consider refactoring.
Open

                    (predicate) => {
                        return [
                            {
                                type: 'bgp',
                                triples: [
Severity: Minor
Found in src/service/SPARQLGenerator.ts - About 1 hr to fix

    Function loadClasses has 26 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        protected static loadClasses(module: NodeModule = require.main): void {
            if (module === undefined) {
                // Use cache instead
                Object.values(require.cache).map((m) => this.loadClasses(m));
                return;
    Severity: Minor
    Found in src/rdf/RDFModelSerializer.ts - About 1 hr to fix

      Function serializer has 26 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

              serializer: (pos: GeographicalPosition) => {
                  if (pos.altitude) {
                      return {
                          predicates: {
                              [ogc.asWKT]: [
      Severity: Minor
      Found in src/mapping/GeographicalPosition.ts - About 1 hr to fix

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

            protected serializeMap(
                sourceObject: Map<any, any>,
                typeDescriptor?: MapTypeDescriptor,
                memberName?: string,
                _?: Serializer,
        Severity: Major
        Found in src/rdf/InternalRDFSerializer.ts and 1 other location - About 1 hr to fix
        src/rdf/InternalRDFSerializer.ts on lines 304..315

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

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

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

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

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

        Refactorings

        Further Reading

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

        const urn_comunica_default_rdf_join_actors_inner_multi_bind = new (require('@comunica/actor-rdf-join-inner-multi-bind').ActorRdfJoinMultiBind)({
          'bindOrder': 'depth-first',
          'selectivityModifier': 0.0001,
          'mediatorJoinEntriesSort': urn_comunica_default_rdf_join_entries_sort_mediators_main,
          'mediatorQueryOperation': urn_comunica_default_query_operation_mediators_main,
        Severity: Major
        Found in src/service/engine-minimal.js and 1 other location - About 1 hr to fix
        src/service/engine-default.js on lines 748..756

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

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

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

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

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

        Refactorings

        Further Reading

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

                    const memberOptions =
                        member.options && member.options.rdf
                            ? member
                            : rootMember && rootMember.options && rootMember.options.rdf
                              ? rootMember
        Severity: Major
        Found in src/rdf/InternalRDFDeserializer.ts and 1 other location - About 1 hr to fix
        src/rdf/InternalRDFSerializer.ts on lines 218..223

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

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

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

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

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

        Refactorings

        Further Reading

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

        const urn_comunica_default_rdf_join_actors_inner_multi_bind = new (require('@comunica/actor-rdf-join-inner-multi-bind').ActorRdfJoinMultiBind)({
          'bindOrder': 'depth-first',
          'selectivityModifier': 0.0001,
          'mediatorJoinEntriesSort': urn_comunica_default_rdf_join_entries_sort_mediators_main,
          'mediatorQueryOperation': urn_comunica_default_query_operation_mediators_main,
        Severity: Major
        Found in src/service/engine-default.js and 1 other location - About 1 hr to fix
        src/service/engine-minimal.js on lines 748..756

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

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

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

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

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

        Refactorings

        Further Reading

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

                        const memberOptions =
                            member.options && member.options.rdf
                                ? member
                                : rootMember && rootMember.options && rootMember.options.rdf
                                  ? rootMember
        Severity: Major
        Found in src/rdf/InternalRDFSerializer.ts and 1 other location - About 1 hr to fix
        src/rdf/InternalRDFDeserializer.ts on lines 223..228

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

        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

            protected serializeSet(
                sourceObject: Map<any, any>,
                typeDescriptor?: MapTypeDescriptor,
                memberName?: string,
                _?: Serializer,
        Severity: Major
        Found in src/rdf/InternalRDFSerializer.ts and 1 other location - About 1 hr to fix
        src/rdf/InternalRDFSerializer.ts on lines 291..302

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

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

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

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

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

        Refactorings

        Further Reading

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

            protected serializeLiteral(
                sourceObject: any,
                typeDescriptor?: TypeDescriptor,
                memberName?: string,
                serializer?: Serializer,
        Severity: Minor
        Found in src/rdf/InternalRDFSerializer.ts - About 55 mins to fix

        Cognitive Complexity

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

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

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

        Further reading

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

                '@openhps/video': module ?  "./openhps-video.es" + (env.prod ? ".min" : "") + ".js" : {
                  commonjs: '@openhps/video',
                  commonjs2: '@openhps/video',
                  amd: 'video',
                  root: ['OpenHPS', 'video']
        Severity: Major
        Found in webpack.config.js and 3 other locations - About 55 mins to fix
        webpack.config.js on lines 84..89
        webpack.config.js on lines 90..95
        webpack.config.js on lines 102..107

        Duplicated Code

        Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

        Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

        When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

        Tuning

        This issue has a mass of 53.

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

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

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

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

        Refactorings

        Further Reading

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

                '@openhps/fingerprinting': module ?  "./openhps-fingerprinting.es" + (env.prod ? ".min" : "") + ".js" : {
                  commonjs: '@openhps/fingerprinting',
                  commonjs2: '@openhps/fingerprinting',
                  amd: 'fingerprinting',
                  root: ['OpenHPS', 'fingerprinting']
        Severity: Major
        Found in webpack.config.js and 3 other locations - About 55 mins to fix
        webpack.config.js on lines 84..89
        webpack.config.js on lines 90..95
        webpack.config.js on lines 96..101

        Duplicated Code

        Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

        Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

        When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

        Tuning

        This issue has a mass of 53.

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

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

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

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

        Refactorings

        Further Reading

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

                '@openhps/rf': module ?  "./openhps-rf.es" + (env.prod ? ".min" : "") + ".js" : {
                  commonjs: '@openhps/rf',
                  commonjs2: '@openhps/rf',
                  amd: 'rf',
                  root: ['OpenHPS', 'rf']
        Severity: Major
        Found in webpack.config.js and 3 other locations - About 55 mins to fix
        webpack.config.js on lines 84..89
        webpack.config.js on lines 96..101
        webpack.config.js on lines 102..107

        Duplicated Code

        Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

        Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

        When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

        Tuning

        This issue has a mass of 53.

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

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

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

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

        Refactorings

        Further Reading

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

                '@openhps/geospatial': module ?  "./openhps-geospatial.es" + (env.prod ? ".min" : "") + ".js" : {
                  commonjs: '@openhps/geospatial',
                  commonjs2: '@openhps/geospatial',
                  amd: 'geospatial',
                  root: ['OpenHPS', 'geospatial']
        Severity: Major
        Found in webpack.config.js and 3 other locations - About 55 mins to fix
        webpack.config.js on lines 90..95
        webpack.config.js on lines 96..101
        webpack.config.js on lines 102..107

        Duplicated Code

        Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

        Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

        When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

        Tuning

        This issue has a mass of 53.

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

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

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

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

        Refactorings

        Further Reading

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

        const urn_comunica_default_query_result_serialize_actors_sparql_xml = new (require('@comunica/actor-query-result-serialize-sparql-xml').ActorQueryResultSerializeSparqlXml)({
          'mediaTypePriorities': {"application/sparql-results+xml":0.8},
          'mediaTypeFormats': {"application/sparql-results+xml":"http://www.w3.org/ns/formats/SPARQL_Results_XML"},
          'name': 'urn:comunica:default:query-result-serialize/actors#sparql-xml',
          'bus': https___linkedsoftwaredependencies_org_bundles_npm__comunica_bus_query_result_serialize__2_0_0_components_ActorQueryResultSerialize_jsonld_ActorQueryResultSerialize_default_bus
        Severity: Major
        Found in src/service/engine-default.js and 11 other locations - About 50 mins to fix
        src/service/engine-default.js on lines 128..133
        src/service/engine-default.js on lines 134..139
        src/service/engine-default.js on lines 140..145
        src/service/engine-default.js on lines 146..151
        src/service/engine-default.js on lines 165..170
        src/service/engine-minimal.js on lines 128..133
        src/service/engine-minimal.js on lines 134..139
        src/service/engine-minimal.js on lines 140..145
        src/service/engine-minimal.js on lines 146..151
        src/service/engine-minimal.js on lines 152..157
        src/service/engine-minimal.js on lines 165..170

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

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

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

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

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

        Refactorings

        Further Reading

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

        const urn_comunica_default_rdf_resolve_quad_pattern_actors_string_source = new (require('@comunica/actor-rdf-resolve-quad-pattern-string-source').ActorRdfResolveQuadPatternStringSource)({
          'cacheSize': 100,
          'mediatorRdfParse': urn_comunica_default_rdf_parse_mediators_parse,
          'mediatorRdfResolveQuadPattern': urn_comunica_default_rdf_resolve_quad_pattern_mediators_main,
          'name': 'urn:comunica:default:rdf-resolve-quad-pattern/actors#string-source',
        Severity: Minor
        Found in src/service/engine-minimal.js and 1 other location - About 50 mins to fix
        src/service/engine-default.js on lines 932..941

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

        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