repo_name
stringlengths
5
100
ref
stringlengths
12
67
path
stringlengths
4
244
copies
stringlengths
1
8
content
stringlengths
0
1.05M
⌀
tempbottle/kosmosfs-1
refs/heads/master
scripts/kfssetup.py
13
#!/usr/bin/env python # # $Id: kfssetup.py 36 2007-11-12 02:43:36Z sriramsrao $ # # Copyright 2007 Kosmix Corp. # # This file is part of Kosmos File System (KFS). # # 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 cop...
agiovann/Constrained_NMF
refs/heads/master
use_cases/CaImAnpaper/compare_gt_cnmf_CNN.py
2
# -*- coding: utf-8 -*- """ Created on Fri Aug 25 14:49:36 2017 @author: agiovann """ from __future__ import division from __future__ import print_function from builtins import zip from builtins import str from builtins import map from builtins import range from past.utils import old_div import cv2 import pickle fro...
tuturto/breakfast
refs/heads/master
ui.py
1
# Copyright 2012 Tuukka Turto # # This file is part of breakfast, a behave demo. # # breakfast 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)...
Dino0631/RedRain-Bot
refs/heads/develop
cogs/lib/pip/_vendor/html5lib/filters/whitespace.py
353
from __future__ import absolute_import, division, unicode_literals import re from . import base from ..constants import rcdataElements, spaceCharacters spaceCharacters = "".join(spaceCharacters) SPACES_REGEX = re.compile("[%s]+" % spaceCharacters) class Filter(base.Filter): spacePreserveElements = frozenset([...
acenario/Payable
refs/heads/master
lib/python2.7/site-packages/django/db/migrations/operations/special.py
374
from __future__ import unicode_literals from django.db import router from .base import Operation class SeparateDatabaseAndState(Operation): """ Takes two lists of operations - ones that will be used for the database, and ones that will be used for the state change. This allows operations that don't ...
altanawealth/django-otp
refs/heads/master
django_otp/models.py
1
from __future__ import absolute_import, division, print_function, unicode_literals from django.conf import settings from django.core.exceptions import ObjectDoesNotExist from django.db import models from django.utils import six class DeviceManager(models.Manager): """ The :class:`~django.db.models.Manager` o...
AntoineCezar/flockcontext
refs/heads/master
flockcontext/__init__.py
1
# -*- coding: utf-8 -*- __author__ = 'Antoine Cezar' __email__ = 'antoine@cezar.fr' __version__ = '0.3.1' from .flock import Flock from .flock_open import FlockOpen __all__ = [ 'Flock', 'FlockOpen', ]
Kelfast/mamba-framework
refs/heads/master
mamba/test/dummy_app/__init__.py
3
# Application Package
jreinhardt/manual-labour
refs/heads/master
src/manuallabour/layouts/html_single/basic/__init__.py
1
# Manual labour - a library for step-by-step instructions # Copyright (C) 2014 Johannes Reinhardt <jreinhardt@ist-dein-freund.de> # # 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; eith...
CollabQ/CollabQ
refs/heads/master
.google_appengine/google/appengine/api/labs/__init__.py
1333
#!/usr/bin/env python # # Copyright 2007 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 o...
seanli9jan/tensorflow
refs/heads/master
tensorflow/contrib/distributions/python/ops/bijectors/cholesky_outer_product.py
18
# 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...
smmribeiro/intellij-community
refs/heads/master
python/testData/completion/reexportModules/a.after.py
166
import b b.da<caret>
Crystalnix/house-of-life-chromium
refs/heads/master
third_party/simplejson/encoder.py
62
""" Implementation of JSONEncoder """ import re try: from simplejson import _speedups except ImportError: _speedups = None ESCAPE = re.compile(r'[\x00-\x19\\"\b\f\n\r\t]') ESCAPE_ASCII = re.compile(r'([\\"/]|[^\ -~])') ESCAPE_DCT = { # escape all forward slashes to prevent </script> attack '/': '\\/', ...
AnhellO/DAS_Sistemas
refs/heads/development
Ago-Dic-2017/Enrique Castillo/Ordinario/test/Lib/site-packages/django/contrib/messages/apps.py
130
from django.apps import AppConfig from django.utils.translation import gettext_lazy as _ class MessagesConfig(AppConfig): name = 'django.contrib.messages' verbose_name = _("Messages")
tsrnnash/bg8-cdw11
refs/heads/master
users/a/g8/ag8_40323131_task1.py
9
# 各組分別在各自的 .py 程式中建立應用程式 (第1步/總共3步) from flask import Blueprint, render_template, make_response # 利用 Blueprint建立 ag1, 並且 url 前綴為 /ag1, 並設定 template 存放目錄 ag8_40323131 = Blueprint('ag8_40323131', __name__, url_prefix='/ag8_40323131', template_folder='templates') @ag8_40323131.route('/task1_31') def task1_31(): o...
nirzari18/Query-Analysis-Application-on-Google-App-Engine
refs/heads/master
lib/oauth2client/crypt.py
36
# -*- coding: utf-8 -*- # # Copyright 2014 Google Inc. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requ...
luogangyi/Ceilometer-oVirt
refs/heads/stable/juno
ceilometer/storage/sqlalchemy/migrate_repo/versions/009_event_strings.py
10
# # 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...
SUSE/azure-sdk-for-python
refs/heads/master
azure-mgmt-resource/azure/mgmt/resource/resources/v2016_09_01/models/plan.py
16
# 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 ...
houzhenggang/hiwifi-openwrt-HC5661-HC5761
refs/heads/master
scripts/dl_cleanup.py
131
#!/usr/bin/env python """ # OpenWRT download directory cleanup utility. # Delete all but the very last version of the program tarballs. # # Copyright (c) 2010 Michael Buesch <mb@bu3sch.de> """ import sys import os import re import getopt # Commandline options opt_dryrun = False def parseVer_1234(match, filepath): ...
austinharris/gem5-riscv
refs/heads/master
src/arch/x86/X86NativeTrace.py
42
# Copyright (c) 2009 The Regents of The University of Michigan # 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, this list ...
JetBrains/intellij-community
refs/heads/master
python/testData/completion/superInitKwParamsNoCompletion.after.py
83
class A: def __init__(self, first=True, second=False): pass class B(A): def __init__(self, **kwargs): A.__init__(self, first=False) b = B(fir)
kcwu/2048-python
refs/heads/master
ai_modules/kcwu_short2.py
1
# Copyright 2014 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. from multiprocessing import * import sys range4 = range(4) job_table = {} def rotateRight(grid): return [[grid[r][3-c] for r in range4] for c in range4] def move_...
Health123/ansible
refs/heads/devel
v1/tests/TestModuleUtilsDatabase.py
325
import collections import mock import os import re from nose.tools import eq_ try: from nose.tools import assert_raises_regexp except ImportError: # Python < 2.7 def assert_raises_regexp(expected, regexp, callable, *a, **kw): try: callable(*a, **kw) except expected as e: ...
adamcharnock/swiftwind
refs/heads/master
swiftwind/costs/exceptions.py
2
class CannotEnactUnenactableRecurringCostError(Exception): pass class CannotRecreateTransactionOnRecurredCost(Exception): pass class NoSplitsFoundForRecurringCost(Exception): pass class ProvidedBillingCycleBeginsBeforeInitialBillingCycle(Exception): pass class RecurringCostAlreadyEnactedForBillingCycle(Except...
ElitosGon/medgoproject
refs/heads/master
medgointranet/signals/doctor_signal.py
1
from django.contrib.auth.models import User from django.db.models.signals import post_save, pre_save from django.dispatch import receiver from medgointranet import models @receiver(pre_save, sender=models.Doctor) def model_pre_save_doctor(sender, instance, **kwargs): # Doctor # Es activo if instance.id: old_doc...
Kazade/NeHe-Website
refs/heads/master
google_appengine/lib/django-1.2/django/db/backends/creation.py
44
import sys import time from django.conf import settings from django.core.management import call_command # The prefix to put on the default database name when creating # the test database. TEST_DATABASE_PREFIX = 'test_' class BaseDatabaseCreation(object): """ This class encapsulates all backend-specific diffe...
PlayCircular/play_circular
refs/heads/master
apps/actividades/forms.py
1
# coding=utf-8 # Copyright (C) 2014 by Víctor Romero Blanco <info at playcircular dot com>. # http://playcircular.com/ # It's licensed under the AFFERO GENERAL PUBLIC LICENSE unless stated otherwise. # You can get copies of the licenses here: http://www.affero.org/oagpl.html # AFFERO GENERAL PUBLIC LICENSE is also in...
duralog/repo
refs/heads/master
color.py
36
# # Copyright (C) 2008 The Android Open Source Project # # 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 la...
pools/JaikuEngine
refs/heads/master
common/properties.py
34
#!/usr/bin/python2.4 # Copyright 2009 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 a...
chambers-brian/SIG_Digital-Strategy_SI_ODP_Backend
refs/heads/master
tests/unit/dataactvalidator/test_a32_appropriations.py
1
from dataactcore.models.stagingModels import Appropriation from tests.unit.dataactvalidator.utils import number_of_errors, query_columns _FILE = 'a32_appropriations' _TAS = 'a32_appropriations_tas' def test_column_headers(database): expected_subset = {'row_number', 'allocation_transfer_agency', 'agency_identifi...
gregdek/ansible
refs/heads/devel
lib/ansible/modules/cloud/openstack/os_ironic_inspect.py
31
#!/usr/bin/python # coding: utf-8 -*- # (c) 2015-2016, Hewlett Packard Enterprise Development Company LP # 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_ve...
ayushagrawal288/zamboni
refs/heads/master
mkt/websites/indexers.py
8
import re from operator import attrgetter from urlparse import urlparse from mkt.search.indexers import BaseIndexer from mkt.tags.models import attach_tags from mkt.translations.models import attach_trans_dict URL_RE = re.compile( r'^www\.|^m\.|^mobile\.|' # Remove common subdomains. r'\.com$|\.net$|\.org$|...
TNT-Samuel/Coding-Projects
refs/heads/master
DNS Server/Source - Copy/Lib/importlib/_bootstrap_external.py
14
"""Core implementation of path-based import. This module is NOT meant to be directly imported! It has been designed such that it can be bootstrapped into Python as the implementation of import. As such it requires the injection of specific modules and attributes in order to work. One should use importlib as the public...
lukassup/route-ctl
refs/heads/master
tests/test_cli.py
1
# -*- coding: utf-8 -*- from __future__ import ( absolute_import, print_function, unicode_literals, with_statement, ) import contextlib import os import shlex import sys import unittest from route_ctl import cli try: from io import StringIO except ImportError: # NOTE: PY2 compat from cSt...
ivandavid77/learnetic_monitoreo_mcourserpro
refs/heads/master
apps/learnetic_monitoreo_mcourserpro/priv/utils/obtener_datos_dgespe_accesos.py
1
# -*- coding: utf-8 -*- import sys import csv import datetime import yaml import pymysql.cursors def get_config(): with open('../config/database.yaml') as f: return yaml.load(f.read()) def get_connection(config): db = config['db'] return pymysql.connect(db=db['name'], us...
40223205/w16b_test-
refs/heads/master
static/Brython3.1.3-20150514-095342/Lib/test/__init__.py
2547
# Dummy file to make this directory a package.
SpectraLogic/samba
refs/heads/master
buildtools/wafsamba/hpuxcc.py
67
# compiler definition for HPUX # based on suncc.py from waf import os, optparse, sys import Utils, Options, Configure import ccroot, ar from Configure import conftest import gcc @conftest def gcc_modifier_hpux(conf): v=conf.env v['CCFLAGS_DEBUG']=['-g'] v['CCFLAGS_RELEASE']=['-O2'] v['CC_SRC_F']='' ...
IV-GII/Ingenia
refs/heads/master
Versiones antiguas/proyecto_con_template/pedidos/models.py
2
from django.db import models # Create your models here. class Usuarios (models.Model): nombre = models.CharField (max_length=100) correo_electronico = models.CharField (max_length=300) password = models.CharField (max_length=30) rol = models.CharField (max_length=30) def __unicode__(self): return self.nombre...
DanteOnline/free-art
refs/heads/master
venv/lib/python3.4/site-packages/django/contrib/messages/api.py
512
from django.contrib.messages import constants from django.contrib.messages.storage import default_storage from django.http import HttpRequest __all__ = ( 'add_message', 'get_messages', 'get_level', 'set_level', 'debug', 'info', 'success', 'warning', 'error', 'MessageFailure', ) class MessageFailure(E...
codermoji-contrib/python
refs/heads/master
start/Intro to Dicts/001/mkfs.py
18
# Things that are available: # U # fs
tectronics/photivo
refs/heads/master
scons-local-2.2.0/SCons/Tool/midl.py
14
"""SCons.Tool.midl Tool-specific initialization for midl (Microsoft IDL compiler). There normally shouldn't be any need to import this module directly. It will usually be imported through the generic SCons.Tool.Tool() selection method. """ # # Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010...
rvalyi/geraldo
refs/heads/master
site/newsite/django_1_0/tests/regressiontests/requests/__init__.py
272
""" Tests for Django's various Request objects. """
bhansa/fireball
refs/heads/master
pyvenv/Lib/site-packages/pygame/tests/test_utils/endian.py
21
# Module pygame.tests.test_utils.endian # # Machine independent conversion to little-endian and big-endian Python # integer values. import struct def little_endian_uint32(i): """Return the 32 bit unsigned integer little-endian representation of i""" s = struct.pack('<I', i) return struct.unpack('=I', s)[...
Tjorriemorrie/trading
refs/heads/master
09_scalping/s-takeprofit.py
1
import matplotlib.pyplot as plt import numpy as np import pandas as pd from sklearn import linear_model from features import calculateTargets from simulate import backtest from pprint import pprint currency = 'EURUSD' interval = '60' factor = 10000 df = pd.read_csv( r'../data/' + currency.upper() + interval + '.c...
vizual54/MissionPlanner
refs/heads/master
Lib/distutils/command/build_py.py
54
"""distutils.command.build_py Implements the Distutils 'build_py' command.""" __revision__ = "$Id$" import os import sys from glob import glob from distutils.core import Command from distutils.errors import DistutilsOptionError, DistutilsFileError from distutils.util import convert_path from distutils ...
Asnelchristian/coala
refs/heads/master
coalib/output/Interactions.py
6
def fail_acquire_settings(log_printer, settings_names_dict, section): """ This method throws an exception if any setting needs to be acquired. :param log_printer: Printer responsible for logging the messages. :param settings: A dictionary with the settings name as key and ...
katstalk/android_external_chromium_org
refs/heads/kk44
chrome/browser/extensions/PRESUBMIT_test.py
58
#!/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. import difflib import os import re import unittest import PRESUBMIT class MockLogging(object): def __init__(self): self.lin...
jjneely/current
refs/heads/master
cwebapp/cwebapp/controllers.py
1
import xmlrpclib import turbogears import auth import cherrypy.config from turbogears import controllers class SubDir(object): def __init__(self, api): self._api = api class Policy(SubDir): @turbogears.expose(html="cwebapp.templates.policy") @auth.needsLogin def index(self, userInfo): ...
smmribeiro/intellij-community
refs/heads/master
python/testData/psi/FStringBackslashBeforeExpression.py
15
s = f'foo{\ 42}bar'
yaph/z3lstore
refs/heads/master
store_tests.py
1
# -*- coding: utf-8 -*- """ Store Tests ~~~~~~~~~~~~ Tests the store application. """ import os import store import unittest class StoreTestCase(unittest.TestCase): """Test cases for the store application.""" def setUp(self): store.app.config['TESTING'] = True self.app = store.ap...
nemesisdesign/django
refs/heads/master
tests/middleware_exceptions/tests.py
24
from django.conf import settings from django.core.exceptions import MiddlewareNotUsed from django.test import RequestFactory, SimpleTestCase, override_settings from django.test.utils import patch_logger from . import middleware as mw @override_settings(ROOT_URLCONF='middleware_exceptions.urls') class MiddlewareTests...
bigswitch/horizon
refs/heads/master
openstack_dashboard/dashboards/admin/networks/subnets/tables.py
61
# Copyright 2012 NEC Corporation # # 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 ag...
ndebuhr/thermo-state-solver
refs/heads/master
thermo-env/lib/python3.5/site-packages/pip/_vendor/distlib/scripts.py
333
# -*- coding: utf-8 -*- # # Copyright (C) 2013-2015 Vinay Sajip. # Licensed to the Python Software Foundation under a contributor agreement. # See LICENSE.txt and CONTRIBUTORS.txt. # from io import BytesIO import logging import os import re import struct import sys from .compat import sysconfig, detect_encoding, ZipFi...
vipul-sharma20/oh-mainline
refs/heads/master
vendor/packages/django-tastypie/tastypie/admin.py
57
from __future__ import unicode_literals from django.conf import settings from django.contrib import admin if 'django.contrib.auth' in settings.INSTALLED_APPS: from tastypie.models import ApiKey class ApiKeyInline(admin.StackedInline): model = ApiKey extra = 0 ABSTRACT_APIKEY = getattr(se...
petrus-v/odoo
refs/heads/8.0
addons/base_import/__openerp__.py
317
{ 'name': 'Base import', 'description': """ New extensible file import for OpenERP ====================================== Re-implement openerp's file import system: * Server side, the previous system forces most of the logic into the client which duplicates the effort (between clients), makes the import s...
akash1808/nova_test_latest
refs/heads/master
nova/tests/unit/virt/libvirt/volume/test_remotefs.py
6
# Copyright 2014 Cloudbase Solutions Srl # 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 r...
daniestevez/gr-satellites
refs/heads/master
python/ccsds/telemetry_parser.py
1
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # Copyright 2019 Athanasios Theocharis <athatheoc@gmail.com> # This was made under ESA Summer of Code in Space 2019 # by Athanasios Theocharis, mentored by Daniel Estevez # # This file is part of gr-satellites # # SPDX-License-Identifier: GPL-3.0-or-later # import numpy ...
analogdevicesinc/gnuradio
refs/heads/master
grc/gui/FlowGraph.py
5
""" Copyright 2007-2011 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 option) any l...
aerwin3/swift
refs/heads/master
test/unit/common/test_exceptions.py
51
# Copyright (c) 2010-2012 OpenStack Foundation # # 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 agree...
bxlab/HiFive_Paper
refs/heads/master
Scripts/HiCLib/mirnylab-hiclib-460c3fbc0f72/build/lib/hiclib/fragmentHiC.py
2
# (c) 2012 Massachusetts Institute of Technology. All Rights Reserved # Code written by: Maksim Imakaev (imakaev@mit.edu) """ This is a module class for fragment-level Hi-C data analysis. The base class "HiCdataset" can load, save and merge Hi-C datasets, perform certain filters, and save binned heatmaps. Additional c...
yzl0083/orange
refs/heads/master
Orange/tuning/__init__.py
6
import Orange.core import Orange.classification import Orange.evaluation.scoring import Orange.evaluation.testing import Orange.misc from Orange.utils import deprecated_class_attribute, deprecated_keywords, \ deprecated_members @deprecated_members({"returnWhat": "return_what", "object": "lea...
carlohamalainen/nipype
refs/heads/master
nipype/workflows/__init__.py
156
# emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*- # vi: set ft=python sts=4 ts=4 sw=4 et:
uberamd/NGECore2
refs/heads/master
scripts/object/tangible/collection/col_ent_instrument_01.py
85615
import sys def setup(core, object): return
uberamd/NGECore2
refs/heads/master
scripts/object/tangible/crafting/station/armor_repair.py
85615
import sys def setup(core, object): return
agry/NGECore2
refs/heads/master
scripts/object/tangible/quest/quest_start/profession_bounty_hunter_30.py
85615
import sys def setup(core, object): return
mlperf/training_results_v0.7
refs/heads/master
Fujitsu/benchmarks/resnet/implementations/implementation_open/mxnet/3rdparty/tvm/python/tvm/relay/module.py
1
# 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...
ftCommunity/ftcommunity-apps
refs/heads/master
packages/ftDuinIO/ftduinio.py
1
#! /usr/bin/env python3 # -*- coding: utf-8 -*- # import sys, time, serial import ftduino_direct as ftd from PyQt4 import QtCore from TouchStyle import * from TouchAuxiliary import * from PyQt4.QtCore import QTimer import queue, pty, subprocess, select, os import urllib.request, urllib.parse, urllib.error import avrdud...
jeffkistler/django-request-utils
refs/heads/master
docs/conf.py
1
# -*- coding: utf-8 -*- # # Django Request Utils documentation build configuration file, created by # sphinx-quickstart on Mon Nov 15 20:58:37 2010. # # This file is execfile()d with the current directory set to its containing dir. # # Note that not all possible configuration values are present in this # autogenerated ...
PhiInnovations/mdp28-linux-bsp
refs/heads/master
meta/lib/oe/qa.py
2
class ELFFile: EI_NIDENT = 16 EI_CLASS = 4 EI_DATA = 5 EI_VERSION = 6 EI_OSABI = 7 EI_ABIVERSION = 8 # possible values for EI_CLASS ELFCLASSNONE = 0 ELFCLASS32 = 1 ELFCLASS64 = 2 # possible value for EI_VERSION EV_CURRENT = 1 # possible va...
chdecultot/erpnext
refs/heads/develop
erpnext/patches/v5_4/notify_system_managers_regarding_wrong_tax_calculation.py
30
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors # License: GNU General Public License v3. See license.txt from __future__ import print_function, unicode_literals import frappe from frappe.email import sendmail_to_system_managers from frappe.utils import get_link_to_form def execute(): wrong_r...
saintdragon2/python-3-lecture-2015
refs/heads/master
civil_mid_mid/pymunk-4.0.0/tests/test_space.py
1
import pymunk as p from pymunk import * from pymunk.vec2d import Vec2d import unittest #################################################################### class UnitTestSpace(unittest.TestCase): def setUp(self): p.reset_shapeid_counter() self.s = p.Space() self.b1, self.b2 ...
felixrieseberg/lets-encrypt-preview
refs/heads/iis
letsencrypt/tests/continuity_auth_test.py
1
"""Test the ContinuityAuthenticator dispatcher.""" import unittest import mock from acme import challenges from letsencrypt import achallenges from letsencrypt import errors class PerformTest(unittest.TestCase): """Test client perform function.""" def setUp(self): from letsencrypt.continuity_auth ...
KamranMackey/CloudBot
refs/heads/gonzobot
plugins/minecraft_ping.py
4
import socket from mcstatus import MinecraftServer from cloudbot import hook mc_colors = [('\xa7f', '\x0300'), ('\xa70', '\x0301'), ('\xa71', '\x0302'), ('\xa72', '\x0303'), ('\xa7c', '\x0304'), ('\xa74', '\x0305'), ('\xa75', '\x0306'), ('\xa76', '\x0307'), ('\xa7e', '\x0308'), ('\xa7a', '\...
matthaywardwebdesign/rethinkdb
refs/heads/next
external/v8_3.30.33.16/test/mozilla/testcfg.py
73
# Copyright 2008 the V8 project authors. 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, this list of conditi...
roadmapper/ansible
refs/heads/devel
lib/ansible/modules/network/exos/exos_vlans.py
13
#!/usr/bin/python # -*- coding: utf-8 -*- # Copyright 2019 Red Hat # GNU General Public License v3.0+ # (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) ############################################# # WARNING # ############################################# # # This file is au...
Betaboxguugi/P6
refs/heads/master
code/test/manual_vs_framework/tests/test_fd.py
1
import os from test.manual_vs_framework import framework_fd_test from test.manual_vs_framework.dw import setup __author__ = 'Arash Michael Sami Kjær' __maintainer__ = 'Arash Michael Sami Kjær' number = 100 dbname = 'fd.db' if not os.path.isfile('./'+dbname): setup(dbname, number) framework_fd_test(dbname)
djnugent/ardupilot-solo
refs/heads/master
Tools/LogAnalyzer/tests/TestDupeLogData.py
273
from LogAnalyzer import Test,TestResult import DataflashLog class TestDupeLogData(Test): '''test for duplicated data in log, which has been happening on PX4/Pixhawk''' def __init__(self): Test.__init__(self) self.name = "Dupe Log Data" def __matchSample(self, sample, sampleStartIndex, logdata): '''return...
dongguangming/django-angular
refs/heads/master
djangular/styling/__init__.py
14224
# -*- coding: utf-8 -*-
18praveenb/toil-rnaseq-sc
refs/heads/master
src/toil_rnaseq_sc/rnaseq_sc_cgl_plot_functions.py
1
#!/usr/bin/env python2.7 # This is a modified version of a source file from the repository "scRNA-Seq-tcc-prep" by the Pachter Lab which can be found here: https://github.com/pachterlab/scRNA-Seq-TCC-prep/blob/201469940e138c2f09bcd058a6291b17794f7c88/notebooks/10xResults.ipynb # The citation for the paper with which t...
NewBeeStudio/xichao-new
refs/heads/master
xichao/packages/route/special.py
1
# -*- coding: utf-8 -*- from imports import * ################################## 专栏页面 ################################## # 专栏列表页 @app.route('/special_all', methods=['GET']) def special_all(): try: view = request.args.get('view') sort = request.args.get('sort') page_id = int(request.args.g...
GaryKriebel/osf.io
refs/heads/develop
website/profile/utils.py
12
# -*- coding: utf-8 -*- import framework from website.util.permissions import reduce_permissions from website.filters import gravatar from website import settings from modularodm import Q def get_projects(user): '''Return a list of user's projects, excluding registrations and folders.''' return list(user.node...
yencarnacion/jaikuengine
refs/heads/master
.google_appengine/lib/django-1.3/tests/modeltests/m2m_intermediary/tests.py
92
from datetime import datetime from django.test import TestCase from models import Reporter, Article, Writer class M2MIntermediaryTests(TestCase): def test_intermeiary(self): r1 = Reporter.objects.create(first_name="John", last_name="Smith") r2 = Reporter.objects.create(first_name="Jane", last_na...
awemulya/fieldsight-kobocat
refs/heads/master
onadata/apps/viewer/south_migrations/0010_auto__add_field_export_filepath.py
13
# encoding: 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): # Adding field 'Export.filepath' db.add_column('odk_viewer_export', 'filepath', self.gf('django.db.models....
dsajkl/123
refs/heads/master
cms/djangoapps/contentstore/views/xblock.py
64
""" Views dedicated to rendering xblocks. """ from __future__ import absolute_import import logging import mimetypes from xblock.core import XBlock from django.conf import settings from django.http import Http404, HttpResponse log = logging.getLogger(__name__) def xblock_resource(request, block_type, uri): # py...
jugonzalez/topology_lib_scapy
refs/heads/master
lib/topology_lib_scapy/library.py
1
# -*- coding: utf-8 -*- # # Copyright (C) 2016 Hewlett Packard Enterprise Development LP # # 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...
megaumi/django
refs/heads/master
tests/contenttypes_tests/tests.py
81
# -*- coding: utf-8 -*- from __future__ import unicode_literals import datetime from django.apps.registry import Apps, apps from django.contrib.contenttypes import management from django.contrib.contenttypes.fields import ( GenericForeignKey, GenericRelation, ) from django.contrib.contenttypes.models import Conte...
biln/airflow
refs/heads/master
airflow/contrib/hooks/fs_hook.py
63
# -*- coding: utf-8 -*- # # 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 ...
dunn/gammu
refs/heads/master
tests/gen_sms_tests.py
1
#!/usr/bin/env python # -*- coding: UTF-8 -*- # vim: expandtab sw=4 ts=4 sts=4: ''' Gammu SMS backup generator. ''' __author__ = 'Michal Čihař' __email__ = 'michal@cihar.com' __license__ = ''' Copyright © 2003 - 2015 Michal Čihař This program is free software; you can redistribute it and/or modify it under the terms o...
jcftang/ansible
refs/heads/devel
lib/ansible/modules/cloud/amazon/rds.py
4
#!/usr/bin/python # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # Ansible is distributed...
xstaticxgpx/pylw
refs/heads/master
pylw/response.py
2
#!/usr/bin/env python # Copyright 2015 Michael Gugino # # 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...
IBM-Security/ibmsecurity
refs/heads/master
ibmsecurity/isam/base/network/felb/services/servers.py
1
import ibmsecurity.utilities.tools import logging from ibmsecurity.utilities import tools logger = logging.getLogger(__name__) module_uri = "/isam/felb/configuration/services" requires_modules = None requires_version = None requires_model = "Appliance" def add(isamAppliance, service_name, address, active, port, we...
yjxtogo/horizon
refs/heads/master
openstack_dashboard/test/helpers.py
19
# Copyright 2012 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # All Rights Reserved. # # Copyright 2012 Nebula, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the...
zacko-belsch/pazookle
refs/heads/master
tests/self_test.py
1
#!/usr/bin/env python # see http://docs.python.org/2/library/unittest.html # or http://docs.python.org/2/library/test.html import unittest from StringIO import StringIO from pazookle.ugen import UGen,Mixer,Pan from pazookle.generate import Periodic class TestUGen(unittest.TestCase): def setUp(self): ...
boghison/servo
refs/heads/master
tests/wpt/css-tests/tools/html5lib/html5lib/treewalkers/etree.py
658
from __future__ import absolute_import, division, unicode_literals try: from collections import OrderedDict except ImportError: try: from ordereddict import OrderedDict except ImportError: OrderedDict = dict import gettext _ = gettext.gettext import re from six import text_type from . im...
TRESCLOUD/odoo
refs/heads/Integracion&ControlDeCalidad
openerp/addons/base/ir/ir_sequence.py
15
# -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-TODAY OpenERP S.A. <http://www.openerp.com> # # This program is free software: you can redistribute it and/or modify # it under the terms o...
Sing-Li/go-buildpack
refs/heads/master
builds/runtimes/python-2.7.6/lib/python2.7/test/test_univnewlines2k.py
137
# Tests universal newline support for both reading and parsing files. import unittest import os import sys from test import test_support if not hasattr(sys.stdin, 'newlines'): raise unittest.SkipTest, \ "This Python does not have universal newline support" FATX = 'x' * (2**14) DATA_TEMPLATE = [ "line...
googlearchive/pywebsocket
refs/heads/master
test/set_sys_path.py
496
# Copyright 2009, Google 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, this list of conditions and the f...
smourph/PGo-TrainerTools
refs/heads/master
pgoapi/protos/POGOProtos/Networking/Requests/Messages/DiskEncounterMessage_pb2.py
16
# Generated by the protocol buffer compiler. DO NOT EDIT! # source: POGOProtos/Networking/Requests/Messages/DiskEncounterMessage.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _mes...
khalibartan/Antidote-DM
refs/heads/master
Antidotes DM/youtube_dl/extractor/howstuffworks.py
106
from __future__ import unicode_literals from .common import InfoExtractor from ..utils import ( find_xpath_attr, int_or_none, js_to_json, unescapeHTML, ) class HowStuffWorksIE(InfoExtractor): _VALID_URL = r'https?://[\da-z-]+\.howstuffworks\.com/(?:[^/]+/)*(?:\d+-)?(?P<id>.+?)-video\.htm' _TE...
WillisXChen/django-oscar
refs/heads/master
oscar/lib/python2.7/site-packages/requests/packages/chardet/euckrprober.py
2930
######################## BEGIN LICENSE BLOCK ######################## # The Original Code is mozilla.org 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 Reserved. # # Con...