text stringlengths 0 1.05M | meta dict |
|---|---|
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.http import HttpResponseRedirect
from django.core.urlresolvers import reverse
from django.http import HttpResponseForbidden
from django.shortcuts import get_object_or_404
from django.utils.decorators import method_... | {
"repo_name": "tabdon/crmeasy-deploy-build",
"path": "crmapp/contacts/views.py",
"copies": "2",
"size": "3509",
"license": "mit",
"hash": -7610925962615946000,
"line_mean": 31.1926605505,
"line_max": 98,
"alpha_frac": 0.6189797663,
"autogenerated": false,
"ratio": 4.397243107769423,
"config_tes... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.http import HttpResponseRedirect
from django.urls import reverse
import numpy as np
import decimal
from .models import MentalFatigue, AttentionRelatedCognitiveError, DaydreamFrequency, MindfulAttentionAwareness
... | {
"repo_name": "warrenatmindset/DjangoFlowApp",
"path": "questionnaires/views.py",
"copies": "1",
"size": "3315",
"license": "mit",
"hash": -4016047446256422000,
"line_mean": 33.1855670103,
"line_max": 111,
"alpha_frac": 0.783107089,
"autogenerated": false,
"ratio": 3.2278481012658227,
"config_t... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.http import HttpResponseRedirect
from .forms import *
@login_required
def profile_view(request):
return render(request, 'profile.html')
@login_required
def edit_profile_view(request):
if request.method ... | {
"repo_name": "tpeek/bike_safety",
"path": "imagersite/imager_profile/views.py",
"copies": "2",
"size": "1153",
"license": "mit",
"hash": 420886219845635800,
"line_mean": 37.4333333333,
"line_max": 79,
"alpha_frac": 0.6279271466,
"autogenerated": false,
"ratio": 4.045614035087719,
"config_test"... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.http import JsonResponse
from django.views.decorators.http import require_POST
from django.views.decorators.csrf import csrf_exempt
from .forms import ImageForm
from .models import Image
# Create your views here... | {
"repo_name": "glon/django_test",
"path": "image/views.py",
"copies": "1",
"size": "1383",
"license": "apache-2.0",
"hash": 6818066329664275000,
"line_mean": 21.6721311475,
"line_max": 72,
"alpha_frac": 0.6710050615,
"autogenerated": false,
"ratio": 3.7994505494505493,
"config_test": false,
"... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.http import JsonResponse, QueryDict
from django.db.models import Q, Count
from django.core.paginator import Paginator, EmptyPage, PageNotAnInteger
from .models import Tag, Family, Item
import datetime
@login_requ... | {
"repo_name": "bencrowder/gent",
"path": "gent/views.py",
"copies": "1",
"size": "12719",
"license": "mit",
"hash": 35621539236219464,
"line_mean": 33.0991957105,
"line_max": 262,
"alpha_frac": 0.5358125639,
"autogenerated": false,
"ratio": 3.924406047516199,
"config_test": false,
"has_no_key... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.shortcuts import get_object_or_404
from django.contrib.auth.models import User
from django.forms import ModelForm
from django.views.generic.edit import UpdateView
from .models import ImagerProfile
PROFILE_TEMPLATE... | {
"repo_name": "SeleniumK/django-imager",
"path": "imagersite/imager_profile/views.py",
"copies": "1",
"size": "1527",
"license": "mit",
"hash": -4409446574516927000,
"line_mean": 25.7894736842,
"line_max": 81,
"alpha_frac": 0.6614276359,
"autogenerated": false,
"ratio": 3.856060606060606,
"conf... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.shortcuts import get_object_or_404, redirect
import os
# Create your views here.
from individuals.models import Individual
from django.contrib import messages
from django.conf import settings
from django.utils.te... | {
"repo_name": "raonyguimaraes/mendelmd",
"path": "dashboard/views.py",
"copies": "1",
"size": "4392",
"license": "bsd-3-clause",
"hash": -8450669807504645000,
"line_mean": 38.9272727273,
"line_max": 108,
"alpha_frac": 0.6145264117,
"autogenerated": false,
"ratio": 4.2682215743440235,
"config_te... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.shortcuts import render_to_response
from django.template import RequestContext
from forms import *
from models import *
from datetime import datetime
from django.core.paginator import Paginator, EmptyPage, PageNotA... | {
"repo_name": "hujingguang/OpsSystem",
"path": "asset/views.py",
"copies": "1",
"size": "1832",
"license": "mit",
"hash": -3141204681441569300,
"line_mean": 34.9215686275,
"line_max": 96,
"alpha_frac": 0.7379912664,
"autogenerated": false,
"ratio": 3.4500941619585688,
"config_test": false,
"h... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.template.context_processors import csrf
from django.http import HttpResponse
import cStringIO
from data.models import RadiosondeMeasurement, WeatherMeasurement, MeasuringDevice
from forms import WeatherMeasurementF... | {
"repo_name": "FSavoy/visuo-server",
"path": "downloads/views.py",
"copies": "1",
"size": "12500",
"license": "bsd-3-clause",
"hash": 5939163975908590000,
"line_mean": 35.5497076023,
"line_max": 173,
"alpha_frac": 0.60528,
"autogenerated": false,
"ratio": 3.5785857429144,
"config_test": false,
... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.template import RequestContext
from django.shortcuts import render, render_to_response
from django.views.generic import View
from django.http import HttpResponse
from customers import models as m
from django.db imp... | {
"repo_name": "abhaystoic/barati",
"path": "barati/customers/views_cluster/add_to_cart.py",
"copies": "1",
"size": "2985",
"license": "apache-2.0",
"hash": -1987504461889483800,
"line_mean": 47.1451612903,
"line_max": 231,
"alpha_frac": 0.6703517588,
"autogenerated": false,
"ratio": 3.87159533073... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.template import RequestContext
from django.template.context_processors import request
from django.shortcuts import render, redirect, get_object_or_404
from django.utils.six import b
from notifications.signals impor... | {
"repo_name": "othreecodes/MY-RIDE",
"path": "broadcast/views.py",
"copies": "1",
"size": "6694",
"license": "mit",
"hash": 9134678458522815000,
"line_mean": 26.3224489796,
"line_max": 117,
"alpha_frac": 0.6523752614,
"autogenerated": false,
"ratio": 4.099203919167177,
"config_test": false,
"... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.urls import reverse
from django.http import HttpResponseRedirect
from django.http import JsonResponse
from django.utils import timezone
from django.views.decorators.csrf import ensure_csrf_cookie
import random
imp... | {
"repo_name": "zserg/flashcard",
"path": "flashcardgui/views.py",
"copies": "1",
"size": "3354",
"license": "mit",
"hash": -656649284361654900,
"line_mean": 26.95,
"line_max": 83,
"alpha_frac": 0.576326774,
"autogenerated": false,
"ratio": 3.8070374574347334,
"config_test": false,
"has_no_key... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.utils.decorators import method_decorator
from django.shortcuts import *
from django.shortcuts import get_object_or_404, render, render_to_response, redirect
from django.http import HttpResponseRedirect
from django.... | {
"repo_name": "Thuruv/ticketman",
"path": "ticketman/app/views.py",
"copies": "1",
"size": "3221",
"license": "unlicense",
"hash": 7918944518321025000,
"line_mean": 36.0229885057,
"line_max": 88,
"alpha_frac": 0.5619372866,
"autogenerated": false,
"ratio": 4.30614973262032,
"config_test": false... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.utils.decorators import method_decorator
from django.views.generic.edit import CreateView, UpdateView, DeleteView
from django.views.generic import ListView
from django.views.generic.detail import DetailView
from dj... | {
"repo_name": "Humch/nxt-simplecost",
"path": "simplecost/views.py",
"copies": "1",
"size": "12331",
"license": "mit",
"hash": 1783599701826326000,
"line_mean": 37.53125,
"line_max": 178,
"alpha_frac": 0.6206504988,
"autogenerated": false,
"ratio": 4.081098973849719,
"config_test": false,
"ha... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.utils.decorators import method_decorator
from django.views import View
from django.views.generic import ListView
from django.views.generic.edit import CreateView, UpdateView, DeleteView
from django.views.generic.de... | {
"repo_name": "Humch/django-paperworks",
"path": "paperworks/views.py",
"copies": "1",
"size": "7296",
"license": "mit",
"hash": 4191587607741042000,
"line_mean": 32.0135746606,
"line_max": 111,
"alpha_frac": 0.6344572368,
"autogenerated": false,
"ratio": 4.030939226519337,
"config_test": false... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.views.decorators.csrf import csrf_exempt
from django.http import HttpResponse
from django.views.decorators.http import require_POST
from django.shortcuts import get_object_or_404
from django.core.paginator import P... | {
"repo_name": "glon/django_test",
"path": "article/views.py",
"copies": "1",
"size": "6502",
"license": "apache-2.0",
"hash": 6654725894053499000,
"line_mean": 35.1222222222,
"line_max": 164,
"alpha_frac": 0.6453398954,
"autogenerated": false,
"ratio": 3.863339275103981,
"config_test": false,
... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.views.decorators.csrf import csrf_exempt
from django.http.response import HttpResponse, HttpResponseRedirect
from django.utils.decorators import method_decorator
from django.views.decorators.csrf import csrf_exempt... | {
"repo_name": "naelstrof/PugBot-Discord-Django",
"path": "api/views.py",
"copies": "1",
"size": "39650",
"license": "mit",
"hash": -5147273147811455000,
"line_mean": 41.2707889126,
"line_max": 215,
"alpha_frac": 0.5216141236,
"autogenerated": false,
"ratio": 3.698004103711994,
"config_test": fa... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from django.views.generic import FormView, ListView
from django.utils.decorators import method_decorator
from django.core.urlresolvers import reverse
from django.views.defaults import page_not_found
from modularodm import Q
f... | {
"repo_name": "brandonPurvis/osf.io",
"path": "admin/spam/views.py",
"copies": "2",
"size": "3502",
"license": "apache-2.0",
"hash": 4360991257164214000,
"line_mean": 32.6730769231,
"line_max": 118,
"alpha_frac": 0.6222158766,
"autogenerated": false,
"ratio": 3.761546723952739,
"config_test": f... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from forms import GenerateForm, SubmitForm
from django.http import HttpResponse, Http404, HttpResponseBadRequest
from django.utils.translation import ugettext as _, ugettext_lazy
from django.db import transaction
from main.mod... | {
"repo_name": "oadam/proprio",
"path": "bank_import/views.py",
"copies": "1",
"size": "9434",
"license": "mit",
"hash": 8700115786897392000,
"line_mean": 32.3356890459,
"line_max": 79,
"alpha_frac": 0.6373754505,
"autogenerated": false,
"ratio": 3.611791730474732,
"config_test": false,
"has_n... |
from django.shortcuts import render
# from django.contrib.auth.decorators import login_required
from .forms import PostForm
from authentication.nodes import UserNode,PostNode
from authentication.models import UserProfile
from django.http import HttpResponse,HttpResponseRedirect
from operator import attrgetter
from djan... | {
"repo_name": "programmernoob1/MeeT",
"path": "home/views.py",
"copies": "1",
"size": "4411",
"license": "apache-2.0",
"hash": 7396060301699527000,
"line_mean": 36.3898305085,
"line_max": 135,
"alpha_frac": 0.6395375198,
"autogenerated": false,
"ratio": 3.815743944636678,
"config_test": false,
... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from forms import SkyPictureQueryForm
from data.models import SkyPicture, MeasuringDevice
from django.template.context_processors import csrf
from django.core.paginator import Paginator, EmptyPage, PageNotAnInteger
@login_req... | {
"repo_name": "FSavoy/visuo-server",
"path": "picture_browser/views.py",
"copies": "1",
"size": "2788",
"license": "bsd-3-clause",
"hash": 8951179752241006000,
"line_mean": 40.6119402985,
"line_max": 147,
"alpha_frac": 0.6520803443,
"autogenerated": false,
"ratio": 3.8349381017881705,
"config_t... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from .forms import VerificationCodeForm
from twilio.rest import TwilioRestClient
from django.http import HttpResponseRedirect, HttpResponse
from django2fa.settings import TWILIO_ACCOUNT_SID, TWILIO_AUTH_TOKEN, TWILIO_PHONE_NUM... | {
"repo_name": "frankmaina/django2fa",
"path": "verification/views.py",
"copies": "1",
"size": "4641",
"license": "mit",
"hash": -1531635894524659500,
"line_mean": 42.3738317757,
"line_max": 151,
"alpha_frac": 0.6298211592,
"autogenerated": false,
"ratio": 4.613320079522863,
"config_test": false... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from imager_images.models import ImagerPhoto, ImagerAlbum, User
from django.views.generic import UpdateView
from imagerprofile.models import ImagerProfile
# from imagerprofile.forms import UserProfileForm
class ImagerProfile... | {
"repo_name": "nbeck90/django-imager",
"path": "imager/imagerprofile/views.py",
"copies": "1",
"size": "4103",
"license": "mit",
"hash": 4706480456023413000,
"line_mean": 29.6194029851,
"line_max": 92,
"alpha_frac": 0.6249086035,
"autogenerated": false,
"ratio": 3.580279232111693,
"config_test"... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from productores.models import *
from reportes.models import *
import json as simplejson
from django.http import HttpResponse
# Create your views here.
@login_required
def index(request,template="index.html"):
try:
... | {
"repo_name": "CARocha/plasystem",
"path": "plasystem/views.py",
"copies": "1",
"size": "1896",
"license": "mit",
"hash": -3676497668223385600,
"line_mean": 34.1296296296,
"line_max": 77,
"alpha_frac": 0.6371308017,
"autogenerated": false,
"ratio": 3.646153846153846,
"config_test": false,
"ha... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from requests.models import Request
from profiles.models import Profile
from django.views.generic import UpdateView
from profiles.forms import UserProfileForm
class ProfileUpdateView(UpdateView):
model = Profile
temp... | {
"repo_name": "nbeck90/city-swap",
"path": "cityswap/profiles/views.py",
"copies": "1",
"size": "1499",
"license": "mit",
"hash": 3355799168554384000,
"line_mean": 32.3111111111,
"line_max": 74,
"alpha_frac": 0.6817878586,
"autogenerated": false,
"ratio": 3.8733850129198966,
"config_test": fals... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from shaker.shaker_core import *
from minions.models import Minions_status
from returner.models import Salt_grains
from shaker.tasks import accept_grains_task, minions_status_task
import logging
logger = logging.getLogger('dj... | {
"repo_name": "yueyongyue/saltshaker",
"path": "minions/views.py",
"copies": "1",
"size": "3341",
"license": "apache-2.0",
"hash": 2490034344120277000,
"line_mean": 36.9659090909,
"line_max": 100,
"alpha_frac": 0.5950314277,
"autogenerated": false,
"ratio": 3.4126659856996935,
"config_test": fa... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from shaker.shaker_core import *
from shaker.nodegroups import *
@login_required(login_url="/account/login/")
def shell_runcmd(request):
group = NodeGroups()
all = group.list_groups_hosts()
return render(request, ... | {
"repo_name": "net592/OneOps",
"path": "execute/views.py",
"copies": "2",
"size": "1088",
"license": "apache-2.0",
"hash": -8638060022187267000,
"line_mean": 40.8846153846,
"line_max": 113,
"alpha_frac": 0.6516544118,
"autogenerated": false,
"ratio": 3.6266666666666665,
"config_test": false,
... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from shaker.shaker_core import *
from shaker.nodegroups import *
#本地缓存主机信息
execfile('/tmp/salt_file.tmp')
@login_required(login_url="/account/login/")
def minions_status(request):
status_up = []
status_down = []
g... | {
"repo_name": "xuhengpw/saltshakerxh",
"path": "minions/views.py",
"copies": "1",
"size": "2652",
"license": "apache-2.0",
"hash": 8315573297632754000,
"line_mean": 36.6571428571,
"line_max": 88,
"alpha_frac": 0.62784522,
"autogenerated": false,
"ratio": 3.2423124231242313,
"config_test": false... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from api.task.log import get_tasklog_cached
from gui.tasklog.utils import get_tasklog
from gui.tasklog.forms import TaskLogFilterForm
from gui.decorators import ajax_required, profile_required
from gui.utils import collect_vi... | {
"repo_name": "erigones/esdc-ce",
"path": "gui/tasklog/views.py",
"copies": "1",
"size": "1250",
"license": "apache-2.0",
"hash": 5662216856459599000,
"line_mean": 31.8947368421,
"line_max": 101,
"alpha_frac": 0.7296,
"autogenerated": false,
"ratio": 3.5511363636363638,
"config_test": false,
... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from custom.views import group_required
from django.utils.timezone import get_current_timezone
from django.contrib.auth.models import User, Group
from dateutil.parser import parse
from accounts.models import author, BDHuse... | {
"repo_name": "ejerzyk/editBoard",
"path": "BDHapp/management/views.py",
"copies": "1",
"size": "6657",
"license": "apache-2.0",
"hash": 4449282422840251000,
"line_mean": 39.5975609756,
"line_max": 574,
"alpha_frac": 0.7085774373,
"autogenerated": false,
"ratio": 2.971875,
"config_test": false,... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from .models import Tag, TaggedItem
from .forms import TagItForm
from django.contrib.contenttypes.models import ContentType
from django.shortcuts import redirect
def tag_cloud(request):
tags = Tag.objects.all()
tag_... | {
"repo_name": "acidjunk/django-tagger",
"path": "tagger/views.py",
"copies": "1",
"size": "2515",
"license": "bsd-3-clause",
"hash": -4704458903756294000,
"line_mean": 34.4225352113,
"line_max": 84,
"alpha_frac": 0.6516898608,
"autogenerated": false,
"ratio": 3.4882108183079055,
"config_test": ... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required
from .models import ZhiHuCollection, ZhiHuCategory, CollectionArticle, Collection
@login_required
def index(request):
context = {}
article_list = []
categories = ZhiHuCategory.objects.all()
for category in c... | {
"repo_name": "studyxiao/blog-site",
"path": "mycollections/views.py",
"copies": "1",
"size": "1399",
"license": "apache-2.0",
"hash": 4317375046440857600,
"line_mean": 33.975,
"line_max": 81,
"alpha_frac": 0.7012151537,
"autogenerated": false,
"ratio": 3.9971428571428573,
"config_test": false,... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required, permission_required
from django.utils.html import escape
from django.db.models import Q
from django.db.models import Value
from django.db.models.functions import Concat
from directorio.models import Profesor, Asignatura
from... | {
"repo_name": "josemfc/directorio-iep",
"path": "directorio/views/vistas_index.py",
"copies": "1",
"size": "2658",
"license": "apache-2.0",
"hash": -4833953739163820000,
"line_mean": 34.4133333333,
"line_max": 236,
"alpha_frac": 0.6837349398,
"autogenerated": false,
"ratio": 2.8376068376068377,
... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required, user_passes_test
from django.http import HttpResponseRedirect
from django.core.urlresolvers import reverse
from django.db.models import Q
from postermap.models import Poster
from ticketing.models import Production
from core.m... | {
"repo_name": "tfiers/arenberg-online",
"path": "postermap/views.py",
"copies": "1",
"size": "3088",
"license": "mit",
"hash": 7364227686976519000,
"line_mean": 38.6025641026,
"line_max": 108,
"alpha_frac": 0.7370466321,
"autogenerated": false,
"ratio": 3.1933815925542914,
"config_test": false,... |
from django.shortcuts import render
from django.contrib.auth.decorators import login_required, user_passes_test
from django.shortcuts import get_object_or_404
from django.http import HttpResponseRedirect
from django.urls import reverse
from .models import Announcement
from .forms import AnnouncementForm
def announcem... | {
"repo_name": "ByrdOfAFeather/AlphaTrion",
"path": "Announcements/views.py",
"copies": "1",
"size": "1700",
"license": "mit",
"hash": 4667493505864487000,
"line_mean": 26.868852459,
"line_max": 99,
"alpha_frac": 0.7564705882,
"autogenerated": false,
"ratio": 3.476482617586912,
"config_test": fa... |
from django.shortcuts import render
from django.contrib.auth.decorators import permission_required
from django.conf import settings
from django.template import RequestContext
from django.template.loader import render_to_string
from wagtail.wagtailadmin.forms import SearchForm
from wagtail.wagtailcore import hooks
fro... | {
"repo_name": "benemery/wagtail",
"path": "wagtail/wagtailadmin/views/home.py",
"copies": "6",
"size": "3023",
"license": "bsd-3-clause",
"hash": -6225400056526476000,
"line_mean": 32.9662921348,
"line_max": 137,
"alpha_frac": 0.6685411843,
"autogenerated": false,
"ratio": 3.920881971465629,
"c... |
from django.shortcuts import render
from django.contrib.auth.decorators import permission_required
from wagtail.wagtailadmin.userbar import EditPageItem, AddPageItem, ApproveModerationEditPageItem, \
RejectModerationEditPageItem
from wagtail.wagtailcore import hooks
from wagtail.wagtailcore.models import Page, Pag... | {
"repo_name": "JoshBarr/wagtail",
"path": "wagtail/wagtailadmin/views/userbar.py",
"copies": "5",
"size": "1803",
"license": "bsd-3-clause",
"hash": -4254808807162141700,
"line_mean": 33.0188679245,
"line_max": 100,
"alpha_frac": 0.7176927343,
"autogenerated": false,
"ratio": 3.8118393234672303,
... |
from django.shortcuts import render
from django.contrib.auth.decorators import permission_required
from wagtail.wagtailadmin.userbar import EditPageItem, AddPageItem, ApproveModerationEditPageItem, RejectModerationEditPageItem
from wagtail.wagtailcore import hooks
from wagtail.wagtailcore.models import Page, PageRevis... | {
"repo_name": "100Shapes/wagtail",
"path": "wagtail/wagtailadmin/views/userbar.py",
"copies": "10",
"size": "1801",
"license": "bsd-3-clause",
"hash": -2011446056136915700,
"line_mean": 33.6346153846,
"line_max": 127,
"alpha_frac": 0.7196002221,
"autogenerated": false,
"ratio": 3.807610993657505,... |
from django.shortcuts import render
from django.contrib.auth.decorators import user_passes_test, login_required
from django.http import HttpResponseRedirect
from django.core.paginator import Paginator, EmptyPage, PageNotAnInteger
import approver.utils as utils
from approver.models import Person
from approver.constants... | {
"repo_name": "ctsit/qipr_approver",
"path": "qipr_approver/approver/views/userlist.py",
"copies": "1",
"size": "1697",
"license": "apache-2.0",
"hash": -5131524290766095000,
"line_mean": 39.4047619048,
"line_max": 85,
"alpha_frac": 0.6263995286,
"autogenerated": false,
"ratio": 4.059808612440191... |
from django.shortcuts import render
from django.contrib.auth.decorators import user_passes_test
from rest_framework.permissions import IsAdminUser
from guide.models import ArtificialProblem
# Create your views here.
from rest_framework import viewsets
from members.models import User, Member
from members.seria... | {
"repo_name": "jalibras/coop",
"path": "coop/members/views.py",
"copies": "1",
"size": "1255",
"license": "apache-2.0",
"hash": 5446919307206555000,
"line_mean": 24.612244898,
"line_max": 93,
"alpha_frac": 0.7171314741,
"autogenerated": false,
"ratio": 3.971518987341772,
"config_test": false,
... |
# from django.shortcuts import render
from django.contrib.auth.forms import AuthenticationForm
from django.http import HttpResponseRedirect
from django.utils.decorators import method_decorator
from django.views import generic
from django.shortcuts import redirect
from django.core.urlresolvers import reverse_lazy, rever... | {
"repo_name": "iago-suarez/ancoweb-TFG",
"path": "src/accounts/views.py",
"copies": "1",
"size": "3037",
"license": "apache-2.0",
"hash": 2071862540161244200,
"line_mean": 35.1547619048,
"line_max": 74,
"alpha_frac": 0.6513006256,
"autogenerated": false,
"ratio": 4.307801418439716,
"config_test... |
from django.shortcuts import render
from django.contrib.auth.forms import AuthenticationForm, UserCreationForm
from django.contrib.auth import authenticate, login, logout
from django.contrib.auth.decorators import login_required
from django.contrib.auth.models import User
from django.http import HttpResponseRedirect, H... | {
"repo_name": "katsuya94/CollegeCareerPlanner",
"path": "usrman/views.py",
"copies": "1",
"size": "2500",
"license": "mit",
"hash": 1994915488131371800,
"line_mean": 32.3466666667,
"line_max": 117,
"alpha_frac": 0.7292,
"autogenerated": false,
"ratio": 3.4722222222222223,
"config_test": false,
... |
from django.shortcuts import render
from django.contrib.auth.forms import UserCreationForm
from django.contrib.auth.models import User
from django.contrib.auth import authenticate, login, logout
from django.core.urlresolvers import reverse_lazy
from django.views.generic import CreateView, FormView, RedirectView
from .f... | {
"repo_name": "hbutau/pyladies",
"path": "accounts/views.py",
"copies": "2",
"size": "1311",
"license": "mit",
"hash": -1812145400119609000,
"line_mean": 32.6153846154,
"line_max": 68,
"alpha_frac": 0.7055682685,
"autogenerated": false,
"ratio": 4.0588235294117645,
"config_test": false,
"has_... |
from django.shortcuts import render
from django.contrib.auth.forms import UserCreationForm
from django.core.urlresolvers import reverse
from django.shortcuts import redirect, render_to_response
from django.contrib.auth import authenticate, login
from django.contrib.auth.models import User
from django.template.context i... | {
"repo_name": "axsauze/eventsfinder",
"path": "eventsfinder/views.py",
"copies": "1",
"size": "7466",
"license": "bsd-3-clause",
"hash": -1273081801790404600,
"line_mean": 34.5571428571,
"line_max": 189,
"alpha_frac": 0.6425127244,
"autogenerated": false,
"ratio": 3.840534979423868,
"config_tes... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login as auth_login, logout as auth_logout
from django.http import HttpResponseRedirect
from django.contrib.auth.models import User
def login(request):
login_error = ""
nexturl = request.GET.get('next', '/')
try:
user... | {
"repo_name": "jonhoo/django-zoobar",
"path": "zlogio/views.py",
"copies": "1",
"size": "1812",
"license": "mit",
"hash": -8529576432250098000,
"line_mean": 40.1818181818,
"line_max": 94,
"alpha_frac": 0.5932671082,
"autogenerated": false,
"ratio": 4.731070496083551,
"config_test": false,
"ha... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login as django_login
from django.contrib import messages
from django.http.response import HttpResponseRedirect
from django.urls import reverse
from .models import Usuario
def login(request):
if request.method == 'POST':
sia... | {
"repo_name": "vinigracindo/universidade_digital",
"path": "src/universidade_digital/apps/nucleo/views.py",
"copies": "1",
"size": "1338",
"license": "bsd-3-clause",
"hash": -785784640175491100,
"line_mean": 43.5333333333,
"line_max": 128,
"alpha_frac": 0.6696629213,
"autogenerated": false,
"rati... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login as LOGIN, logout as LOGOUT
from django.contrib.auth.decorators import login_required
from django.http import HttpResponse, HttpResponseRedirect
from mainsite import forms
from .models import *
from django.contrib.auth.models import ... | {
"repo_name": "kylebegovich/ICIdo",
"path": "mainsite/views.py",
"copies": "1",
"size": "2554",
"license": "mit",
"hash": 2658917283617153000,
"line_mean": 36.5588235294,
"line_max": 121,
"alpha_frac": 0.6186374315,
"autogenerated": false,
"ratio": 4.180032733224222,
"config_test": false,
"ha... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login, logout
from django.contrib.auth.decorators import login_required
from django.http import HttpResponseRedirect, HttpResponse
from django.core.urlresolvers import reverse
from django.shortcuts import get_object_or_404
from django.uti... | {
"repo_name": "skill-huddle/skill-huddle",
"path": "sh_app/views.py",
"copies": "1",
"size": "18121",
"license": "mit",
"hash": -190857215845295460,
"line_mean": 40.5619266055,
"line_max": 126,
"alpha_frac": 0.5914132774,
"autogenerated": false,
"ratio": 3.8637526652452028,
"config_test": false... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login, logout
from django.contrib.auth.decorators import login_required
from django.shortcuts import redirect
# Create your views here.
def signin(request):
if request.method == 'POST' and 'username' in request.POST:
username ... | {
"repo_name": "wasit7/PythonDay",
"path": "django/mysite2/myauthen/views.py",
"copies": "1",
"size": "1753",
"license": "bsd-3-clause",
"hash": 6474331478493629000,
"line_mean": 34.7959183673,
"line_max": 76,
"alpha_frac": 0.6303479749,
"autogenerated": false,
"ratio": 4.19377990430622,
"config... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login, logout
from django.contrib.auth.decorators import login_required
from django.shortcuts import redirect
from django.contrib.sessions.models import Session
import sys
import social.apps.django_app.default.models as sm
# Create your v... | {
"repo_name": "wasit7/PythonDay",
"path": "django/mysite3_/myquiz/views.py",
"copies": "1",
"size": "1450",
"license": "bsd-3-clause",
"hash": 5123947035709319000,
"line_mean": 33.5238095238,
"line_max": 95,
"alpha_frac": 0.675862069,
"autogenerated": false,
"ratio": 3.5626535626535625,
"config... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login, logout
from django.contrib.auth.decorators import login_required
from django.shortcuts import redirect
import social.apps.django_app.default.models as sm
# Create your views here.
def signin(request):
if request.method == 'POST... | {
"repo_name": "wasit7/PythonDay",
"path": "django/mysite3_/myauthen/views.py",
"copies": "1",
"size": "1918",
"license": "bsd-3-clause",
"hash": -4900524085736349000,
"line_mean": 38.9791666667,
"line_max": 99,
"alpha_frac": 0.6293013556,
"autogenerated": false,
"ratio": 4.046413502109704,
"con... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login, logout
from django.core.urlresolvers import reverse_lazy
from django.views.generic import CreateView, FormView, RedirectView, TemplateView
from .forms import RegistrationForm, LoginForm
from django.contrib.auth.models import User
... | {
"repo_name": "pyladieshre/pyladies",
"path": "accounts/views.py",
"copies": "1",
"size": "2031",
"license": "mit",
"hash": -9220520992660453000,
"line_mean": 28.0142857143,
"line_max": 81,
"alpha_frac": 0.6676514032,
"autogenerated": false,
"ratio": 4.037773359840954,
"config_test": false,
"... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login, logout
from django.core.urlresolvers import reverse
from django.http import HttpResponseRedirect
from django.views import generic
import random
from question.models import Question, Category1, Category2, Category3, Choice
from sq... | {
"repo_name": "aejenner/sequoia",
"path": "djangoSQ/SiQuoia/squser/views.py",
"copies": "1",
"size": "4871",
"license": "mit",
"hash": 3523788412082341400,
"line_mean": 22.3062200957,
"line_max": 118,
"alpha_frac": 0.6877437898,
"autogenerated": false,
"ratio": 2.5489272632129776,
"config_test"... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login, logout
from django.http import HttpResponse, HttpResponseRedirect
from ljosmyndasida import settings
from django.contrib.auth.decorators import login_required
def Login(request):
next = request.GET.get('next', '/')
if requ... | {
"repo_name": "dadisigursveinn/VEF-Lokaverkefni",
"path": "index/views.py",
"copies": "1",
"size": "1089",
"license": "bsd-3-clause",
"hash": -689734738523108400,
"line_mean": 31.0588235294,
"line_max": 65,
"alpha_frac": 0.668503214,
"autogenerated": false,
"ratio": 4.463114754098361,
"config_t... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login, logout
from django.http import HttpResponse, JsonResponse, HttpResponseRedirect
from django.urls import reverse
from django.contrib.auth.models import User
from django.views.generic import View, TemplateView, ListView
from django.c... | {
"repo_name": "mingziV5/opsweb_test",
"path": "accounts/views.py",
"copies": "1",
"size": "3861",
"license": "apache-2.0",
"hash": 5536100617648213000,
"line_mean": 36.4215686275,
"line_max": 100,
"alpha_frac": 0.6368876081,
"autogenerated": false,
"ratio": 3.8055832502492524,
"config_test": fa... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login, logout
from django.http import HttpResponseRedirect, HttpResponse
from django.conf import settings
from django.core.urlresolvers import reverse
from django.contrib.auth.forms import AuthenticationForm
from django.contrib.auth.decor... | {
"repo_name": "math4youbyusgroupillinois/large-lots",
"path": "lots_admin/views.py",
"copies": "1",
"size": "5059",
"license": "mit",
"hash": 1543968355236562700,
"line_mean": 36.1985294118,
"line_max": 126,
"alpha_frac": 0.5845028662,
"autogenerated": false,
"ratio": 3.853008377760853,
"config... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login, logout
from django.http import HttpResponseRedirect, HttpResponse
from django.core.urlresolvers import reverse
from django.contrib.auth.forms import AuthenticationForm
from django.contrib.auth.decorators import login_required
from ... | {
"repo_name": "skorasaurus/large-lots",
"path": "lots_admin/views.py",
"copies": "2",
"size": "5412",
"license": "mit",
"hash": -5189328076371766000,
"line_mean": 33.6923076923,
"line_max": 128,
"alpha_frac": 0.593495935,
"autogenerated": false,
"ratio": 3.6666666666666665,
"config_test": false... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login, logout
from django.http import HttpResponseRedirect
from django.core.exceptions import ObjectDoesNotExist
from django.contrib.auth.decorators import login_required
from django.contrib.auth.models import User
from .models import Tas... | {
"repo_name": "jailuthra/taskzilla",
"path": "taskzilla/views.py",
"copies": "2",
"size": "3846",
"license": "mit",
"hash": 8110838978927542000,
"line_mean": 34.2844036697,
"line_max": 112,
"alpha_frac": 0.7360894436,
"autogenerated": false,
"ratio": 3.521978021978022,
"config_test": false,
"... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login, logout
from django.http import HttpResponseRedirect
from django.urls import reverse
from django.core.paginator import Paginator, EmptyPage, PageNotAnInteger
from index.models import *
from news.models import *
from index.forms impo... | {
"repo_name": "light-white/meeting",
"path": "index/views.py",
"copies": "1",
"size": "4379",
"license": "apache-2.0",
"hash": 1303909701192794000,
"line_mean": 38.5545454545,
"line_max": 190,
"alpha_frac": 0.5817053551,
"autogenerated": false,
"ratio": 4.333665338645418,
"config_test": false,
... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login
from django.contrib.auth.decorators import login_required
from django.views.decorators.http import require_http_methods
from django.conf import settings
from django.http import HttpResponseRedirect
from oauth import kong, forms
@lo... | {
"repo_name": "toast38coza/docker-kong-oauth",
"path": "userservice/oauth/views.py",
"copies": "1",
"size": "2113",
"license": "mit",
"hash": -3006033271588118000,
"line_mean": 30.5373134328,
"line_max": 74,
"alpha_frac": 0.6611452911,
"autogenerated": false,
"ratio": 3.8278985507246377,
"confi... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login
from django.contrib.auth.models import User
from django.views.decorators.csrf import csrf_protect, ensure_csrf_cookie
from rest_framework import permissions, viewsets
from app1.models import Tweet
from app1.permissions import IsAut... | {
"repo_name": "aredmond/djangular",
"path": "code/app1/views.py",
"copies": "1",
"size": "1033",
"license": "mit",
"hash": 2117652068851157200,
"line_mean": 30.303030303,
"line_max": 73,
"alpha_frac": 0.7512100678,
"autogenerated": false,
"ratio": 4.115537848605578,
"config_test": false,
"has... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login
from django.http import HttpResponse, Http404, HttpResponseRedirect
from django.contrib.auth.models import User
from django.views import generic
# Create your views here.
from todo.models import TodoList
'''
def login_view(requ... | {
"repo_name": "zhy0216/django-todo",
"path": "todo/views.py",
"copies": "1",
"size": "1311",
"license": "mit",
"hash": -4020496151598888400,
"line_mean": 23.2777777778,
"line_max": 68,
"alpha_frac": 0.6674294432,
"autogenerated": false,
"ratio": 4.2290322580645165,
"config_test": false,
"has_... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login
from django.http import HttpResponseRedirect, HttpResponse, JsonResponse
from app.models import Bar, Tapa
from app.forms import BarForm, TapaForm, RegistroForm
from django.contrib.auth import logout
from django.contrib.auth.decorat... | {
"repo_name": "AngelValera/Practica_7_DAI",
"path": "app/views.py",
"copies": "2",
"size": "8640",
"license": "mit",
"hash": -5937389827055291000,
"line_mean": 33.8387096774,
"line_max": 122,
"alpha_frac": 0.6236111111,
"autogenerated": false,
"ratio": 3.870967741935484,
"config_test": false,
... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login
from django.http import HttpResponseRedirect, HttpResponse
from django.contrib.auth import logout
from .forms import UserForm, UserProfileForm
def register(request):
registered = False
if request.method == 'POST':
... | {
"repo_name": "studyxiao/blog-site",
"path": "user/views.py",
"copies": "1",
"size": "1801",
"license": "apache-2.0",
"hash": 3434745878098250000,
"line_mean": 29.1186440678,
"line_max": 94,
"alpha_frac": 0.6133933596,
"autogenerated": false,
"ratio": 4.355392156862745,
"config_test": false,
... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login
from django.http import HttpResponseRedirect, HttpResponse
from django.views.decorators.csrf import csrf_exempt
from webapp_nkana.utils.common import mongo_instance
from rest_framework.views import APIView
from rest_framework.respo... | {
"repo_name": "kaarthikeyapreyan/Trust-for-Youth-and-Child-Leadership",
"path": "webapp_nkana/views.py",
"copies": "2",
"size": "3322",
"license": "apache-2.0",
"hash": -7003094595086918000,
"line_mean": 42.7105263158,
"line_max": 118,
"alpha_frac": 0.5424443107,
"autogenerated": false,
"ratio": ... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login
import os
from rest_framework import generics
from monitor.serializers import PiSerializer
from monitor.models import Raspberry
from django.http import HttpResponse
import json
import re
import time
def index(request):
# if us... | {
"repo_name": "GaryLam56/RaspberryPiMonitor",
"path": "monitor/views.py",
"copies": "1",
"size": "4090",
"license": "mit",
"hash": -7771845511161975000,
"line_mean": 34.5652173913,
"line_max": 114,
"alpha_frac": 0.6012224939,
"autogenerated": false,
"ratio": 3.755739210284665,
"config_test": fa... |
from django.shortcuts import render
from django.contrib.auth import authenticate, login, views as auth_views
from django.views import generic
'''
from .models import MyUserManager, MyUser
#class IndexView(generic):
# model = MyUser
# template_name = 'uiaccounts/login.html'
def login(request):
username = req... | {
"repo_name": "hongchhe/mypython",
"path": "django/projects/uicloud/uiaccounts/views.py",
"copies": "1",
"size": "22423",
"license": "apache-2.0",
"hash": -2424971806832219000,
"line_mean": 36.6224832215,
"line_max": 112,
"alpha_frac": 0.6389421576,
"autogenerated": false,
"ratio": 4.193566485879... |
from django.shortcuts import render
from django.contrib.auth import authenticate, logout as lg
from django.http import HttpResponseRedirect
from django.contrib.auth.decorators import login_required
from django.contrib import auth
from chartjs.views.lines import BaseLineChartView
from .forms import ChooseStudentForm
fro... | {
"repo_name": "PayPal-Opportunity-Hack-Chennai-2015/ANEW",
"path": "anew/assessment_management/views.py",
"copies": "2",
"size": "2880",
"license": "apache-2.0",
"hash": 3431424112517544000,
"line_mean": 33.7108433735,
"line_max": 98,
"alpha_frac": 0.6482638889,
"autogenerated": false,
"ratio": 3... |
from django.shortcuts import render
from django.contrib.auth import authenticate, logout, login
from django.contrib.auth.decorators import login_required
from django.core.urlresolvers import reverse
from django.http import HttpResponseRedirect, HttpResponse, Http404
from django.contrib import messages
from iedu.forms ... | {
"repo_name": "wispwisp/interactiveEducator",
"path": "iedu/views.py",
"copies": "1",
"size": "3875",
"license": "mit",
"hash": 5303322375204763000,
"line_mean": 33.7706422018,
"line_max": 77,
"alpha_frac": 0.6427440633,
"autogenerated": false,
"ratio": 3.9894736842105263,
"config_test": false,... |
from django.shortcuts import render
from django.contrib.auth import authenticate, logout, login
from django.contrib.auth.models import User
from django.shortcuts import redirect, HttpResponseRedirect
from django.db.models import Q
from django.core import serializers
from django.shortcuts import render_to_response, get_... | {
"repo_name": "G4brym/Ecomerce",
"path": "Main/views/products.py",
"copies": "1",
"size": "2281",
"license": "apache-2.0",
"hash": 1283866037284806400,
"line_mean": 39.0175438596,
"line_max": 193,
"alpha_frac": 0.7466023674,
"autogenerated": false,
"ratio": 4.239776951672862,
"config_test": fal... |
from django.shortcuts import render
from django.contrib.auth import authenticate, logout
from django.contrib.auth import login as login_1
from django.http import HttpResponse, HttpResponseRedirect, JsonResponse
from studnit import settings
def login(request):
next = request.GET.get('next', '/home/')
if reques... | {
"repo_name": "sonali0901/hackathon-studnit",
"path": "studnit/studnit_app/views.py",
"copies": "1",
"size": "1386",
"license": "mit",
"hash": -7712451034733990000,
"line_mean": 31.2325581395,
"line_max": 75,
"alpha_frac": 0.6305916306,
"autogenerated": false,
"ratio": 4.125,
"config_test": fal... |
from django.shortcuts import render
from django.contrib.auth import (authenticate,
login,
logout,
)
from django.contrib.auth.models import User
from django.http import (HttpResponseRedirect,
JsonR... | {
"repo_name": "kyokley/vittlify",
"path": "vittlify/groceries/views.py",
"copies": "1",
"size": "6379",
"license": "bsd-3-clause",
"hash": -6389075607167166000,
"line_mean": 35.8728323699,
"line_max": 94,
"alpha_frac": 0.5826932121,
"autogenerated": false,
"ratio": 4.227302849569251,
"config_te... |
from django.shortcuts import render
from django.contrib.auth import get_user_model
from django.contrib.auth.models import Group
from django.contrib.auth.decorators import login_required
from profiles.models import Profile
from django.http import HttpResponseRedirect
User = get_user_model()
@login_required
def modera... | {
"repo_name": "abhijithanilkumar/ns-3-AppStore",
"path": "src/accounts/views_admin.py",
"copies": "1",
"size": "1464",
"license": "mit",
"hash": -2113264542766351400,
"line_mean": 31.5555555556,
"line_max": 61,
"alpha_frac": 0.6215846995,
"autogenerated": false,
"ratio": 4.055401662049862,
"con... |
from django.shortcuts import render
from django.contrib.auth import get_user_model
from django.http import Http404
from rest_framework import permissions, status, views, viewsets, generics
from rest_framework.response import Response
from rest_framework.authentication import BasicAuthentication, SessionAuthenticatio... | {
"repo_name": "hellojerry/buddy",
"path": "accounts/views.py",
"copies": "1",
"size": "4330",
"license": "mit",
"hash": -1166817477924262000,
"line_mean": 32.0534351145,
"line_max": 84,
"alpha_frac": 0.5889145497,
"autogenerated": false,
"ratio": 4.57233368532207,
"config_test": false,
"has_n... |
from django.shortcuts import render
from django.contrib.auth import login, authenticate, get_user
from django.contrib.auth.decorators import login_required
from django.contrib.auth.forms import UserCreationForm
from django.contrib.auth.models import User
from django.shortcuts import get_object_or_404, render, redirect,... | {
"repo_name": "GFynbo/GoudaTime",
"path": "swiper/views.py",
"copies": "1",
"size": "5690",
"license": "mit",
"hash": 2483697465399129600,
"line_mean": 25.9668246445,
"line_max": 126,
"alpha_frac": 0.6217926186,
"autogenerated": false,
"ratio": 4.3073429220287665,
"config_test": false,
"has_n... |
from django.shortcuts import render
from django.contrib.auth import login, logout, authenticate
from django.http import HttpResponseRedirect
from sf_user.models import CustomUser
import urllib
import uuid
# Create your views here.
def login_view(request):
if hasattr(request.user, "is_guest_user") and request.user... | {
"repo_name": "superfluidity/RDCL3D",
"path": "code/sf_user/views.py",
"copies": "1",
"size": "2717",
"license": "apache-2.0",
"hash": 2847162872645940000,
"line_mean": 36.2328767123,
"line_max": 152,
"alpha_frac": 0.6293706294,
"autogenerated": false,
"ratio": 3.8539007092198583,
"config_test"... |
from django.shortcuts import render
from django.contrib.auth import login, logout
from django.http.response import HttpResponseRedirect, JsonResponse
from .forms import RegistrationForm, LoginForm
from django.contrib.auth.models import User
from django_mfa.models import is_u2f_enabled
from django.conf import settings
... | {
"repo_name": "MicroPyramid/django-mfa",
"path": "sandbox/sample/views.py",
"copies": "1",
"size": "1801",
"license": "mit",
"hash": -9186447496565003000,
"line_mean": 33.6346153846,
"line_max": 77,
"alpha_frac": 0.6635202665,
"autogenerated": false,
"ratio": 4.093181818181818,
"config_test": f... |
from django.shortcuts import render
from django.contrib.auth import logout
from django.template.context_processors import csrf
from django.utils.translation import ugettext, ugettext_lazy as _
from .models import *
from .utils import *
from .forms.users import *
import re
#Creates a login view
def login_action(request... | {
"repo_name": "Maachi/Gestion",
"path": "users/views.py",
"copies": "1",
"size": "2013",
"license": "mit",
"hash": 6633499400005785000,
"line_mean": 25.8533333333,
"line_max": 94,
"alpha_frac": 0.7108792846,
"autogenerated": false,
"ratio": 3.140405616224649,
"config_test": false,
"has_no_key... |
from django.shortcuts import render
from django.contrib.auth import logout
from django.template import RequestContext, loader
from django.contrib.auth import authenticate, login
from django.http import HttpResponse, HttpResponseRedirect
from django.conf import settings
from django.contrib.auth import authenticate, logi... | {
"repo_name": "castaway2000/OpenStay",
"path": "hackathon_starter/frontend/views.py",
"copies": "1",
"size": "7119",
"license": "mpl-2.0",
"hash": -5875210104005134000,
"line_mean": 37.9016393443,
"line_max": 183,
"alpha_frac": 0.5743784239,
"autogenerated": false,
"ratio": 4.418994413407821,
"... |
from django.shortcuts import render
from django.contrib.auth import views, authenticate, login, logout
from django.contrib.auth.models import User
from django.views.decorators.csrf import csrf_exempt
from django.http import HttpResponse
import json
from faver_app.models import FaverUser, FaverRequest, FaverContract
... | {
"repo_name": "Zylphrex/faver",
"path": "faver_site/faver_app/views.py",
"copies": "1",
"size": "5408",
"license": "mit",
"hash": 4590393816675054600,
"line_mean": 38.1884057971,
"line_max": 224,
"alpha_frac": 0.6911982249,
"autogenerated": false,
"ratio": 3.808450704225352,
"config_test": fals... |
from django.shortcuts import render
from django.contrib.auth.mixins import LoginRequiredMixin
from django.views.generic import ListView, DetailView, CreateView, UpdateView
from .models import Item
from .forms import ItemForm
class ItemListView(ListView):
def get_queryset(self):
return Item.objects.filter(... | {
"repo_name": "madebydaniz/django1-11",
"path": "src/menus/views.py",
"copies": "1",
"size": "1721",
"license": "mit",
"hash": -1712825624877059000,
"line_mean": 32.7450980392,
"line_max": 77,
"alpha_frac": 0.6891342243,
"autogenerated": false,
"ratio": 3.841517857142857,
"config_test": false,
... |
from django.shortcuts import render
from django.contrib.auth.mixins import LoginRequiredMixin
from django.views.generic import ListView, UpdateView, DetailView, CreateView
from django.core.urlresolvers import reverse
from .models import Approval as ApprovalModel, CommunicationApproval
from django.db.models import Q
fr... | {
"repo_name": "xzzy/statdev",
"path": "approvals/views.py",
"copies": "1",
"size": "15129",
"license": "apache-2.0",
"hash": -5690087715416603000,
"line_mean": 39.6693548387,
"line_max": 153,
"alpha_frac": 0.6213232864,
"autogenerated": false,
"ratio": 3.8663429593662153,
"config_test": false,
... |
from django.shortcuts import render
from django.contrib.auth.mixins import LoginRequiredMixin
from django.views.generic import ListView, UpdateView, DetailView
from django.core.urlresolvers import reverse
from .models import Approval as ApprovalModel
from django.db.models import Q
from django.contrib.auth.models impor... | {
"repo_name": "ropable/statdev",
"path": "approvals/views.py",
"copies": "1",
"size": "7311",
"license": "apache-2.0",
"hash": -2372054737931412500,
"line_mean": 38.9508196721,
"line_max": 153,
"alpha_frac": 0.6164683354,
"autogenerated": false,
"ratio": 3.876458112407211,
"config_test": false,... |
from django.shortcuts import render
from django.contrib.auth.mixins import LoginRequiredMixin
from django.views.generic import TemplateView
from .models import Plan, Task
from .serializers import PlanListSerializer, PlanSerializer, TaskListSerializer,TaskSerializer
from rest_framework import mixins
from rest_framework ... | {
"repo_name": "Joneyviana/todolist-django-angular",
"path": "todolist/dashboard/views.py",
"copies": "1",
"size": "2189",
"license": "mit",
"hash": 7019842959395714000,
"line_mean": 32.6923076923,
"line_max": 94,
"alpha_frac": 0.705801736,
"autogenerated": false,
"ratio": 4.091588785046729,
"co... |
from django.shortcuts import render
from django.contrib.auth.mixins import LoginRequiredMixin
from django.views import generic
from django.urls import reverse, reverse_lazy
from django.http import HttpResponseRedirect
from django.utils import timezone
from .models import Project, ProjectTodo
from .forms import Project... | {
"repo_name": "lindychi/mnec",
"path": "project/views.py",
"copies": "1",
"size": "3788",
"license": "mit",
"hash": -3788953197336066000,
"line_mean": 36.137254902,
"line_max": 129,
"alpha_frac": 0.6803062302,
"autogenerated": false,
"ratio": 3.822401614530777,
"config_test": false,
"has_no_k... |
from django.shortcuts import render
from django.contrib.auth.models import User, Group
from django.contrib.auth import authenticate, login, logout
from django.shortcuts import redirect
from .utils import getGroup
from .models import Board, Post, Category, Profile
from django.http import HttpResponse, HttpResponseRedire... | {
"repo_name": "porowns/Boards",
"path": "Boards/app/views.py",
"copies": "1",
"size": "14781",
"license": "bsd-3-clause",
"hash": 6543774027222947000,
"line_mean": 28.621242485,
"line_max": 88,
"alpha_frac": 0.5649144172,
"autogenerated": false,
"ratio": 4.244974152785756,
"config_test": false,... |
from django.shortcuts import render
from django.contrib.auth.models import User, Group
from rest_framework import viewsets
from imager_api.serializer import PhotoSerializer
from imager_images.models import Photo
from rest_framework import permissions
from imager_api.permissions import IsOwner
from rest_framework.respon... | {
"repo_name": "nadiabahrami/django-imager",
"path": "imagersite/imager_api/views.py",
"copies": "1",
"size": "1025",
"license": "mit",
"hash": 7330238986866310000,
"line_mean": 30.0909090909,
"line_max": 61,
"alpha_frac": 0.7180487805,
"autogenerated": false,
"ratio": 4.183673469387755,
"config... |
#from django.shortcuts import render
from django.contrib.auth.models import User, Group
from rest_framework import viewsets
from quickstart.serializers import UserSerializer, GroupSerializer
from rest_framework.views import APIView
from rest_framework.response import Response
from rest_framework import status
from quic... | {
"repo_name": "BTCX/BTCX_blockchain",
"path": "btcxblockchainapi/quickstart/views.py",
"copies": "1",
"size": "1295",
"license": "mit",
"hash": -9028320197918185000,
"line_mean": 31.375,
"line_max": 66,
"alpha_frac": 0.7065637066,
"autogenerated": false,
"ratio": 4.0092879256965945,
"config_tes... |
from django.shortcuts import render
from django.contrib.auth.models import User, Group
from rest_framework import viewsets
from reservas.reservasapi.serializers import UserSerializer, GroupSerializer, MerchantSerializer, MerchantItemSerializer
from reservas.reservasapi.models import Merchant, MerchantItem
class UserV... | {
"repo_name": "alexgarzao/poc_reservas",
"path": "reservas/reservas/reservasapi/views.py",
"copies": "1",
"size": "1140",
"license": "mit",
"hash": 714526957739569200,
"line_mean": 29.8108108108,
"line_max": 120,
"alpha_frac": 0.748245614,
"autogenerated": false,
"ratio": 4.175824175824176,
"co... |
from django.shortcuts import render
from django.contrib.auth.models import User, Group
from rest_framework import viewsets
from .serializers import *
from .models import *
from django.http import HttpResponse
from django.http.response import HttpResponseBadRequest
import json
import os
import time
from django.views.de... | {
"repo_name": "narsi84/digilib",
"path": "gui/views.py",
"copies": "1",
"size": "4488",
"license": "mit",
"hash": -7790434943393089000,
"line_mean": 26.2,
"line_max": 97,
"alpha_frac": 0.7303921569,
"autogenerated": false,
"ratio": 3.3871698113207547,
"config_test": false,
"has_no_keywords": ... |
from django.shortcuts import render
from django.contrib.auth.models import User, Group
from rest_framework import viewsets
from services.models import Event, Picture, Mosaic
from services.serializers import UserSerializer, GroupSerializer, EventSerializer, PictureSerializer, MosaicSerializer
from services.geolocalisati... | {
"repo_name": "insacloud/insacloud-back",
"path": "insacloud/services/views.py",
"copies": "1",
"size": "4550",
"license": "mit",
"hash": -4020257109118537700,
"line_mean": 35.9918699187,
"line_max": 163,
"alpha_frac": 0.703956044,
"autogenerated": false,
"ratio": 3.5714285714285716,
"config_te... |
from django.shortcuts import render
from django.contrib.auth.models import User, Group
from server.models import *
from api.serializers import *
from rest_framework import viewsets
from rest_framework.response import Response
from rest_framework.permissions import *
from rest_framework.decorators import detail_route, l... | {
"repo_name": "lancha90/menu",
"path": "api/views.py",
"copies": "1",
"size": "1984",
"license": "apache-2.0",
"hash": 5071967550647135000,
"line_mean": 31.5409836066,
"line_max": 79,
"alpha_frac": 0.6975806452,
"autogenerated": false,
"ratio": 4.082304526748971,
"config_test": false,
"has_no... |
from django.shortcuts import render
from django.contrib.auth.models import User
# Create your views here.
def base(request):
template = 'base.html'
html_code = """<form class="navbar-form navbar-right" role="form">
<div class="form-group">
<input type="text" placeholder="Email" class="form-control"... | {
"repo_name": "Constante/orcamento-facil",
"path": "orcamentos/views.py",
"copies": "1",
"size": "1044",
"license": "mit",
"hash": 9150754572700379000,
"line_mean": 21.2340425532,
"line_max": 77,
"alpha_frac": 0.6293103448,
"autogenerated": false,
"ratio": 3.125748502994012,
"config_test": fals... |
from django.shortcuts import render
from django.contrib.auth.models import User
from django.contrib.auth.decorators import login_required
from django.utils.decorators import method_decorator
from django.views.generic import ListView, DetailView, CreateView, UpdateView
from .models import Photographer
from django import... | {
"repo_name": "crashtack/django-imager",
"path": "imager_profile/views.py",
"copies": "1",
"size": "1473",
"license": "mit",
"hash": -9027455826573880000,
"line_mean": 34.9268292683,
"line_max": 77,
"alpha_frac": 0.7019687712,
"autogenerated": false,
"ratio": 3.7103274559193955,
"config_test": ... |
from django.shortcuts import render
from django.contrib.auth.models import User
from django.contrib.auth.decorators import login_required
from imager_images.models import Photo, Album
from django.views.generic import ListView, DetailView, CreateView, UpdateView
from django.utils.decorators import method_decorator
from ... | {
"repo_name": "crashtack/django-imager",
"path": "imager_images/views.py",
"copies": "1",
"size": "2946",
"license": "mit",
"hash": -7886440396838493000,
"line_mean": 33.2558139535,
"line_max": 77,
"alpha_frac": 0.6985743381,
"autogenerated": false,
"ratio": 3.5883069427527405,
"config_test": f... |
from django.shortcuts import render
from django.contrib.auth.models import User
from django.contrib.auth.decorators import login_required
from sesame import utils
from django.core.mail import send_mail
def login_page(request):
if request.method == "POST":
email = request.POST.get("emailId")
user =... | {
"repo_name": "greglinch/sourcelist",
"path": "django-magic-link/customers/views.py",
"copies": "1",
"size": "1143",
"license": "mit",
"hash": 5499205760701764000,
"line_mean": 30.7777777778,
"line_max": 107,
"alpha_frac": 0.615048119,
"autogenerated": false,
"ratio": 3.6634615384615383,
"confi... |
from django.shortcuts import render
from django.contrib.auth.models import User
from django.contrib.auth import authenticate, login, logout as dj_logout
import json
import couchdb
couchbase = "localhost:5984"
COUCH_BASE = couchbase
ADMIN_USER = "admin"
ADMIN_PASS = "admin"
def setup_db(username):
docdata = open(... | {
"repo_name": "iivvoo/sodfa",
"path": "sodfa/app/views.py",
"copies": "1",
"size": "3193",
"license": "bsd-2-clause",
"hash": 7847540512761088000,
"line_mean": 35.7011494253,
"line_max": 80,
"alpha_frac": 0.5471343564,
"autogenerated": false,
"ratio": 4.109395109395109,
"config_test": false,
... |
from django.shortcuts import render
from django.contrib.auth.models import User
from django.contrib.auth import authenticate, login
from django.http import HttpResponseRedirect
def index(request):
if request.method == 'POST':
try:
checklogin = request.POST['mail']
except:
ch... | {
"repo_name": "erikkn/vmx-hosting",
"path": "virt/portal/views.py",
"copies": "1",
"size": "1669",
"license": "apache-2.0",
"hash": -6300174103712481000,
"line_mean": 33.7916666667,
"line_max": 72,
"alpha_frac": 0.5674056321,
"autogenerated": false,
"ratio": 5.1993769470404985,
"config_test": f... |
from django.shortcuts import render
from django.contrib.auth.models import User
from django.contrib.auth import logout
from django.contrib.auth.forms import UserCreationForm, AuthenticationForm
from django.http import HttpResponseRedirect, HttpResponse
from truco.forms import *
from truco.models import Partida, Jugador... | {
"repo_name": "emmanuel-santos/GEM",
"path": "trucoGemSite/truco/views.py",
"copies": "1",
"size": "4850",
"license": "mit",
"hash": -8096884938365961000,
"line_mean": 32.6805555556,
"line_max": 141,
"alpha_frac": 0.66,
"autogenerated": false,
"ratio": 3.303814713896458,
"config_test": false,
... |
from django.shortcuts import render
from django.contrib.auth.models import User
from django.contrib.auth import logout
from django.http import HttpResponse, HttpResponseRedirect, \
HttpResponseNotFound
from django.template import RequestContext
from django.contrib.auth.decorators import login_required
from django.s... | {
"repo_name": "karlfloersch/friends-r-us",
"path": "social_network/views.py",
"copies": "1",
"size": "27762",
"license": "mit",
"hash": -6776851618651008000,
"line_mean": 37.1870701513,
"line_max": 205,
"alpha_frac": 0.5913478856,
"autogenerated": false,
"ratio": 3.719453376205788,
"config_test... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.