repo_name stringlengths 5 100 | ref stringlengths 12 67 | path stringlengths 4 244 | copies stringlengths 1 8 | content stringlengths 0 1.05M ⌀ |
|---|---|---|---|---|
liurenqiu520/AutobahnPython | refs/heads/master | examples/twisted/websocket/echo_variants/client_with_proxy.py | 18 | ###############################################################################
##
## Copyright (C) 2011-2013 Tavendo GmbH
##
## Licensed under the Apache License, Version 2.0 (the "License");
## you may not use this file except in compliance with the License.
## You may obtain a copy of the License at
##
## h... |
yanchen036/tensorflow | refs/heads/master | tensorflow/python/util/future_api.py | 198 | # Copyright 2016 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... |
afaheem88/tempest_neutron | refs/heads/master | tempest/thirdparty/boto/__init__.py | 12133432 | |
shurihell/testasia | refs/heads/test1 | common/djangoapps/track/management/tests/__init__.py | 12133432 | |
CatalansMB/War1714 | refs/heads/master | src/header_scene_props.py | 5 | ###################################################
# header_scene_props.py
# This file contains declarations for scene props
# DO NOT EDIT THIS FILE!
###################################################
sokf_type_container = 0x0000000000000005
sokf_type_ai_limiter = 0x0000000000000008
sokf_type_barrier ... |
msabramo/ansible | refs/heads/devel | lib/ansible/modules/network/iosxr/iosxr_config.py | 8 | #!/usr/bin/python
#
# This file is part of Ansible
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Ansible is distribut... |
junhuac/MQUIC | refs/heads/master | depot_tools/external_bin/gsutil/gsutil_4.15/gsutil/third_party/boto/boto/sts/connection.py | 136 | # Copyright (c) 2011 Mitch Garnaat http://garnaat.org/
# Copyright (c) 2011, Eucalyptus Systems, Inc.
# Copyright (c) 2013 Amazon.com, Inc. or its affiliates. All Rights Reserved
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the
... |
tplusx/stdma-ns3 | refs/heads/master | sources/src/netanim/test/examples-to-run.py | 176 | #! /usr/bin/env python
## -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-
# A list of C++ examples to run in order to ensure that they remain
# buildable and runnable over time. Each tuple in the list contains
#
# (example_name, do_run, do_valgrind_run).
#
# See test.py for more i... |
vnsofthe/odoo | refs/heads/8.0 | addons/website_hr/controllers/__init__.py | 7372 | import main
|
aymeric-spiga/planetoplot | refs/heads/master | tutorial/planetoplot_tutorial.py | 1 |
# coding: utf-8
# # PLANETOPLOT tutorial
#
# *Author: [Aymeric SPIGA](http://www.lmd.jussieu.fr/~aslmd)*
#
# PLANETOPLOT is a plotting/mapping tool based on popular Python librairies. Here the great work done by the [matplotlib](http://matplotlib.org/) and [basemap](http://matplotlib.org/basemap) teams shall be ack... |
pratikmallya/heat | refs/heads/master | heat/tests/test_template_format.py | 6 | #
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# ... |
BlueLens/bl-magi | refs/heads/master | tensorflow/object_detection/core/box_predictor.py | 14 | # Copyright 2017 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... |
MOD-ASL/smores_ros | refs/heads/master | nodes/nbv_relay_node.py | 2 | #!/usr/bin/env python
import rospy
import time
from smores_ros.srv import nbv_request
from geometry_msgs.msg import Pose
from std_msgs.msg import Int32, String
class NBV_Relay(object):
def __init__(self):
self.param_dict = {}
self.param_name_list = []
self.nbv_result = None
self._i... |
JustAFakeName/ss | refs/heads/github_open | utils/autoban.py | 1 | #!/usr/bin/python
# -*- coding: utf-8 -*-
# Copyright (c) 2015 clowwindy
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to u... |
cliffordwolf/yosys | refs/heads/master | techlibs/ecp5/brams_init.py | 3 | #!/usr/bin/env python3
with open("techlibs/ecp5/bram_init_1_2_4.vh", "w") as f:
for i in range(0, 0x40):
init_snippets = []
for j in range(32):
init_snippets.append("INIT[%4d*8 +: 8]" % (32 * i + j))
init_snippets.append("3'b000" if (j % 2 == 1) else "1'b0")
init_snip... |
silvansky/pjsip_mod | refs/heads/master | tests/cdash/main.py | 107 | #!/bin/env python
#
# main.py - main entry for PJSIP's CDash tests
#
# Copyright (C) 2008-2009 Teluu Inc. (http://www.teluu.com)
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version... |
blacktear23/django | refs/heads/master | tests/regressiontests/syndication/models.py | 103 | from django.db import models
class Entry(models.Model):
title = models.CharField(max_length=200)
date = models.DateTimeField()
class Meta:
ordering = ('date',)
def __unicode__(self):
return self.title
def get_absolute_url(self):
return "/blog/%s/" % self.pk
class Articl... |
hnjamba/ckanext-iauthfunctions | refs/heads/master | ckanext/iauthfunctions/tests/test_plugin.py | 1 | """Tests for plugin.py."""
import ckanext.iauthfunctions.plugin as plugin
def test_plugin():
pass |
cosmicAsymmetry/zulip | refs/heads/master | confirmation/management/commands/__init__.py | 12133432 | |
helldorado/ansible | refs/heads/devel | lib/ansible/module_utils/network/iosxr/providers/cli/config/bgp/__init__.py | 12133432 | |
szeged/servo | refs/heads/master | tests/wpt/web-platform-tests/tools/third_party/html5lib/html5lib/filters/__init__.py | 12133432 | |
randomic/antinub-auth | refs/heads/master | dashboard/views.py | 1 | from django.contrib.auth.decorators import login_required
from django.shortcuts import render
@login_required
def profile(request): return render(request, 'dashboard/base.djhtml')
@login_required
def apikeys(request): return render(request, 'dashboard/apikeys.djhtml') |
sjperkins/tensorflow | refs/heads/master | tensorflow/python/estimator/canned/metric_keys.py | 6 | # Copyright 2017 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... |
beni55/django | refs/heads/master | tests/validation/test_picklable.py | 576 | import pickle
from unittest import TestCase
from django.core.exceptions import ValidationError
class PickableValidationErrorTestCase(TestCase):
def test_validationerror_is_picklable(self):
original = ValidationError('a', code='something')
unpickled = pickle.loads(pickle.dumps(original))
... |
ekwoodrich/nirha | refs/heads/master | nirhaweb/venv/lib/python2.7/site-packages/pip/_vendor/html5lib/filters/sanitizer.py | 1734 | from __future__ import absolute_import, division, unicode_literals
from . import _base
from ..sanitizer import HTMLSanitizerMixin
class Filter(_base.Filter, HTMLSanitizerMixin):
def __iter__(self):
for token in _base.Filter.__iter__(self):
token = self.sanitize_token(token)
if tok... |
fedora-infra/fmn | refs/heads/develop | fmn/tests/rules/test_generic.py | 1 | # -*- coding: utf-8 -*-
#
# This file is part of FMN.
# Copyright (C) 2017 Red Hat, Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) ... |
mozvip/Sick-Beard | refs/heads/development | cherrypy/__init__.py | 35 | """CherryPy is a pythonic, object-oriented HTTP framework.
CherryPy consists of not one, but four separate API layers.
The APPLICATION LAYER is the simplest. CherryPy applications are written as
a tree of classes and methods, where each branch in the tree corresponds to
a branch in the URL path. Each method i... |
ankurankan/scikit-learn | refs/heads/master | sklearn/utils/tests/test_graph.py | 24 | # Author: Gael Varoquaux <gael.varoquaux@normalesup.org>
# License: BSD 3 clause
import numpy as np
from scipy import sparse
from ..graph import graph_laplacian
def test_graph_laplacian():
for mat in (np.arange(10) * np.arange(10)[:, np.newaxis],
np.ones((7, 7)),
np.eye(19),
... |
HuahuaMonk/moviehunter | refs/heads/master | moviehunter/baidupan_log_in.py | 1 | # coding=utf-8
"""
百度网盘自动登录、手动登录、cookie保存读取。
"""
import pickle
from os.path import isfile
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
from global_consts import COOKIES_FILE_PATH
BAIDUPAN_URL = '... |
harshilasu/GraphicMelon | refs/heads/master | y/google-cloud-sdk/lib/google/apputils/app.py | 24 | #!/usr/bin/env python
# Copyright 2003 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required... |
jiangwei1221/django-virtualenv-demo | refs/heads/master | env/lib/python2.7/site-packages/south/__init__.py | 21 | """
South - Useable migrations for Django apps
"""
__version__ = "0.8.4"
__authors__ = [
"Andrew Godwin <andrew@aeracode.org>",
"Andy McCurdy <andy@andymccurdy.com>"
]
|
deisi/home-assistant | refs/heads/master | homeassistant/components/notify/message_bird.py | 8 | """
MessageBird platform for notify component.
For more details about this platform, please refer to the documentation at
https://home-assistant.io/components/notify.message_bird/
"""
import logging
from homeassistant.components.notify import (
ATTR_TARGET, DOMAIN, BaseNotificationService)
from homeassistant.cons... |
bguillot/OpenUpgrade | refs/heads/master | addons/report/models/abstract_report.py | 38 | # -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2014-Today OpenERP SA (<http://www.openerp.com>).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms ... |
akretion/odoo | refs/heads/12-patch-paging-100-in-o2m | addons/l10n_de_skr03/migrations/9.0.2.0/post-migrate_tags_on_taxes.py | 832 | # -*- coding: utf-8 -*-
import odoo
def migrate(cr, version):
registry = odoo.registry(cr.dbname)
from odoo.addons.account.models.chart_template import migrate_tags_on_taxes
migrate_tags_on_taxes(cr, registry)
|
leiferikb/bitpop | refs/heads/master | src/third_party/tlslite/tlslite/utils/Python_RC4.py | 207 | # Author: Trevor Perrin
# See the LICENSE file for legal information regarding use of this file.
"""Pure-Python RC4 implementation."""
from .rc4 import RC4
from .cryptomath import *
def new(key):
return Python_RC4(key)
class Python_RC4(RC4):
def __init__(self, keyBytes):
RC4.__init__(self, keyBytes,... |
marcoarruda/MissionPlanner | refs/heads/master | Lib/site-packages/numpy/matrixlib/tests/test_multiarray.py | 54 | import numpy as np
from numpy.testing import *
class TestView(TestCase):
def test_type(self):
x = np.array([1,2,3])
assert(isinstance(x.view(np.matrix),np.matrix))
def test_keywords(self):
x = np.array([(1,2)],dtype=[('a',np.int8),('b',np.int8)])
# We must be specific about the... |
adrienbrault/home-assistant | refs/heads/dev | homeassistant/helpers/event.py | 2 | """Helpers for listening to events."""
from __future__ import annotations
import asyncio
import copy
from dataclasses import dataclass
from datetime import datetime, timedelta
import functools as ft
import logging
import time
from typing import Any, Awaitable, Callable, Iterable, List
import attr
from homeassistant.... |
mr-karan/coala | refs/heads/master | coalib/settings/SectionFilling.py | 5 | import copy
from coalib.bears.BEAR_KIND import BEAR_KIND
from coalib.collecting.Collectors import collect_bears
from coalib.output.printers.LOG_LEVEL import LOG_LEVEL
from coalib.settings.Setting import Setting
def fill_settings(sections, acquire_settings, log_printer):
"""
Retrieves all bears and requests m... |
MihaiMoldovanu/ansible | refs/heads/devel | lib/ansible/modules/clustering/znode.py | 46 | #!/usr/bin/python
# Copyright 2015 WP Engine, Inc. All rights reserved.
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import absolute_import, division, print_function
__metaclass__ = type
ANSIBLE_METADATA = {'metadata_version': '1.1',
... |
trondhindenes/ansible-modules-extras | refs/heads/devel | windows/win_share.py | 70 | #!/usr/bin/python
# -*- coding: utf-8 -*-
# Copyright 2015, Hans-Joachim Kliemeck <git@kliemeck.de>
#
# This file is part of Ansible
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version ... |
gordon-elliott/glod | refs/heads/master | src/glod/in_out/subject.py | 1 | __copyright__ = 'Copyright(c) Gordon Elliott 2017'
"""
"""
from a_tuin.in_out.gsheet_integration import get_gsheet_fields, load_class
from a_tuin.metadata import Mapping
from glod.db.subject import Subject
def subjects_from_gsheet(session, extract_from_detailed_ledger):
subject_gsheet = get_gsheet_fields(
... |
setten/pymatgen | refs/heads/master | pymatgen/phonon/tests/test_plotter.py | 6 | from __future__ import division, unicode_literals
import unittest
import os
import json
import scipy
from io import open
from pymatgen.phonon.dos import CompletePhononDos
from pymatgen.phonon.plotter import PhononDosPlotter, PhononBSPlotter
from pymatgen.phonon.bandstructure import PhononBandStructureSymmLine
test_... |
matthiaskoenig/tellurium-web | refs/heads/develop | teweb/combine/urls.py | 1 | from django.conf.urls import url, include
from . import views
from . import views_api
app_name = 'combine'
urlpatterns = [
url(r'^$', views.archives, name='index'),
url(r'^archive/(?P<archive_id>[0-9]+)/$', views.archive_view, name='archive'),
url(r'^archive/(?P<archive_id>[0-9]+)/results$', views.results... |
ericmckean/syzygy | refs/heads/master | syzygy/dashboard/setup.py | 5 | #!python
# Copyright 2012 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable... |
davidyezsetz/kuma | refs/heads/master | kuma/wiki/__init__.py | 12133432 | |
javierlgroba/Eventer-gapp | refs/heads/master | django/contrib/localflavor/at/__init__.py | 12133432 | |
GoSteven/Diary | refs/heads/master | django/conf/locale/fi/__init__.py | 12133432 | |
nharraud/invenio-demosite | refs/heads/master | invenio_demosite/base/format_templates/__init__.py | 12133432 | |
cloudera/hue | refs/heads/master | desktop/core/ext-py/oauth2client-4.1.3/tests/contrib/appengine/__init__.py | 12133432 | |
RO-ny9/python-for-android | refs/heads/master | python3-alpha/python3-src/Tools/demo/rpython.py | 107 | #!/usr/bin/env python3
"""
Remote python client.
Execute Python commands remotely and send output back.
"""
import sys
from socket import socket, AF_INET, SOCK_STREAM, SHUT_WR
PORT = 4127
BUFSIZE = 1024
def main():
if len(sys.argv) < 3:
print("usage: rpython host command")
sys.exit(2)
host =... |
gennad/www_gennad_org | refs/heads/master | django/contrib/admin/__init__.py | 246 | # ACTION_CHECKBOX_NAME is unused, but should stay since its import from here
# has been referenced in documentation.
from django.contrib.admin.helpers import ACTION_CHECKBOX_NAME
from django.contrib.admin.options import ModelAdmin, HORIZONTAL, VERTICAL
from django.contrib.admin.options import StackedInline, TabularInli... |
ncole458/generator-phonegapsass | refs/heads/master | node_modules/phonegap/node_modules/cordova/node_modules/plugman/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/MSVSVersion.py | 115 | # Copyright (c) 2013 Google Inc. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""Handle version information related to Visual Stuio."""
import errno
import os
import re
import subprocess
import sys
import gyp
class VisualStudioVersion(obj... |
praekelt/helpdesk | refs/heads/develop | casepro/cases/migrations/0011_auto_20150513_1542.py | 2 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
('cases', '0010_auto_20150512_1424'),
]
operations = [
migrations.AlterField(
model_name='partner',
na... |
devops2014/djangosite | refs/heads/master | tests/migrations/migrations_test_apps/__init__.py | 12133432 | |
gunnarku/mysql-5.6 | refs/heads/webscalesql-5.6.27.75 | xtrabackup/test/kewpie/lib/modes/__init__.py | 12133432 | |
keedio/hue | refs/heads/master | desktop/core/ext-py/Django-1.6.10/tests/template_tests/models.py | 12133432 | |
shawnchin/django-doccomment | refs/heads/master | example/dc_project/__init__.py | 12133432 | |
kustodian/ansible | refs/heads/devel | lib/ansible/modules/storage/zfs/__init__.py | 12133432 | |
styxit/CouchPotatoServer | refs/heads/master | couchpotato/core/providers/torrent/torrentday/main.py | 5 | from couchpotato.core.helpers.variable import tryInt
from couchpotato.core.logger import CPLog
from couchpotato.core.providers.torrent.base import TorrentProvider
log = CPLog(__name__)
class TorrentDay(TorrentProvider):
urls = {
'test': 'http://www.td.af/',
'login': 'http://www.td.af/torrents/',... |
torwag/micropython | refs/heads/master | tests/basics/getattr.py | 100 | # test __getattr__
class A:
def __init__(self, d):
self.d = d
def __getattr__(self, attr):
return self.d[attr]
a = A({'a':1, 'b':2})
print(a.a, a.b)
|
ranea/ArxPy | refs/heads/master | arxpy/primitives/tests/test_primitives.py | 1 | """Tests for the Cipher module."""
import doctest
import unittest
from arxpy.bitvector.core import Variable
from arxpy.primitives import primitives
from arxpy.primitives.primitives import BvFunction, KeySchedule, Encryption, Cipher
class TestBvFunction(unittest.TestCase):
"""Tests of the BvFunction class."""
... |
aglne/lenskit | refs/heads/master | lenskit-integration-tests/src/it/eval/external-algorithms/item-mean.py | 9 | import sys
class ItemMeanData(object):
def __init__(self):
self.global_sum = 0
self.global_count = 0
self.item_sums = {}
self.item_counts = {}
def train(self, trainfile):
with open(trainfile) as f:
for line in f:
user, item, rating = line.st... |
daler3/smack-next | refs/heads/next | Documentation/target/tcm_mod_builder.py | 498 | #!/usr/bin/python
# The TCM v4 multi-protocol fabric module generation script for drivers/target/$NEW_MOD
#
# Copyright (c) 2010 Rising Tide Systems
# Copyright (c) 2010 Linux-iSCSI.org
#
# Author: nab@kernel.org
#
import os, sys
import subprocess as sub
import string
import re
import optparse
tcm_dir = ""
fabric_ops... |
BitWriters/Zenith_project | refs/heads/master | zango/lib/python3.5/site-packages/pip/_vendor/html5lib/treewalkers/etree_lxml.py | 384 | from __future__ import absolute_import, division, unicode_literals
from pip._vendor.six import text_type
from lxml import etree
from ..treebuilders.etree import tag_regexp
from . import base
from .. import _ihatexml
def ensure_str(s):
if s is None:
return None
elif isinstance(s, text_type):
... |
weiawe/django | refs/heads/master | tests/field_defaults/__init__.py | 12133432 | |
mzdaniel/oh-mainline | refs/heads/master | vendor/packages/scrapy/scrapy/tests/test_utils_misc/test_walk_modules/mod1.py | 12133432 | |
aforalee/rally | refs/heads/master | rally/task/__init__.py | 12133432 | |
CT-Data-Collaborative/ctdata-wagtail-cms | refs/heads/master | ctdata_wagtail/contrib/sites/migrations/0003_auto_20160819_1900.py | 1 | # -*- coding: utf-8 -*-
# Generated by Django 1.9.9 on 2016-08-19 19:00
from __future__ import unicode_literals
import django.contrib.sites.models
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('sites', '0002_set_site_domain_and_name'),
]
opera... |
comses/catalog | refs/heads/master | catalog/wsgi.py | 2 | """
WSGI config for catalog project.
It exposes the WSGI callable as a module-level variable named ``application``.
For more information on this file, see
https://docs.djangoproject.com/en/1.8/howto/deployment/wsgi/
"""
import os
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "catalog.settings")
from django.core.w... |
johnmcdowall/procedural_city_generation | refs/heads/master | procedural_city_generation/polygons/plot_poly.py | 3 | import matplotlib.pyplot as plt
def plot_edge(edge, color="k"):
plt.plot((edge[0][0], edge[1][0]),(edge[0][1], edge[1][1]), color)
def plot_self(self, mode="type"):
if mode == "type":
t = self.self_type
if t == "lot" or t=="block":
for edge in self.edges:
plot_edge(edge, "g")
elif t == "road":
... |
karyon/django | refs/heads/master | tests/m2m_and_m2o/models.py | 282 | """
Many-to-many and many-to-one relationships to the same table
Make sure to set ``related_name`` if you use relationships to the same table.
"""
from __future__ import unicode_literals
from django.db import models
from django.utils import six
from django.utils.encoding import python_2_unicode_compatible
class Use... |
dominjune/python | refs/heads/master | renzongxian/0024/mysite/todolist/models.py | 40 | from django.db import models
from django.contrib.auth.models import User
class List(models.Model):
# user = models.ForeignKey(User)
task = models.CharField(max_length=500) |
rnzaws/test-ci-codepipeline-elastic-beanstalk | refs/heads/master | app/manage.py | 34 | #!/usr/bin/env python
import os
import sys
if __name__ == "__main__":
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "app.settings")
try:
from django.core.management import execute_from_command_line
except ImportError:
# The above import may fail for some other reason. Ensure that the
... |
samuelclay/NewsBlur | refs/heads/master | apps/analyzer/__init__.py | 12133432 | |
kpreid/shinysdr | refs/heads/master | shinysdr/__init__.py | 12133432 | |
MRigal/django | refs/heads/master | django/template/loaders/__init__.py | 12133432 | |
DavidSpickett/pyelftools | refs/heads/master | elftools/elf/descriptions.py | 11 | #-------------------------------------------------------------------------------
# elftools: elf/descriptions.py
#
# Textual descriptions of the various enums and flags of ELF
#
# Eli Bendersky (eliben@gmail.com)
# This code is in the public domain
#----------------------------------------------------------------------... |
colab/colab-gitlab-plugin | refs/heads/master | src/colab_gitlab/data_importer.py | 1 | import json
import urllib
import urllib2
import logging
from dateutil.parser import parse
from django.db.models.fields import DateTimeField
from colab.plugins.data import PluginDataImporter
from .models import (GitlabProject, GitlabMergeRequest,
GitlabComment, GitlabIssue, GitlabGroup,
... |
karllessard/tensorflow | refs/heads/master | tensorflow/python/autograph/operators/dispatch_context.py | 60 | # Copyright 2018 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... |
cloudbase/lis-tempest | refs/heads/master | tempest/api/compute/v3/__init__.py | 12133432 | |
MikeOfNoTrades/netmiko | refs/heads/master | netmiko/base_connection.py | 4 | '''
Base connection class for netmiko
Handles SSH connection and methods that are generically applicable to different
platforms (Cisco and non-Cisco).
Also defines methods that should generally be supported by child classes
'''
from __future__ import print_function
from __future__ import unicode_literals
import par... |
t3dev/odoo | refs/heads/master | addons/website_slides_survey/__init__.py | 265 | # -*- coding: utf-8 -*-
# Part of Odoo. See LICENSE file for full copyright and licensing details.
from . import models
from . import controllers
|
iw3hxn/server | refs/heads/master | openerp/addons/base/res/res_bank.py | 1 | # -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the... |
NMTHydro/Recharge | refs/heads/develop | utils/config_file_formatter.py | 1 | # ===============================================================================
# Copyright 2016 gabe-parrish
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licen... |
robhudson/django | refs/heads/master | django/contrib/gis/gdal/prototypes/raster.py | 320 | """
This module houses the ctypes function prototypes for GDAL DataSource (raster)
related data structures.
"""
from ctypes import POINTER, c_char_p, c_double, c_int, c_void_p
from functools import partial
from django.contrib.gis.gdal.libgdal import GDAL_VERSION, std_call
from django.contrib.gis.gdal.prototypes.genera... |
yland/mailman3 | refs/heads/develop | src/mailman/runners/command.py | 7 | # Copyright (C) 1998-2015 by the Free Software Foundation, Inc.
#
# This file is part of GNU Mailman.
#
# GNU Mailman is free software: you can redistribute it and/or modify it under
# the terms of the GNU General Public License as published by the Free
# Software Foundation, either version 3 of the License, or (at you... |
erkrishna9/odoo | refs/heads/master | addons/document/wizard/document_configuration.py | 381 | # -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU... |
turbulenz/gyp | refs/heads/master | test/dependencies/gyptest-double-dependency.py | 344 | #!/usr/bin/env python
# Copyright (c) 2012 Google Inc. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""
Verify that pulling in a dependency a second time in a conditional works for
shared_library targets. Regression test for http://crbug.co... |
ademuk/django-oscar | refs/heads/master | tests/integration/dashboard/__init__.py | 1349 | # -*- coding: utf-8 -*- |
Lujeni/ansible | refs/heads/devel | lib/ansible/modules/network/netvisor/pn_fabric_local.py | 32 | #!/usr/bin/python
# Copyright: (c) 2018, Pluribus Networks
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import absolute_import, division, print_function
__metaclass__ = type
ANSIBLE_METADATA = {'metadata_version': '1.1',
'status': ['... |
PeterPetrik/QGIS | refs/heads/master | python/plugins/processing/gui/FixedTableDialog.py | 45 | # -*- coding: utf-8 -*-
"""
***************************************************************************
FixedTableDialog.py
---------------------
Date : August 2012
Copyright : (C) 2012 by Victor Olaya
Email : volayaf at gmail dot com
**********************... |
aboganas/frappe | refs/heads/develop | frappe/patches/v7_0/replace_upgrade_link_limit.py | 26 | from __future__ import unicode_literals
import frappe
from frappe.limits import get_limits, clear_limit, update_limits
def execute():
limits = get_limits()
if limits and limits.upgrade_link:
upgrade_url = limits.upgrade_link
clear_limit('upgrade_link')
update_limits({'upgrade_url': upgrade_url})
|
toolmacher/micropython | refs/heads/master | tests/basics/fun_callstar.py | 46 | # function calls with *pos
def foo(a, b, c):
print(a, b, c)
foo(*(1, 2, 3))
foo(1, *(2, 3))
foo(1, 2, *(3,))
foo(1, 2, 3, *())
# Another sequence type
foo(1, 2, *[100])
# Iterator
foo(*range(3))
# pos then iterator
foo(1, *range(2, 4))
# an iterator with many elements
def foo(*rest):
print(rest)
foo(*rang... |
errx/django | refs/heads/master | tests/extra_regress/tests.py | 55 | from __future__ import unicode_literals
from collections import OrderedDict
import datetime
from django.contrib.auth.models import User
from django.test import TestCase
from .models import TestObject, Order, RevisionableModel
class ExtraRegressTests(TestCase):
def setUp(self):
self.u = User.objects.cr... |
unreal666/outwiker | refs/heads/master | src/outwiker/actions/sortsiblingsalpha.py | 3 | # -*- coding: utf-8 -*-
from outwiker.gui.baseaction import BaseAction
from outwiker.core.commands import testreadonly, showError
class SortSiblingsAlphabeticalAction (BaseAction):
"""
Отсортировать страницы того же уровня по алфавиту
"""
stringId = u"SortSiblingsAlphabetically"
def __init__(sel... |
jimi-c/ansible | refs/heads/devel | lib/ansible/utils/module_docs_fragments/aci.py | 37 | # -*- coding: utf-8 -*-
# Copyright: (c) 2017, Dag Wieers (@dagwieers) <dag@wieers.com>
# Copyright: (c) 2017, Swetha Chunduri (@schunduri)
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
class ModuleDocFragment(object):
# Standard files documentation fragment
DO... |
thomas-young-2013/wherehowsX | refs/heads/master | metadata-etl/src/main/resources/jython/requests/packages/chardet/jisfreq.py | 3130 | ######################## BEGIN LICENSE BLOCK ########################
# The Original Code is Mozilla Communicator client code.
#
# The Initial Developer of the Original Code is
# Netscape Communications Corporation.
# Portions created by the Initial Developer are Copyright (C) 1998
# the Initial Developer. All Rights R... |
Mistobaan/tensorflow | refs/heads/master | tensorflow/tools/dist_test/scripts/k8s_tensorflow_test.py | 130 | # Copyright 2017 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... |
GunnerJnr/_CodeInstitute | refs/heads/master | Stream-3/Full-Stack-Development/8.Django-Blog-Part-Four/1.Adding-A-Counter/Blog_prj/Blog_app/migrations/__init__.py | 12133432 | |
peterayeni/django-smsgateway | refs/heads/master | smsgateway/tests/backends/__init__.py | 12133432 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.