juanmard/icestudio

View on GitHub

Showing 203 of 447 total issues

File joint.shapes.js has 2554 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/* eslint-disable new-cap */

var os = require('os');
var sha1 = require('sha1');
var marked = require('marked');
Severity: Major
Found in graphics/joint.shapes.js - About 1 wk to fix

    File blocks.js has 1613 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    angular
      .module('icestudio')
      .service('blocks', function ($log, joint, utils, common, gettextCatalog) {
        'use strict';
    
    
    Severity: Major
    Found in services/blocks.js - About 4 days to fix

      File graph.js has 1482 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      /* eslint-disable new-cap */
      
      angular
        .module('icestudio')
        .service(
      Severity: Major
      Found in services/graph.js - About 3 days to fix

        Function createPaper has 542 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

              this.createPaper = function (element) {
                graph = new joint.dia.Graph();
        
                paper = new joint.dia.Paper({
                  el: element,
        Severity: Major
        Found in services/graph.js - About 2 days to fix

          File menu.js has 981 lines of code (exceeds 250 allowed). Consider refactoring.
          Open

          /* eslint-disable camelcase */
          
          angular
            .module('icestudio')
            .controller(
          Severity: Major
          Found in controllers/menu.js - About 2 days to fix

            File tools.js has 956 lines of code (exceeds 250 allowed). Consider refactoring.
            Open

            angular
              .module('icestudio')
              .service(
                'tools',
                function (
            Severity: Major
            Found in services/tools.js - About 2 days to fix

              Function ice has a Cognitive Complexity of 114 (exceeds 5 allowed). Consider refactoring.
              Open

              joint.routers.ice = (function (g, _, joint) {
                'use strict';
              
                var config = {
                  // size of the step to find a route
              Severity: Minor
              Found in graphics/joint.routers.js - About 2 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

              File compiler.js has 929 lines of code (exceeds 250 allowed). Consider refactoring.
              Open

              angular
                .module('icestudio')
                .service('compiler', function (common, utils, _package) {
                  'use strict';
              
              
              Severity: Major
              Found in services/compiler.js - About 2 days to fix

                Function ice has 397 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                joint.routers.ice = (function (g, _, joint) {
                  'use strict';
                
                  var config = {
                    // size of the step to find a route
                Severity: Major
                Found in graphics/joint.routers.js - About 1 day to fix

                  Function ICEpm has 312 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                  var ICEpm = new (function () {
                    'use strict';
                  
                    this.pluginDir = false;
                    this.pluginUri = false;
                  Severity: Major
                  Found in iceplugmanager.js - About 1 day to fix

                    File project.js has 684 lines of code (exceeds 250 allowed). Consider refactoring.
                    Open

                    angular
                      .module('icestudio')
                      .service(
                        'project',
                        function (
                    Severity: Major
                    Found in services/project.js - About 1 day to fix

                      Function processResult has 310 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                            function processResult(result, code) {
                              result = result || {};
                              var _error = result.error;
                              var stdout = result.stdout;
                              var stderr = result.stderr;
                      Severity: Major
                      Found in services/tools.js - About 1 day to fix

                        Function ICEpm has a Cognitive Complexity of 72 (exceeds 5 allowed). Consider refactoring.
                        Open

                        var ICEpm = new (function () {
                          'use strict';
                        
                          this.pluginDir = false;
                          this.pluginUri = false;
                        Severity: Minor
                        Found in iceplugmanager.js - About 1 day 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 updateBifurcations has a Cognitive Complexity of 67 (exceeds 5 allowed). Consider refactoring.
                        Open

                          updateBifurcations: function () {
                            'use strict';
                        
                            if (this._V.markerBifurcations) {
                              var self = this;
                        Severity: Minor
                        Found in graphics/joint.shapes.js - About 1 day 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

                        File utils.js has 605 lines of code (exceeds 250 allowed). Consider refactoring.
                        Open

                        angular
                          .module('icestudio')
                          .service(
                            'utils',
                            function (
                        Severity: Major
                        Found in services/utils.js - About 1 day to fix

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

                          module.exports = function (grunt) {
                            'use strict';
                          
                            var platforms = [];
                            var distCommands = [];
                          Severity: Major
                          Found in gruntfile.js - About 1 day to fix

                            Function updateBox has 202 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                              updateBox: function () {
                                'use strict';
                            
                                var pendingTasks = [];
                                var i, j, port, portDefault, tokId, paths, rects, dome, anotations;
                            Severity: Major
                            Found in graphics/joint.shapes.js - About 1 day to fix

                              Function newBasicCode has 186 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  function newBasicCode(callback, block) {
                                    var blockInstance = {
                                      id: null,
                                      data: {
                                        code: '',
                              Severity: Major
                              Found in services/blocks.js - About 7 hrs to fix

                                Function updateBox has a Cognitive Complexity of 48 (exceeds 5 allowed). Consider refactoring.
                                Open

                                  updateBox: function () {
                                    'use strict';
                                
                                    var pendingTasks = [];
                                    var i, j, port, portDefault, tokId, paths, rects, dome, anotations;
                                Severity: Minor
                                Found in graphics/joint.shapes.js - About 7 hrs 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 updateBox has 182 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                  updateBox: function () {
                                    'use strict';
                                
                                    var pendingTasks = [];
                                    var i, j, port;
                                Severity: Major
                                Found in graphics/joint.shapes.js - About 7 hrs to fix
                                  Severity
                                  Category
                                  Status
                                  Source
                                  Language