Showing 551 of 2,707 total issues
File jquery.js
has 6829 lines of code (exceeds 250 allowed). Consider refactoring. Open
/*!
* jQuery JavaScript Library v1.11.1
* http://jquery.com/
*
* Includes Sizzle.js
File jquery-1.11.1.min.js
has 6829 lines of code (exceeds 250 allowed). Consider refactoring. Open
/*!
* jQuery JavaScript Library v1.11.1
* http://jquery.com/
*
* Includes Sizzle.js
Function Sizzle
has 1347 lines of code (exceeds 25 allowed). Consider refactoring. Open
(function( window ) {
var i,
support,
Expr,
Function Sizzle
has 1347 lines of code (exceeds 25 allowed). Consider refactoring. Open
(function( window ) {
var i,
support,
Expr,
Function autocomplete
has a Cognitive Complexity of 198 (exceeds 5 allowed). Consider refactoring. Open
jQuery.autocomplete = function(input, options) {
// Create a link to self
var me = this;
// Create jQuery object for input element
- 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 bootstrap.js
has 1387 lines of code (exceeds 250 allowed). Consider refactoring. Open
/*!
* Bootstrap v3.2.0 (http://getbootstrap.com)
* Copyright 2011-2014 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
*/
File views.py
has 1025 lines of code (exceeds 250 allowed). Consider refactoring. Open
import datetime
from django import forms
from django.conf import settings
from django.contrib import messages
from django.contrib.auth import models as auth
Function activity_handler
has a Cognitive Complexity of 122 (exceeds 5 allowed). Consider refactoring. Open
def activity_handler(cls, sender, **kwargs):
action = kwargs.get('action', None)
player = kwargs.get('user_from', None)
if player:
- 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 ajaxSubmit
has 492 lines of code (exceeds 25 allowed). Consider refactoring. Open
$.fn.ajaxSubmit = function(options) {
/*jshint scripturl:true */
// fast fail if nothing selected (http://dev.jquery.com/ticket/2752)
if (!this.length) {
Function autocomplete
has 381 lines of code (exceeds 25 allowed). Consider refactoring. Open
jQuery.autocomplete = function(input, options) {
// Create a link to self
var me = this;
// Create jQuery object for input element
File jquery.form.js
has 767 lines of code (exceeds 250 allowed). Consider refactoring. Open
/*!
* jQuery Form Plugin
* version: 3.14 (30-JUL-2012)
* @requires jQuery v1.3.2 or later
*
Function fileUploadIframe
has 337 lines of code (exceeds 25 allowed). Consider refactoring. Open
function fileUploadIframe(a) {
var form = $form[0], el, i, s, g, id, $io, io, xhr, sub, n, timedOut, timeoutHandle;
var useProp = !!$.fn.prop;
if ($(':input[name=submit],:input[id=submit]', form).length) {
File models.py
has 656 lines of code (exceeds 250 allowed). Consider refactoring. Open
import random
from datetime import datetime, time, timedelta, date
from random import shuffle
import pickle as pk
import sys
File tests.py
has 632 lines of code (exceeds 250 allowed). Consider refactoring. Open
from datetime import datetime, timedelta
from wouso.core.magic.models import Artifact, Spell, SpellHistory
from wouso.core.magic.manager import MagicManager
from wouso.core.tests import WousoTest
from wouso.core import scoring, signals
Function import_from_file
has a Cognitive Complexity of 64 (exceeds 5 allowed). Consider refactoring. Open
def import_from_file(opened_file, proposed_by=None, endorsed_by=None, category=None, tags=None, all_active=False):
# read file and parse contents
a_saved = True
q_saved = True
a = {}
- 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 ajax
has 240 lines of code (exceeds 25 allowed). Consider refactoring. Open
ajax: function( url, options ) {
// If url is an object, simulate pre-1.5 signature
if ( typeof url === "object" ) {
options = url;
Function ajax
has 240 lines of code (exceeds 25 allowed). Consider refactoring. Open
ajax: function( url, options ) {
// If url is an object, simulate pre-1.5 signature
if ( typeof url === "object" ) {
options = url;
Function setDocument
has 216 lines of code (exceeds 25 allowed). Consider refactoring. Open
setDocument = Sizzle.setDocument = function( node ) {
var hasCompare,
doc = node ? node.ownerDocument || node : preferredDoc,
parent = doc.defaultView;
Function setDocument
has 216 lines of code (exceeds 25 allowed). Consider refactoring. Open
setDocument = Sizzle.setDocument = function( node ) {
var hasCompare,
doc = node ? node.ownerDocument || node : preferredDoc,
parent = doc.defaultView;
Function import_questions_from_file
has a Cognitive Complexity of 54 (exceeds 5 allowed). Consider refactoring. Open
def import_questions_from_file(f, proposed_by=None, endorsed_by=None, category=None, tag=None, active=False):
# read file and parse contents
a_saved = True
q_saved = True
a = {}
- 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"