text
stringlengths
0
1.05M
meta
dict
from django.shortcuts import render_to_response, redirect, get_object_or_404 from django.template import RequestContext from main.models import Post from main.forms import PostForm def view(request, post_id): post = get_object_or_404(Post, id=int(post_id), active=True, parent=None) if request.method == 'POST...
{ "repo_name": "RodolpheOrg/Rodolphe", "path": "rodolphe/main/views/thread.py", "copies": "2", "size": "1163", "license": "bsd-2-clause", "hash": -1012057086153859300, "line_mean": 29.6052631579, "line_max": 77, "alpha_frac": 0.6018916595, "autogenerated": false, "ratio": 3.8637873754152823, "co...
from django.shortcuts import render_to_response, redirect, get_object_or_404 from ...models.author import Author from ...tools import render_with_user def edit(request): if request.method == 'GET': current_user = request.session['currentUser'] if current_user is None: return render_...
{ "repo_name": "jmescuderojustel/codeyourblogin-python-django-1.7", "path": "src/blog/controllers/management/author_management.py", "copies": "1", "size": "1271", "license": "mit", "hash": -7086674880888022000, "line_mean": 33.3783783784, "line_max": 96, "alpha_frac": 0.615263572, "autogenerated": f...
from django.shortcuts import render_to_response, redirect, HttpResponseRedirect from map.map_info.models import Point, Layer, Comment from map.map_info.forms import AddPointForm, CommentForm from django.template import RequestContext from django.core.urlresolvers import reverse from django.conf import settings import o...
{ "repo_name": "haithamk/oMap", "path": "src/map/map_info/views.py", "copies": "1", "size": "5902", "license": "bsd-3-clause", "hash": 6989152707694118000, "line_mean": 36.8333333333, "line_max": 175, "alpha_frac": 0.6474076584, "autogenerated": false, "ratio": 3.8449511400651466, "config_test":...
from django.shortcuts import render_to_response, redirect from app_search.helpers.message_helper import message from django.core.context_processors import csrf from app_search.helpers.paginate_helper import Paginate from django.http import HttpResponseNotFound from django.http import HttpResponse import json from app_a...
{ "repo_name": "nakamura-akifumi/kassis_orange", "path": "app_admin/views.py", "copies": "1", "size": "6829", "license": "mit", "hash": -8959230122983791000, "line_mean": 30.9090909091, "line_max": 126, "alpha_frac": 0.5969410706, "autogenerated": false, "ratio": 3.5473404255319148, "config_test...
from django.shortcuts import render_to_response, redirect from datetime import datetime from core.views import initRequest from django.db import connection, transaction from django.http import HttpResponse from django.http import HttpResponseRedirect import json from collections import defaultdict from operator import ...
{ "repo_name": "PanDAWMS/panda-bigmon-core", "path": "core/globalpage/views.py", "copies": "1", "size": "5180", "license": "apache-2.0", "hash": 1602389673963090700, "line_mean": 44.4385964912, "line_max": 432, "alpha_frac": 0.6131274131, "autogenerated": false, "ratio": 2.683937823834197, "conf...
from django.shortcuts import render_to_response, redirect from diary.models import DiaryItem, ImageItem from django.core.context_processors import csrf from django.core.mail import send_mail from django.http import JsonResponse, HttpResponse from markdown import markdown from urllib import urlopen from icalendar import...
{ "repo_name": "DevLoL/devlol.at", "path": "devlol/views.py", "copies": "1", "size": "3886", "license": "mit", "hash": -6331081289379684000, "line_mean": 36.7281553398, "line_max": 169, "alpha_frac": 0.6698404529, "autogenerated": false, "ratio": 3.5359417652411285, "config_test": false, "has_...
from django.shortcuts import render_to_response, redirect from django.contrib.admin.views.decorators import staff_member_required from farmer.models import Task from farmer.settings import NUMBER_OF_TASK_PER_PAGE def run_task(request, inventory, cmd): task = Task() task.inventory = inventory task.cmd = cm...
{ "repo_name": "zws0932/farmer", "path": "farmer/views.py", "copies": "2", "size": "1904", "license": "mit", "hash": 904164269478348000, "line_mean": 30.2131147541, "line_max": 76, "alpha_frac": 0.6370798319, "autogenerated": false, "ratio": 3.461818181818182, "config_test": false, "has_no_key...
from django.shortcuts import render_to_response, redirect from django.contrib.auth import authenticate, login from django.core.context_processors import csrf from django.contrib.auth.decorators import login_required from django.contrib.auth import logout from django.conf import settings # # def logout_view(request): #...
{ "repo_name": "townbull/dome", "path": "acorn/views.py", "copies": "1", "size": "1174", "license": "apache-2.0", "hash": 3695750987654633000, "line_mean": 30.7567567568, "line_max": 65, "alpha_frac": 0.5928449744, "autogenerated": false, "ratio": 4.3003663003663, "config_test": false, "has_no...
from django.shortcuts import render_to_response, redirect from django.contrib.auth import logout from tiles.views import gen_context from django.template import RequestContext from django.contrib import messages from django.http import HttpResponseNotAllowed, HttpResponseRedirect import core.sync from django.conf impor...
{ "repo_name": "m3brown/pantheon", "path": "devdash/core/views.py", "copies": "5", "size": "1611", "license": "cc0-1.0", "hash": -8872953609414792000, "line_mean": 31.22, "line_max": 86, "alpha_frac": 0.7181874612, "autogenerated": false, "ratio": 4.354054054054054, "config_test": false, "has_...
from django.shortcuts import render_to_response, redirect from django.contrib import messages from django.core.urlresolvers import reverse from django.template import RequestContext from django.conf import settings import shopify def _return_address(request): return request.session.get('return_to') or reverse('roo...
{ "repo_name": "adewinter/bitpay-shopify", "path": "shopify_app/views.py", "copies": "4", "size": "1919", "license": "mit", "hash": 7596106105274928000, "line_mean": 35.2075471698, "line_max": 97, "alpha_frac": 0.6915059927, "autogenerated": false, "ratio": 4.048523206751055, "config_test": fals...
from django.shortcuts import render_to_response, redirect from django.core.mail import send_mail from django.template import RequestContext, Context from django.template.loader import get_template from django.http import Http404, HttpResponse, HttpResponseForbidden, HttpResponseRedirect from django.contrib import...
{ "repo_name": "MAPC/developmentdatabase-python", "path": "tim/views.py", "copies": "2", "size": "5712", "license": "bsd-3-clause", "hash": -8135434083062280000, "line_mean": 34.7, "line_max": 149, "alpha_frac": 0.6638655462, "autogenerated": false, "ratio": 4.045325779036827, "config_test": fal...
from django.shortcuts import render_to_response, redirect from django.core.urlresolvers import reverse from django.template import RequestContext from django.contrib.sites.models import Site def welcome(request): """ Handles site Welcome redirects behavior. It handles last opened page in session. And i...
{ "repo_name": "MVReddy/TMS", "path": "adlibre_tms/apps/accounts/views.py", "copies": "3", "size": "1734", "license": "bsd-3-clause", "hash": 2985086132126960600, "line_mean": 42.35, "line_max": 91, "alpha_frac": 0.6286043829, "autogenerated": false, "ratio": 4.724795640326976, "config_test": fa...
from django.shortcuts import render_to_response, redirect from django.core.urlresolvers import reverse from django.template import RequestContext from django.views.decorators.http import require_http_methods from django.contrib.auth import ( authenticate, login as login_user, logout as logout_user ) from dj...
{ "repo_name": "honza/wharf-ci", "path": "accounts/views.py", "copies": "1", "size": "1329", "license": "bsd-2-clause", "hash": 8385910760129365000, "line_mean": 35.9166666667, "line_max": 78, "alpha_frac": 0.6260346125, "autogenerated": false, "ratio": 4.79783393501805, "config_test": false, ...
from django.shortcuts import render_to_response, redirect from django.http import Http404 from django.contrib.auth.decorators import login_required from django.utils.decorators import method_decorator from django.template import RequestContext from django.contrib import messages from django.utils.translation import uge...
{ "repo_name": "saebyn/django-classifieds", "path": "classifieds/views/manage.py", "copies": "1", "size": "1534", "license": "bsd-3-clause", "hash": -6047455071726411000, "line_mean": 30.9583333333, "line_max": 77, "alpha_frac": 0.7059973924, "autogenerated": false, "ratio": 4.047493403693931, "...
from django.shortcuts import render_to_response, redirect from django.http import HttpResponse, HttpResponseRedirect from django.core.context_processors import csrf from django.core.urlresolvers import reverse from django.template import RequestContext from django.contrib.auth.decorators import login_required from phyl...
{ "repo_name": "NESCent/phylocommons", "path": "treeupload/views.py", "copies": "1", "size": "4435", "license": "mit", "hash": -2031386795973639000, "line_mean": 29.7986111111, "line_max": 88, "alpha_frac": 0.604735062, "autogenerated": false, "ratio": 4.053930530164534, "config_test": false, ...
from django.shortcuts import render_to_response, redirect from django.http import HttpResponse, HttpResponseRedirect from django.template.context import RequestContext from django.contrib.auth.models import User from core.models import Profile def home(request): # If a Chef installation does not exist, redirect to '...
{ "repo_name": "CampusHash/chef", "path": "chef/ui/views.py", "copies": "1", "size": "1254", "license": "mit", "hash": -1577056730051496700, "line_mean": 26.2826086957, "line_max": 69, "alpha_frac": 0.7232854864, "autogenerated": false, "ratio": 3.6138328530259365, "config_test": false, "has_n...
from django.shortcuts import render_to_response, redirect from django.http import HttpResponse from Application.models import Medico def index(request): if request.session.get('login', '') == '': #return redirect('/login') return render_to_response('Publico/index.html') else: request....
{ "repo_name": "jonathanguartan/GePTCOdont", "path": "Application/views/Index.py", "copies": "1", "size": "2849", "license": "unlicense", "hash": -8250107404040566000, "line_mean": 26.6310679612, "line_max": 97, "alpha_frac": 0.5839775123, "autogenerated": false, "ratio": 4.166910688140557, "con...
from django.shortcuts import render_to_response, redirect from django.http import HttpResponse from django.core.context_processors import csrf from django.core.paginator import Paginator, EmptyPage, PageNotAnInteger from django.template import RequestContext from phylocommons.get_treestore import get_treestore, tree_id...
{ "repo_name": "NESCent/phylocommons", "path": "treeview/views.py", "copies": "1", "size": "7144", "license": "mit", "hash": 5985933942939138000, "line_mean": 35.824742268, "line_max": 98, "alpha_frac": 0.5477323628, "autogenerated": false, "ratio": 3.844994617868676, "config_test": false, "ha...
from django.shortcuts import render_to_response, redirect from django.http import HttpResponse from django.core.context_processors import csrf from django.forms.util import ErrorList from django.forms.forms import NON_FIELD_ERRORS from django.template import RequestContext from phylocommons.get_treestore import get_tre...
{ "repo_name": "NESCent/phylocommons", "path": "treequery/views.py", "copies": "1", "size": "7443", "license": "mit", "hash": 5807694222527932000, "line_mean": 40.8146067416, "line_max": 192, "alpha_frac": 0.4678221147, "autogenerated": false, "ratio": 5.080546075085325, "config_test": false, ...
from django.shortcuts import render_to_response,redirect from django.http import HttpResponse from django.core.context_processors import csrf from forum import usersControl,forumsControl from security import securityControl from webapp import models def index(request): users = usersControl.users(request) forums = f...
{ "repo_name": "jeffersonmourak/UrgentCode", "path": "webapp/forums.py", "copies": "1", "size": "2665", "license": "mit", "hash": -4957374856933880000, "line_mean": 24.8737864078, "line_max": 80, "alpha_frac": 0.7272045028, "autogenerated": false, "ratio": 3.25, "config_test": false, "has_no_k...
from django.shortcuts import render_to_response,redirect from django.http import HttpResponse from django.core.context_processors import csrf from forum import usersControl,ForumsList from security import securityControl from webapp import models def isNotEmpty(s): return bool(s and s.strip()) def reply(request,u...
{ "repo_name": "jeffersonmourak/UrgentCode", "path": "webapp/actions.py", "copies": "1", "size": "1965", "license": "mit", "hash": 4151005994860605400, "line_mean": 25.9178082192, "line_max": 84, "alpha_frac": 0.724173028, "autogenerated": false, "ratio": 3.189935064935065, "config_test": false,...
from django.shortcuts import render_to_response, redirect from django.http import HttpResponse from django.core.exceptions import ObjectDoesNotExist from django.template import RequestContext from models import Person, User, Judgement from .forms import PersonForm from services import group_service, fake_service, perso...
{ "repo_name": "tommymcglynn/group-tinder", "path": "web/views.py", "copies": "1", "size": "2686", "license": "apache-2.0", "hash": -3990123141607060000, "line_mean": 33.8831168831, "line_max": 140, "alpha_frac": 0.6615785555, "autogenerated": false, "ratio": 4.057401812688822, "config_test": fa...
from django.shortcuts import render_to_response, redirect from django import forms from django.template import RequestContext from . import models class BankForm(forms.ModelForm): def __init__(self, *args, **kwargs): super(BankForm, self).__init__(*args, **kwargs) class Meta: model = models....
{ "repo_name": "davidhalter-archive/django-beginner-skeleton", "path": "simple/views.py", "copies": "1", "size": "1064", "license": "mit", "hash": 679476186909449500, "line_mean": 27.7567567568, "line_max": 71, "alpha_frac": 0.5986842105, "autogenerated": false, "ratio": 4.124031007751938, "conf...
from django.shortcuts import render_to_response,redirect from django.template.context import RequestContext from django.contrib.auth.decorators import permission_required from django.core.urlresolvers import reverse from django.http import HttpResponseRedirect, Http404 from django.conf import settings from django.views...
{ "repo_name": "jrutila/django-reportengine", "path": "reportengine/views.py", "copies": "1", "size": "17553", "license": "bsd-3-clause", "hash": -1500130018744334600, "line_mean": 44.2396907216, "line_max": 149, "alpha_frac": 0.6311171879, "autogenerated": false, "ratio": 4.076405016256387, "co...
from django.shortcuts import render_to_response,redirect from django.template.context import RequestContext from django.core.paginator import Paginator from django.contrib.admin.views.main import ALL_VAR,ORDER_VAR, PAGE_VAR from django.contrib.admin.views.decorators import staff_member_required from django.core.urlreso...
{ "repo_name": "nikolajbaer/django-reportengine", "path": "reportengine/views.py", "copies": "1", "size": "7547", "license": "bsd-3-clause", "hash": 8728013327088499000, "line_mean": 40.467032967, "line_max": 124, "alpha_frac": 0.674042666, "autogenerated": false, "ratio": 3.819331983805668, "co...
from django.shortcuts import render_to_response, redirect from django.template.context import RequestContext from google.appengine.api import users from forms import PollForm, AnswerForm from models import Choose, Question, Answer from django.http import HttpResponseNotAllowed from datetime import datetime openIdProvi...
{ "repo_name": "soswow/yet-another-one-poll-on-app-engine", "path": "polls/views.py", "copies": "1", "size": "5553", "license": "apache-2.0", "hash": -4798753142902441000, "line_mean": 32.6606060606, "line_max": 106, "alpha_frac": 0.586169638, "autogenerated": false, "ratio": 3.734364492266308, ...
from django.shortcuts import render_to_response, redirect from django.template.context import RequestContext from members.models import HsUser, WebLink from members.forms import HsUserForm from django.forms.models import inlineformset_factory import logging from django.contrib import messages logger = logging.getLog...
{ "repo_name": "elifkus/Hackerhane", "path": "src/members/views.py", "copies": "1", "size": "2531", "license": "mit", "hash": 8380665904400688000, "line_mean": 33.6575342466, "line_max": 104, "alpha_frac": 0.5928853755, "autogenerated": false, "ratio": 4.377162629757786, "config_test": false, ...
from django.shortcuts import render_to_response,redirect from django.template import RequestContext from django.contrib.auth.decorators import login_required from google.appengine.api import users from blog.models import Post,Kategori,Komentar from blog.forms import KategoriForm,PostForm from decorator.ip import get_ip...
{ "repo_name": "freezmeinster/avagata-site", "path": "system/views.py", "copies": "1", "size": "2187", "license": "bsd-3-clause", "hash": 968128860455152100, "line_mean": 24.4302325581, "line_max": 57, "alpha_frac": 0.6456332876, "autogenerated": false, "ratio": 2.9554054054054055, "config_test"...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from django.contrib.auth import authenticate, login from django.contrib.auth.models import User from django.contrib.auth.decorators import login_required from django.core.urlresolvers import reverse from registration.fo...
{ "repo_name": "benjamin-guillet/wmr-frontend", "path": "registration/views.py", "copies": "2", "size": "1529", "license": "apache-2.0", "hash": 2946054583213629400, "line_mean": 38.2307692308, "line_max": 95, "alpha_frac": 0.6527141923, "autogenerated": false, "ratio": 4.591591591591592, "confi...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from django.contrib.auth import login as django_login, logout as django_logout from django.contrib.auth import authenticate from .forms import AuthenticationForm def login(request): """Custom login view to login u...
{ "repo_name": "mod2/codex", "path": "accounts/views.py", "copies": "1", "size": "1364", "license": "mit", "hash": 7945741472327790000, "line_mean": 39.1176470588, "line_max": 80, "alpha_frac": 0.6260997067, "autogenerated": false, "ratio": 4.671232876712328, "config_test": false, "has_no_keyw...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from django.core.mail import EmailMessage from django.core.urlresolvers import reverse from django.conf import settings from contact.forms import ContactForm def contact_form(request): """ Displays and proces...
{ "repo_name": "westphahl/verleihsystem", "path": "verleihsystem/contact/views.py", "copies": "1", "size": "1790", "license": "isc", "hash": 6255350618332268000, "line_mean": 36.2916666667, "line_max": 80, "alpha_frac": 0.6067039106, "autogenerated": false, "ratio": 4.355231143552311, "config_te...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from django.core.servers.basehttp import FileWrapper from django.http import HttpResponse from pickleback.apps.packages.models import Package from pickleback.apps.packages.forms import PackageForm from pickleback.apps....
{ "repo_name": "jonathanchu/pickleback", "path": "apps/packages/views.py", "copies": "1", "size": "1510", "license": "mit", "hash": -4269484922494364000, "line_mean": 38.7368421053, "line_max": 79, "alpha_frac": 0.6814569536, "autogenerated": false, "ratio": 4.277620396600566, "config_test": fal...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from django.core.urlresolvers import reverse from django.contrib.auth.decorators import login_required from django.contrib import messages from vutman.models import EmailUser, EmailAlias, EmailDomain from vutman.search_...
{ "repo_name": "daniellawrence/django-vutman", "path": "vutman/views.py", "copies": "1", "size": "6525", "license": "mit", "hash": -2435637409076791300, "line_mean": 30.2200956938, "line_max": 78, "alpha_frac": 0.6050574713, "autogenerated": false, "ratio": 4.007985257985258, "config_test": fals...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from django.http import HttpResponse, Http404 from django.contrib.auth.decorators import login_required import api @login_required def signup(request): return render_to_response("signup.html", {}, RequestC...
{ "repo_name": "sameenjalal/mavenize-beta", "path": "mavenize/apps/user_profile/views.py", "copies": "1", "size": "2745", "license": "mit", "hash": -3707373564034387000, "line_mean": 24.6542056075, "line_max": 67, "alpha_frac": 0.6367941712, "autogenerated": false, "ratio": 3.796680497925311, "c...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from django.http import HttpResponse from django import forms import app.controllers.main as controller import math class GraphForm(forms.Form): MODEL_CHOICES = (('erdos-renyi', 'Erdős–Rényi model'), ('bollobas-ri...
{ "repo_name": "taras-ua/diplomawork", "path": "app/views.py", "copies": "1", "size": "2393", "license": "apache-2.0", "hash": 8674368274944004000, "line_mean": 49.7659574468, "line_max": 146, "alpha_frac": 0.5410729254, "autogenerated": false, "ratio": 4.562141491395794, "config_test": false, ...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from django.http import HttpResponse from django import forms import lab3.controllers.main as controller class GraphForm(forms.Form): graph_matrix = forms.CharField(widget=forms.Textarea()) class RecreateForm(f...
{ "repo_name": "taras-ua/SA_2s_lab3", "path": "lab3/views.py", "copies": "1", "size": "3351", "license": "mit", "hash": -4335883816437678000, "line_mean": 44.2972972973, "line_max": 104, "alpha_frac": 0.4467323187, "autogenerated": false, "ratio": 4.076642335766423, "config_test": false, "has_...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from django.http import HttpResponseRedirect from django.core.urlresolvers import reverse from django.core.exceptions import ObjectDoesNotExist from django.contrib.auth import logout, login, authenticate from django.con...
{ "repo_name": "openlearningtools/opencompetencies", "path": "users/views.py", "copies": "1", "size": "2473", "license": "mit", "hash": -2691872938763271000, "line_mean": 37.640625, "line_max": 91, "alpha_frac": 0.6413263243, "autogenerated": false, "ratio": 4.783365570599613, "config_test": fal...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from django.template.loader import get_template from django.http import HttpResponse from scipy_central.utils import get_IP_address from scipy_central.pagehit.views import create_hit from haystack.views import SearchV...
{ "repo_name": "wqshi/test", "path": "scipy_central/pages/views.py", "copies": "1", "size": "3878", "license": "bsd-3-clause", "hash": 2974691207972800500, "line_mean": 35.9333333333, "line_max": 78, "alpha_frac": 0.6392470346, "autogenerated": false, "ratio": 3.9571428571428573, "config_test": ...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from django.views.decorators.csrf import csrf_exempt from django.http import HttpResponse, HttpResponseServerError from django.conf import settings from django.core.mail import EmailMultiAlternatives import shopify from...
{ "repo_name": "adewinter/bitpay-shopify", "path": "home/views.py", "copies": "1", "size": "10634", "license": "mit", "hash": 5155497110143238000, "line_mean": 39.2803030303, "line_max": 176, "alpha_frac": 0.6384239233, "autogenerated": false, "ratio": 3.593781683001014, "config_test": false, ...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from django.views.decorators.http import require_POST from django.template.loader import render_to_string from django.http import HttpResponse, HttpResponseBadRequest from django.contrib.auth.views import logout as auth...
{ "repo_name": "craigsonoffergus/OpenReader", "path": "openreader/views.py", "copies": "1", "size": "5512", "license": "mit", "hash": -3092073711828703000, "line_mean": 36.2432432432, "line_max": 198, "alpha_frac": 0.6632801161, "autogenerated": false, "ratio": 3.6918955123911585, "config_test":...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from django.views.generic import View as DjangoView from django.http import HttpResponse from djviewmodels import utils from django.utils import simplejson from django.db.models.query import QuerySet class Redirect(Ex...
{ "repo_name": "freyley/django-viewmodels", "path": "djviewmodels/views.py", "copies": "1", "size": "7246", "license": "bsd-3-clause", "hash": -182504906075266900, "line_mean": 39.9378531073, "line_max": 127, "alpha_frac": 0.601711289, "autogenerated": false, "ratio": 4.459076923076923, "config_...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from forms import LoginForm, PromotionForm, SignUpForm import requests import json API_ENDPOINT = "http://idrivedjango-env-qrs5vkxvvi.elasticbeanstalk.com/api" def home(request): return render_to_response('home.html'...
{ "repo_name": "WilfredWee/iDrive-Django-opensource", "path": "project/views.py", "copies": "2", "size": "3321", "license": "mit", "hash": -1228297036343178000, "line_mean": 33.59375, "line_max": 100, "alpha_frac": 0.6949713942, "autogenerated": false, "ratio": 3.1241768579492004, "config_test":...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from kyleandemily import settings from kyleandemily.rsvp.tasks import send_email from .models import Person, Invitation class DotExpandedDict(dict): """ A special dictionary constructor that takes a dictionary i...
{ "repo_name": "rockmans/KyleAndEmily", "path": "kyleandemily/rsvp/views.py", "copies": "1", "size": "5555", "license": "mit", "hash": -7179417400530246000, "line_mean": 34.3885350318, "line_max": 127, "alpha_frac": 0.5893789379, "autogenerated": false, "ratio": 3.9763779527559056, "config_test"...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from models import Post, User import datetime import uuid import re # from django.contrib.auth.hashers import make_password, check_password # from .forms import EditPosts # Create your views here. def home(request):...
{ "repo_name": "anistark/convergence", "path": "blog/views.py", "copies": "1", "size": "4885", "license": "mit", "hash": 1152664541469552400, "line_mean": 33.8928571429, "line_max": 79, "alpha_frac": 0.5758444217, "autogenerated": false, "ratio": 4.037190082644628, "config_test": false, "has_n...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from forms import PageForm from models import Page from django.contrib.auth.decorators import login_required from django.contrib import messages def index(request): """Lists all pages stored in the wiki.""" ...
{ "repo_name": "linkfloyd/linkfloyd", "path": "linkfloyd/wiki/views.py", "copies": "1", "size": "2688", "license": "bsd-3-clause", "hash": 6929247085126924000, "line_mean": 24.6095238095, "line_max": 63, "alpha_frac": 0.5889136905, "autogenerated": false, "ratio": 4.0299850074962515, "config_tes...
from django.shortcuts import render_to_response, redirect from django.template import RequestContext from forms import PageForm from models import Page def index(request): """Lists all pages stored in the wiki.""" context = { 'pages': Page.objects.all(), } return render_to_response('wiki/ind...
{ "repo_name": "sneeu/django-wiki", "path": "wiki/views.py", "copies": "1", "size": "1472", "license": "bsd-3-clause", "hash": -3287989086872212500, "line_mean": 23.131147541, "line_max": 57, "alpha_frac": 0.5855978261, "autogenerated": false, "ratio": 4.100278551532034, "config_test": false, ...
from django.shortcuts import render_to_response, redirect from django.utils.translation import ugettext as _,get_language from django.core.paginator import Paginator, EmptyPage, PageNotAnInteger from django.contrib.auth.decorators import login_required from django.forms.formsets import formset_factory from django.contr...
{ "repo_name": "Elhuyar/Moodmap", "path": "src/behagunea/behagunea_app/views.py", "copies": "2", "size": "320381", "license": "bsd-3-clause", "hash": 4787872665890043000, "line_mean": 72.3640943439, "line_max": 711, "alpha_frac": 0.5806836236, "autogenerated": false, "ratio": 3.5015082296880804, ...
from django.shortcuts import render_to_response, redirect from pymongo import MongoClient from django.http import HttpResponse from django.template import RequestContext import json client = MongoClient() db = client.socialdb hubs = db.hubs SUPPORTED_SOCIAL = ["twitter", "facebook", "instagram"] def dashboard(reques...
{ "repo_name": "Smiter/north-american-hipster", "path": "mainsite/views.py", "copies": "1", "size": "4483", "license": "mit", "hash": 3402287881670365000, "line_mean": 43.3861386139, "line_max": 138, "alpha_frac": 0.6254740129, "autogenerated": false, "ratio": 3.894874022589053, "config_test": f...
from django.shortcuts import render_to_response, redirect from resejamforaren.settings import STATIC_URL from resejamforaren.config import MAPQUEST_KEY, RESROBOT_KEY, STREETSMART_URL, PRICE_PETROL, PRICE_DRIVING, PRICE_UPDATED, GOOGLE_ANALYTICS_KEY, \ MAP_CENTER_POINT from django.utils import translation def inde...
{ "repo_name": "lundskommun/resejamforaren", "path": "rjweb/views.py", "copies": "1", "size": "1745", "license": "apache-2.0", "hash": 2823060573779983400, "line_mean": 31.3333333333, "line_max": 146, "alpha_frac": 0.6624641834, "autogenerated": false, "ratio": 3.155515370705244, "config_test": ...
from django.shortcuts import render_to_response, redirect from system.models import CustomUser from django.template import RequestContext from django.core.urlresolvers import reverse from django.contrib.auth.forms import UserCreationForm from django.contrib.auth.models import BaseUserManager from django import forms fr...
{ "repo_name": "XMLPro/ManagementSystem", "path": "system/controllers/userRegister.py", "copies": "1", "size": "2164", "license": "mit", "hash": -876969247071931500, "line_mean": 32.3650793651, "line_max": 79, "alpha_frac": 0.6493815414, "autogenerated": false, "ratio": 3.9886148007590134, "conf...
from django.shortcuts import render_to_response, redirect import datetime, os, shutil, re, math import logging from django import forms from django.db import IntegrityError from django.contrib.auth.models import User from django.contrib.auth import authenticate, login, logout from django.http import HttpResponseRedire...
{ "repo_name": "Nucleoos/condor-copasi", "path": "web_frontend/condor_copasi_db/views.py", "copies": "2", "size": "69192", "license": "artistic-2.0", "hash": 5486175289509037000, "line_mean": 44.3718032787, "line_max": 386, "alpha_frac": 0.5678546653, "autogenerated": false, "ratio": 4.14994302165...
from django.shortcuts import render_to_response, redirect import string import traceback from zookeeper_dashboard.zktree.models import ZNode def istext(s, text_chars="".join(map(chr, range(32, 127))) + "\n\r\t\b"): if "\0" in s: return False if not s: return True t = s.translate(string.maketrans("", ""), ...
{ "repo_name": "lgrote/zookeeper_dashboard", "path": "zktree/views.py", "copies": "1", "size": "1642", "license": "apache-2.0", "hash": 1697929142249880300, "line_mean": 31.1960784314, "line_max": 87, "alpha_frac": 0.5146163216, "autogenerated": false, "ratio": 3.8454332552693207, "config_test":...
from django.shortcuts import render_to_response, redirect from bindings import gsevol as Gse from bindings.base import GseError def request_params(request): return request.GET.get("gene"), request.GET.get("species") def fill_gene_and_species(request): """Retrieve values of 'gene' and 'species' params from r...
{ "repo_name": "otraczyk/gsevol-web", "path": "front/views.py", "copies": "1", "size": "2428", "license": "mit", "hash": -8975732639726470000, "line_mean": 29.35, "line_max": 70, "alpha_frac": 0.6256177924, "autogenerated": false, "ratio": 3.8176100628930816, "config_test": false, "has_no_keyw...
from django.shortcuts import render_to_response, redirect, render, get_object_or_404 from django.conf import settings from django.contrib.auth.decorators import login_required from django.contrib.auth import login, logout, authenticate from django.contrib import messages from django.template.response import TemplateRes...
{ "repo_name": "underlost/coreExtend", "path": "coreExtend/views.py", "copies": "1", "size": "2085", "license": "mit", "hash": -3959532829421841400, "line_mean": 39.8823529412, "line_max": 105, "alpha_frac": 0.7232613909, "autogenerated": false, "ratio": 4.112426035502959, "config_test": false, ...
from django.shortcuts import render_to_response, redirect, render, get_object_or_404 from django.http import HttpResponse from app.models import * import json import logging from django.db import * from django.core.exceptions import ValidationError from django.forms.models import model_to_dict from app.status import * ...
{ "repo_name": "yurifariasg/Peer-Assessment", "path": "peerassessment/app/views/common.py", "copies": "1", "size": "3883", "license": "mit", "hash": 3127302773027178000, "line_mean": 33.6696428571, "line_max": 107, "alpha_frac": 0.6858099408, "autogenerated": false, "ratio": 4.3240534521158125, ...
from django.shortcuts import render_to_response, redirect,render from django.contrib.auth import authenticate, login from django.contrib.auth import login as auth_login from django.template import RequestContext from django.http import HttpResponse from django.http import HttpResponseRedirect from django.contrib.auth.d...
{ "repo_name": "pratheekms/cfg14", "path": "pdp/views.py", "copies": "1", "size": "7555", "license": "mit", "hash": 4272828328832863700, "line_mean": 30.7478991597, "line_max": 218, "alpha_frac": 0.6870946393, "autogenerated": false, "ratio": 3.1505421184320266, "config_test": false, "has_no_k...
from django.shortcuts import render_to_response, redirect, render from django.core.urlresolvers import reverse from django.views.decorators.csrf import csrf_exempt from django.views.decorators.http import require_POST from django_auth_lti.decorators import lti_role_required from ab_tool.constants import (ADMINS, INTER...
{ "repo_name": "penzance/ab-testing-tool", "path": "ab_tool/views/intervention_point_pages.py", "copies": "1", "size": "11764", "license": "mit", "hash": 2013156865033576000, "line_mean": 51.2844444444, "line_max": 139, "alpha_frac": 0.7093675621, "autogenerated": false, "ratio": 3.768097373478539...
from django.shortcuts import render_to_response, redirect, render from django.http import HttpResponse, HttpResponseRedirect from django.template import RequestContext from django.contrib.auth.models import User from django.contrib.contenttypes.models import ContentType from django.core.paginator import Paginator, Inva...
{ "repo_name": "LighthouseHPC/lighthouse", "path": "src/lighthouseProject/blog/views.py", "copies": "2", "size": "6041", "license": "mit", "hash": 347263029451898300, "line_mean": 29.9846153846, "line_max": 145, "alpha_frac": 0.6162886939, "autogenerated": false, "ratio": 3.9278283485045513, "co...
from django.shortcuts import render_to_response, redirect, render from django.http import HttpResponse, HttpResponseRedirect from django.template import RequestContext from forms import CameraSettingsForm, NewCameraForm from models import Camera from datetime import datetime from hotqueue import HotQueue import redis i...
{ "repo_name": "anywonder/piGates", "path": "myGates/camsettings/views.py", "copies": "1", "size": "2296", "license": "apache-2.0", "hash": -8515506959349911000, "line_mean": 26.6626506024, "line_max": 159, "alpha_frac": 0.6933797909, "autogenerated": false, "ratio": 3.9047619047619047, "config_...
from django.shortcuts import render_to_response, redirect, render from django.template import RequestContext from signups.forms import * import post.settings as settings from mailsnake import MailSnake import json from django.http import HttpResponse, HttpResponseRedirect import datetime def connect(request): ms ...
{ "repo_name": "davogler/POSTv3", "path": "signups/views.py", "copies": "1", "size": "2049", "license": "mit", "hash": 7963316987194532000, "line_mean": 33.15, "line_max": 107, "alpha_frac": 0.5685700342, "autogenerated": false, "ratio": 4.493421052631579, "config_test": false, "has_no_keyword...
from django.shortcuts import render_to_response, redirect, render from django.template import RequestContext from subscribers.models import * import post.settings as settings from django.http import HttpResponse, HttpResponseRedirect from subscribers.helium import Helium import datetime def get_subscriber(request): ...
{ "repo_name": "davogler/POSTv3", "path": "subscribers/views.py", "copies": "2", "size": "1330", "license": "mit", "hash": 2737239504442488000, "line_mean": 35.9444444444, "line_max": 103, "alpha_frac": 0.6203007519, "autogenerated": false, "ratio": 4.3894389438943895, "config_test": false, "h...
from django.shortcuts import render_to_response, render, get_object_or_404 from django.template import RequestContext, loader from django.http import HttpResponse, HttpResponseRedirect from django.http import Http404 from django.core.urlresolvers import reverse from helping_hands_app.forms import * from django.contrib....
{ "repo_name": "sophiataskova/helping_hands", "path": "helping_hands_site/helping_hands_app/views.py", "copies": "1", "size": "2696", "license": "mit", "hash": -7993477616929553000, "line_mean": 31.8780487805, "line_max": 78, "alpha_frac": 0.6732195846, "autogenerated": false, "ratio": 3.895953757...
from django.shortcuts import render_to_response, render from django.http import HttpResponse from django.http import HttpResponseRedirect from sail.models import AlumnusProfile from django.db.models import Q fields = ['roll_number', 'name', 'batch'] def createQuery(request, result, field): if request.POST[field]...
{ "repo_name": "sail-iitg/alumni-directory", "path": "directory/sail/views.py", "copies": "1", "size": "1037", "license": "mit", "hash": 4698856322376563000, "line_mean": 34.7586206897, "line_max": 83, "alpha_frac": 0.6364513018, "autogenerated": false, "ratio": 3.8694029850746268, "config_test"...
from django.shortcuts import render_to_response, render from django.http import HttpResponse from django.views.generic import View from django.core.mail import send_mail from models import * from forms import ContactUsForm from django.views.generic.edit import FormView class HomeView(FormView): template_name = 'm...
{ "repo_name": "kave/deepscrub", "path": "core/views.py", "copies": "1", "size": "1134", "license": "artistic-2.0", "hash": 8927523153710410000, "line_mean": 30.5, "line_max": 70, "alpha_frac": 0.7028218695, "autogenerated": false, "ratio": 3.5217391304347827, "config_test": false, "has_no_key...
from django.shortcuts import render_to_response, render from django.http import HttpResponseRedirect, HttpResponse from django.contrib import auth, messages from sms.models import * import logging import traceback from django_twilio.decorators import twilio_view from django.contrib.auth.decorators import login_required...
{ "repo_name": "cauanicastro/smssurveytools", "path": "sms/views.py", "copies": "1", "size": "6935", "license": "apache-2.0", "hash": -1899183611191077600, "line_mean": 32.0285714286, "line_max": 123, "alpha_frac": 0.625666907, "autogenerated": false, "ratio": 4.1751956652618905, "config_test": ...
from django.shortcuts import render_to_response, render from django.template.context import RequestContext from django.contrib.auth.decorators import login_required from django.views.generic import ListView from vice.models import Bounty, GiftCard, Pledge, Vice from users.models import UserProfile # class ViceList(Li...
{ "repo_name": "ViceVersusMe/ViceVersus", "path": "ViceVersus/vice/views.py", "copies": "1", "size": "1070", "license": "mit", "hash": 6999783756581464000, "line_mean": 33.5483870968, "line_max": 68, "alpha_frac": 0.6271028037, "autogenerated": false, "ratio": 4.007490636704119, "config_test": f...
from django.shortcuts import render_to_response, render from django.template.context import RequestContext from django.template.loader import render_to_string from django.db.models import ObjectDoesNotExist, Q from django.http import HttpResponse from django.core import serializers from django.core.paginator import Pag...
{ "repo_name": "orlenko/bccf", "path": "src/bccf/views/page.py", "copies": "1", "size": "6976", "license": "unlicense", "hash": -8592024925767562000, "line_mean": 43.7179487179, "line_max": 173, "alpha_frac": 0.6581135321, "autogenerated": false, "ratio": 3.4466403162055337, "config_test": false...
from django.shortcuts import render_to_response, render from django.template import RequestContext from django.http import HttpResponseRedirect from django.core.urlresolvers import reverse from django.views.generic import FormView, DetailView, ListView from filesAndForms.forms import InputForm from filesAndForms.model...
{ "repo_name": "nynguyen/sprint_zero_demo", "path": "main/filesAndForms/views.py", "copies": "1", "size": "1141", "license": "mit", "hash": 6469288771250679000, "line_mean": 34.65625, "line_max": 86, "alpha_frac": 0.7554776512, "autogenerated": false, "ratio": 3.6222222222222222, "config_test": ...
from django.shortcuts import render_to_response, render from django.utils.timezone import localtime from pytz import timezone from django.contrib.auth.decorators import login_required from servicehistory.models import ServiceInvokedHistory from vehicles.models import Vehicle from server.utils import get_setting # Gl...
{ "repo_name": "dvthiriez/rvi_backend", "path": "web/servicehistory/views.py", "copies": "1", "size": "1837", "license": "mpl-2.0", "hash": -2075532799485934000, "line_mean": 34.3461538462, "line_max": 84, "alpha_frac": 0.6483396843, "autogenerated": false, "ratio": 3.764344262295082, "config_te...
from django.shortcuts import render_to_response, render from .forms import UserForm, LoginForm from django.http import HttpResponseRedirect, HttpResponse from django.contrib.auth import authenticate, login from .models import User # Create your views here. def index(request): c = {} return render(request, 'reg...
{ "repo_name": "michaelmdresser/CrowdFind", "path": "website/login/views.py", "copies": "1", "size": "1721", "license": "mit", "hash": -2930595665644031500, "line_mean": 27.2295081967, "line_max": 76, "alpha_frac": 0.5490993608, "autogenerated": false, "ratio": 4.3025, "config_test": false, "h...
from django.shortcuts import render_to_response, render from models import * def template(request,template_id=1): """ you will have to replace "index.html" with (yourappname)/index.html and createa folder named (yourappname) in the templates directory. """ #required functions: #Add Row #Remove Row #Add...
{ "repo_name": "igudym/twango", "path": "twango/template/default/src/apps/grid_designer/views.py", "copies": "1", "size": "1078", "license": "bsd-3-clause", "hash": -152090611458720350, "line_mean": 23.5, "line_max": 76, "alpha_frac": 0.6910946197, "autogenerated": false, "ratio": 3.31692307692307...
from django.shortcuts import render_to_response, render from onlinejudge.models import * from blog.models import * from django.http import HttpResponse, Http404, HttpResponseRedirect from onlinejudge.forms import * from django.views.decorators.csrf import csrf_exempt from datetime import datetime from markdown import m...
{ "repo_name": "alogfans/yaoj", "path": "main/onlinejudge/views.py", "copies": "1", "size": "14273", "license": "mit", "hash": 7084880993615243000, "line_mean": 40.7339181287, "line_max": 148, "alpha_frac": 0.5806768024, "autogenerated": false, "ratio": 4.126337091644984, "config_test": true, ...
from django.shortcuts import render_to_response, render import json import requests import re import datetime from django.http import HttpResponse, Http404, HttpResponseBadRequest, \ HttpRequest, HttpResponseServerError, HttpResponseNotAllowed from models import TheftLocation # --- Helper Functions --- # Regex fo...
{ "repo_name": "plusjeff/phl-bike-thefts", "path": "site/phl_bike_thefts/web/views.py", "copies": "1", "size": "7078", "license": "apache-2.0", "hash": 7922672112185177000, "line_mean": 33.7009803922, "line_max": 170, "alpha_frac": 0.6589432043, "autogenerated": false, "ratio": 4.046883933676386, ...
from django.shortcuts import render_to_response, render, redirect from django.core.context_processors import csrf from django.template import RequestContext def home(request): if request.POST: c = {"request": request} c.update(csrf(request)) return render_to_response("home.html", ...
{ "repo_name": "dogancankilment/ridersofcomu", "path": "website/views.py", "copies": "1", "size": "1648", "license": "apache-2.0", "hash": 8252113647090937000, "line_mean": 26.4833333333, "line_max": 71, "alpha_frac": 0.5691747573, "autogenerated": false, "ratio": 3.8867924528301887, "config_tes...
from django.shortcuts import render_to_response, render, redirect from django.template.context import RequestContext from django.http import HttpResponseRedirect,HttpResponse # Usuario from django.contrib.auth.forms import UserCreationForm, AuthenticationForm from django.contrib.auth import login, authenticate, logout ...
{ "repo_name": "gianpaima/favorless", "path": "favor/registro_usuarios/views.py", "copies": "1", "size": "20362", "license": "mit", "hash": 3382104095588552700, "line_mean": 40.4704684318, "line_max": 272, "alpha_frac": 0.6111875061, "autogenerated": false, "ratio": 3.5810763278227227, "config_t...
from django.shortcuts import render_to_response, render, redirect from django.template.context import RequestContext from django.http import HttpResponseRedirect,HttpResponse #Usuario from django.contrib.auth import login, authenticate, logout from django.contrib.auth.decorators import login_required from django.contri...
{ "repo_name": "gianpaima/favorless", "path": "favor/votos/views.py", "copies": "1", "size": "19914", "license": "mit", "hash": 3545010389262971400, "line_mean": 35.5394495413, "line_max": 248, "alpha_frac": 0.5740684945, "autogenerated": false, "ratio": 3.387310767137268, "config_test": false, ...
from django.shortcuts import render_to_response, render, redirect from django.views.generic import ListView, DetailView from .models import Post, Categoria from django.template import RequestContext, loader from django.core.paginator import Paginator, EmptyPage, PageNotAnInteger from django.core.urlresolvers import rev...
{ "repo_name": "MatheusDaeuble/admsolucoesblog", "path": "blog/views.py", "copies": "1", "size": "3658", "license": "bsd-3-clause", "hash": -3132215188931233300, "line_mean": 29.4833333333, "line_max": 112, "alpha_frac": 0.7208857299, "autogenerated": false, "ratio": 3.121160409556314, "config_t...
from django.shortcuts import render_to_response, render, redirect, \ get_object_or_404 from django.template import RequestContext from django.contrib.auth.models import User import django.contrib.auth as auth from django.contrib.auth.decorators import login_required from models import Hacker, Proposal, Discussi...
{ "repo_name": "PizzaHackers/pizzahackers-web", "path": "core/views.py", "copies": "1", "size": "8189", "license": "mit", "hash": 5394563456675828000, "line_mean": 25, "line_max": 79, "alpha_frac": 0.6656490414, "autogenerated": false, "ratio": 2.9734931009440815, "config_test": false, "has_no...
from django.shortcuts import render_to_response, RequestContext, get_object_or_404, HttpResponseRedirect from pamplesneak.models import Pamplesneak, Player, GameWord from pamplesneak.forms import PamplesneakForm, MessageSender from userprofile.models import UserProfile, PamplesneakInfo from django.contrib.auth.decorato...
{ "repo_name": "peasnrice/pamplemousse", "path": "pamplesneak/views.py", "copies": "1", "size": "5807", "license": "mit", "hash": -6605249867821249000, "line_mean": 34.6319018405, "line_max": 121, "alpha_frac": 0.6338901326, "autogenerated": false, "ratio": 3.624843945068664, "config_test": fals...
from django.shortcuts import render_to_response, RequestContext, get_object_or_404 from django.views.decorators.csrf import csrf_exempt from django.http import HttpResponse, Http404 from .models import Transaction from .forms import SuccessForm, FailureForm, PaymentForm from .utils import get_payway_class import date...
{ "repo_name": "logithr/django-htpayway", "path": "htpayway/views.py", "copies": "1", "size": "4315", "license": "mit", "hash": -3549173598517179400, "line_mean": 39.3271028037, "line_max": 97, "alpha_frac": 0.5969872538, "autogenerated": false, "ratio": 4.145052833813641, "config_test": false, ...
from django.shortcuts import render_to_response, RequestContext, Http404 from django.views.generic import TemplateView from avalonline.models.game import Game from avalonline.models.player import Player class PlayerView(TemplateView): template_name = "player.html" def get(self, request, game_id, player_id, *...
{ "repo_name": "fako/avalonline", "path": "avalonline/views/player.py", "copies": "1", "size": "1303", "license": "mit", "hash": 4840674048387665000, "line_mean": 39.71875, "line_max": 112, "alpha_frac": 0.6323867997, "autogenerated": false, "ratio": 4.021604938271605, "config_test": false, "h...
from django.shortcuts import render_to_response, RequestContext from django.contrib.auth.models import User #my models from infoPlatform.models import ClassInfo, FriendInfo, FriendValidation #others from django_datatables_view.base_datatable_view import BaseDatatableView # Create your views here. class UsersListJ...
{ "repo_name": "lanke/InfoPlatform", "path": "smartAdmin/infoPlatform/views.py", "copies": "1", "size": "4246", "license": "apache-2.0", "hash": -1997906483597793300, "line_mean": 33.5203252033, "line_max": 107, "alpha_frac": 0.7491756948, "autogenerated": false, "ratio": 3.246177370030581, "con...
from django.shortcuts import render_to_response, RequestContext from django.http import HttpResponse, Http404 import tworpus_user_id from models import TworpusSettings import json import data_converter from tworpus import settings def home(request): request.META["CSRF_COOKIE_USED"] = True return render_to_res...
{ "repo_name": "markusmichel/Tworpus-Client", "path": "tworpus/views.py", "copies": "1", "size": "1476", "license": "apache-2.0", "hash": -8328760928425746000, "line_mean": 27.9411764706, "line_max": 88, "alpha_frac": 0.6985094851, "autogenerated": false, "ratio": 3.548076923076923, "config_test...
from django.shortcuts import render_to_response, RequestContext from django.http import HttpResponse, HttpResponseRedirect from .models import Profile from contact.models import Contact from PSEP.utils import id_generator from django.contrib.auth import authenticate from django.contrib.auth.models import User from inte...
{ "repo_name": "tingcar/PSEP", "path": "src/profiles/views.py", "copies": "1", "size": "3534", "license": "apache-2.0", "hash": -2554003857893737500, "line_mean": 35.0612244898, "line_max": 110, "alpha_frac": 0.6997736276, "autogenerated": false, "ratio": 4.217183770883055, "config_test": false,...
from django.shortcuts import render_to_response, RequestContext from django.http import HttpResponse, HttpResponseRedirect from profiles.models import Profile from .models import InternalMail, OutMail from PSEP.utils import id_generator from django.contrib.auth.models import User from django.views.decorators.csrf impor...
{ "repo_name": "tingcar/PSEP", "path": "src/internalmail/views.py", "copies": "1", "size": "3819", "license": "apache-2.0", "hash": 9128360027206791000, "line_mean": 35.0283018868, "line_max": 116, "alpha_frac": 0.6823775858, "autogenerated": false, "ratio": 3.953416149068323, "config_test": fal...
from django.shortcuts import render_to_response,RequestContext from django.http import HttpResponse,HttpResponseRedirect from vertex.models import Vertex,Edge,Flow from django.utils import timezone from login.views import authDetail def profile(request, user_id): try: vertex = Vertex.objects.get(user_id=user_i...
{ "repo_name": "bardia73/Graph", "path": "vertex/views.py", "copies": "2", "size": "3365", "license": "mit", "hash": -1840704277920885800, "line_mean": 34.4210526316, "line_max": 396, "alpha_frac": 0.709063893, "autogenerated": false, "ratio": 3.1071098799630654, "config_test": false, "has_no_...
from django.shortcuts import render_to_response,RequestContext from django.http import HttpResponse,HttpResponseRedirect import cgi from vertex.models import Vertex from time import sleep from urllib import urlencode from django.contrib.auth import authenticate, login def view(request): query = request.META['QUERY_S...
{ "repo_name": "bardia-heydarinejad/Graph", "path": "login/views.py", "copies": "2", "size": "1737", "license": "mit", "hash": -242548461154245730, "line_mean": 23.125, "line_max": 62, "alpha_frac": 0.7173287277, "autogenerated": false, "ratio": 3.392578125, "config_test": false, "has_no_keywo...
from django.shortcuts import render_to_response, RequestContext from django.http import HttpResponseRedirect from django.contrib import auth from django.core.context_processors import csrf from django.contrib import messages from .forms import SGRegisterForm def home(request): return render_to_response('base.htm...
{ "repo_name": "moniquemtucker/simply-good", "path": "simply_good_django/simply_good_django/views.py", "copies": "1", "size": "2087", "license": "apache-2.0", "hash": 842594825195141100, "line_mean": 27.2162162162, "line_max": 90, "alpha_frac": 0.6990896023, "autogenerated": false, "ratio": 4.1573...
from django.shortcuts import render_to_response from django.core.context_processors import csrf from django.http import HttpResponse, HttpResponseRedirect, HttpResponseBadRequest, HttpResponseServerError, HttpResponseForbidden from django.template import RequestContext from django.conf import settings from lingcod...
{ "repo_name": "Alwnikrotikz/marinemap", "path": "lingcod/intersection/views.py", "copies": "3", "size": "10419", "license": "bsd-3-clause", "hash": -7121592958912460000, "line_mean": 42.7167381974, "line_max": 133, "alpha_frac": 0.6025530281, "autogenerated": false, "ratio": 3.916917293233083, ...
from django.shortcuts import render_to_response from django.http import Http404, HttpResponse from django.template import Context, Template from django.contrib.contenttypes.models import ContentType JSON_TEMPLATE = '''[{% for obj in objects %}{contentTypeId:'{{ obj.content_type_id }}',contentTypeText:'{{ obj.co...
{ "repo_name": "maxcutler/Courant-News", "path": "courant/core/genericadmin/views.py", "copies": "1", "size": "1691", "license": "bsd-3-clause", "hash": 4818981909272912000, "line_mean": 38.3095238095, "line_max": 252, "alpha_frac": 0.6002365464, "autogenerated": false, "ratio": 3.7661469933184857...
from django.shortcuts import render_to_response from django import forms from django import VERSION as DJANGO_VERSION from django.template import RequestContext from django.db.models import signals as signalmodule from django.http import HttpResponse import exceptions # Try to be compatible with Django 1.5+. tr...
{ "repo_name": "hfercc/mese2014", "path": "annoying/decorators.py", "copies": "1", "size": "8708", "license": "apache-2.0", "hash": 2337124155119615500, "line_mean": 30.8679245283, "line_max": 111, "alpha_frac": 0.5999081305, "autogenerated": false, "ratio": 4.358358358358358, "config_test": fal...
from django.shortcuts import render_to_response from django.shortcuts import get_object_or_404 from django.http import HttpResponseRedirect from django.template import RequestContext from django.core.urlresolvers import reverse from django.utils.translation import ugettext_lazy as _ from django.contrib.auth.decor...
{ "repo_name": "dongguangming/django-books", "path": "views.py", "copies": "1", "size": "2241", "license": "bsd-3-clause", "hash": 7955262703720014000, "line_mean": 30.9558823529, "line_max": 59, "alpha_frac": 0.5858991522, "autogenerated": false, "ratio": 4.420118343195266, "config_test": false...
from django.shortcuts import render_to_response from django.shortcuts import render from django.template.loader import get_template from django.template import Context from django.http import HttpResponse from django.http import HttpResponseRedirect from django.core.files import File import math import re from...
{ "repo_name": "Adward-R/Info-Retrieval-Project", "path": "djcode/mysite/views.py", "copies": "1", "size": "7914", "license": "apache-2.0", "hash": -1215914827339532500, "line_mean": 30.5679012346, "line_max": 116, "alpha_frac": 0.4761182714, "autogenerated": false, "ratio": 3.8832188420019627, ...
from django.shortcuts import render_to_response from django.shortcuts import render from Report.models import reports from Report.models import Document from django.http import HttpResponseRedirect from django.core.urlresolvers import reverse import sys from Report.models import Folder from pprint import pprint...
{ "repo_name": "vivianbuan/cs3240-s15-team20", "path": "SecureWitness/Report/views.py", "copies": "1", "size": "15354", "license": "mit", "hash": -6757137939653292000, "line_mean": 37.470437018, "line_max": 123, "alpha_frac": 0.5170639573, "autogenerated": false, "ratio": 4.155345060893099, "con...
from django.shortcuts import render_to_response from django.template.context import RequestContext from django.template import add_to_builtins from django.db.models.signals import pre_init from django.conf import settings from django.contrib.contenttypes.models import ContentType from courant.core.gettag import...
{ "repo_name": "maxcutler/Courant-News", "path": "courant/core/utils/__init__.py", "copies": "1", "size": "1547", "license": "bsd-3-clause", "hash": -8348591418283136000, "line_mean": 34.880952381, "line_max": 91, "alpha_frac": 0.7065287654, "autogenerated": false, "ratio": 3.9871134020618557, "...
from django.shortcuts import render_to_response from django.template import RequestContext from django.http import HttpResponseRedirect from django.core.urlresolvers import reverse from models import RatingValue import functions import inspect def add_event(request): context = { 'categories': fun...
{ "repo_name": "Diego999/Social-Recommendation-System", "path": "events/views.py", "copies": "1", "size": "1981", "license": "mit", "hash": 5203917972040300000, "line_mean": 35.4150943396, "line_max": 174, "alpha_frac": 0.6673397274, "autogenerated": false, "ratio": 3.8540856031128405, "config_t...
from django.shortcuts import render_to_response from django.template import RequestContext from userprofiles.forms import UserForm from userprofiles.forms import UserProfileForm from userprofiles.models import UserProfile def update_profile(request): if request.user.is_authenticated(): if request...
{ "repo_name": "nathangeffen/tbonline-2", "path": "tbonlineproject/userprofiles/views.py", "copies": "2", "size": "1465", "license": "mit", "hash": 6895163915013678000, "line_mean": 37.5945945946, "line_max": 77, "alpha_frac": 0.5303754266, "autogenerated": false, "ratio": 5.232142857142857, "co...
from django.shortcuts import render_to_response from django.template import RequestContext import requests, json from django.conf import settings from django.http import HttpResponse from bii_webapp.settings import common from django.shortcuts import redirect from django.contrib.auth import decorators, views fr...
{ "repo_name": "ISA-tools/bii-webapp", "path": "bii_webapp/apps/browse/views.py", "copies": "1", "size": "17837", "license": "mit", "hash": -6892969828936884000, "line_mean": 37.2885462555, "line_max": 172, "alpha_frac": 0.5394965521, "autogenerated": false, "ratio": 4.15103560623691, "config_te...
from django.shortcuts import render_to_response from django.template import RequestContext from facegame.faceguessing.models import Player, UserStats from facegame.faceguessing.views import get_user from operator import itemgetter def hall_of_fame(request): """ Displays top users by highest streaks """ ...
{ "repo_name": "futurice/facegame", "path": "facegame/stats/views.py", "copies": "1", "size": "1127", "license": "mit", "hash": -6206007178444867000, "line_mean": 36.8620689655, "line_max": 142, "alpha_frac": 0.6566104703, "autogenerated": false, "ratio": 3.589171974522293, "config_test": false,...
from django.shortcuts import render_to_response from django.utils.encoding import force_unicode from django.contrib.admin import helpers from django import template import notifications def show_email_confirmation_page(modeladmin, request, queryset, action): opts = modeladmin.model._meta app_label = ...
{ "repo_name": "maxcutler/Courant-News", "path": "courant/core/news/actions.py", "copies": "1", "size": "3164", "license": "bsd-3-clause", "hash": -6267186160793211000, "line_mean": 41.9444444444, "line_max": 110, "alpha_frac": 0.6213653603, "autogenerated": false, "ratio": 4.098445595854923, "c...