repo_name stringlengths 5 100 | ref stringlengths 12 67 | path stringlengths 4 244 | copies stringlengths 1 8 | content stringlengths 0 1.05M ⌀ |
|---|---|---|---|---|
ryfeus/lambda-packs | refs/heads/master | HDF4_H5_NETCDF/source2.7/numpy/core/tests/test_mem_overlap.py | 14 | from __future__ import division, absolute_import, print_function
import sys
import itertools
import pytest
import numpy as np
from numpy.core._multiarray_tests import solve_diophantine, internal_overlap
from numpy.core import _umath_tests
from numpy.lib.stride_tricks import as_strided
from numpy.compat import long
fr... |
jayme-github/CouchPotatoServer | refs/heads/master | libs/requests/packages/chardet2/euctwfreq.py | 323 | ######################## 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... |
nojero/pod | refs/heads/master | src/neg/example.py | 1 | #Negreada para probar BEGIN
class On:
def __init__(self):
self.trans = []
class Transition:
def __init__(self):
self.label = ''
self.name = ''
on1 = On()
ta = Transition()
ta.label = '1'
ta.name = 'e0'
tb = Transition()
tb.label = '4'
tb.name = 'e1'
tc = Transition()
tc.label = '1'
tc.... |
d5ve/mailinabox | refs/heads/master | setup/migrate.py | 7 | #!/usr/bin/python3
# Migrates any file structures, database schemas, etc. between versions of Mail-in-a-Box.
# We have to be careful here that any dependencies are already installed in the previous
# version since this script runs before all other aspects of the setup script.
import sys, os, os.path, glob, re, shuti... |
hb9kns/PyBitmessage | refs/heads/master | src/class_addressGenerator.py | 1 | import shared
import threading
import time
import sys
from pyelliptic.openssl import OpenSSL
import ctypes
import hashlib
import highlevelcrypto
from addresses import *
from bmconfigparser import BMConfigParser
from debug import logger
import defaults
from helper_threading import *
from pyelliptic import arithmetic
imp... |
adieu/allbuttonspressed | refs/heads/master | robots/__init__.py | 12133432 | |
saideepchandg/oracle-r12-accounting | refs/heads/master | lib/django/conf/locale/en_GB/__init__.py | 12133432 | |
GoogleCloudPlatform/ml-on-gcp | refs/heads/master | example_zoo/tensorflow/models/mnist/official/utils/logs/__init__.py | 12133432 | |
tgarland1/datausa-site | refs/heads/master | datausa/profile/__init__.py | 12133432 | |
chkir/django-cms | refs/heads/develop | cms/test_utils/project/pluginapp/plugins/meta/south_migrations/__init__.py | 12133432 | |
tawanda/django-imagekit | refs/heads/develop | imagekit/admin.py | 6 | from django.utils.translation import ugettext_lazy as _
from django.template.loader import render_to_string
class AdminThumbnail(object):
"""
A convenience utility for adding thumbnails to Django's admin change list.
"""
short_description = _('Thumbnail')
allow_tags = True
def __init__(self,... |
schlichtanders/pyparsing-2.0.3-OrderedDict | refs/heads/master | examples/antlr_grammar.py | 1 | '''
antlr_grammar.py
Created on 4 sept. 2010
@author: luca
(Minor updates by Paul McGuire, June, 2012)
'''
from pyparsingOD import Word, ZeroOrMore, printables, Suppress, OneOrMore, Group, \
LineEnd, Optional, White, originalTextFor, hexnums, nums, Combine, Literal, Keyword, \
cStyleComment, Regex... |
wreckJ/intellij-community | refs/heads/master | python/testData/refactoring/extractmethod/DuplicateWithRename.after.py | 71 | def bar():
a = 1
b = 2
foo(a)
foo(b)
def foo(a_new):
print a_new
|
tipsybear/ormbad | refs/heads/master | tests/__init__.py | 1 | # tests
# Testing for the ormbad module
#
# Author: Benjamin Bengfort <[email protected]>
# Created: Thu Aug 13 12:34:07 2015 -0400
#
# Copyright (C) 2015 Tipsy Bear Studios
# For license information, see LICENSE.txt
#
# ID: __init__.py [] [email protected] $
"""
Testing for the ormbad module
"""
#########... |
mikel-egana-aranguren/SADI-Galaxy-Docker | refs/heads/master | galaxy-dist/eggs/numpy-1.6.0-py2.7-linux-x86_64-ucs4.egg/numpy/distutils/from_template.py | 43 | #!/usr/bin/python
"""
process_file(filename)
takes templated file .xxx.src and produces .xxx file where .xxx
is .pyf .f90 or .f using the following template rules:
'<..>' denotes a template.
All function and subroutine blocks in a source file with names that
contain '<..>' will be replicated according to ... |
rgerkin/neuroConstruct | refs/heads/master | lib/jython/Lib/StringIO.py | 146 | r"""File-like objects that read from or write to a string buffer.
This implements (nearly) all stdio methods.
f = StringIO() # ready for writing
f = StringIO(buf) # ready for reading
f.close() # explicitly release resources held
flag = f.isatty() # always false
pos = f.tell() # get current pos... |
PrefPy/opra | refs/heads/master | compsocsite/polls/migrations/0042_auto_20160710_0930.py | 1 | # -*- coding: utf-8 -*-
# Generated by Django 1.9.6 on 2016-07-10 08:30
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('polls', '0041_combination'),
]
operations = [
... |
CERNDocumentServer/invenio | refs/heads/prod | modules/websubmit/lib/functions/Is_Original_Submitter.py | 3 | # This file is part of Invenio.
# Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 CERN.
#
# Invenio 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 o... |
Maspear/odoo | refs/heads/8.0 | addons/report/models/report_paperformat.py | 311 | # -*- 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 ... |
lidavidm/mathics-heroku | refs/heads/master | mathics/core/characters.py | 3 | # -*- coding: utf8 -*-
u"""
Mathics: a general-purpose computer algebra system
Copyright (C) 2011 Jan Pöschko
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 3 of t... |
ultigeo/LIMS | refs/heads/master | testfinal/urls.py | 2 | from django.conf.urls import patterns, include, url
from django.contrib import admin
from testapp.views import * # reader_portal,dc_portal
from testapp.models import las_parcel,Rivers,Roads
from django.conf.urls.static import static
from django.contrib.auth import views as auth_views
from django.views.generic import Li... |
ericzolf/ansible | refs/heads/devel | lib/ansible/utils/multiprocessing.py | 60 | # Copyright (c) 2019 Matt Martz <[email protected]>
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
# Make coding more python3-ish
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
import multiprocessing
# Explicit multiprocessing contex... |
ttglennhall/DjangoGirlsTutorial | refs/heads/master | myvenv/lib/python3.4/site-packages/django/db/models/sql/__init__.py | 237 | from django.db.models.sql.datastructures import EmptyResultSet
from django.db.models.sql.subqueries import * # NOQA
from django.db.models.sql.query import * # NOQA
from django.db.models.sql.where import AND, OR
__all__ = ['Query', 'AND', 'OR', 'EmptyResultSet']
|
huongttlan/bokeh | refs/heads/master | examples/plotting/file/image_url.py | 17 | from bokeh.plotting import figure, show, output_file
output_file("image_url.html")
p = figure()
url = ["http://bokeh.pydata.org/en/latest/_static/bokeh-transparent.png"]*10
x = list(range(0, 100, 10))
y = list(range(0, 100, 10))
p.image_url(x=x, y=y, url=url, global_alpha=0.2)
show(p)
|
imtapps/django-imt-fork | refs/heads/IMT | django/contrib/sessions/management/__init__.py | 12133432 | |
mrshoki/readthedocs.org | refs/heads/master | readthedocs/projects/templatetags/__init__.py | 12133432 | |
TeamEOS/external_chromium_org | refs/heads/lp5.0 | build/compiler_version.py | 104 | #!/usr/bin/env python
# Copyright (c) 2012 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""Compiler version checking tool for gcc
Print gcc version as XY if you are running gcc X.Y.*.
This is used to tweak build flags ... |
blooparksystems/odoo | refs/heads/9.0 | addons/l10n_ca/__init__.py | 12 | # -*- coding: utf-8 -*-
# Part of Odoo. See LICENSE file for full copyright and licensing details.
# Copyright (C) 2010 Savoir-faire Linux (<https://www.savoirfairelinux.com>).
|
GitHublong/hue | refs/heads/master | desktop/core/ext-py/python-openid-2.2.5/openid/test/test_ax.py | 77 | """Tests for the attribute exchange extension module
"""
import unittest
from openid.extensions import ax
from openid.message import NamespaceMap, Message, OPENID2_NS
from openid.consumer.consumer import SuccessResponse
class BogusAXMessage(ax.AXMessage):
mode = 'bogus'
getExtensionArgs = ax.AXMessage._newAr... |
learningequality/kolibri | refs/heads/develop | kolibri/core/device/models.py | 1 | import platform
import time
from uuid import uuid4
from django.conf import settings
from django.db import models
from morango.models import UUIDField
from .utils import LANDING_PAGE_LEARN
from .utils import LANDING_PAGE_SIGN_IN
from kolibri.core.auth.models import Facility
from kolibri.core.auth.models import Facilit... |
lightcn/odoo | refs/heads/8.0 | addons/website_event/tests/test_ui.py | 339 | import openerp.tests
@openerp.tests.common.at_install(False)
@openerp.tests.common.post_install(True)
class TestUi(openerp.tests.HttpCase):
def test_admin(self):
self.phantom_js("/", "openerp.Tour.run('event', 'test')", "openerp.Tour.tours.event", login='admin')
|
gchp/django | refs/heads/master | tests/defer/tests.py | 338 | from __future__ import unicode_literals
from django.db.models.query_utils import DeferredAttribute, InvalidQuery
from django.test import TestCase
from .models import (
BigChild, Child, ChildProxy, Primary, RefreshPrimaryProxy, Secondary,
)
class AssertionMixin(object):
def assert_delayed(self, obj, num):
... |
Pakoach/Sick-Beard | refs/heads/master | lib/pythontwitter/__init__.py | 30 | #!/usr/bin/env python
#
# vim: sw=2 ts=2 sts=2
#
# Copyright 2007 The Python-Twitter Developers
#
# 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.... |
alexlo03/ansible | refs/heads/devel | lib/ansible/modules/network/junos/junos_vlan.py | 25 | #!/usr/bin/python
# -*- coding: utf-8 -*-
# (c) 2017, Ansible by Red Hat, inc
# 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',
... |
DaikiMaekawa/leap_nextage | refs/heads/master | scripts/leap_nextage_node.py | 1 | #!/usr/bin/env python
#############################################################################################
# Copyright (c) 2014 Daiki Maekawa and ROS JAPAN Users Group All Rights Reserved. #
# #
# @file moveit_c... |
cwahbong/onirim-py | refs/heads/master | tests/test_phase.py | 1 | """
Tests for a phase.
"""
import collections
import pytest
from onirim import card
from onirim import core
from onirim import action
from onirim import exception
from onirim import component
from onirim import agent
def test_setup():
starting = [
card.sun(card.Color.red),
card.moon(card.Color.... |
postrational/django | refs/heads/master | tests/foreign_object/tests.py | 2 | import datetime
from operator import attrgetter
from .models import Country, Person, Group, Membership, Friendship, Article, ArticleTranslation
from django.test import TestCase
from django.utils.translation import activate
from django import forms
class MultiColumnFKTests(TestCase):
def setUp(self):
# Cre... |
krsjoseph/youtube-dl | refs/heads/master | devscripts/gh-pages/update-feed.py | 159 | #!/usr/bin/env python3
from __future__ import unicode_literals
import datetime
import io
import json
import textwrap
atom_template = textwrap.dedent("""\
<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
<link rel="self" href="http://rg3.github.io/youtube-dl/update/rel... |
Soya93/Extract-Refactoring | refs/heads/master | python/helpers/pydev/tests_pydevd/test_check_pydevconsole.py | 21 | import threading
import unittest
import os
import sys
try:
import pydevconsole
except:
sys.path.append(os.path.dirname(os.path.dirname(__file__)))
import pydevconsole
from _pydev_bundle.pydev_imports import xmlrpclib, SimpleXMLRPCServer
from _pydev_bundle.pydev_localhost import get_localhost
try:
raw_... |
burzillibus/RobHome | refs/heads/master | venv/lib/python2.7/site-packages/django/contrib/staticfiles/management/__init__.py | 12133432 | |
ArdAmb/campamento_base | refs/heads/master | base/tests/views/__init__.py | 12133432 | |
murraymeehan/marsyas | refs/heads/master | src/django/birdsong/application/birdsong/urls.py | 7 | from django.conf.urls.defaults import *
# Uncomment the next two lines to enable the admin:
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns(
'',
(r'^$', 'birdsong.main.views.index'),
(r'^$', 'birdsong.main.views.index'),
(r'^recordings$', 'birdsong.recordings.views.index'... |
cbertinato/pandas | refs/heads/master | pandas/tests/reshape/merge/test_multi.py | 1 | from collections import OrderedDict
import numpy as np
from numpy import nan
from numpy.random import randn
import pytest
import pandas as pd
from pandas import DataFrame, Index, MultiIndex, Series
from pandas.core.reshape.concat import concat
from pandas.core.reshape.merge import merge
import pandas.util.testing as ... |
willprice/weboob | refs/heads/master | modules/voyagessncf/test.py | 7 | # -*- coding: utf-8 -*-
# Copyright(C) 2013 Romain Bignon
#
# This file is part of weboob.
#
# weboob is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your... |
logicus4078/vertx-web | refs/heads/master | src/test/sockjs-protocol/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... |
WindowsPhoneForensics/find_my_texts_wp8 | refs/heads/master | find_my_texts_wp8/recovery_expressions/sms_text/expressions/type0/full.py | 1 | import re
__author__ = 'Chris Ottersen'
# TODO: identify - deleted
# TODO: identify - location
# TODO: identify -
exp = re.compile(
r"""
(?P<u0>.{9})
(?P<message_id>.{4})
.{4}
\*{45} #74
(?:.{43})?
\*{25}
(?:.{43})?
\*{4} ... |
Dioptas/Dioptas | refs/heads/develop | dioptas/model/util/Pattern.py | 1 | # -*- coding: utf-8 -*-
# Dioptas - GUI program for fast processing of 2D X-ray diffraction data
# Principal author: Clemens Prescher ([email protected])
# Copyright (C) 2014-2019 GSECARS, University of Chicago, USA
# Copyright (C) 2015-2018 Institute for Geology and Mineralogy, University of Cologne, Germany
... |
vermouthmjl/scikit-learn | refs/heads/master | sklearn/neighbors/tests/test_kde.py | 80 | import numpy as np
from sklearn.utils.testing import (assert_allclose, assert_raises,
assert_equal)
from sklearn.neighbors import KernelDensity, KDTree, NearestNeighbors
from sklearn.neighbors.ball_tree import kernel_norm
from sklearn.pipeline import make_pipeline
from sklearn.dataset... |
acsone/odoo | refs/heads/8.0 | addons/mrp/wizard/mrp_product_produce.py | 75 | # -*- 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... |
gogobook/wagtail | refs/heads/master | wagtail/contrib/settings/views.py | 7 | from django.core.exceptions import PermissionDenied
from django.http import Http404
from django.shortcuts import redirect, render, get_object_or_404
from django.utils.lru_cache import lru_cache
from django.utils.text import capfirst
from django.utils.translation import ugettext as _
from wagtail.wagtailadmin import me... |
CiscoSystems/avos | refs/heads/master | openstack_dashboard/dashboards/admin/avos/static/txt/ceilometercommands.py | 2 |
ceilometerclient.Client('1', endpoint='http://172.29.86.41:35357/v2.0', username="admin", api_key="ADMIN_PASS")
carbohydrate-9662312c-a784-4c4d-b959-8ced233f8430:
from novaclient import client as novaclient
from ceilometerclient import client as ceilometerclient
from keystoneclient import client as keystoneclient
... |
cherokee/webserver | refs/heads/master | developers.py | 5 | # -*- coding: utf-8 -*-
DEVELOPERS = {
'alobbs' : "Alvaro Lopez Ortega <[email protected]>",
'skarcha' : "Antonio Perez <[email protected]>",
'ion' : "Jonathan Hernandez <[email protected]>",
'taher' : "Taher Shihadeh <[email protected]>",
'robertounbit' : "Roberto ... |
leppa/home-assistant | refs/heads/dev | homeassistant/components/n26/switch.py | 7 | """Support for N26 switches."""
import logging
from homeassistant.components.switch import SwitchDevice
from . import DEFAULT_SCAN_INTERVAL, DOMAIN
from .const import CARD_STATE_ACTIVE, CARD_STATE_BLOCKED, DATA
_LOGGER = logging.getLogger(__name__)
SCAN_INTERVAL = DEFAULT_SCAN_INTERVAL
def setup_platform(hass, co... |
OliverCole/ZeroNet | refs/heads/master | src/Test/TestRateLimit.py | 3 | import time
import gevent
from util import RateLimit
# Time is around limit +/- 0.05 sec
def around(t, limit):
return t >= limit - 0.05 and t <= limit + 0.05
class ExampleClass(object):
def __init__(self):
self.counted = 0
self.last_called = None
def count(self, back="counted"):
... |
lexus42/2015cd_midterm2 | refs/heads/master | static/Brython3.1.1-20150328-091302/Lib/weakref.py | 769 | """Weak reference support for Python.
This module is an implementation of PEP 205:
http://www.python.org/dev/peps/pep-0205/
"""
# Naming convention: Variables named "wr" are weak reference objects;
# they are called this instead of "ref" to avoid name collisions with
# the module-global ref() function imported from ... |
semonte/intellij-community | refs/heads/master | python/testData/resolve/PercentPositionalArgs.py | 38 | "in percent string it's %<ref>s argument, but i want to pass %d arguments" % ("string", 1423) |
dholbach/snapcraft | refs/heads/master | snaps_tests/tour_tests/10-SNAPS/test_02_service_confined.py | 11 | # -*- Mode:Python; indent-tabs-mode:nil; tab-width:4 -*-
#
# Copyright (C) 2016 Canonical Ltd
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 3 as
# published by the Free Software Foundation.
#
# This program is distributed in the h... |
simon-andrews/django-resource-scheduler | refs/heads/master | resource_scheduler/apps.py | 1 | from django.apps import AppConfig
class ResourceSchedulerConfig(AppConfig):
name = 'resource_scheduler'
verbose_name = 'Resource Scheduler'
|
Eficent/stock-logistics-workflow | refs/heads/8.0 | stock_picking_invoice_link/tests/__init__.py | 8 | # -*- coding: utf-8 -*-
# © 2016 Oihane Crucelaegui - AvanzOSC
# License AGPL-3 - See http://www.gnu.org/licenses/agpl-3.0.html
from . import test_stock_picking_invoice_link
|
Rewardcoin/p2pool-Rewardcoin | refs/heads/master | SOAPpy/Errors.py | 294 | """
################################################################################
#
# SOAPpy - Cayce Ullman ([email protected])
# Brian Matthews ([email protected])
# Gregory Warnes ([email protected])
# Christopher Blunck ([email protected])
#
##########################... |
nbargnesi/proxme | refs/heads/master | proxme/lib.py | 1 | # coding: utf-8
"""Lib module."""
|
berryny/socialcyclingnyc | refs/heads/master | profiles/openoutreach/libraries/openlayers/tools/minimize.py | 297 | # Minimal Python Minimizer
# Copyright 2008, Christopher Schmidt
# Released under the MIT License
#
# Taken from: http://svn.crschmidt.net/personal/python/minimize.py
# $Id: minimize.py 6 2008-01-03 06:33:35Z crschmidt $
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software... |
torchingloom/edx-platform | refs/heads/select/release | common/djangoapps/student/migrations/0030_auto__chg_field_anonymoususerid_anonymous_user_id.py | 167 | # -*- coding: utf-8 -*-
import datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Changing field 'AnonymousUserId.anonymous_user_id'
db.alter_column('student_anonymoususerid', 'anonymous_... |
microcom/odoo | refs/heads/9.0 | addons/account/tests/test_manual_reconciliation.py | 47 | from openerp.addons.account.tests.account_test_classes import AccountingTestCase
class TestManualReconciliation(AccountingTestCase):
def test_reconciliation_proposition(self):
pass
def test_full_reconcile(self):
pass
def test_partial_reconcile(self):
pass
def test_reconcile_... |
sthirugn/robottelo | refs/heads/master | robottelo/cli/settings.py | 8 | # -*- encoding: utf-8 -*-
"""
Usage::
hammer settings [OPTIONS] SUBCOMMAND [ARG] ...
Parameters::
SUBCOMMAND subcommand
[ARG] ... subcommand arguments
Subcommands::
list List all settings
set Update a sett... |
thnee/ansible | refs/heads/devel | lib/ansible/modules/network/fortios/fortios_system_replacemsg_utm.py | 13 | #!/usr/bin/python
from __future__ import (absolute_import, division, print_function)
# Copyright 2019 Fortinet, 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 3 of the Lic... |
joecole889/spam-filter | refs/heads/master | FeatureVecGen.py | 1 | # -*- coding: utf-8 -*-
"""
Contains a class to generate feature vectors from email text. Utility functions are also included for
creating the dictionaries needed to build the feature vectors. Uses the Porter stemmer algorithm
as implemented in the natural language processing toolkit (nltk).
Created on Fri Feb 1... |
ycool/apollo | refs/heads/master | modules/tools/prediction/data_pipelines/data_preprocessing/generate_labels.py | 3 | ###############################################################################
# Copyright 2019 The Apollo 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
#
# h... |
TangHao1987/intellij-community | refs/heads/master | python/helpers/profiler/thrift/TSerialization.py | 36 | #
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not u... |
r2t2sdr/r2t2 | refs/heads/master | linux/trunk/linux-4.0-adi/tools/perf/scripts/python/check-perf-trace.py | 1997 | # perf script event handlers, generated by perf script -g python
# (c) 2010, Tom Zanussi <[email protected]>
# Licensed under the terms of the GNU GPL License version 2
#
# This script tests basic functionality such as flag and symbol
# strings, common_xxx() calls back into perf, begin, end, unhandled
# events, etc. ... |
cloew/KaoResources | refs/heads/master | setup.py | 1 | from distutils.core import setup
setup(name='kao_resources',
version='0.0.1',
description="",
author='',
author_email='',
packages=['kao_resources'],
) |
pombreda/django-hotclub | refs/heads/master | libs/external_libs/python-yadis-1.1.0/yadis/parsehtml.py | 5 | __all__ = ['findHTMLMeta', 'MetaNotFound']
from HTMLParser import HTMLParser, HTMLParseError
import htmlentitydefs
import re
from yadis.constants import YADIS_HEADER_NAME
# Size of the chunks to search at a time (also the amount that gets
# read at a time)
CHUNK_SIZE = 1024 * 16 # 16 KB
class ParseDone(Exception):
... |
EdLogan18/logan-repository | refs/heads/master | plugin.video.exodus/resources/lib/sources/torba_mv_tv.py | 2 | # -*- coding: utf-8 -*-
'''
Exodus Add-on
Copyright (C) 2016 lambda
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 3 of the License, or
(at your option) any l... |
EKiefer/edge-starter | refs/heads/master | py34env/Lib/site-packages/django/contrib/postgres/aggregates/__init__.py | 625 | from .general import * # NOQA
from .statistics import * # NOQA
|
mbarylsk/goldbach-partition | refs/heads/master | goldbach-eliminate_primes.py | 1 | #
# Copyright (c) 2019 - 2020, Marcin Barylski
# All rights reserved.
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice,
# this list of con... |
andmos/ansible | refs/heads/devel | test/units/modules/network/ios/test_ios_vlan.py | 45 | # (c) 2018 Red Hat Inc.
#
# 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 dis... |
saullocastro/pyNastran | refs/heads/master | pyNastran/f06/utils.py | 1 | from __future__ import print_function
import os
import numpy as np
from pyNastran.f06.parse_flutter import plot_flutter_f06
def cmd_line_plot_flutter(): # pragma: no cover
import sys
from docopt import docopt
import pyNastran
msg = "Usage:\n"
msg += " f06 plot_145 F06_FILENAME [--noline] [--mode... |
wemanuel/smry | refs/heads/master | server-auth/ls/google-cloud-sdk/lib/dns/dnssec.py | 33 | # Copyright (C) 2003-2007, 2009 Nominum, Inc.
#
# Permission to use, copy, modify, and distribute this software and its
# documentation for any purpose with or without fee is hereby granted,
# provided that the above copyright notice and this permission notice
# appear in all copies.
#
# THE SOFTWARE IS PROVIDED "AS IS... |
Mlieou/lXXtcode | refs/heads/master | leetcode/python/ex_535.py | 3 | class Codec:
table = {}
chars = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'
url = 'https://short.it/'
def encode(self, longUrl):
"""Encodes a URL to a shortened URL.
:type longUrl: str
:rtype: str
"""
key = ''
while not key or... |
akirk/youtube-dl | refs/heads/master | youtube_dl/extractor/regiotv.py | 99 | # coding: utf-8
from __future__ import unicode_literals
from .common import InfoExtractor
from ..utils import (
sanitized_Request,
xpath_text,
xpath_with_ns,
)
class RegioTVIE(InfoExtractor):
_VALID_URL = r'https?://(?:www\.)?regio-tv\.de/video/(?P<id>[0-9]+)'
_TESTS = [{
'url': 'http://... |
jwren/intellij-community | refs/heads/master | python/testData/quickFixes/PyAddImportQuickFixTest/reexportedName/flask/globals.py | 35 | request = object() |
Furzoom/learnpython | refs/heads/master | learnpythonthehardway/ex8.py | 1 | # -*- encoding: utf-8 -*-
formatter = "%r %r %r %r"
print formatter % (1, 2, 3, 4)
print formatter % ("one", "two", "three", "four")
print formatter % (True, False, False, True)
print formatter % (formatter, formatter, formatter, formatter)
print formatter % (
"I had this thing.",
"That you could type up right... |
vincent-tr/rpi-js-os | refs/heads/master | ext/v8-6.3.166/v8/tools/unittests/testdata/d8_mocked2.py | 7 | #!/usr/bin/env python
# Copyright 2017 the V8 project authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
print 'Richards1: 1'
print 'DeltaBlue1: 1'
print 'Richards2: 0.2'
print 'DeltaBlue2: 1.0'
print 'DeltaBlue3: 0.1'
|
cstipkovic/spidermonkey-research | refs/heads/master | testing/puppeteer/firefox/firefox_puppeteer/ui/browser/notifications.py | 1 | # This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this file,
# You can obtain one at http://mozilla.org/MPL/2.0/.
from abc import ABCMeta
from marionette_driver import By
from firefox_puppeteer.ui_base_lib import UIBaseLib
class B... |
solidfire/solidfire-cli | refs/heads/master | element/cli/parser.py | 2 | from element import exceptions
def parse_array(input_string):
# The base case is that it is None:
if(input_string == '' or input_string == 'null' or input_string is None):
return None
# If it is surrounded by brackets, we just remove the brackets:
if(input_string[0] == '[' and input_string[-1] =... |
kressi/erpnext | refs/heads/develop | erpnext/schools/doctype/program/test_program.py | 46 | # -*- coding: utf-8 -*-
# Copyright (c) 2015, Frappe Technologies and Contributors
# See license.txt
from __future__ import unicode_literals
import frappe
import unittest
# test_records = frappe.get_test_records('Program')
class TestProgram(unittest.TestCase):
pass
|
jarn0ld/gnuradio | refs/heads/master | grc/gui/DrawingArea.py | 19 | """
Copyright 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
This file is part of GNU Radio
GNU Radio Companion 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 ... |
sabi0/intellij-community | refs/heads/master | python/testData/completion/heavyStarPropagation/lib/_pkg1/_pkg1_1/_pkg1_1_0/_pkg1_1_0_0/_pkg1_1_0_0_1/__init__.py | 30 | from ._mod1_1_0_0_1_0 import *
from ._mod1_1_0_0_1_1 import *
from ._mod1_1_0_0_1_2 import *
from ._mod1_1_0_0_1_3 import *
from ._mod1_1_0_0_1_4 import * |
longmen21/edx-platform | refs/heads/master | common/test/acceptance/tests/studio/base_studio_test.py | 7 | """
Base classes used by studio tests.
"""
from bok_choy.web_app_test import WebAppTest
from bok_choy.page_object import XSS_INJECTION
from common.test.acceptance.pages.studio.auto_auth import AutoAuthPage
from common.test.acceptance.fixtures.course import CourseFixture
from common.test.acceptance.fixtures.library impo... |
tboyce021/home-assistant | refs/heads/dev | homeassistant/components/traccar/__init__.py | 8 | """Support for Traccar."""
from aiohttp import web
import voluptuous as vol
from homeassistant.components.device_tracker import DOMAIN as DEVICE_TRACKER
from homeassistant.const import CONF_WEBHOOK_ID, HTTP_OK, HTTP_UNPROCESSABLE_ENTITY
from homeassistant.helpers import config_entry_flow
import homeassistant.helpers.c... |
mick-d/nipype_source | refs/heads/master | nipype/interfaces/spm/tests/test_auto_ApplyTransform.py | 2 | # AUTO-GENERATED by tools/checkspecs.py - DO NOT EDIT
from nipype.testing import assert_equal
from nipype.interfaces.spm.utils import ApplyTransform
def test_ApplyTransform_inputs():
input_map = dict(ignore_exception=dict(nohash=True,
usedefault=True,
),
in_file=dict(copyfile=True,
mandatory=True,
... |
Lyrositor/moul-scripts | refs/heads/master | Python/xKI.py | 12 | # -*- coding: utf-8 -*-
""" *==LICENSE==*
CyanWorlds.com Engine - MMOG client, server and tools
Copyright (C) 2011 Cyan Worlds, 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 3... |
anksp21/Community-Zenpacks | refs/heads/master | ZenPacks.atrawog.Brocade/ZenPacks/atrawog/Brocade/modeler/__init__.py | 504 | # __init__.py
|
CloCkWeRX/rabbitvcs | refs/heads/master | rabbitvcs/vcs/status.py | 3 | #
# This is an extension to the Nautilus file manager to allow better
# integration with the Subversion source control system.
#
# Copyright (C) 2006-2008 by Jason Field <[email protected]>
# Copyright (C) 2007-2008 by Bruce van der Kooij <[email protected]>
# Copyright (C) 2008-2010 by Adam Plumb <adamplumb@... |
synconics/odoo | refs/heads/8.0 | addons/payment_buckaroo/models/buckaroo.py | 33 | # -*- coding: utf-'8' "-*-"
from hashlib import sha1
import logging
import urllib
import urlparse
from openerp.addons.payment.models.payment_acquirer import ValidationError
from openerp.addons.payment_buckaroo.controllers.main import BuckarooController
from openerp.osv import osv, fields
from openerp.tools.float_utils... |
kenwang815/KodiPlugins | refs/heads/master | script.module.oceanktv/lib/youtube_dl/extractor/ruhd.py | 19 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from .common import InfoExtractor
class RUHDIE(InfoExtractor):
_VALID_URL = r'https?://(?:www\.)?ruhd\.ru/play\.php\?vid=(?P<id>\d+)'
_TEST = {
'url': 'http://www.ruhd.ru/play.php?vid=207',
'md5': 'd1a9ec4edf8598e3fbd92bb16072ba8... |
qbektrix/namebench | refs/heads/master | nb_third_party/dns/rdtypes/ANY/PTR.py | 248 | # Copyright (C) 2003-2007, 2009, 2010 Nominum, Inc.
#
# Permission to use, copy, modify, and distribute this software and its
# documentation for any purpose with or without fee is hereby granted,
# provided that the above copyright notice and this permission notice
# appear in all copies.
#
# THE SOFTWARE IS PROVIDED ... |
jhd/spunout | refs/heads/master | flask/lib/python2.7/site-packages/migrate/__init__.py | 79 | """
SQLAlchemy migrate provides two APIs :mod:`migrate.versioning` for
database schema version and repository management and
:mod:`migrate.changeset` that allows to define database schema changes
using Python.
"""
import pkg_resources
from migrate.versioning import *
from migrate.changeset import *
__ver... |
peeyush-tm/check_mk | refs/heads/nocout | doc/treasures/modbus/perfometer/modbus.py | 6 | #!/usr/bin/python
# -*- encoding: utf-8; py-indent-offset: 4 -*-
# +------------------------------------------------------------------+
# | ____ _ _ __ __ _ __ |
# | / ___| |__ ___ ___| | __ | \/ | |/ / |
# | | | | '_ \ / _ \/ __| |/ /... |
blackzw/openwrt_sdk_dev1 | refs/heads/master | staging_dir/host/lib/python2.7/stringold.py | 293 | # module 'string' -- A collection of string operations
# Warning: most of the code you see here isn't normally used nowadays. With
# Python 1.6, many of these functions are implemented as methods on the
# standard string object. They used to be implemented by a built-in module
# called strop, but strop is now obsolet... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.