codenautas/qa-control

View on GitHub
bin/0.1.3/definition.js

Summary

Maintainability
F
1 mo
Test Coverage

Function exports has a Cognitive Complexity of 187 (exceeds 5 allowed). Consider refactoring.
Open

module.exports = function(qaControl){
    return {
        fileNameMainDoc: 'LEEME.md',
        sections: { // podria llamarse 'json-sections'...
            'run-in': {
Severity: Minor
Found in bin/0.1.3/definition.js - About 3 days to fix

Cognitive Complexity

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

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

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

Further reading

Function exports has 603 lines of code (exceeds 25 allowed). Consider refactoring.
Open

module.exports = function(qaControl){
    return {
        fileNameMainDoc: 'LEEME.md',
        sections: { // podria llamarse 'json-sections'...
            'run-in': {
Severity: Major
Found in bin/0.1.3/definition.js - About 3 days to fix

    File definition.js has 613 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    "use strict";
    
    var stripBom = require("strip-bom-string");
    var semver = require("semver");
    var jsh = require('jshint');
    Severity: Major
    Found in bin/0.1.3/definition.js - About 1 day to fix

      Function warnings has 37 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

                          warnings:function(info) {
                              var warns=[];
                              var customs = qaControl.projectDefinition[info.packageVersion].customs;
                              function makeCheck(strOrRegexp, isMatchFunc) {
                                  var checker;
      Severity: Minor
      Found in bin/0.1.3/definition.js - About 1 hr to fix

        Function warnings has 35 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

                            warnings:function(info) {
                                var warns=[];
                                var qaControlSection=info.packageJson['qa-control'];
                                var whichRunIn=qaControlSection['run-in'];
                                var whichType=qaControlSection.type;
        Severity: Minor
        Found in bin/0.1.3/definition.js - About 1 hr to fix

          Function warnings has 29 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                              warnings:function(info){
                                  var warns=[];
                                  var readme=info.files[qaControl.mainDoc()].content;
                                  if(readme.indexOf(qaControl.cucaMarker) === -1) {
                                      warns.push({warning:'lack_of_cucarda_marker_in_readme'});
          Severity: Minor
          Found in bin/0.1.3/definition.js - About 1 hr to fix

            Avoid deeply nested control flow statements.
            Open

                                                    for(var i=0; i<model1.length; i++){
                                                        if(code[i]!== model1[i] && code[i] !== model2[i]){
                                                            console.log('RUN-IN', whichRunIn);
                                                            console.log('DIF STARTS IN:',JSON.stringify(code.substring(i, Math.min(model1.length, i+20))));
                                                            console.log('MODEL 1      :',JSON.stringify(model1.substring(i, Math.min(model1.length, i+20))));
            Severity: Major
            Found in bin/0.1.3/definition.js - About 45 mins to fix

              Avoid deeply nested control flow statements.
              Open

                                                      if(detect(content) && ! match(content)) {
                                                          warns.push({warning:'file_1_does_not_match_custom_2', params:[file,customeName], scoring:{customs:1}});
                                                      }
              Severity: Major
              Found in bin/0.1.3/definition.js - About 45 mins to fix

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

                            first_lines:{
                                checks:[{
                                    warnings:function(info) {
                                        var warns=[];
                                        var qaControlSection=info.packageJson['qa-control'];
                Severity: Major
                Found in bin/0.1.3/definition.js and 1 other location - About 3 days to fix
                bin/0.0.1/definition.js on lines 427..468

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

                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

                            cucardas:{
                                eclipsers:['invalid_repository_section_in_package_json', 'lack_of_repository_section_in_package_json'],
                                checks:[{
                                    warnings:function(info){
                                        var warns=[];
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 3 days to fix
                bin/0.0.1/definition.js on lines 343..382
                bin/0.0.2/definition.js on lines 355..394
                bin/0.1.4/definition.js on lines 390..429

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

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

                            customs:{
                                checks:[{
                                    warnings:function(info) {
                                        var warns=[];
                                        var customs = qaControl.projectDefinition[info.packageVersion].customs;
                Severity: Major
                Found in bin/0.1.3/definition.js and 2 other locations - About 2 days to fix
                bin/0.0.1/definition.js on lines 383..426
                bin/0.1.4/definition.js on lines 430..473

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

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

                            jshint:{
                                eclipsers:['packagejson_main_file_1_does_not_exists', 'first_lines_does_not_match_in_file_1',
                                           'lack_of_jshintconfig_section_in_package_json', 'incorrect_jshintconfig_option_1_in_package_json'],
                                checks:[{
                                    warnings:function(info){
                Severity: Major
                Found in bin/0.1.3/definition.js and 2 other locations - About 1 day to fix
                bin/0.0.1/definition.js on lines 497..526
                bin/0.1.4/definition.js on lines 557..586

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

                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

                            eslint:{
                                eclipsers:['packagejson_main_file_1_does_not_exists', 'first_lines_does_not_match_in_file_1',
                                           'lack_of_eslintconfig_section_in_package_json', 'incorrect_eslintconfig_option_1_in_package_json'],
                                checks:[{
                                    warnings:function(info){
                Severity: Major
                Found in bin/0.1.3/definition.js and 1 other location - About 1 day to fix
                bin/0.1.4/definition.js on lines 587..615

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

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

                            mandatory_files:{
                                checks:[{
                                    warnings:function(info) {
                                        var warns =[];
                                        var files=qaControl.projectDefinition[info.packageVersion].files;
                Severity: Major
                Found in bin/0.1.3/definition.js and 2 other locations - About 1 day to fix
                bin/0.0.1/definition.js on lines 231..252
                bin/0.1.4/definition.js on lines 268..289

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

                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

                            valid_values_for_qa_control_keys:{
                                checks:[{
                                    warnings:function(info){
                                        var warns=[];
                                        var qaControlSection=info.packageJson['qa-control'];
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 1 day to fix
                bin/0.0.1/definition.js on lines 269..292
                bin/0.0.2/definition.js on lines 271..294
                bin/0.1.4/definition.js on lines 306..329

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

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

                            multilang:{
                                checks:[{
                                    warnings:function(info) {
                                        var warns = [];
                                        var defReadme = qaControl.mainDoc();
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 1 day to fix
                bin/0.0.1/definition.js on lines 527..548
                bin/0.0.2/definition.js on lines 548..569
                bin/0.1.4/definition.js on lines 616..637

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

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

                            mandatory_lines:{
                                checks:[{
                                    warnings:function(info) {
                                        var warns =[];
                                        var files=qaControl.projectDefinition[info.packageVersion].files;
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 1 day to fix
                bin/0.0.1/definition.js on lines 293..315
                bin/0.0.2/definition.js on lines 295..317
                bin/0.1.4/definition.js on lines 330..352

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

                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

                            repository_in_package_json:{
                                checks:[{
                                    warnings:function(info) {
                                        var warns = [];
                                        if(!('repository' in info.packageJson)) {
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 5 hrs to fix
                bin/0.0.1/definition.js on lines 253..268
                bin/0.0.2/definition.js on lines 255..270
                bin/0.1.4/definition.js on lines 290..305

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

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

                            normal_promises:{
                                checks:[{
                                    warnings:function(info){
                                        var warns = [];
                                        for(var file in info.files) {
                Severity: Major
                Found in bin/0.1.3/definition.js and 2 other locations - About 5 hrs to fix
                bin/0.0.1/definition.js on lines 469..484
                bin/0.1.4/definition.js on lines 517..532

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

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

                        customs:{
                            softRegExp:function(realRegex) {
                                var re=realRegex.replace(/\\/g, '\\\\')
                                                .replace(/\s*(=+)\s*/g,'\\s*$1\\s*')
                                                .replace(/ /g, '\\s+')
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 5 hrs to fix
                bin/0.0.1/definition.js on lines 131..153
                bin/0.0.2/definition.js on lines 131..153
                bin/0.1.4/definition.js on lines 158..180

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

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

                            invalid_repository_in_package_json:{
                                checks:[{
                                    warnings:function(info) {
                                        var warns = [];
                                        var repoParts = qaControl.getRepositoryUrl(info.packageJson).split('/');
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 4 hrs to fix
                bin/0.0.1/definition.js on lines 330..342
                bin/0.0.2/definition.js on lines 342..354
                bin/0.1.4/definition.js on lines 377..389

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

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

                            package_version_in_qa_control_section:{
                                checks:[{
                                    warnings:function(info){
                                        if(!info.packageJson['qa-control']['package-version']){
                                            return [{warning:'no_package_version_in_qa_control_section', scoring:{qac:1}}];
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 3 hrs to fix
                bin/0.0.1/definition.js on lines 193..206
                bin/0.0.2/definition.js on lines 193..206
                bin/0.1.4/definition.js on lines 230..243

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

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

                            no_multilang_section_in_1:{
                                checks:[{
                                    warnings:function(info){
                                        if(!info.files[qaControl.mainDoc()].content.match(/<!--multilang v[0-9]+\s+(.+)(-->)/)) {
                                            return [{
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 3 hrs to fix
                bin/0.0.1/definition.js on lines 316..329
                bin/0.0.2/definition.js on lines 328..341
                bin/0.1.4/definition.js on lines 363..376

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

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

                        files:{
                            'README.md':{ mandatory:true },
                            'LEEME.md':{ mandatory:true },
                            '.travis.yml':{ mandatory:true },
                            '.gitignore':{
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 3 hrs to fix
                bin/0.0.1/definition.js on lines 31..45
                bin/0.0.2/definition.js on lines 31..45
                bin/0.1.4/definition.js on lines 32..46

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

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

                            qa_control_section_in_package_json:{
                                checks:[{
                                    warnings:function(info){
                                        if(!info.packageJson['qa-control']){
                                            return [{warning:info.files['package.json'].content.match(/codenautas/)?
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 3 hrs to fix
                bin/0.0.1/definition.js on lines 180..192
                bin/0.0.2/definition.js on lines 180..192
                bin/0.1.4/definition.js on lines 217..229

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

                            deprecated_control_version: {
                                checks:[{
                                    warnings:function(info) {
                                        var ver=info.packageVersion;
                                        if(semver.satisfies(ver, qaControl.deprecatedVersions)){
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 2 hrs to fix
                bin/0.0.1/definition.js on lines 219..230
                bin/0.0.2/definition.js on lines 219..230
                bin/0.1.4/definition.js on lines 256..267

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

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

                            invalid_qa_control_version: {
                                checks:[{
                                    warnings:function(info){
                                        var ver=info.packageVersion;
                                        if(! semver.valid(ver)){
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 2 hrs to fix
                bin/0.0.1/definition.js on lines 207..218
                bin/0.0.2/definition.js on lines 207..218
                bin/0.1.4/definition.js on lines 244..255

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

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

                        sections: { // podria llamarse 'json-sections'...
                            'run-in': {
                                mandatory: true,
                                values: {
                                    server:{},
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 2 hrs to fix
                bin/0.0.1/definition.js on lines 13..30
                bin/0.0.2/definition.js on lines 13..30
                bin/0.1.4/definition.js on lines 14..31

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

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

                            exist_package_json:{
                                checks:[{
                                    warnings:function(info){
                                        if(!info.files['package.json']){
                                            return [{warning:'no_package_json', scoring:{mandatories:1}}];
                Severity: Major
                Found in bin/0.1.3/definition.js and 3 other locations - About 1 hr to fix
                bin/0.0.1/definition.js on lines 169..179
                bin/0.0.2/definition.js on lines 169..179
                bin/0.1.4/definition.js on lines 206..216

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

                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

                            eslint_config:{
                                checks:[{
                                    warnings:function(info){
                                        return qaControl.checkLintConfig(info,
                                                                         'eslintConfig',
                Severity: Major
                Found in bin/0.1.3/definition.js and 5 other locations - About 1 hr to fix
                bin/0.0.1/definition.js on lines 485..496
                bin/0.0.2/definition.js on lines 504..515
                bin/0.1.3/definition.js on lines 532..543
                bin/0.1.4/definition.js on lines 533..544
                bin/0.1.4/definition.js on lines 545..556

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

                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

                            jshint_config:{
                                checks:[{
                                    warnings:function(info){
                                        return qaControl.checkLintConfig(info,
                                                                         'jshintConfig',
                Severity: Major
                Found in bin/0.1.3/definition.js and 5 other locations - About 1 hr to fix
                bin/0.0.1/definition.js on lines 485..496
                bin/0.0.2/definition.js on lines 504..515
                bin/0.1.3/definition.js on lines 544..555
                bin/0.1.4/definition.js on lines 533..544
                bin/0.1.4/definition.js on lines 545..556

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

                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

                            stable:{
                                check: function(packageJson){ 
                                    return semver.satisfies(packageJson.version,'>=1.0.0') && !packageJson['qa-control'].purpose;
                                },
                                md:'![stable](https://img.shields.io/badge/stability-stable-brightgreen.svg)',
                Severity: Major
                Found in bin/0.1.3/definition.js and 1 other location - About 1 hr to fix
                bin/0.1.4/definition.js on lines 87..93

                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

                There are no issues that match your filters.

                Category
                Status