repo_name
stringlengths
5
100
ref
stringlengths
12
67
path
stringlengths
4
244
copies
stringlengths
1
8
content
stringlengths
0
1.05M
davy39/eric
refs/heads/master
eric6_tray.py
1
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # Copyright (c) 2006 - 2014 Detlev Offenbach <detlev@die-offenbachs.de> # """ Eric6 Tray. This is the main Python script that performs the necessary initialization of the system-tray application. This acts as a quickstarter by providing a context menu to start the eric6...
prakritish/ansible
refs/heads/devel
lib/ansible/plugins/lookup/shelvefile.py
89
# (c) 2015, Alejandro Guirao <lekumberri@gmail.com> # # 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...
DebrahR/lab4
refs/heads/master
server/lib/flask/exthook.py
783
# -*- coding: utf-8 -*- """ flask.exthook ~~~~~~~~~~~~~ Redirect imports for extensions. This module basically makes it possible for us to transition from flaskext.foo to flask_foo without having to force all extensions to upgrade at the same time. When a user does ``from flask.ext.foo import...
mdblv2/joatu-django
refs/heads/master
application/site-packages/django/contrib/webdesign/lorem_ipsum.py
230
""" Utility functions for generating "lorem ipsum" Latin text. """ from __future__ import unicode_literals import random COMMON_P = 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco ...
mixman/djangodev
refs/heads/master
tests/regressiontests/select_related_onetoone/__init__.py
12133432
EnTeQuAk/django-filer
refs/heads/develop
filer/fields/__init__.py
12133432
likelyzhao/mxnet
refs/heads/dev-faster-rcnn
example/stochastic-depth/sd_mnist.py
15
################################################################################ # A sanity check mainly for debugging purpose. See sd_cifar10.py for a non-trivial # example of stochastic depth on cifar10. ################################################################################ import os import sys import mxne...
robweber/maraschino
refs/heads/master
lib/jinja2/_markupsafe/_constants.py
1535
# -*- coding: utf-8 -*- """ markupsafe._constants ~~~~~~~~~~~~~~~~~~~~~ Highlevel implementation of the Markup string. :copyright: (c) 2010 by Armin Ronacher. :license: BSD, see LICENSE for more details. """ HTML_ENTITIES = { 'AElig': 198, 'Aacute': 193, 'Acirc': 194, 'Agrave': 1...
Hellowlol/plexpy
refs/heads/master
lib/unidecode/x082.py
252
data = ( 'Yao ', # 0x00 'Yu ', # 0x01 'Chong ', # 0x02 'Xi ', # 0x03 'Xi ', # 0x04 'Jiu ', # 0x05 'Yu ', # 0x06 'Yu ', # 0x07 'Xing ', # 0x08 'Ju ', # 0x09 'Jiu ', # 0x0a 'Xin ', # 0x0b 'She ', # 0x0c 'She ', # 0x0d 'Yadoru ', # 0x0e 'Jiu ', # 0x0f 'Shi ', # 0x10 'Tan ...
bigzz/autotest
refs/heads/master
server/profiler.py
4
import itertools try: import autotest.common as common except ImportError: import common def _get_unpassable_types(arg): """ Given an argument, returns a set of types contained in arg that are unpassable. If arg is an atomic type (e.g. int) it either returns an empty set (if the type is passable) ...
gaddman/ansible
refs/heads/devel
test/units/modules/network/slxos/test_slxos_facts.py
30
# # (c) 2018 Extreme Networks Inc. # # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # Ans...
TwilioDevEd/api-snippets
refs/heads/master
ip-messaging/rest/users/update-user/update-user.6.x.py
1
# Download the Python helper library from twilio.com/docs/python/install import os from twilio.rest import Client # Your Account Sid and Auth Token from twilio.com/user/account # To set up environmental variables, see http://twil.io/secure account = os.environ['TWILIO_ACCOUNT_SID'] token = os.environ['TWILIO_AUTH_TOKE...
codesnake/xbmc
refs/heads/master
lib/gtest/test/gtest_filter_unittest.py
2826
#!/usr/bin/env python # # Copyright 2005 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...
Ernesto99/odoo
refs/heads/8.0
addons/account_asset/account_asset_invoice.py
141
# -*- encoding: 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 G...
nens/cassandralib
refs/heads/master
setup.py
1
from setuptools import setup version = '0.7.dev0' long_description = '\n\n'.join([ open('README.rst').read(), open('CREDITS.rst').read(), open('CHANGES.rst').read(), ]) install_requires = [ 'numpy', 'pandas', 'pycassa', 'pytz', 'setuptools', ], tests_require = [ ] setup(...
q1ang/scikit-learn
refs/heads/master
examples/datasets/plot_iris_dataset.py
283
#!/usr/bin/python # -*- coding: utf-8 -*- """ ========================================================= The Iris Dataset ========================================================= This data sets consists of 3 different types of irises' (Setosa, Versicolour, and Virginica) petal and sepal length, stored in a 150x4 numpy...
erkrishna9/odoo
refs/heads/master
addons/account/wizard/account_report_central_journal.py
378
# -*- 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...
shingonoide/odoo
refs/heads/deverp_8.0
openerp/addons/test_impex/tests/test_export.py
211
# -*- coding: utf-8 -*- import itertools import openerp.modules.registry import openerp from openerp.tests import common class CreatorCase(common.TransactionCase): model_name = False def __init__(self, *args, **kwargs): super(CreatorCase, self).__init__(*args, **kwargs) self.model = None ...
tmerrick1/spack
refs/heads/develop
lib/spack/spack/paths.py
4
############################################################################## # 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...
Beauhurst/django
refs/heads/master
django/contrib/sessions/backends/cache.py
113
from django.conf import settings from django.contrib.sessions.backends.base import ( CreateError, SessionBase, UpdateError, ) from django.core.cache import caches KEY_PREFIX = "django.contrib.sessions.cache" class SessionStore(SessionBase): """ A cache-based session store. """ cache_key_prefix = ...
dkim-95112/infosys
refs/heads/master
node_modules/node-gyp/gyp/pylib/gyp/input.py
713
# Copyright (c) 2012 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. from compiler.ast import Const from compiler.ast import Dict from compiler.ast import Discard from compiler.ast import List from compiler.ast import Module from co...
TomasM/django-denorm
refs/heads/master
denorm/db/sqlite3/triggers.py
7
from django.db import transaction from denorm.db import base import logging logger = logging.getLogger('denorm-sqlite') class RandomBigInt(base.RandomBigInt): def sql(self): return 'RANDOM()' class TriggerNestedSelect(base.TriggerNestedSelect): def sql(self): columns = self.columns ...
Guts/isogeo-api-py-minsdk
refs/heads/master
isogeo_pysdk/exceptions.py
1
# -*- coding: UTF-8 -*- #! python3 """ Isogeo Python SDK - Custom exceptions See: https://docs.python.org/fr/3/tutorial/errors.html#user-defined-exceptions """ # ############################################################################# # ########## Libraries ############# # ##############################...
MicroPyramid/Django-CRM
refs/heads/master
opportunity/api_urls.py
1
from django.urls import path from opportunity import api_views app_name = "api_opportunities" urlpatterns = [ path("", api_views.OpportunityListView.as_view()), path("<int:pk>/", api_views.OpportunityDetailView.as_view()), path("comment/<int:pk>/", api_views.OpportunityCommentView.as_view()), path("at...
Ali-aqrabawi/ezclinic
refs/heads/master
appengine_config.py
1
# Copyright 2015 Google Inc. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or a...
magicmonty/qmk_firmware
refs/heads/master
util/atmega32a_program.py
29
#!/usr/bin/env python # Copyright 2017 Luiz Ribeiro <luizribeiro@gmail.com>, Sebastian Kaim <sebb@sebb767.de> # # 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, o...
flavour/cedarbluff
refs/heads/master
modules/ClimateDataPortal/import_tabbed_readings.py
53
#!/usr/bin/python # this will be used for aggregating data. def get_or_create(dict, key, creator): try: value = dict[key] except KeyError: value = dict[key] = creator() return value #from import_NetCDF_readings import InsertChunksWithoutCheckingForExistingReadings import sys class Reading...
saideepchandg/oracle-r12-accounting
refs/heads/master
lib/django/core/management/__init__.py
10
from __future__ import unicode_literals import collections from importlib import import_module import os import pkgutil import sys import django from django.apps import apps from django.conf import settings from django.core.exceptions import ImproperlyConfigured from django.core.management.base import (BaseCommand, C...
algorithm-ninja/cmsocial
refs/heads/master
cmsocial/db/base.py
2
#-*- coding: utf8 -*- from sqlalchemy.ext.declarative import declarative_base from sqlalchemy import func from sqlalchemy import Column, DateTime, Integer from cms.db import Base as CMSBase class Base(CMSBase): __abstract__ = True _created = Column(DateTime, default=func.now()) _updated = Column(DateTime...
jnhdny/parts-unlimited-to-bigcommerce
refs/heads/master
python_scripts/import_products_to_bigcommerce.py
1
#!usr/bin/python import mysql.connector import json import sys from mysql.connector import Error import getpass import argparse # Bigcommerce login credentials BIG_USER = 'henry' BIG_KEY = '10f0f4f371f7953c4d7d7809b62463281f15c829' BIG_API = 'https://store-45eg5.mybigcommerce.com/api/v2/' BIG_HEADERS = ...
belimawr/django-filer
refs/heads/develop
filer/test_utils/custom_image/models.py
4
# -*- coding: utf-8 -*- from django.db import models from filer.models.abstract import BaseImage class Image(BaseImage): extra_description = models.TextField() class Meta: pass
honza801/django-swiftbrowser
refs/heads/master
swiftbrowser/templatetags/dateconv.py
8
from datetime import datetime from django import template from django.template.defaultfilters import stringfilter from django.utils.timezone import utc register = template.Library() @register.filter @stringfilter def dateconv(value): try: value = datetime.strptime(value, "%Y-%m-%dT%H:%M:%S.%f") va...
raj454raj/eden
refs/heads/master
modules/s3db/stats.py
5
# -*- coding: utf-8 -*- """ Sahana Eden Stats Model @copyright: 2012-15 (c) Sahana Software Foundation @license: MIT 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 ...
danielberndt/Feature_Langpop
refs/heads/master
tests/helpers.py
3
""" helpers.py: Helper functions for testing Copyright 2014-2015, Outernet Inc. Some rights reserved. This software is free software licensed under the terms of GPLv3. See COPYING file that comes with the source code, or http://www.gnu.org/licenses/gpl.txt. """ def strip_wrappers(fn): """ For decorated fn, retu...
SFPD/rlreloaded
refs/heads/master
domain_data/mujoco_worlds/make_xml.py
1
import re def do_substitution(in_lines): lines_iter = iter(in_lines) defn_lines = [] while True: try: line = lines_iter.next() except StopIteration: raise RuntimeError("didn't find line starting with ---") if line.startswith('---'): break e...
bbsan2k/nzbToMedia
refs/heads/nightly
libs/requests/packages/urllib3/contrib/pyopenssl.py
488
'''SSL with SNI_-support for Python 2. Follow these instructions if you would like to verify SSL certificates in Python 2. Note, the default libraries do *not* do certificate checking; you need to do additional work to validate certificates yourself. This needs the following packages installed: * pyOpenSSL (tested wi...
dezynetechnologies/odoo
refs/heads/8.0
addons/auth_oauth/controllers/main.py
205
import functools import logging import simplejson import urlparse import werkzeug.utils from werkzeug.exceptions import BadRequest import openerp from openerp import SUPERUSER_ID from openerp import http from openerp.http import request from openerp.addons.web.controllers.main import db_monodb, ensure_db, set_cookie_...
grib0ed0v/hse-cv-course-2017
refs/heads/master
6. Template Matching/drawMatches.py
1
import numpy as np import cv2 def drawMatches(img1, kp1, img2, kp2, matches): """ My own implementation of cv2.drawMatches as OpenCV 2.4.9 does not have this function available but it's supported in OpenCV 3.0.0 This function takes in two images with their associated keypoints, as well as a l...
noroutine/ansible
refs/heads/devel
lib/ansible/modules/cloud/openstack/os_keystone_service.py
25
#!/usr/bin/python # Copyright 2016 Sam Yaple # 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'], ...
pepetreshere/odoo
refs/heads/patch-2
addons/crm/tests/common.py
1
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from unittest.mock import patch from odoo.addons.mail.tests.common import MailCase, mail_new_test_user from odoo.addons.sales_team.tests.common import TestSalesCommon from odoo.fields import Datetime from odoo import to...
mrtnrdl/.macdots
refs/heads/master
scripts/bin/platform-tools/systrace/catapult/systrace/systrace/tracing_agents/agents_unittest.py
8
# 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. import unittest from systrace import util from devil.android import device_utils from devil.android.sdk import intent from devil.android.sdk import keyeven...
resmo/ansible
refs/heads/devel
test/units/module_utils/urls/test_fetch_url.py
30
# -*- coding: utf-8 -*- # (c) 2018 Matt Martz <matt@sivel.net> # 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 import socket from ansible.module_utils.six import StringIO from ansible.mo...
holmes-app/holmes-api
refs/heads/master
tests/unit/validators/test_body.py
2
#!/usr/bin/python # -*- coding: utf-8 -*- import lxml.html from mock import Mock from preggy import expect from holmes.config import Config from holmes.reviewer import Reviewer from holmes.validators.body import BodyValidator from tests.fixtures import PageFactory from tests.unit.base import ValidatorTestCase class...
7Robot/cerveau
refs/heads/master
ia/missions/gros/__init__.py
12133432
jacksonicson/paper.IS2015
refs/heads/master
control/Control/src/filelock/__init__.py
12133432
lordmuffin/aws-cfn-plex
refs/heads/master
functions/credstash/pip/_vendor/html5lib/treewalkers/__init__.py
354
"""A collection of modules for iterating through different kinds of tree, generating tokens identical to those produced by the tokenizer module. To create a tree walker for a new type of tree, you need to do implement a tree walker object (called TreeWalker by convention) that implements a 'serialize' method taking a ...
blrm/openshift-tools
refs/heads/stg
ansible/roles/lib_gcloud/library/gcloud_config.py
7
#!/usr/bin/env python # ___ ___ _ _ ___ ___ _ _____ ___ ___ # / __| __| \| | __| _ \ /_\_ _| __| \ # | (_ | _|| .` | _|| / / _ \| | | _|| |) | # \___|___|_|\_|___|_|_\/_/_\_\_|_|___|___/_ _____ # | \ / _ \ | \| |/ _ \_ _| | __| \_ _|_ _| # | |) | (_) | | .` | (_) || | | _|| |) | | ...
ProfessorX/CIS508
refs/heads/master
Codes/xen-4.3.1/tools/xm-test/tests/block-list/03_block-list_anotherbd_pos.py
42
#!/usr/bin/python # Copyright (C) International Business Machines Corp., 2005 # Author: Li Ge <lge@us.ibm.com> # Positive Test: create domain with block attach, attach another, verify both in list from XmTestLib import * ...
mmnelemane/neutron
refs/heads/master
neutron/tests/unit/plugins/ml2/drivers/mech_sriov/agent/extension_drivers/test_qos_driver.py
7
# Copyright 2015 Mellanox Technologies, Ltd # # 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 t...
Igalia/snabbswitch
refs/heads/disable-blacklisting
src/program/lwaftr/tests/subcommands/bench_test.py
9
""" Test the "snabb lwaftr bench" subcommand. Does not need NIC cards. """ import unittest from test_env import (BENCHMARK_FILENAME, BENCHMARK_PATH, DATA_DIR, BENCHDATA_DIR, SNABB_CMD, BaseTestCase) class TestBench(BaseTestCase): cmd_args = [ str(SNABB_CMD), 'lwaftr', 'bench', '--duration', ...
BizzyBane/qBittorrent
refs/heads/master
src/searchengine/nova3/engines/__init__.py
12133432
carsongee/edx-platform
refs/heads/master
cms/djangoapps/models/__init__.py
12133432
yigitguler/django
refs/heads/master
tests/staticfiles_tests/__init__.py
12133432
foobar999/Suchmaschine
refs/heads/master
src/processors/__init__.py
12133432
gagneurlab/concise
refs/heads/master
concise/layers.py
1
import numpy as np from keras import backend as K from keras.engine.topology import Layer from keras.layers.pooling import _GlobalPooling1D from keras.layers import Conv1D, Input, LocallyConnected1D from keras.layers.core import Dropout from concise.utils.plot import seqlogo, seqlogo_fig import matplotlib.pyplot as plt...
codervince/flashingredlight
refs/heads/master
env/lib/python2.7/site-packages/flask/testsuite/ext.py
563
# -*- coding: utf-8 -*- """ flask.testsuite.ext ~~~~~~~~~~~~~~~~~~~ Tests the extension import thing. :copyright: (c) 2011 by Armin Ronacher. :license: BSD, see LICENSE for more details. """ import sys import unittest try: from imp import reload as reload_module except ImportError: reload...
MLAB-project/data-uploader
refs/heads/master
dataUpload.py
2
#!/usr/bin/python import os import sys import optparse from src import DataUpload import time def main(): arg = sys.argv if len(arg) != 2: print "Usage: dataUpload [radio-observer configFile]" sys.exit(1) else: du = DataUpload.dataUpload(arg) while True: last_s...
analogue/bravado-core
refs/heads/master
bravado_core/marshal.py
7
from six import iteritems from bravado_core import formatter, schema from bravado_core.exception import SwaggerMappingError from bravado_core.model import is_model, MODEL_MARKER from bravado_core.schema import is_dict_like from bravado_core.schema import is_list_like from bravado_core.schema import SWAGGER_PRIMITIVES ...
Xeralux/tensorflow
refs/heads/master
tensorflow/python/kernel_tests/garbage_collection_test.py
81
# 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...
dbremner/bite-project
refs/heads/master
deps/gdata-python-client/src/gdata/tlslite/api.py
359
"""Import this module for easy access to TLS Lite objects. The TLS Lite API consists of classes, functions, and variables spread throughout this package. Instead of importing them individually with:: from tlslite.TLSConnection import TLSConnection from tlslite.HandshakeSettings import HandshakeSettings f...
yotchang4s/cafebabepy
refs/heads/develop
src/main/python/idlelib/idle_test/test_configdialog.py
3
"""Test idlelib.configdialog. Half the class creates dialog, half works with user customizations. Coverage: 46% just by creating dialog, 56% with current tests. """ from idlelib.configdialog import ConfigDialog, idleConf # test import from test.support import requires requires('gui') from tkinter import Tk import uni...
robbrockbank/calicoctl
refs/heads/master
calico_containers/tests/st/__init__.py
12133432
gtsiokos/diogenis
refs/heads/master
common/tests.py
6666
""" This file demonstrates writing tests using the unittest module. These will pass when you run "manage.py test". Replace this with more appropriate tests for your application. """ from django.test import TestCase class SimpleTest(TestCase): def test_basic_addition(self): """ Tests that 1 + 1 a...
eerimoq/asn1tools
refs/heads/master
tests/files/time_types_pp.py
1
EXPECTED = {'Foo': {'extensibility-implied': False, 'imports': {}, 'object-classes': {}, 'object-sets': {}, 'types': {'B': {'type': 'DATE'}, 'C': {'type': 'TIME-OF-DAY'}, 'D': {'type': 'DATE-TIME'}}, 'values': {}}}
KohlsTechnology/ansible
refs/heads/devel
test/units/cli/test_cli.py
57
# (c) 2017, Adrian Likins <alikins@redhat.com> # # 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 vers...
allen501pc/phpmyadmin
refs/heads/master
doc/conf.py
1
# -*- coding: utf-8 -*- # # phpMyAdmin documentation build configuration file, created by # sphinx-quickstart on Wed Sep 26 14:04:48 2012. # # 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 file. # # ...
mgedmin/ansible
refs/heads/devel
lib/ansible/modules/packaging/language/__init__.py
12133432
sunny94/temp
refs/heads/iss8501_parsing
sympy/polys/tests/__init__.py
12133432
cactusbin/nyt
refs/heads/master
matplotlib/doc/users/plotting/examples/annotate_simple_coord02.py
6
import matplotlib.pyplot as plt plt.figure(figsize=(3,2)) ax=plt.axes([0.1, 0.1, 0.8, 0.7]) an1 = ax.annotate("Test 1", xy=(0.5, 0.5), xycoords="data", va="center", ha="center", bbox=dict(boxstyle="round", fc="w")) an2 = ax.annotate("Test 2", xy=(0.5, 1.), xycoords=an1, ...
overviewer/Minecraft-Overviewer
refs/heads/master
overviewer_core/optimizeimages.py
4
# This file is part of the Minecraft Overviewer. # # Minecraft Overviewer 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...
mcr/ietfdb
refs/heads/master
django/contrib/flatpages/__init__.py
12133432
stacywsmith/ansible
refs/heads/devel
lib/ansible/modules/messaging/__init__.py
12133432
felliott/osf.io
refs/heads/develop
website/reviews/__init__.py
12133432
kenshay/ImageScript
refs/heads/master
ProgramData/SystemFiles/Python/Lib/site-packages/django/conf/locale/ru/__init__.py
12133432
Sarah-Alsinan/muypicky
refs/heads/master
lib/python3.6/site-packages/django/conf/locale/en/__init__.py
12133432
vismartltd/edx-platform
refs/heads/master
lms/djangoapps/mobile_api/social_facebook/courses/__init__.py
128
""" Courses API """
avrem/ardupilot
refs/heads/pmu40
Tools/LogAnalyzer/tests/TestVCC.py
73
from LogAnalyzer import Test,TestResult import DataflashLog import collections class TestVCC(Test): '''test for VCC within recommendations, or abrupt end to log in flight''' def __init__(self): Test.__init__(self) self.name = "VCC" def run(self, logdata, verbose): self.result = ...
onfido/dependencies-resolver
refs/heads/master
tests/dependency_handler/test_validation.py
1
from __future__ import division from __future__ import print_function from __future__ import absolute_import import pytest from dependencies_resolver.dependency_handler.validation import validate_data from jsonschema import ValidationError mocked_dependencies = { "repository": "onfido-blobs", "dependencies": ...
MSOpenTech/python-social-auth
refs/heads/master
social/tests/backends/test_nationbuilder.py
77
import json from social.tests.backends.oauth import OAuth2Test class NationBuilderOAuth2Test(OAuth2Test): backend_path = 'social.backends.nationbuilder.NationBuilderOAuth2' user_data_url = 'https://foobar.nationbuilder.com/api/v1/people/me' expected_username = 'foobar' access_token_body = json.dumps(...
NeCTAR-RC/swift
refs/heads/nectar/icehouse
swift/common/middleware/catch_errors.py
3
# 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...
ermo/privateer_wcu
refs/heads/master
modules/missions/total_jump.py
1
import Briefing import Director import VS import debug import faction_ships import launch import unit import universe import vsrandom class total_jump: def __init__(self): VS.SetDifficulty(.1) self.lasttime=-1000 self.waittime=5.0 def launch_new_wave(self): un = VS.getPlayer() ...
ffrankies/tf-terry
refs/heads/master
tests/__init__.py
12133432
ChameleonCloud/blazar
refs/heads/chameleoncloud/train
blazar/plugins/__init__.py
12133432
joalder/billstation
refs/heads/master
station/__init__.py
12133432
hellofreedom/ansible
refs/heads/devel
lib/ansible/plugins/shell/powershell.py
35
# (c) 2014, Chris Church <chris@ninemoreminutes.com> # # 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 lat...
barliant/rpb-rsc
refs/heads/master
karawang.py
1
import pandas as pd import numpy as np import matplotlib.pylab as plt #%matplotlib inline from matplotlib.pylab import rcParams from statsmodels.tsa.stattools import adfuller def test_stationarity(timeseries): #Determing rolling statistics rolmean = pd.rolling_mean(timeseries, window=12) #rolmean = Se...
raycarnes/odoomrp-utils
refs/heads/8.0
stock_planning/wizard/__init__.py
15
# -*- coding: utf-8 -*- ############################################################################## # For copyright and license notices, see __openerp__.py file in root directory ############################################################################## from . import wiz_stock_planning
rschnapka/server-tools
refs/heads/8.0
users_ldap_push/models/res_users.py
10
# -*- coding: utf-8 -*- ############################################################################## # # This module copyright (C) 2015 Therp BV (<http://therp.nl>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as # ...
hynnet/hiwifi-openwrt-HC5661-HC5761
refs/heads/master
staging_dir/target-mipsel_r2_uClibc-0.9.33.2/usr/lib/python2.7/lib2to3/fixes/fix_print.py
326
# Copyright 2006 Google, Inc. All Rights Reserved. # Licensed to PSF under a Contributor Agreement. """Fixer for print. Change: 'print' into 'print()' 'print ...' into 'print(...)' 'print ... ,' into 'print(..., end=" ")' 'print >>x, ...' into 'print(..., file=x)' No changes are appl...
w0bb13z/Life-Objects
refs/heads/master
Mock_Ups/Animal.py
1
#!/usr/bin/python36 import os, sys, getopt try: import numpy except ImportWarning: "It is recommended to have 'numpy' installed for 'python3.6'." pass class Animal: """\ This is a class object representing a real world 'Animal'. Note: This does not include "citizen" implementations such ...
noahwilliamsson/micropython
refs/heads/wpa-enterprise
tests/basics/object1.py
110
# test builtin object() # creation object() # printing print(repr(object())[:7])
ajslater/picopt
refs/heads/develop
tests/__init__.py
1
"""Tests init.""" import inspect from pathlib import Path TEST_FILES_DIR = Path("tests/test_files") IMAGES_DIR = TEST_FILES_DIR / "images" INVALID_DIR = TEST_FILES_DIR / "invalid" COMIC_DIR = TEST_FILES_DIR / "comic_archives" TMP_ROOT = "/tmp" def get_test_dir(): """Return a module specific tmpdir.""" fram...
s40171225/2016fallcp_hw
refs/heads/gh-pages
course/week12.py
19
# week12.py print("week12.py")
PennartLoettring/Poettrix
refs/heads/master
rootfs/usr/lib/python3.4/xml/__init__.py
925
"""Core XML support for Python. This package contains four sub-packages: dom -- The W3C Document Object Model. This supports DOM Level 1 + Namespaces. parsers -- Python wrappers for XML parsers (currently only supports Expat). sax -- The Simple API for XML, developed by XML-Dev, led by David Megginso...
Nepherhotep/django
refs/heads/master
tests/template_tests/urls.py
153
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.conf.urls import include, url from . import views ns_patterns = [ # Test urls for testing reverse lookups url(r'^$', views.index), url(r'^client/([0-9,]+)/$', views.client), url(r'^client/(?P<id>[0-9]+)/(?P<action>[^/]+)/$', ...
akosyakov/intellij-community
refs/heads/master
python/testData/inspections/PyMethodOverridingInspection/NotOverridingMethod.py
83
class B: pass class C(B): def foo(self): pass
raphaelm/python-sepadd
refs/heads/master
tests/__init__.py
12133432
gslab-econ/gslab_python
refs/heads/master
gslab_misc/gencat/tests/test_zipFile.py
1
import unittest import os import shutil import zipfile import sys # Ensure the script is run from its own directory os.chdir(os.path.dirname(os.path.realpath(__file__))) sys.path.append('../../') from gencat import gencat class MockCat(gencat): def makeZipDict(self): pass def makeConcatDict(self):...
adoosii/edx-platform
refs/heads/master
lms/djangoapps/commerce/api/urls.py
128
""" API URLs. """ from django.conf.urls import patterns, url, include urlpatterns = patterns( '', url(r'^v0/', include('commerce.api.v0.urls', namespace='v0')), url(r'^v1/', include('commerce.api.v1.urls', namespace='v1')), )
divio/django-cms
refs/heads/develop
cms/tests/test_settings.py
1
from classytags.utils import flatten_context from cms import constants from cms.test_utils.testcases import CMSTestCase from cms.utils.conf import get_cms_setting from django.core.exceptions import ImproperlyConfigured from django.template.loader import render_to_string from django.test.utils import override_settings ...