repo_name stringlengths 5 100 | ref stringlengths 12 67 | path stringlengths 4 244 | copies stringlengths 1 8 | content stringlengths 0 1.05M ⌀ |
|---|---|---|---|---|
xifengchuo/openembedded | refs/heads/master | contrib/python/generate-manifest-2.4.py | 45 | #!/usr/bin/env python
# generate Python Manifest for the OpenEmbedded build system
# (C) 2002-2007 Michael 'Mickey' Lauer <mickey@Vanille.de>
# MIT license
import os
import sys
import time
VERSION = "2.4.4"
# increase when touching python-core
BASEREV = 2
__author__ = "Michael 'Mickey' Lauer <mickey@Vanille.de>"
__... |
ThinkOpen-Solutions/odoo | refs/heads/stable | addons/hr_timesheet_sheet/wizard/hr_timesheet_current.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... |
mmnelemane/nova | refs/heads/master | nova/db/sqlalchemy/migrate_repo/versions/277_add_fixed_ip_updated_index.py | 73 | # 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
# distributed under the Li... |
bkach/TravelTerminal | refs/heads/master | program.py | 1 | from findLocation import findLocation
import sys
import datetime
import time
from search import search
from time import mktime
from datetime import datetime
reload(sys)
sys.setdefaultencoding('UTF8')
def printResults(results,start,num):
if(num > len(results.items()) - 1):
num = len(results.items()) - 1
... |
CiscoSystems/vespa | refs/heads/master | neutron/tests/unit/test_metadata_namespace_proxy.py | 13 | # vim: tabstop=4 shiftwidth=4 softtabstop=4
#
# Copyright 2012 New Dream Network, LLC (DreamHost)
#
# 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/li... |
remh/dd-agent | refs/heads/master | tests/checks/mock/test_consul.py | 18 | import random
from tests.checks.common import AgentCheckTest, load_check
MOCK_CONFIG = {
'init_config': {},
'instances' : [{
'url': 'http://localhost:8500',
'catalog_checks': True,
}]
}
MOCK_CONFIG_SERVICE_WHITELIST = {
'init_config': {},
'instances' : [{
'url': 'http://lo... |
prakritish/ansible | refs/heads/devel | test/units/module_utils/json_utils/__init__.py | 12133432 | |
camptocamp/QGIS | refs/heads/master | python/plugins/processing/admintools/geoserver/__init__.py | 12133432 | |
sgzsh269/django | refs/heads/master | tests/version/__init__.py | 12133432 | |
wji/plenarnavi_backend | refs/heads/master | api/__init__.py | 12133432 | |
since2014/gitosis | refs/heads/master | gitosis/test/test_group.py | 29 | from nose.tools import eq_ as eq, assert_raises
from ConfigParser import RawConfigParser
from gitosis import group
def test_no_emptyConfig():
cfg = RawConfigParser()
gen = group.getMembership(config=cfg, user='jdoe')
eq(gen.next(), 'all')
assert_raises(StopIteration, gen.next)
def test_no_emptyGroup... |
OpenNingia/l5r-character-manager | refs/heads/master | l5rcm/dal/query.py | 1 | # -*- coding: utf-8 -*-
# Copyright (C) 2014 Daniele Simonetti
#
# 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) any later version.
#
# Thi... |
openlabs/nereid-project | refs/heads/develop | application.py | 3 | #!/usr/bin/env python
import os
import datetime
import mimetypes
from nereid import Nereid
from werkzeug.contrib.sessions import FilesystemSessionStore
from werkzeug.wsgi import SharedDataMiddleware
from nereid.contrib.locale import Babel
from nereid.sessions import Session
from raven.contrib.flask import Sentry
CWD ... |
krafczyk/root | refs/heads/master | interpreter/llvm/src/utils/llvm-build/llvmbuild/util.py | 143 | import os
import sys
def _write_message(kind, message):
program = os.path.basename(sys.argv[0])
sys.stderr.write('%s: %s: %s\n' % (program, kind, message))
note = lambda message: _write_message('note', message)
warning = lambda message: _write_message('warning', message)
error = lambda message: _write_message... |
Vassy/odoo | refs/heads/master | addons/hr_recruitment/report/hr_recruitment_report.py | 56 | # -*- 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... |
mastbaum/rat-pac | refs/heads/master | python/ratproc/ntuple.py | 7 | from ratproc.base import Processor
from rat import ROOT, RAT, ratiter
from rat.parser import create_evaluation_tree
from array import array
import operator
import itertools
class NtupleWriter(object):
def __init__(self, ntuple, field_selectors):
self.ntuple = ntuple
self.field_selectors = field_sel... |
bclau/nova | refs/heads/master | nova/netconf.py | 17 | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2010 United States Government as represented by the
# Administrator of the National Aeronautics and Space Administration.
# All Rights Reserved.
# Copyright 2012 Red Hat, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not... |
saydulk/django | refs/heads/master | django/contrib/admin/decorators.py | 558 | def register(*models, **kwargs):
"""
Registers the given model(s) classes and wrapped ModelAdmin class with
admin site:
@register(Author)
class AuthorAdmin(admin.ModelAdmin):
pass
A kwarg of `site` can be passed as the admin site, otherwise the default
admin site will be used.
... |
ThiagoGarciaAlves/intellij-community | refs/heads/master | python/testData/refactoring/move/relativeImportsToModulesInSameMovedPackageNotUpdated/before/src/pkg/subpkg/m1.py | 76 | from . import m2
import m3
import subsubpkg as foo
from . import subsubpkg as bar
from .subsubpkg import m4
from .. import m5
print(m2, m3, m4, m5, foo, bar)
|
aerickson/ansible | refs/heads/devel | lib/ansible/modules/web_infrastructure/ansible_tower/tower_group.py | 33 | #!/usr/bin/python
#coding: utf-8 -*-
# (c) 2017, Wayne Witzel III <wayne@riotousliving.com>
#
# This module 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 optio... |
python-dirbtuves/Misago | refs/heads/ubuntu-lt | misago/apps/profiles/followers/urls.py | 3 | from django.conf.urls import patterns, url
def register_profile_urls(first=False):
urlpatterns = []
if first:
urlpatterns += patterns('misago.apps.profiles.followers.views',
url(r'^$', 'followers', name="user"),
url(r'^$', 'followers', name="user_followers"),
url(r'^... |
polinom/djangopeople | refs/heads/master | djangopeople/djangopeople/groupedselect.py | 1 | from django import forms
from django.forms.util import flatatt
from django.utils.encoding import smart_unicode
from django.utils.html import escape
from django.utils.safestring import mark_safe
from django.utils.translation import ugettext as _
# From http://www.djangosnippets.org/snippets/200/
# widget for select wit... |
cgstudiomap/cgstudiomap | refs/heads/develop | main/eggs/PyChart-1.39-py2.7.egg/pychart/range_plot_doc.py | 143 | # automatically generated by generate_docs.py.
doc=" "
|
Ikergune/firos | refs/heads/master | scripts/include/pubsub/contextbroker/cbQueryBuilder.py | 1 | # MIT License
#
# Copyright (c) <2015> <Ikergune, Etxetar>
#
# 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 use, copy, modify, m... |
AltSchool/django-allauth | refs/heads/master | allauth/socialaccount/providers/daum/__init__.py | 12133432 | |
go-bears/nupic | refs/heads/master | src/nupic/bindings/proto/__init__.py | 12133432 | |
davgibbs/django | refs/heads/master | django/conf/locale/is/__init__.py | 12133432 | |
gangadhar-kadam/sapphire_app | refs/heads/1310 | stock/report/requested_items_to_be_transferred/__init__.py | 12133432 | |
craynot/django | refs/heads/master | django/views/static.py | 300 | """
Views and functions for serving static files. These are only to be used
during development, and SHOULD NOT be used in a production setting.
"""
from __future__ import unicode_literals
import mimetypes
import os
import posixpath
import re
import stat
from django.http import (
FileResponse, Http404, HttpRespons... |
kaleidos/intranet | refs/heads/master | backend/cmsutils/templatetags/datefilters.py | 3 | from django import template
from django.conf import settings
from django.utils.translation import get_language
register = template.Library()
## ("short format", "long format") as strptime format
DATEFORMAT_TRANSLATIONS_DEFAULT = {
'es': ("%d/%m/%Y", ),
'fr': ("%d/%m/%Y", ),
'en': ("%Y-%m-%d", ),
'de'... |
francis-liberty/PHD | refs/heads/master | tests/test_srt.py | 1 | import unittest
import os
import parser.srt as psrt
class TestSRT(unittest.TestCase):
def setUp(self):
pass
def test_parse(self):
dr = os.path.dirname(__file__)
file_path = os.path.join(dr, '../data/test.srt')
texts = psrt.parse(file_path)
print texts
|
inspirehep/invenio | refs/heads/prod | modules/bibdocfile/lib/icon_migration_kit.py | 23 | ## This file is part of Invenio.
## Copyright (C) 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 option) any later version.
##
... |
fpy171/django | refs/heads/master | django/conf/locale/vi/__init__.py | 12133432 | |
rockneurotiko/django | refs/heads/master | tests/dbshell/__init__.py | 12133432 | |
dsfsdgsbngfggb/odoo | refs/heads/8.0 | addons/hr_gamification/wizard/__init__.py | 388 | # -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2013 OpenERP SA (<http://openerp.com>).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU... |
smenon8/AlgDataStruct_practice | refs/heads/master | practice_problems/sample.py | 2 | from itertools import product
k,m = input().split()
k,m = int(k),int(m)
a = []
for lno in range(k):
a.append(input().split())
ad = []
for l in a:
l = (list(map(int,l[1:])))
ad.append(l)
al = product(*ad)
maxim = []
for i in al:
i = [x**2 for x in i]
summ = sum(i)% m
maxim.append... |
MarcosCommunity/odoo | refs/heads/marcos-8.0 | comunity_modules/website_countdown/models/countdown.py | 1 | # -*- encoding: utf-8 -*-
##############################################################################
# For copyright and license notices, see __openerp__.py file in root directory
##############################################################################
from openerp.osv import osv, orm, fields
from openerp.a... |
Jeremy-WEI/python-mode | refs/heads/develop | pymode/libs2/rope/refactor/change_signature.py | 59 | import copy
import rope.base.exceptions
from rope.base import pyobjects, taskhandle, evaluate, worder, codeanalyze, utils
from rope.base.change import ChangeContents, ChangeSet
from rope.refactor import occurrences, functionutils
class ChangeSignature(object):
def __init__(self, project, resource, offset):
... |
gibiansky/tensorflow | refs/heads/master | tensorflow/python/ops/gradient_checker.py | 33 | # Copyright 2015 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... |
jromang/clop | refs/heads/master | LaTeX/2008-06-02-CLOP/old-plots/plot_parameters.py | 1 | from qlr import *
def build_tikz(p, scale):
#########################################################################
"build tikz object"
#########################################################################
if p.GetDimensions() == 1:
tikz = CTikZOneD()
tikz.SetScale(5.5)
elif p... |
fengbaicanhe/intellij-community | refs/heads/master | python/testData/completion/superClassAttributesNoCompletionInFunc.after.py | 166 | class Foo:
attribute = 1
class Boo(Foo):
def f(self):
attr<caret> |
kmoocdev2/edx-platform | refs/heads/real_2019 | openedx/core/djangoapps/zendesk_proxy/v1/__init__.py | 12133432 | |
adedayo/intellij-community | refs/heads/master | python/lib/Lib/site-packages/django/contrib/localflavor/in_/__init__.py | 12133432 | |
procangroup/edx-platform | refs/heads/master | openedx/core/djangoapps/embargo/migrations/__init__.py | 12133432 | |
poiati/django | refs/heads/master | django/conf/locale/sq/__init__.py | 12133432 | |
edry/edx-platform | refs/heads/master | lms/djangoapps/instructor_task/__init__.py | 12133432 | |
marcydoty/geraldo | refs/heads/master | site/newsite/site-geraldo/django/contrib/auth/handlers/modpython.py | 436 | from mod_python import apache
import os
def authenhandler(req, **kwargs):
"""
Authentication handler that checks against Django's auth database.
"""
# mod_python fakes the environ, and thus doesn't process SetEnv. This fixes
# that so that the following import works
os.environ.update(req.subp... |
kingosticks/mopidy | refs/heads/develop | tests/file/conftest.py | 4 | import pytest
@pytest.fixture
def file_config():
return {"file": {}}
@pytest.fixture
def file_library(file_config):
# Import library, thus scanner, thus gobject as late as possible to avoid
# hard to track import errors during conftest setup.
from mopidy.file import library
return library.FileL... |
Stanford-Online/edx-platform | refs/heads/master | openedx/core/djangoapps/schedules/management/__init__.py | 12133432 | |
manqala/erpnext | refs/heads/develop | erpnext/maintenance/report/maintenance_schedules/__init__.py | 12133432 | |
AlexanderMatveenko/omim | refs/heads/master | 3party/protobuf/examples/list_people.py | 429 | #! /usr/bin/python
# See README.txt for information and build instructions.
import addressbook_pb2
import sys
# Iterates though all people in the AddressBook and prints info about them.
def ListPeople(address_book):
for person in address_book.person:
print "Person ID:", person.id
print " Name:", person.na... |
delph-in/pydmrs | refs/heads/master | examples/examples_dmrs.py | 1 | from pydmrs.components import Pred, GPred, RealPred, Sortinfo, EventSortinfo, InstanceSortinfo
from pydmrs.core import Node, Link, DictDmrs
def the():
dmrs = DictDmrs()
dmrs.add_node(Node(pred=RealPred('the', 'q'))) # node id set automatically
return dmrs
def the_cat():
dmrs = DictDmrs(surface='the... |
Thor77/youtube-dl | refs/heads/master | youtube_dl/extractor/lynda.py | 7 | from __future__ import unicode_literals
import re
from .common import InfoExtractor
from ..compat import (
compat_HTTPError,
compat_str,
compat_urlparse,
)
from ..utils import (
ExtractorError,
int_or_none,
urlencode_postdata,
)
class LyndaBaseIE(InfoExtractor):
_SIGNIN_URL = 'https://ww... |
immanetize/supernova | refs/heads/master | tests/test_credentials.py | 5 | import keyring.backend
import pytest
import six
from supernova import credentials, utils
class TestKeyring(keyring.backend.KeyringBackend):
"""A test keyring which always outputs same password
"""
priority = 1
def set_password(self, servicename, username, password):
pass
def get_pa... |
ktaneishi/deepchem | refs/heads/master | contrib/atomicconv/feat/atomicnet_coordinates.py | 7 | """
Atomic coordinate featurizer.
"""
from __future__ import print_function
from __future__ import division
from __future__ import unicode_literals
__author__ = "Joseph Gomes"
__copyright__ = "Copyright 2016, Stanford University"
__license__ = "MIT"
import numpy as np
from rdkit import Chem
from deepchem.feat import ... |
silenci/neutron | refs/heads/master | neutron/db/rbac_db_models.py | 20 | # Copyright (c) 2015 Mirantis, 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 requir... |
ziir/lumbergh | refs/heads/master | vendor-local/lib/python/south/tests/db.py | 12 | import datetime
from south.db import db, generic
from django.db import connection, models, IntegrityError
from south.tests import unittest, skipUnless
# Create a list of error classes from the various database libraries
errors = []
try:
from psycopg2 import ProgrammingError
errors.append(ProgrammingE... |
ltyscu/ReducingWastedEvaluationsCGP | refs/heads/master | plotter.py | 2 | '''
Takes file names from the output/ folder and parses the information into
readable values and produces a graph. Use this module as an executable to
process all information for a single problem, such as:
python plotter.py output/multiply*
Do not mix problems in a single run. The graph will be saved to a .eps file... |
Spiderlover/Toontown | refs/heads/master | toontown/suit/DistributedGridGoon.py | 5 | from pandac.PandaModules import *
from direct.interval.IntervalGlobal import *
from toontown.battle.BattleProps import *
from direct.directnotify import DirectNotifyGlobal
import DistributedGoon
from toontown.toonbase import ToontownGlobals
from toontown.coghq import MovingPlatform
class DistributedGridGoon(Distribute... |
sajuptpm/neutron-ipam | refs/heads/stable/icehouse | neutron/services/loadbalancer/agent/agent_manager.py | 4 | # vim: tabstop=4 shiftwidth=4 softtabstop=4
#
# Copyright 2013 New Dream Network, LLC (DreamHost)
#
# 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/li... |
hsoft/pdfmasher | refs/heads/master | hscommon/tests/__init__.py | 12133432 | |
noironetworks/python-neutronclient | refs/heads/master | neutronclient/osc/__init__.py | 12133432 | |
lixt/lily2-gem5 | refs/heads/master | ext/ply/test/lex_module_import.py | 174 | # -----------------------------------------------------------------------------
# lex_module_import.py
#
# A lexer defined in a module, but built in lex_module.py
# -----------------------------------------------------------------------------
tokens = (
'NAME','NUMBER',
'PLUS','MINUS','TIMES','DIVIDE','EQUALS'... |
elmerdpadilla/iv | refs/heads/8.0 | addons/l10n_multilang/account.py | 348 | # -*- 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... |
slac207/cs207project | refs/heads/master | timeseries/tests/test_lazy.py | 2 | from pytest import raises
from timeseries.lazy import lazy_add, lazy_mul, LazyOperation, lazy
def test_type():
assert isinstance(lazy_add(2,3),LazyOperation)==True
assert isinstance(lazy_mul(2,3),LazyOperation)==True
def test_operation():
assert lazy_add(3,4).eval()==7
assert lazy_mul(3,4).eval()==12
... |
antb/TPT----My-old-mod | refs/heads/master | src/python/stdlib/test/test_getargs.py | 130 | """
Test the internal getargs.c implementation
PyArg_ParseTuple() is defined here.
The test here is not intended to test all of the module, just the
single case that failed between 2.1 and 2.2a2.
"""
# marshal.loads() uses PyArg_ParseTuple(args, "s#:loads")
# The s code will cause a Unicode conversion to occur. Th... |
erramuzpe/NeuroVault | refs/heads/master | neurovault/apps/users/tests/test_oauth.py | 4 | from django.test import TestCase, Client
from django.http import HttpResponse
from django.core.urlresolvers import reverse
from django.conf.urls import patterns, url, include
from django.contrib.auth import get_user_model
from rest_framework import permissions
from rest_framework.views import APIView
from oauth2_provi... |
chrta/simulavr | refs/heads/master | regress/modtest/adc_gain.py | 3 | from simtestutil import SimTestCase, SimTestLoader
import pysimulavr
class TestCase(SimTestCase):
ADC_CLOCK = 8000 # ADC clock is 125kHz
adc0_pin = {
"atmega16": "A0",
"atmega644": "A0",
"at90can32": "F0",
"atmega128": "F0",
}
adc1_pin = {
"atmega16": "A1",
"atmega644": "A1",
... |
florian-f/sklearn | refs/heads/master | sklearn/neighbors/graph.py | 14 | """Nearest Neighbors graph functions"""
# Author: Jake Vanderplas <vanderplas@astro.washington.edu>
#
# License: BSD, (C) INRIA, University of Amsterdam
from .base import KNeighborsMixin, RadiusNeighborsMixin
from .unsupervised import NearestNeighbors
def kneighbors_graph(X, n_neighbors, mode='connectivity'):
"... |
rohitwaghchaure/erpnext_develop | refs/heads/develop | erpnext/docs/user/manual/en/selling/setup/__init__.py | 12133432 | |
tupolev/plugin.video.mitele | refs/heads/master | lib/youtube_dl/extractor/thestar.py | 14 | # coding: utf-8
from __future__ import unicode_literals
from .common import InfoExtractor
from .brightcove import BrightcoveLegacyIE
from ..compat import compat_parse_qs
class TheStarIE(InfoExtractor):
_VALID_URL = r'https?://(?:www\.)?thestar\.com/(?:[^/]+/)*(?P<id>.+)\.html'
_TEST = {
'url': 'http:... |
vebin/Wox | refs/heads/master | PythonHome/Lib/site-packages/requests/packages/urllib3/util/timeout.py | 303 | from socket import _GLOBAL_DEFAULT_TIMEOUT
import time
from ..exceptions import TimeoutStateError
def current_time():
"""
Retrieve the current time, this function is mocked out in unit testing.
"""
return time.time()
_Default = object()
# The default timeout to use for socket connections. This is t... |
dennis-sheil/commandergenius | refs/heads/sdl_android | project/jni/python/src/Tools/scripts/finddiv.py | 102 | #! /usr/bin/env python
"""finddiv - a grep-like tool that looks for division operators.
Usage: finddiv [-l] file_or_directory ...
For directory arguments, all files in the directory whose name ends in
.py are processed, and subdirectories are processed recursively.
This actually tokenizes the files to avoid false h... |
xodus7/tensorflow | refs/heads/master | tensorflow/contrib/distributions/python/kernel_tests/bijectors/reshape_test.py | 24 | # 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... |
aurelieladier/openturns | refs/heads/master | python/test/t_LaplaceFactory_std.py | 4 | #! /usr/bin/env python
from __future__ import print_function
from openturns import *
TESTPREAMBLE()
RandomGenerator.SetSeed(0)
try:
distribution = Laplace(2.5, -1.3)
size = 10000
sample = distribution.getSample(size)
factory = LaplaceFactory()
estimatedDistribution = factory.build(sample)
pri... |
christophercrouzet/bana | refs/heads/master | tests/OpenMaya/test_MPoint.py | 2 | #!/usr/bin/env mayapy
import os
import sys
import unittest
import maya.standalone
from maya import OpenMaya
_HERE = os.path.abspath(os.path.dirname(__file__))
sys.path.insert(0, os.path.abspath(os.path.join(_HERE, *((os.pardir,) * 2))))
import bana
bana.initialize()
maya.standalone.initialize()
class MPointTest(... |
intervigilium/android_kernel_motorola_ghost | refs/heads/cm-12.1 | tools/perf/scripts/python/net_dropmonitor.py | 4235 | # Monitor the system for dropped packets and proudce a report of drop locations and counts
import os
import sys
sys.path.append(os.environ['PERF_EXEC_PATH'] + \
'/scripts/python/Perf-Trace-Util/lib/Perf/Trace')
from perf_trace_context import *
from Core import *
from Util import *
drop_log = {}
kallsyms = []
def... |
alphonzo79/ShaveKeeper | refs/heads/master | ProductDataCompiler/src/main/com/rowley/shavekeeper/productdatacompiler/utils/__init__.py | 12133432 | |
mmcdermo/helpinghand | refs/heads/master | server/venv/lib/python2.7/site-packages/django/conf/locale/lt/__init__.py | 12133432 | |
valtech-mooc/edx-platform | refs/heads/master | common/djangoapps/course_modes/helpers.py | 12133432 | |
pixelgremlins/ztruck | refs/heads/master | dj/lib/python2.7/site-packages/django/conf/locale/ml/__init__.py | 12133432 | |
andlima/olheiro | refs/heads/master | olheiro.py | 1 | #!/usr/bin/python
import os
import mercado
ARQUIVO_MOD = 'olheiro.mod'
ARQUIVO_DAT = 'olheiro.dat'
GLPSOL_EXEC = 'glpsol -m %s -d %s' % (ARQUIVO_MOD, ARQUIVO_DAT)
LISTA_CONJUNTOS = ['S_Jogadores', 'S_Posicoes', 'S_Formacoes']
LISTA_PARAMETROS = ['P_Patrimonio', 'P_Preco', 'P_Media',
'Pe_Posicao',... |
iambibhas/django | refs/heads/master | tests/urlpatterns_reverse/included_urls2.py | 47 | """
These URL patterns are included in two different ways in the main urls.py, with
an extra argument present in one case. Thus, there are two different ways for
each name to resolve and Django must distinguish the possibilities based on the
argument list.
"""
from django.conf.urls import url
from .views import empty... |
shootsoft/practice | refs/heads/master | LeetCode/python/061-090/082-remove-duplicates-from-sorted-list-ii/solution.py | 1 | __author__ = 'yinjun'
# Definition for singly-linked list.
# class ListNode:
# def __init__(self, x):
# self.val = x
# self.next = None
class Solution:
# @param head, a ListNode
# @return a ListNode
def deleteDuplicates(self, head):
h = ListNode(0)
h.next = head
... |
Microsoft/PTVS | refs/heads/master | Python/Product/Miniconda/Miniconda3-x64/Lib/unittest/test/test_skipping.py | 25 | import unittest
from unittest.test.support import LoggingResult
class Test_TestSkipping(unittest.TestCase):
def test_skipping(self):
class Foo(unittest.TestCase):
def test_skip_me(self):
self.skipTest("skip")
events = []
result = LoggingResult(events)
... |
wevote/WeVoteServer | refs/heads/develop | import_export_wikipedia/views.py | 2 | # import_export_wikipedia/views.py
# Brought to you by We Vote. Be good.
# -*- coding: UTF-8 -*-
# See also import_export_wikipedia/views_admin.py for views used in the admin area
|
sjperkins/tensorflow | refs/heads/master | tensorflow/python/debug/examples/debug_fibonacci.py | 58 | # 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... |
mpavone/vCloudPy | refs/heads/master | src/vCloud.py | 1 | # vCloudPy: VMWare vCloud Automation for Python Devops
# Copyright (c) 2014 Martino Pavone. All Rights Reserved.
#
# Licensed under the MIT License , (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://opensource.org/licenses/MIT
... |
lrowe/selenium | refs/heads/master | py/selenium/webdriver/common/by.py | 69 | # Licensed to the Software Freedom Conservancy (SFC) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The SFC licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not... |
zhouyejoe/spark | refs/heads/master | dev/sparktestsupport/shellutils.py | 42 | #
# 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 us... |
oinopion/django | refs/heads/master | tests/sites_tests/__init__.py | 12133432 | |
tdsymonds/djangocms-flexslider | refs/heads/master | djangocms_flexslider/__init__.py | 12133432 | |
Vixionar/django | refs/heads/master | tests/migrations/migrations_test_apps/migrated_app/migrations/__init__.py | 12133432 | |
indro/t2c | refs/heads/master | apps/external_apps/ajax_validation/urls.py | 12133432 | |
pwz3n0/buck | refs/heads/master | third-party/py/twitter-commons/src/python/twitter/common/python/testing.py | 23 | import contextlib
import os
import random
import tempfile
from textwrap import dedent
import zipfile
from .common import safe_mkdir, safe_mkdtemp, safe_rmtree
from .installer import EggInstaller
from .util import DistributionHelper
@contextlib.contextmanager
def temporary_dir():
td = tempfile.mkdtemp()
try:
... |
ramosian-glider/kasan | refs/heads/kasan_slab_slub | scripts/gdb/linux/__init__.py | 2010 | # nothing to do for the initialization of this package
|
RedHatQE/cfme_tests | refs/heads/master | cfme/fixtures/rdb.py | 1 | """Rdb: Remote debugger
Given the following configuration in conf/rdb.yaml::
breakpoints:
- subject: Brief explanation of a problem
exceptions:
- cfme.exceptions.ImportableExampleException
- BuiltinException (e.g. ValueError)
recipients:
- user@example.com
Any ... |
PatidarWeb/poedit | refs/heads/master | deps/boost/tools/build/src/util/regex.py | 34 | # (C) Copyright David Abrahams 2001. Permission to copy, use, modify, sell and
# distribute this software is granted provided this copyright notice appears in
# all copies. This software is provided "as is" without express or implied
# warranty, and with no claim as to its suitability for any purpose.
import re
d... |
3L3N4/volatility | refs/heads/master | volatility/plugins/linux/banner.py | 58 | # Volatility
# Copyright (C) 2007-2013 Volatility Foundation
#
# This file is part of Volatility.
#
# Volatility 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... |
yebeloved/idapython | refs/heads/master | build.py | 15 | #!/usr/bin/env python
#---------------------------------------------------------------------
# IDAPython - Python plugin for Interactive Disassembler
#
# (c) The IDAPython Team <idapython@googlegroups.com>
#
# All rights reserved.
#
# For detailed copyright information see the file COPYING in
# the root of the distribu... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.