repo_name
stringlengths
5
100
ref
stringlengths
12
67
path
stringlengths
4
244
copies
stringlengths
1
8
content
stringlengths
0
1.05M
vecnet/vnetsource
refs/heads/master
data_services/utils/run_data.py
2
__author__ = 'lselvy' from data_services.models import BaseFactData, DimExecution, DimRun, DimReplication, DimChannel from django.core.exceptions import ObjectDoesNotExist from django.db.models.query import QuerySet import json import time import itertools class RunData(object): """ This is the RunData Class....
roadmapper/ansible
refs/heads/devel
test/units/module_utils/remote_management/dellemc/test_ome.py
25
# -*- coding: utf-8 -*- # # Dell EMC OpenManage Ansible Modules # Version 2.0 # Copyright (C) 2019 Dell Inc. # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) # All rights reserved. Dell, EMC, and other trademarks are trademarks of Dell Inc. or its subsidiaries. # Other trad...
robertwbrandt/KopanoAdmin
refs/heads/master
bin/zarafa-mdm.py
1
#!/usr/bin/env python """ Python wrapper for z-push-admin.php """ import argparse, textwrap, fnmatch, datetime import xml.etree.cElementTree as ElementTree import subprocess # Import Brandt Common Utilities import sys, os sys.path.append( os.path.realpath( os.path.join( os.path.dirname(__file__), "/opt/brandt/common" ...
Vaghesh/upm
refs/heads/master
examples/python/lsm303.py
16
#!/usr/bin/python # Author: Brendan Le Foll <brendan.le.foll@intel.com> # Contributions: Zion Orent <zorent@ics.com> # Copyright (c) 2014 Intel Corporation. # # Permission is hereby granted, free of charge, to any person obtaining # a copy of this software and associated documentation files (the # "Software"), to deal...
danielparton/TargetExplorer
refs/heads/master
targetexplorer/core.py
3
import sys import os from lxml import etree from lxml.builder import E import yaml import logging # ======== # Global package variables # ======== datestamp_format_string = '%Y-%m-%d %H:%M:%S UTC' project_config_filename = 'project_config.yaml' manual_overrides_filename = 'manual_overrides.yaml' database_filename = ...
GraemeFulton/job-search
refs/heads/master
docutils-0.12/test/test_parsers/test_rst/test_inline_markup.py
16
#! /usr/bin/env python # -*- coding: utf-8 -*- # $Id: test_inline_markup.py 7668 2013-06-04 12:46:30Z milde $ # Author: David Goodger <goodger@python.org> # Copyright: This module has been placed in the public domain. """ Tests for inline markup in docutils/parsers/rst/states.py. Interpreted text tests are in a separ...
noba3/KoTos
refs/heads/master
addons/plugin.video.iptvxtra-neki/resources/requests/packages/chardet/__init__.py
745
######################## BEGIN LICENSE BLOCK ######################## # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Lesser General Public # License as published by the Free Software Foundation; either # version 2.1 of the License, or (at your option) any later ve...
feroda/django
refs/heads/master
tests/admin_scripts/custom_templates/app_template/api.py
581
# your API code
joakim-hove/django
refs/heads/master
tests/gis_tests/data/rasters/__init__.py
12133432
RNAcentral/rnacentral-webcode
refs/heads/master
rnacentral/portal/config/__init__.py
12133432
madflojo/cloudroutes-service
refs/heads/master
src/web/__init__.py
12133432
postrational/django
refs/heads/master
tests/db_typecasts/models.py
12133432
gregdek/ansible-modules-core
refs/heads/devel
windows/__init__.py
12133432
AutorestCI/azure-sdk-for-python
refs/heads/master
azure-mgmt-devtestlabs/azure/mgmt/devtestlabs/models/identity_properties.py
3
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator. # Changes ...
harterj/moose
refs/heads/devel
python/TestHarness/tests/test_FailedTests.py
13
#* This file is part of the MOOSE framework #* https://www.mooseframework.org #* #* All rights reserved, see COPYRIGHT for full restrictions #* https://github.com/idaholab/moose/blob/master/COPYRIGHT #* #* Licensed under LGPL 2.1, please see LICENSE for details #* https://www.gnu.org/licenses/lgpl-2.1.html import subp...
FNCS/ns-3.22
refs/heads/master
src/aodv/bindings/modulegen__gcc_ILP32.py
16
from pybindgen import Module, FileCodeSink, param, retval, cppclass, typehandlers import pybindgen.settings import warnings class ErrorHandler(pybindgen.settings.ErrorHandler): def handle_error(self, wrapper, exception, traceback_): warnings.warn("exception %r in wrapper %s" % (exception, wrapper)) ...
odoousers2014/odoo
refs/heads/master
addons/point_of_sale/controllers/__init__.py
7372
import main
naritta/numpy
refs/heads/master
numpy/distutils/npy_pkg_config.py
102
from __future__ import division, absolute_import, print_function import sys import re import os import shlex if sys.version_info[0] < 3: from ConfigParser import SafeConfigParser, NoOptionError else: from configparser import ConfigParser, SafeConfigParser, NoOptionError __all__ = ['FormatError', 'PkgNotFound...
dannyperry571/theapprentice
refs/heads/master
script.module.livestreamer/lib/livestreamer/plugins/seemeplay.py
34
import re from livestreamer.compat import urlparse from livestreamer.plugin import Plugin from livestreamer.plugin.api import http, validate from livestreamer.stream import HLSStream, HTTPStream _url_re = re.compile("http(s)?://(\w+\.)?seemeplay.ru/") _player_re = re.compile(""" SMP.(channel|video).player.init\({...
dart-lang/sdk
refs/heads/master
tools/linux_dist_support/create_debian_packages.py
2
#!/usr/bin/env python3 # # Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file # for details. All rights reserved. Use of this source code is governed by a # BSD-style license that can be found in the LICENSE file. # # Script to build a Debian packages from a Dart tarball. The script # will buil...
akloster/bokeh
refs/heads/master
examples/plotting/file/legend.py
43
import numpy as np from bokeh.plotting import figure, show, output_file, vplot N = 100 x = np.linspace(0, 4*np.pi, N) y = np.sin(x) output_file("legend.html", title="legend.py example") TOOLS = "pan,wheel_zoom,box_zoom,reset,save,box_select" p1 = figure(title="Legend Example", tools=TOOLS) p1.circle(x, y, legend...
40423141/2017springcd_hw
refs/heads/gh-pages
plugin/liquid_tags/b64img.py
312
""" Image Tag --------- This implements a Liquid-style image tag for Pelican, based on the liquid img tag which is based on the octopress image tag [1]_ Syntax ------ {% b64img [class name(s)] [http[s]:/]/path/to/image [width [height]] [title text | "title text" ["alt text"]] %} Examples -------- {% b64img /images/ni...
lmignon/l10n-belgium
refs/heads/master
__unported__/account_statement_coda_import/parser/coda_file_parser.py
1
# -*- coding: utf-8 -*- # # # Authors: Laurent Mignon # Copyright (c) 2014 Acsone SA/NV (http://www.acsone.eu) # All Rights Reserved # # This program 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, eith...
bretshack/hexamap
refs/heads/master
test.py
1
import os import urllib import jinja2 import webapp2 JINJA_ENVIRONMENT = jinja2.Environment( loader=jinja2.FileSystemLoader(os.path.dirname(__file__)), extensions=['jinja2.ext.autoescape'], autoescape=True) class MainPage(webapp2.RequestHandler): def get(self): template = JINJA_ENVIRONMENT....
martajaw/Db_noncanonic
refs/heads/master
functions.py
1
import re import subprocess import os, sys import psycopg2 import config #Functions that retrive data from RNAView output files: def rv_full(line): line = line.lstrip().rstrip() return(line) def rv_interaction(line): interactions = re.findall('[sSwWhH\+\-\?\.]{1}/{1}[sSwWhH\+\-\?\.]{1}',line) conformation = re.fi...
TwinkleChawla/nova
refs/heads/master
nova/tests/unit/keymgr/test_conf_key_mgr.py
71
# Copyright (c) 2013 The Johns Hopkins University/Applied Physics Laboratory # 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/...
jcnielsendk/SU0159Test
refs/heads/master
test.py
1
print "Hej verden!"
wemanuel/smry
refs/heads/master
smry/server-auth/ls/google-cloud-sdk/platform/gsutil/third_party/httplib2/python2/httplib2/test/miniserver.py
303
import logging import os import select import SimpleHTTPServer import SocketServer import threading HERE = os.path.dirname(__file__) logger = logging.getLogger(__name__) class ThisDirHandler(SimpleHTTPServer.SimpleHTTPRequestHandler): def translate_path(self, path): path = path.split('?', 1)[0].split('#'...
nuagenetworks/tempest
refs/heads/master
tempest/api/compute/admin/test_floating_ips_bulk.py
6
# Copyright 2014 NEC Technologies India Ltd. # 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 # # Unle...
calpeyser/google-cloud-python
refs/heads/master
storage/tests/unit/__init__.py
216
# Copyright 2016 Google Inc. # # 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, ...
isnnn/Sick-Beard-TPB
refs/heads/ThePirateBay
lib/hachoir_core/timeout.py
186
""" limitedTime(): set a timeout in seconds when calling a function, raise a Timeout error if time exceed. """ from math import ceil IMPLEMENTATION = None class Timeout(RuntimeError): """ Timeout error, inherits from RuntimeError """ pass def signalHandler(signum, frame): """ Signal handler t...
Sutto/cloud-custodian
refs/heads/master
tools/c7n_gcp/c7n_gcp/query.py
2
# Copyright 2017-2018 Capital One Services, LLC # # 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 ...
yp/reHCstar
refs/heads/master
rehcstar/__init__.py
12133432
ar45/django
refs/heads/master
tests/custom_methods/__init__.py
12133432
selective-inference/selective-inference
refs/heads/master
sandbox/bayesian/__init__.py
12133432
jusjusjus/pyedf
refs/heads/master
pyedf/recording/recording.py
1
#! /usr/bin/python import numpy as np from .edf_hdr_struct import edf_hdr_struct, read_md5 from .channeltypes import is_channeltype import pyedf.score as score import datetime import logging if not hasattr(__builtins__, 'xrange'): xrange = range class Recording(edf_hdr_struct): logger = logging.getLogger...
BastienDufaud/pewpew
refs/heads/master
classes/obstacle.py
1
#-*- coding: utf-8 -*- class Obstacle: def __init__(self, coo, v, t, p): self.setCoord(coo);#coordonnées de l'obstacle sur la map self.setView(v);#vue/image de l'obstacle self.setType(t);#ralentisseur, accelerateur de balle... self.setPower(p);#defini la puissance de l'effet ...
tuanvu216/udacity-course
refs/heads/master
developing_scalable_apps_in_python/ud858_master/lesson_4/00_conference_central/models.py
86
#!/usr/bin/env python """models.py Udacity conference server-side Python App Engine data & ProtoRPC models $Id: models.py,v 1.1 2014/05/24 22:01:10 wesc Exp $ created/forked from conferences.py by wesc on 2014 may 24 """ __author__ = 'wesc+api@google.com (Wesley Chun)' import httplib import endpoints from protor...
menardorama/ReadyNAS-Add-ons
refs/heads/master
headphones-1.0.0/files/apps/headphones/lib/certgen.py
161
# -*- coding: latin-1 -*- # # Copyright (C) Martin Sjögren and AB Strakt 2001, All rights reserved # Copyright (C) Jean-Paul Calderone 2008, All rights reserved # This file is licenced under the GNU LESSER GENERAL PUBLIC LICENSE Version 2.1 or later (aka LGPL v2.1) # Please see LGPL2.1.txt for more information """ Cert...
ayarshabeer/wagtail
refs/heads/master
wagtail/wagtailadmin/blocks.py
31
import warnings warnings.warn("wagtail.wagtailadmin.blocks has moved to wagtail.wagtailcore.blocks", UserWarning, stacklevel=2) from wagtail.wagtailcore.blocks import * # noqa
geminateCoder/Gemini-Project
refs/heads/develop
rp_grounds/posts/dict.py
1
POST_TYPES = ( ('Blog', 'Blog'), ('Prompt', 'Prompt'), ('Fanfiction', 'Fanfiction') ) STYLES = ( ('Script', 'Script'), ('Para', 'Para'), ('Novel', 'Novel') ) GENRE = ( ('Fandom', 'Fandom'), ('Fantasy/Supernatural', 'Fantasy/Supernatural'), ('Historical', 'Historical')...
eagleamon/home-assistant
refs/heads/dev
homeassistant/components/sensor/torque.py
15
""" Support for the Torque OBD application. For more details about this platform, please refer to the documentation at https://home-assistant.io/components/sensor.torque/ """ import logging import re import voluptuous as vol from homeassistant.core import callback from homeassistant.components.http import HomeAssist...
picklingjar/Webkitd
refs/heads/master
depends/spynner-0.0.3/examples/wordreference.py
1
#!/usr/bin/python import spynner import pyquery import os def images_filter(operation, url): return os.path.splitext(url)[1] not in (".jpg", ".png", ".gif") browser = spynner.Browser(debug_level=spynner.INFO) browser.set_html_parser(pyquery.PyQuery) browser.set_url_filter(images_filter) browser.create_w...
MrRagga-/ncclient
refs/heads/master
examples/juniper/edit-config-std.py
6
#!/usr/bin/env python from ncclient import manager from ncclient.xml_ import new_ele, sub_ele def connect(host, user, password): conn = manager.connect(host=host, username=user, password=password, timeout=10, hostkey_verify=False) conn.lock() root = new_el...
NathanWycoff/SySE
refs/heads/master
setup.py
1
from setuptools import setup, find_packages # To use a consistent encoding from codecs import open from os import path here = path.abspath(path.dirname(__file__)) # Get the long description from the README file with open(path.join(here, 'README'), encoding='utf-8') as f: long_description = f.read() setup( na...
Kalyzee/edx-platform
refs/heads/master
cms/djangoapps/contentstore/views/tests/test_item.py
35
"""Tests for items views.""" import json from datetime import datetime, timedelta import ddt from mock import patch, Mock, PropertyMock from pytz import UTC from pyquery import PyQuery from webob import Response from django.http import Http404 from django.test import TestCase from django.test.client import RequestFac...
AlexStarov/Shop
refs/heads/master
applications/extended_price/admin.py
1
# coding=utf-8 __author__ = 'Alex Starov' from django.contrib import admin from applications.extended_price.models import Price_Additional_Information class Price_Additional_Information_Admin(admin.ModelAdmin, ): pass admin.site.register(Price_Additional_Information, Price_Additional_Information_Admin, ) fro...
boyuegame/kbengine
refs/heads/master
kbe/res/scripts/common/Lib/lib2to3/fixer_base.py
100
# Copyright 2006 Google, Inc. All Rights Reserved. # Licensed to PSF under a Contributor Agreement. """Base class for fixers (optional, but recommended).""" # Python imports import logging import itertools # Local imports from .patcomp import PatternCompiler from . import pygram from .fixer_util import does_tree_imp...
pombredanne/TSP-CloudStack
refs/heads/master
src/it/tsp/cloudstack/amqp/pika/connection_amqp.py
1
# -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*- # Copyright (C) 2011 Houssem Medhioub - Institut Telecom # # This library is free software: you can redistribute it and/or modify # it under the terms of the GNU Lesser General Public License as # published by the Free Software Foundati...
lukius/mts
refs/heads/master
set1/challenge3.py
1
from common.challenge import MatasanoChallenge from common.tools.converters import HexToBytes from common.attacks.xor import SingleByteXORDecrypter class Set1Challenge03(MatasanoChallenge): STRING = '1b37373331363f78151b7f2b783431333d78397828372d363c7'+\ '8373e783a393b3736' def expecte...
9h37/pompadour-wiki
refs/heads/master
pompadour_wiki/pompadour_wiki/apps/wiki/tests.py
1
# -*- coding: utf-8 -*- from django.test import TestCase from django.test.client import Client from django.template.defaultfilters import slugify from django.contrib.auth.models import User from pompadour_wiki.apps.wiki.models import Wiki from pompadour_wiki.apps.tagging.models import Tag from pompadour_wiki.views ...
hyqneuron/pylearn2-maxsom
refs/heads/master
pylearn2/datasets/tests/test_zca_dataset.py
10
""" Tests for the ZCA_Dataset class. """ import numpy as np from pylearn2.datasets.preprocessing import ZCA from pylearn2.datasets.zca_dataset import ZCA_Dataset from pylearn2.testing.datasets import random_dense_design_matrix def test_zca_dataset(): """ Test that a ZCA dataset can be constructed without cr...
GitSomeCode/RecipeApp
refs/heads/master
Proj/chef/tests.py
24123
from django.test import TestCase # Create your tests here.
sriprasanna/django-1.3.1
refs/heads/master
tests/regressiontests/i18n/test_warnings.py
47
from os.path import join, normpath, abspath, dirname import warnings import django from django.conf import settings from django.test.utils import get_warnings_state, restore_warnings_state from django.utils.translation import _trans from django.utils.unittest import TestCase class DeprecationWarningTests(TestCase): ...
NL66278/OCB
refs/heads/8.0
addons/product/partner.py
385
# -*- 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...
Johanndutoit/PyCon2013AppEngineTutorial
refs/heads/master
lib/python2.7/site-packages/setuptools/__init__.py
55
"""Extensions to the 'distutils' for large or complex distributions""" from setuptools.extension import Extension, Library from setuptools.dist import Distribution, Feature, _get_unpatched import distutils.core, setuptools.command from setuptools.depends import Require from distutils.core import Command as _Command fro...
nlloyd/SubliminalCollaborator
refs/heads/master
libs/twisted/manhole/ui/gtk2manhole.py
37
# -*- test-case-name: twisted.manhole.ui.test.test_gtk2manhole -*- # Copyright (c) Twisted Matrix Laboratories. # See LICENSE for details. """ Manhole client with a GTK v2.x front-end. """ __version__ = '$Revision: 1.9 $'[11:-2] from twisted import copyright from twisted.internet import reactor from twisted.python i...
migueldvb/django-guardian
refs/heads/master
guardian/tests/conf_test.py
43
from __future__ import unicode_literals import mock from django.core.exceptions import ImproperlyConfigured from django.test import TestCase from guardian.conf import settings as guardian_settings class TestConfiguration(TestCase): def test_check_configuration(self): with mock.patch('guardian.conf.setti...
swharden/SWHLab
refs/heads/master
doc/uses/EPSCs-and-IPSCs/smooth histogram method/13.py
2
""" MOST OF THIS CODE IS NOT USED ITS COPY/PASTED AND LEFT HERE FOR CONVENIENCE """ import os import sys # in case our module isn't installed (running from this folder) if not os.path.abspath('../../../') in sys.path: sys.path.append('../../../') # helps spyder get docs import swhlab import swhlab.common as cm i...
BaconPancakes/valor
refs/heads/master
lib/aiohttp/server.py
17
"""simple HTTP server.""" import asyncio import http.server import socket import traceback import warnings from contextlib import suppress from html import escape as html_escape import aiohttp from aiohttp import errors, hdrs, helpers, streams from aiohttp.helpers import Timeout, _get_kwarg, ensure_future from aiohtt...
mbuij/ldns-cga-tsig
refs/heads/master
contrib/python/examples/ldns-zone.py
9
#!/usr/bin/python import ldns #Read zone from file zone = ldns.ldns_zone.new_frm_fp(open("zone.txt","r"), None, 0, ldns.LDNS_RR_CLASS_IN) print zone print "SOA:", zone.soa() for r in zone.rrs().rrs(): print "RR:", r zone = ldns.ldns_zone() #print zone
supersven/intellij-community
refs/heads/master
python/testData/MockSdk3.2/Lib/_abcoll.py
112
# Copyright 2007 Google, Inc. All Rights Reserved. # Licensed to PSF under a Contributor Agreement. """Abstract Base Classes (ABCs) for collections, according to PEP 3119. DON'T USE THIS MODULE DIRECTLY! The classes here should be imported via collections; they are defined here only to alleviate certain bootstrappin...
othelarian/arcns
refs/heads/master
arcstools/arcstools.py
1
# -*- coding: utf-8 -*- from panda3d.core import DirectionalLight, Spotlight, PerspectiveLens, Vec4 from direct.stdpy.file import * from direct.gui.DirectGui import DirectFrame, DGG import json class arcsTools: def __init__(self,app): self.app = app # # TODO : création des dictionnaires, ...
mferenca/HMS-ecommerce
refs/heads/HMSecommerce
ecommerce/coupons/views.py
1
from __future__ import unicode_literals import csv import logging from django.contrib.auth.decorators import login_required from django.core.exceptions import PermissionDenied from django.core.urlresolvers import reverse from django.http import Http404, HttpResponse, HttpResponseRedirect from django.utils.decorators ...
bigswitch/horizon
refs/heads/master
openstack_dashboard/api/nova.py
2
# Copyright 2012 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # All Rights Reserved. # # Copyright 2012 OpenStack Foundation # Copyright 2012 Nebula, Inc. # Copyright (c) 2012 X.commerce, a business unit of eBay Inc. # # Licensed under the Apach...
Cenditel/cenditel.comunidades.cynin
refs/heads/master
src/ubify.xmlrpc/setup.py
5
from setuptools import setup, find_packages import os version = '1.0' setup(name='ubify.xmlrpc', version=version, description="Provides an XMLRPC server object for consumption by client(s).", long_description=open("README.txt").read() + "\n" + open(os.path.join("docs", "HISTOR...
benschmaus/catapult
refs/heads/master
third_party/webapp2/webapp2_extras/__init__.py
67
# -*- coding: utf-8 -*- """ webapp2_extras ============== Extra modules for webapp2. :copyright: 2011 by tipfy.org. :license: Apache Sotware License, see LICENSE for details. """
ritchyteam/odoo
refs/heads/master
addons/l10n_ch/account_wizard.py
424
# -*- coding: utf-8 -*- ############################################################################## # # Author: Nicolas Bessi. Copyright Camptocamp SA # Financial contributors: Hasa SA, Open Net SA, # Prisme Solutions Informatique SA, Quod SA # # Translation contributors: brain-te...
cainiaocome/drench
refs/heads/master
drench/drench.py
2
"""Geo lookup provided courtesy of freegeoip.net""" import argparse import requests import socket import tparser import hashlib import reactor import peer import time import os import random import json from string import ascii_letters, digits from listener import Listener from switchboard import Switchboard VERSION ...
caseymm/django-ebola
refs/heads/master
liberia/migrations/0026_auto__del_summary.py
1
# -*- coding: utf-8 -*- from south.utils import datetime_utils as datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Deleting model 'Summary' db.delete_table(u'liberia_summary') def ...
FlorianLudwig/odoo
refs/heads/8.0
addons/portal_project_issue/__init__.py
493
# -*- 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...
sbuss/voteswap
refs/heads/master
lib/django/conf/locale/eu/formats.py
611
# -*- encoding: utf-8 -*- # This file is distributed under the same license as the Django package. # from __future__ import unicode_literals # The *_FORMAT strings use the Django date format syntax, # see http://docs.djangoproject.com/en/dev/ref/templates/builtins/#date DATE_FORMAT = r'Yeko M\re\n d\a' TIME_FORMAT = '...
bdelliott/wordgame
refs/heads/master
web/django/contrib/gis/geos/tests/test_mutable_list.py
94
# Copyright (c) 2008-2009 Aryeh Leib Taurog, http://www.aryehleib.com # All rights reserved. # # Modified from original contribution by Aryeh Leib Taurog, which was # released under the New BSD license. from django.contrib.gis.geos.mutable_list import ListMixin from django.utils import unittest class UserListA(ListMi...
jlspyaozhongkai/Uter
refs/heads/master
third_party_backup/Python-2.7.9/Lib/SimpleHTTPServer.py
29
"""Simple HTTP Server. This module builds on BaseHTTPServer by implementing the standard GET and HEAD requests in a fairly straightforward manner. """ __version__ = "0.6" __all__ = ["SimpleHTTPRequestHandler"] import os import posixpath import BaseHTTPServer import urllib import cgi import sys import shutil impor...
carolFrohlich/nipype
refs/heads/master
nipype/interfaces/mrtrix/tests/test_auto_MRTrixViewer.py
12
# AUTO-GENERATED by tools/checkspecs.py - DO NOT EDIT from ....testing import assert_equal from ..preprocess import MRTrixViewer def test_MRTrixViewer_inputs(): input_map = dict(args=dict(argstr='%s', ), debug=dict(argstr='-debug', position=1, ), environ=dict(nohash=True, usedefault=True, ...
erramuzpe/NeuroVault
refs/heads/master
neurovault/apps/statmaps/management/__init__.py
12133432
matthiasdiener/spack
refs/heads/develop
var/spack/repos/builtin/packages/gurobi/package.py
3
############################################################################## # Copyright (c) 2013-2018, Lawrence Livermore National Security, LLC. # Produced at the Lawrence Livermore National Laboratory. # # This file is part of Spack. # Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved. # LLNL-CODE-64...
hujiajie/chromium-crosswalk
refs/heads/master
build/android/gyp/java_cpp_enum_tests.py
20
#!/usr/bin/env python # Copyright 2014 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. """Tests for enum_preprocess.py. This test suite containss various tests for the C++ -> Java enum generator. """ import collections f...
pratikmallya/hue
refs/heads/master
desktop/core/ext-py/Django-1.6.10/tests/delete_regress/tests.py
51
from __future__ import absolute_import import datetime from django.conf import settings from django.db import transaction, DEFAULT_DB_ALIAS, models from django.db.utils import ConnectionHandler from django.test import TestCase, TransactionTestCase, skipUnlessDBFeature from .models import (Book, Award, AwardNote, Per...
markkolich/FrameworkBenchmarks
refs/heads/master
frameworks/Python/turbogears/models/World.py
79
from sqlalchemy.ext.declarative import declarative_base from sqlalchemy import Column from sqlalchemy.types import String, Integer Base = declarative_base() class World(Base): __tablename__ = "world" id = Column(Integer, primary_key = True) randomNumber = Column(Integer) def serialize(self): ...
Muxelmann/voltage-assessment
refs/heads/master
ntvv/python/cimConverter/CIMClass.py
1
import os import xml.etree.ElementTree as et import csv import re import math from cimConverter import logger class CIMClass: """CIMClass contains all functionality to convert CIM to OpenDSS""" _ele = list() _output_dir = None _equipment = dict() _dss_ele = dict() _ele_buffers = list() def __init__(self, ou...
PythonScientists/Shape
refs/heads/master
env/lib/python3.5/site-packages/pip/_vendor/webencodings/labels.py
512
""" webencodings.labels ~~~~~~~~~~~~~~~~~~~ Map encoding labels to their name. :copyright: Copyright 2012 by Simon Sapin :license: BSD, see LICENSE for details. """ # XXX Do not edit! # This file is automatically generated by mklabels.py LABELS = { 'unicode-1-1-utf-8': 'utf-8', 'utf-...
stresler/cattle
refs/heads/master
tests/integration/cattletest/core/test_resource_change.py
4
from threading import Thread from websocket import create_connection from common_fixtures import * # NOQA SUB_OPTIONS = '?include=hosts&include=instances&include=instanceLinks' \ '&include=ipAddresses&eventNames=resource.change' def stop_collection(collector): collector() def collect_events(cl...
sorenk/ansible
refs/heads/devel
lib/ansible/modules/storage/netapp/na_cdot_aggregate.py
72
#!/usr/bin/python # (c) 2017, NetApp, 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', 'status': ['preview'], ...
Spoken-tutorial/spoken-website
refs/heads/master
cron/spoken_search/whoosh/analysis/filters.py
1
# coding=utf-8 # Copyright 2007 Matt Chaput. 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 co...
wolverineav/neutron
refs/heads/master
neutron/agent/l2/extensions/qos.py
3
# Copyright (c) 2015 Mellanox Technologies, Ltd # 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 # # U...
MiLk/youtube-dl
refs/heads/master
test/test_playlists.py
1
#!/usr/bin/env python # encoding: utf-8 from __future__ import unicode_literals # Allow direct execution import os import sys import unittest sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__)))) from test.helper import ( expect_info_dict, FakeYDL, ) from youtube_dl.extractor impor...
bsmrstu-warriors/Moytri--The-Drone-Aider
refs/heads/master
LogAnalyzer/tests/TestThrust.py
261
from LogAnalyzer import Test,TestResult import DataflashLog class TestThrust(Test): '''test for sufficient thrust (copter only for now)''' def __init__(self): Test.__init__(self) self.name = "Thrust" def run(self, logdata, verbose): self.result = TestResult() self...
luc-demeyer/account-financial-tools
refs/heads/8.0
account_invoice_constraint_chronology/model/account_invoice.py
31
# -*- coding: utf-8 -*- # # # Authors: Adrien Peiffer # Copyright (c) 2014 Acsone SA/NV (http://www.acsone.eu) # All Rights Reserved # # WARNING: This program as such is intended to be used by professional # programmers who take the whole responsibility of assessing all potential # consequences result...
kitsunde/ansible
refs/heads/devel
test/integration/consul_running.py
106
''' Checks that the consul agent is running locally. ''' if __name__ == '__main__': try: import consul consul = consul.Consul(host='0.0.0.0', port=8500) consul.catalog.nodes() print "True" except: pass
lseyesl/phantomjs
refs/heads/master
src/qt/qtwebkit/Tools/Scripts/webkitpy/layout_tests/models/test_run_results.py
118
# Copyright (C) 2010 Google Inc. All rights reserved. # Copyright (C) 2010 Gabor Rapcsanyi (rgabor@inf.u-szeged.hu), University of Szeged # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of so...
edespino/gpdb
refs/heads/master
gpMgmt/bin/pythonSrc/subprocess32/testdata/input_reader.py
241
"""When called as a script, consumes the input""" import sys if __name__ == "__main__": for line in sys.stdin: pass
ychen820/microblog
refs/heads/master
y/google-cloud-sdk/.install/.backup/lib/googlecloudsdk/__init__.py
332
# Copyright 2013 Google Inc. All Rights Reserved. """Package marker file."""
cocoloco69/pynet
refs/heads/master
ANSIBLE/library/eos_vxlan_vlan.py
5
#!/usr/bin/python # # Copyright (c) 2015, Arista Networks, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # Redistributions of source code must retain the above copyright notice, # t...
lamontu/data-analysis
refs/heads/master
pandas/hierarchical_index_using_columns.py
1
# -*- coding: utf-8 -*- import numpy as np from pandas import DataFrame print("## create hierarchical index using columns") frame = DataFrame({'a': range(7), 'b': range(7, 0, -1), 'c': ['one', 'one', 'one', 'two', 'two', 'two', 'two'], 'd': [0, 1, 2, 0, 1, 2, 3...
ArianaGashi/Techstitution
refs/heads/master
venv/lib/python2.7/site-packages/flask/module.py
850
# -*- coding: utf-8 -*- """ flask.module ~~~~~~~~~~~~ Implements a class that represents module blueprints. :copyright: (c) 2011 by Armin Ronacher. :license: BSD, see LICENSE for more details. """ import os from .blueprints import Blueprint def blueprint_is_module(bp): """Used to figure ou...
psawaya/Mental-Ginger
refs/heads/master
django/contrib/localflavor/ar/forms.py
309
# -*- coding: utf-8 -*- """ AR-specific Form helpers. """ from django.forms import ValidationError from django.core.validators import EMPTY_VALUES from django.forms.fields import RegexField, CharField, Select from django.utils.encoding import smart_unicode from django.utils.translation import ugettext_lazy as _ class...
benjyw/pants
refs/heads/fix_docs_urls
src/python/pants/help/help_printer.py
3
# Copyright 2015 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). import dataclasses import difflib import json import textwrap from typing import Dict, cast from typing_extensions import Literal from pants.base.build_environment import pants_version f...
anhelus/emw-museum-output
refs/heads/master
visit/tests.py
24123
from django.test import TestCase # Create your tests here.
jeremiahyan/odoo
refs/heads/master
addons/sale_stock/models/res_users.py
1
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models, fields class Users(models.Model): _inherit = ['res.users'] property_warehouse_id = fields.Many2one('stock.warehouse', string='Default Warehouse', company_dependent=True, check_company=...