Showing 695 of 1,362 total issues
File codemirror.js
has 6179 lines of code (exceeds 250 allowed). Consider refactoring. Open
// CodeMirror, copyright (c) by Marijn Haverbeke and others
// Distributed under an MIT license: http://codemirror.net/LICENSE
// This is CodeMirror (http://codemirror.net), a code editor
// implemented in JavaScript on top of the browser's DOM.
File raphael.js
has 5649 lines of code (exceeds 250 allowed). Consider refactoring. Open
// ┌────────────────────────────────────────────────────────────────────┐ \\
// │ Raphaël 2.1.2 - JavaScript Vector Library │ \\
// ├────────────────────────────────────────────────────────────────────┤ \\
// │ Copyright © 2008-2012 Dmitry Baranovskiy (http://raphaeljs.com) │ \\
// │ Copyright © 2008-2012 Sencha Labs (http://sencha.com) │ \\
File 0001_squashed_0025_levels_ordering_pt1.py
has 4781 lines of code (exceeds 250 allowed). Consider refactoring. Open
from __future__ import unicode_literals
from builtins import range
from django.db import models, migrations
from django.conf import settings
Function LevelEditor
has a Cognitive Complexity of 620 (exceeds 5 allowed). Consider refactoring. Open
ocargo.LevelEditor = function(levelId) {
/*************/
/* Constants */
/*************/
- Read upRead up
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 LevelEditor
has 2076 lines of code (exceeds 25 allowed). Consider refactoring. Open
ocargo.LevelEditor = function(levelId) {
/*************/
/* Constants */
/*************/
File messages.py
has 2124 lines of code (exceeds 250 allowed). Consider refactoring. Open
from builtins import str
def level_creation_email_subject():
return "Custom level to moderate"
File level_editor.js
has 2104 lines of code (exceeds 250 allowed). Consider refactoring. Open
'use strict';
var ocargo = ocargo || {};
ocargo.LevelEditor = function(levelId) {
Function Drawing
has a Cognitive Complexity of 205 (exceeds 5 allowed). Consider refactoring. Open
ocargo.Drawing = function (startingPosition) {
/*************/
/* Constants */
/*************/
- Read upRead up
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 Drawing
has 803 lines of code (exceeds 25 allowed). Consider refactoring. Open
ocargo.Drawing = function (startingPosition) {
/*************/
/* Constants */
/*************/
Function factory
has 725 lines of code (exceeds 25 allowed). Consider refactoring. Open
var factory = function( $, DataTable ) {
"use strict";
/**
* When making use of DataTables' x-axis scrolling feature, you may wish to
File handlebars.runtime-v4.7.7.js
has 1146 lines of code (exceeds 250 allowed). Consider refactoring. Open
/**!
@license
handlebars v4.7.7
File game.js
has 1131 lines of code (exceeds 250 allowed). Consider refactoring. Open
'use strict'
var ocargo = ocargo || {}
ocargo.Game = function () {
Function setupToolbox
has 550 lines of code (exceeds 25 allowed). Consider refactoring. Open
function setupToolbox() {
var tabs = [];
var currentTabSelected = null;
tabs.play = new ocargo.Tab($('#play_radio'), $("#run-code-button"), $('#play_radio + label'));
TestPlayThrough
has 137 functions (exceeds 20 allowed). Consider refactoring. Open
class TestPlayThrough(BaseGameTest):
def setUp(self):
self.login_once()
def _complete_episode(self, episode_number, level_number, **kwargs):
File drawing.js
has 1018 lines of code (exceeds 250 allowed). Consider refactoring. Open
'use strict'
var ocargo = ocargo || {}
let GRID_WIDTH = 10
Function initCustomBlocksDescription
has 441 lines of code (exceeds 25 allowed). Consider refactoring. Open
function initCustomBlocksDescription() {
Blockly.Blocks["start"] = {
// Beginning block - identifies the start of the program
init: function () {
ocargo.blocklyControl.numStartBlocks++;
Function BlocklyCustomisations
has a Cognitive Complexity of 99 (exceeds 5 allowed). Consider refactoring. Open
ocargo.BlocklyCustomisations = function () {
const TOOLBOX_REMAINING_CAPACITY_TEXT_COLUMN_WIDTH = 50;
var limitedBlocks = false;
- Read upRead up
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 generate_random_path
has a Cognitive Complexity of 92 (exceeds 5 allowed). Consider refactoring. Open
def generate_random_path(num_road_tiles, branchiness_factor, loopiness_factor, curviness_factor):
def pick_adjacent_node(nodes, connections, branchiness_factor, curviness_factor):
for attempts in range(5):
origin = pick_origin_node(nodes, connections, branchiness_factor)
possibles = []
- Read upRead up
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 dataTables.fixedColumns.js
has 739 lines of code (exceeds 250 allowed). Consider refactoring. Open
/*! FixedColumns 3.0.4
* ©2010-2014 SpryMedia Ltd - datatables.net/license
*/
/**
File foundation.joyride.js
has 732 lines of code (exceeds 250 allowed). Consider refactoring. Open
;(function ($, window, document, undefined) {
'use strict';
var Modernizr = Modernizr || false;