repo_name stringlengths 5 100 | ref stringlengths 12 67 | path stringlengths 4 244 | copies stringlengths 1 8 | content stringlengths 0 1.05M ⌀ |
|---|---|---|---|---|
thaim/ansible | refs/heads/fix-broken-link | test/units/modules/net_tools/nios/test_nios_fixed_address.py | 52 | # 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 in the hope that ... |
bwbeach/ansible | refs/heads/devel | lib/ansible/cli/pull.py | 81 | # (c) 2012, Michael DeHaan <michael.dehaan@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 lat... |
minhthuanit/selenium | refs/heads/master | py/selenium/webdriver/firefox/firefox_profile.py | 60 | # Licensed to the Software Freedom Conservancy (SFC) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The SFC licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not... |
gregdek/ansible | refs/heads/devel | test/units/modules/packaging/os/test_rhn_register.py | 31 | import contextlib
import json
import os
from units.compat.mock import mock_open
from ansible.module_utils import basic
from ansible.module_utils._text import to_native
import ansible.module_utils.six
from ansible.module_utils.six.moves import xmlrpc_client
from ansible.modules.packaging.os import rhn_register
import ... |
gbirke/scrapy | refs/heads/master | scrapy/contrib/downloadermiddleware/downloadtimeout.py | 163 | """
Download timeout middleware
See documentation in docs/topics/downloader-middleware.rst
"""
from scrapy import signals
class DownloadTimeoutMiddleware(object):
def __init__(self, timeout=180):
self._timeout = timeout
@classmethod
def from_crawler(cls, crawler):
o = cls(crawler.setti... |
amanharitsh123/zulip | refs/heads/master | zerver/templatetags/minified_js.py | 3 | from typing import Any, Dict
from django.template import Node, Library, TemplateSyntaxError
from django.conf import settings
from django.contrib.staticfiles.storage import staticfiles_storage
if False:
# no need to add dependency
from django.template.base import Parser, Token
register = Library()
class Mini... |
jimberlage/servo | refs/heads/master | tests/wpt/web-platform-tests/websockets/handlers/set-cookie-secure_wsh.py | 33 | #!/usr/bin/python
from six.moves import urllib
def web_socket_do_extra_handshake(request):
url_parts = urllib.parse.urlsplit(request.uri)
request.extra_headers.append(('Set-Cookie', 'ws_test_'+(url_parts.query or '')+'=test; Secure; Path=/'))
def web_socket_transfer_data(request):
# Expect close() from u... |
hynnet/openwrt-mt7620 | refs/heads/master | staging_dir/target-mipsel_r2_uClibc-0.9.33.2/root-ralink/usr/lib/libstdc++.so.6.0.16-gdb.py | 4 | # -*- python -*-
# Copyright (C) 2009, 2010 Free Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later versi... |
Azure/azure-sdk-for-python | refs/heads/sync-eng/common-js-nightly-docs-2-1768-ForTestPipeline | sdk/sql/azure-mgmt-sql/azure/mgmt/sql/operations/_long_term_retention_managed_instance_backups_operations.py | 1 | # 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 may ... |
gangadharkadam/smrterp | refs/heads/develop | erpnext/manufacturing/doctype/bom_replace_tool/__init__.py | 12133432 | |
jelugbo/hebs_repo | refs/heads/master | lms/djangoapps/notes/migrations/__init__.py | 12133432 | |
yongshengwang/builthue | refs/heads/master | desktop/core/ext-py/Django-1.4.5/django/conf/locale/te/__init__.py | 12133432 | |
Vixionar/django | refs/heads/master | tests/select_related/__init__.py | 12133432 | |
eeshangarg/oh-mainline | refs/heads/master | vendor/packages/gdata/samples/oauth/oauth_on_appengine/appengine_utilities/__init__.py | 12133432 | |
sliz1/servo | refs/heads/master | tests/wpt/web-platform-tests/tools/manifest/tests/__init__.py | 12133432 | |
AlexHill/django | refs/heads/master | django/template/loaders/__init__.py | 12133432 | |
ioannistsanaktsidis/invenio | refs/heads/prod | modules/bibindex/lib/tokenizers/BibIndexAuthorTokenizer.py | 2 | # -*- coding:utf-8 -*-
##
## This file is part of Invenio.
## Copyright (C) 2010, 2011, 2012 CERN.
##
## Invenio is free software; you can redistribute it and/or
## modify it under the terms of the GNU General Public License as
## published by the Free Software Foundation; either version 2 of the
## License, or (at you... |
kawasaki2013/python-for-android-x86 | refs/heads/master | python3-alpha/python3-src/Parser/spark.py | 85 | # Copyright (c) 1998-2002 John Aycock
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
# "Software"), to deal in the Software without restriction, including
# without limitation the rights to use, copy, modify, merge, publis... |
jaimeMF/youtube-dl | refs/heads/master | youtube_dl/extractor/nick.py | 9 | # coding: utf-8
from __future__ import unicode_literals
from .mtv import MTVServicesInfoExtractor
from ..compat import compat_urllib_parse
class NickIE(MTVServicesInfoExtractor):
IE_NAME = 'nick.com'
_VALID_URL = r'https?://(?:www\.)?nick\.com/videos/clip/(?P<id>[^/?#.]+)'
_FEED_URL = 'http://udat.mtvnse... |
gchild320/kernel_lge_g3 | refs/heads/lp5.1 | tools/perf/scripts/python/Perf-Trace-Util/lib/Perf/Trace/SchedGui.py | 12980 | # SchedGui.py - Python extension for perf script, basic GUI code for
# traces drawing and overview.
#
# Copyright (C) 2010 by Frederic Weisbecker <fweisbec@gmail.com>
#
# This software is distributed under the terms of the GNU General
# Public License ("GPL") version 2 as published by the Free Software
# Foundation.
... |
mikedlowis-prototypes/albase | refs/heads/master | source/kernel/tools/perf/scripts/python/export-to-postgresql.py | 238 | # export-to-postgresql.py: export perf data to a postgresql database
# Copyright (c) 2014, Intel Corporation.
#
# This program is free software; you can redistribute it and/or modify it
# under the terms and conditions of the GNU General Public License,
# version 2, as published by the Free Software Foundation.
#
# Thi... |
billgreenwald/pgltools | refs/heads/master | Module/PyGLtools/__init__.py | 1 |
# coding: utf-8
# In[2]:
import browser as _brow
import closest as _clos2d
import closest1D as _clos1d
import condense as _cond
import conveRt as _conv
import coverage as _cov
import expand as _expa
import findLoops as _fl
import intersect as _inter2d
import intersect1D as _inter1d
import juicebox as _jb
import merg... |
axt/angr | refs/heads/master | angr/procedures/glibc/__libc_init.py | 3 | import angr
######################################
# __libc_init
#
# Refer to http://androidxref.com/5.1.1_r6/xref/bionic/libc/bionic/libc_init_dynamic.cpp
# and http://androidxref.com/5.1.1_r6/xref/bionic/libc/private/KernelArgumentBlock.h
# raw_args points to argc, *argv, and *envp located on the stack
# unused is a... |
nerzhul/ansible | refs/heads/devel | lib/ansible/modules/network/illumos/flowadm.py | 48 | #!/usr/bin/python
# -*- coding: utf-8 -*-
# (c) 2016, Adam Števko <adam.stevko@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 L... |
mtwharmby/lucky | refs/heads/master | Lucky/src_Mike_GUI_Total/start_lucky.py | 1 | '''
Created on 3 Nov 2015
@author: wnm24546
'''
import sys
from PyQt4 import QtGui
# import Lucky.LuckyUIView
from Lucky.AllViews import MainView
if __name__ == '__main__':
app = QtGui.QApplication(sys.argv)
# lucky0 = Lucky.LuckyUIView.MainWindow()
# lucky0.show()
lucky = MainView()
lucky.show(... |
Shanec132006/project | refs/heads/master | lib/flask/testsuite/test_apps/moduleapp/apps/frontend/__init__.py | 628 | from flask import Module, render_template
frontend = Module(__name__)
@frontend.route('/')
def index():
return render_template('frontend/index.html')
|
marcydoty/geraldo | refs/heads/master | site/newsite/django_1_0/django/forms/formsets.py | 11 | from forms import Form
from django.utils.encoding import StrAndUnicode
from django.utils.safestring import mark_safe
from fields import IntegerField, BooleanField
from widgets import Media, HiddenInput
from util import ErrorList, ValidationError
__all__ = ('BaseFormSet', 'all_valid')
# special field names
TOTAL_FORM_... |
MarkWh1te/xueqiu_predict | refs/heads/master | python3_env/lib/python3.4/site-packages/pygments/lexers/foxpro.py | 47 | # -*- coding: utf-8 -*-
"""
pygments.lexers.foxpro
~~~~~~~~~~~~~~~~~~~~~~
Simple lexer for Microsoft Visual FoxPro source code.
:copyright: Copyright 2006-2015 by the Pygments team, see AUTHORS.
:license: BSD, see LICENSE for details.
"""
import re
from pygments.lexer import RegexLexer
from pygm... |
samfoo/servo | refs/heads/master | tests/wpt/web-platform-tests/webdriver/navigation/forward.py | 58 | import unittest
import sys
import os
sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../..")))
import base_test
class ForwardTest(base_test.WebDriverBaseTest):
# Get a static page that must be the same upon refresh
def test_forward(self):
self.driver.get(self.webserver.where_is('navigation... |
Salat-Cx65/python-for-android | refs/heads/master | python3-alpha/python3-src/Lib/encodings/cp1256.py | 272 | """ Python Character Mapping Codec cp1256 generated from 'MAPPINGS/VENDORS/MICSFT/WINDOWS/CP1256.TXT' with gencodec.py.
"""#"
import codecs
### Codec APIs
class Codec(codecs.Codec):
def encode(self,input,errors='strict'):
return codecs.charmap_encode(input,errors,encoding_table)
def decode(self,in... |
rgerkin/neuroConstruct | refs/heads/master | lib/jython/Lib/test/autotest.py | 420 | # This should be equivalent to running regrtest.py from the cmdline.
# It can be especially handy if you're in an interactive shell, e.g.,
# from test import autotest.
from test import regrtest
regrtest.main()
|
wd5/jangr | refs/heads/master | _django/contrib/gis/geos/polygon.py | 321 | from ctypes import c_uint, byref
from django.contrib.gis.geos.error import GEOSIndexError
from django.contrib.gis.geos.geometry import GEOSGeometry
from django.contrib.gis.geos.libgeos import get_pointer_arr, GEOM_PTR
from django.contrib.gis.geos.linestring import LinearRing
from django.contrib.gis.geos import prototyp... |
camilonova/sentry | refs/heads/master | tests/sentry/utils/http/tests.py | 1 | # -*- coding: utf-8 -*-
from __future__ import absolute_import
import mock
from django.conf import settings
from exam import fixture
from sentry.models import Project
from sentry.testutils import TestCase
from sentry.utils.http import (
is_same_domain, is_valid_origin, get_origins, absolute_uri)
class Absolut... |
ericgriffin/metasort | refs/heads/master | lib/boost/tools/build/v2/test/dependency_test.py | 44 | #!/usr/bin/python
# Copyright 2003 Dave Abrahams
# Copyright 2002, 2003, 2005, 2006 Vladimir Prus
# Distributed under the Boost Software License, Version 1.0.
# (See accompanying file LICENSE_1_0.txt or copy at
# http://www.boost.org/LICENSE_1_0.txt)
import BoostBuild
def test_basic():
t = BoostBuild.Tester(["-... |
quru/qis | refs/heads/master | src/imageserver/conf/base_settings.py | 1 | #
# Quru Image Server
#
# Base server settings (production settings)
#
# Do not edit this file - it will be overwritten when you upgrade the package.
#
# These settings can instead be overridden by creating the file
# <base>/conf/local_settings.py and adding entries there instead.
#
# The server's public/external host... |
ahamilton55/ansible | refs/heads/devel | lib/ansible/modules/net_tools/exoscale/__init__.py | 12133432 | |
mitdbg/modeldb | refs/heads/master | client/verta/verta/_swagger/_public/common/__init__.py | 12133432 | |
vismartltd/edx-platform | refs/heads/master | lms/djangoapps/django_comment_client/management/commands/__init__.py | 12133432 | |
matteoredaelli/scrapy_web | refs/heads/master | scrapy_web/spiders/nomi_maschili_femminili_nomix_it.py | 1 | # -*- coding: utf-8 -*-
# scrapy_web
# Copyright (C) 2016-2017 Matteo.Redaelli@gmail.com>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# ... |
tntnatbry/tensorflow | refs/heads/master | tensorflow/contrib/learn/python/learn/estimators/prediction_key.py | 28 | # 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... |
rubbenrc/uip-prog3 | refs/heads/master | parcial/presupuesto_parcial.py | 1 | #-------------------------------------------------------------------------------
# Name: presupuesto parcial#1
# Author: programar
#
# Creado: 12/11/2015
# Copyright: (c) programar 2015
# Licence: <your licence 1.1>
#-------------------------------------------------------------------------------
im... |
tumbl3w33d/ansible | refs/heads/devel | test/units/plugins/loader_fixtures/import_fixture.py | 129 | # Nothing to see here, this file is just empty to support a imp.load_source
# without doing anything
__metaclass__ = type
class test:
def __init__(self, *args, **kwargs):
pass
|
runfalk/stormspans | refs/heads/master | stormspans/__init__.py | 1 | """
StormSpans brings support for PostgreSQL's range types to Canonical's Storm
using PsycoSpans paired with Spans.
from spans import intrange
from storm.locals import *
from stormspans import IntRange
class Model(Storm):
id = Int(primary=True)
span = IntRange(default=intrange(1, 10))
... |
avirajsaha/rts_scheduler | refs/heads/master | rts_util.py | 1 | T_INSTANCE_OFF = 0
T_TIME_FROM_OFF = 1
T_TIME_TO_OFF = 2
T_REL_TIME_OFF = 3
T_DEADLINE_OFF = 4
T_EXEC_LEFT_OFF = 5
T_PERIOD_OFF = 6
T_ACTIVE_OFF = 7
T_PROMOTION_OFF = 8
def gcd(*numbers):
"""Return the greatest common divisor of the given integers"""
from fractions import gcd
return reduce(gcd, ... |
j0gurt/ggrc-core | refs/heads/develop | src/ggrc/models/section.py | 4 | # Copyright (C) 2016 Google Inc.
# Licensed under http://www.apache.org/licenses/LICENSE-2.0 <see LICENSE file>
from ggrc import db
from ggrc.models.directive import Directive
from ggrc.models.mixins import CustomAttributable
from ggrc.models.mixins import Described
from ggrc.models.mixins import Hierarchical
from ggr... |
zhangzhishan/thefuck | refs/heads/master | thefuck/rules/quotation_marks.py | 9 | # Fixes careless " and ' usage
#
# Example:
# > git commit -m 'My Message"
def match(command, settings):
return '\'' in command.script and '\"' in command.script
def get_new_command(command, settings):
return command.script.replace('\'', '\"')
|
havt/odoo | refs/heads/8.0 | addons/website_event_track/__openerp__.py | 323 | # -*- coding: utf-8 -*-
{
'name': 'Advanced Events',
'category': 'Website',
'summary': 'Sponsors, Tracks, Agenda, Event News',
'website': 'https://www.odoo.com/page/events',
'version': '1.0',
'description': """
Online Advanced Events
======================
Adds support for:
- sponsors
- dedica... |
130265/Galaxy-S4-Value-Edition-I9515L-Kernel | refs/heads/cm-12.1-oc | scripts/rt-tester/rt-tester.py | 11005 | #!/usr/bin/python
#
# rt-mutex tester
#
# (C) 2006 Thomas Gleixner <tglx@linutronix.de>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
import os
import sys
import getopt
import sh... |
bollu/sandhi | refs/heads/master | modules/gr36/gr-input/python/gr_ramp_source.py | 7 | #!/usr/bin/python
import gras
import numpy
# Serial is imported in __init__
class ramp(gras.Block):
def __init__(self):
gras.Block.__init__(self,
name="ser",
in_sig=[numpy.float32],
out_sig=[numpy.float32])
self.i = 0
... |
akhilari7/pa-dude | refs/heads/master | lib/python2.7/site-packages/pip/_vendor/six.py | 2715 | """Utilities for writing code that runs on Python 2 and 3"""
# Copyright (c) 2010-2015 Benjamin Peterson
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including with... |
joelddiaz/openshift-tools | refs/heads/prod | openshift/installer/vendored/openshift-ansible-3.6.173.0.59/roles/openshift_health_checker/openshift_checks/package_availability.py | 5 | """Check that required RPM packages are available."""
from openshift_checks import OpenShiftCheck
from openshift_checks.mixins import NotContainerizedMixin
class PackageAvailability(NotContainerizedMixin, OpenShiftCheck):
"""Check that required RPM packages are available."""
name = "package_availability"
... |
Hydrospheredata/mist | refs/heads/master | mist-lib/src/main/python/tests/decorators/__init__.py | 12133432 | |
akshatharaj/django | refs/heads/master | tests/admin_scripts/management/commands/__init__.py | 12133432 | |
simongoffin/my_odoo_tutorial | refs/heads/master | addons/l10n_in_hr_payroll/report/__init__.py | 424 | #-*- coding:utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>). All Rights Reserved
# d$
#
# This program is free software: you can redistribute it and/or modify
# it... |
ivan7farre/PyFreeFOAM | refs/heads/master | Foam/src/finiteVolume/__init__.py | 338 | ## pythonFlu - Python wrapping for OpenFOAM C++ API
## Copyright (C) 2010- Alexey Petrov
## Copyright (C) 2009-2010 Pebble Bed Modular Reactor (Pty) Limited (PBMR)
##
## 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 F... |
iwm911/plaso | refs/heads/master | plaso/lib/pfilter_test.py | 1 | #!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Copyright 2012 The Plaso Project Authors.
# Please see the AUTHORS file for details on individual authors.
#
# 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 L... |
colbyga/pychess | refs/heads/master | lib/pychess/Variants/suicide.py | 20 | from __future__ import print_function
# Suicide Chess
from pychess.Utils.const import *
from pychess.Utils.Board import Board
SUICIDESTART = "rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w - - 0 1"
class SuicideBoard(Board):
variant = SUICIDECHESS
def __init__ (self, setup=False, lboard=None):
if set... |
boxed/CMi | refs/heads/master | web_frontend/CMi/cal/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... |
DD-L/deel.boost.python | refs/heads/master | revise/libs/python/pyste/dist/setup.py | 13 | # Copyright Bruno da Silva de Oliveira 2006. Distributed under the Boost
# Software License, Version 1.0. (See accompanying
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
from distutils.core import setup
import py2exe
import sys
sys.path.append('../src')
setup(name='pyste', scripts=[... |
palginpav/Cryptonite | refs/heads/master | qa/rpc-tests/python-bitcoinrpc/setup.py | 182 | #!/usr/bin/env python
from distutils.core import setup
setup(name='python-bitcoinrpc',
version='0.1',
description='Enhanced version of python-jsonrpc for use with Bitcoin',
long_description=open('README').read(),
author='Jeff Garzik',
author_email='<jgarzik@exmulti.com>',
maintaine... |
ol-loginov/intellij-community | refs/heads/master | python/helpers/pydev/third_party/pep8/lib2to3/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... |
macbre/index-digest | refs/heads/master | indexdigest/test/linters/test_0019_queries_not_using_indices.py | 1 | from __future__ import print_function
from unittest import TestCase
from indexdigest.linters.linter_0019_queries_not_using_indices import check_queries_not_using_indices
from indexdigest.test import DatabaseTestMixin, read_queries_from_log
class TestQueriesNotUsingIndices(TestCase, DatabaseTestMixin):
def test... |
enirinth/free-food-calendar | refs/heads/master | foodscrape/spiders/__init__.py | 2415 | # This package will contain the spiders of your Scrapy project
#
# Please refer to the documentation for information on how to create and manage
# your spiders.
|
ubc/lti-parser | refs/heads/master | oauth_store.py | 1 | class OAuthStoreError(Exception):
pass
class OAuthStoreSaveError(OAuthStoreError):
'''
Throw this error if saving to the data store fails.
'''
pass
class OAuthStore:
'''
Base class for OAuth data storage.
This is intended to abstract the actual details of the storage of data
necess... |
yannrouillard/weboob | refs/heads/master | modules/banquepopulaire/backend.py | 2 | # -*- coding: utf-8 -*-
# Copyright(C) 2012-2013 Romain Bignon
#
# This file is part of weboob.
#
# weboob is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your... |
rsvip/Django | refs/heads/master | django/contrib/auth/models.py | 13 | from __future__ import unicode_literals
from django.contrib import auth
from django.contrib.auth.base_user import AbstractBaseUser, BaseUserManager
from django.contrib.auth.signals import user_logged_in
from django.contrib.contenttypes.models import ContentType
from django.core import validators
from django.core.excep... |
sublime1809/django | refs/heads/master | tests/view_tests/__init__.py | 435 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
class BrokenException(Exception):
pass
except_args = (b'Broken!', # plain exception with ASCII text
'¡Broken!', # non-ASCII unicode data
'¡Broken!'.encode('utf-8'), # non-ASCII, utf-8 encoded bytestring... |
Murii/Bonding | refs/heads/master | src/3rdparty/freetype/src/tools/glnames.py | 360 | #!/usr/bin/env python
#
#
# FreeType 2 glyph name builder
#
# Copyright 1996-2000, 2003, 2005, 2007, 2008, 2011 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
# and distributed under the terms of the FreeType project license,
# LI... |
ezeeyahoo/android_kernel_motorola_msm8916 | refs/heads/cm-12.1 | scripts/rt-tester/rt-tester.py | 11005 | #!/usr/bin/python
#
# rt-mutex tester
#
# (C) 2006 Thomas Gleixner <tglx@linutronix.de>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
import os
import sys
import getopt
import sh... |
vizual54/MissionPlanner | refs/heads/master | Lib/sunau.py | 53 | """Stuff to parse Sun and NeXT audio files.
An audio file consists of a header followed by the data. The structure
of the header is as follows.
+---------------+
| magic word |
+---------------+
| header size |
+---------------+
| data size |
... |
jhgoebbert/cvl-fabric-launcher | refs/heads/master | pyinstaller-2.1/PyInstaller/hooks/hook-matplotlib.backends.py | 10 | #-----------------------------------------------------------------------------
# Copyright (c) 2013, PyInstaller Development Team.
#
# Distributed under the terms of the GNU General Public License with exception
# for distributing bootloader.
#
# The full license is in the file COPYING.txt, distributed with this softwa... |
kenwmitchell/ansible-modules-core | refs/heads/devel | system/__init__.py | 12133432 | |
kyuridenamida/ToolsForAtCoder | refs/heads/master | atcodertools/fileutils/__init__.py | 12133432 | |
grow/pygrow | refs/heads/master | grow/translators/__init__.py | 12133432 | |
htzy/bigfour | refs/heads/master | common/djangoapps/embargo/tests/test_middleware.py | 36 | """
Tests for EmbargoMiddleware with CountryAccessRules
"""
import unittest
from mock import patch
import ddt
from django.core.urlresolvers import reverse
from django.conf import settings
from django.core.cache import cache as django_cache
from util.testing import UrlResetMixin
from student.tests.factories import Us... |
silenci/neutron | refs/heads/master | neutron/plugins/ml2/drivers/linuxbridge/agent/common/constants.py | 18 | # Copyright 2012 Cisco Systems, Inc. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless requir... |
timmygee/investorservitude | refs/heads/master | investorservitude/core/management/commands/poll.py | 1 | import requests
import re
from decimal import Decimal
from datetime import datetime
from bs4 import BeautifulSoup
from django.core.management.base import BaseCommand, CommandError
from django.conf import settings
from django.db import models
from django.db.utils import IntegrityError
from core.models import Holding
... |
peterjanes/dosage | refs/heads/master | tests/test_rss.py | 1 | # -*- coding: utf-8 -*-
# Copyright (C) 2019 Tobias Gruetzmacher
from __future__ import absolute_import, division, print_function
import time
from dosagelib.rss import parseFeed
class TestFeed(object):
"""
Tests for rss.py
"""
def test_parseFeed(self):
testTime = time.localtime(1560000000.0... |
travislbrundage/geonode | refs/heads/master | geonode/contrib/api_basemaps/osm.py | 13 | # -*- coding: utf-8 -*-
#########################################################################
#
# Copyright (C) 2016 OSGeo
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 ... |
aljim/deploymentmanager-samples | refs/heads/master | community/cloud-foundation/tests/unit/test_deployment.py | 2 | from six import PY2
from apitools.base.py.exceptions import HttpNotFoundError
import jinja2
import pytest
from ruamel.yaml import YAML
from cloud_foundation_toolkit.deployment import Config
from cloud_foundation_toolkit.deployment import ConfigGraph
from cloud_foundation_toolkit.deployment import Deployment
if PY2:
... |
ftick/pyNES | refs/heads/0.1.x | pynes/tests/commandline_test.py | 28 | # -*- coding: utf-8 -*-
from pynes import main
from pynes.tests import FileTestCase
from mock import patch
class CommandLineTest(FileTestCase):
@patch('pynes.compiler.compile_file')
def test_asm(self, compiler):
main("pynes asm fixtures/movingsprite/movingsprite.asm".split())
compiler.assert_... |
jgeskens/django | refs/heads/master | tests/bug8245/__init__.py | 12133432 | |
yongshengwang/hue | refs/heads/master | desktop/core/ext-py/django-extensions-1.5.0/build/lib/django_extensions/db/__init__.py | 12133432 | |
leopardPrint/ipythonNotebookModules | refs/heads/master | src/__init__.py | 12133432 | |
Arundhatii/erpnext | refs/heads/develop | erpnext/schools/doctype/assessment_criteria_group/__init__.py | 12133432 | |
rtoal/polyglot | refs/heads/master | python/animals.py | 1 | class Animal:
def __init__(self, name):
self.name = name
def speak(self):
return '{} says {}'.format(self.name, self.sound())
class Cow(Animal):
def sound(self):
return 'moooo'
class Horse(Animal):
def sound(self):
return 'neigh'
class Sheep(Animal):
def sound(self... |
nekulin/arangodb | refs/heads/devel | 3rdParty/V8-4.3.61/third_party/python_26/Lib/sqlite3/dump.py | 247 | # Mimic the sqlite3 console shell's .dump command
# Author: Paul Kippes <kippesp@gmail.com>
def _iterdump(connection):
"""
Returns an iterator to the dump of the database in an SQL text format.
Used to produce an SQL dump of the database. Useful to save an in-memory
database for later restoration. T... |
mubix/pth-toolkit | refs/heads/master | lib/python2.7/site-packages/samba/tests/samba3.py | 5 | # Unix SMB/CIFS implementation.
# Copyright (C) Jelmer Vernooij <jelmer@samba.org> 2007
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) a... |
espadrine/opera | refs/heads/master | chromium/src/tools/grit/grit/node/base.py | 7 | #!/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.
'''Base types for nodes in a GRIT resource tree.
'''
import collections
import os
import sys
import types
from xml.sax import saxu... |
jakirkham/ilastik | refs/heads/master | bin/downsample_pointcloud.py | 3 | import sys
import os
import csv
import numpy
import logging
logger = logging.getLogger(__name__)
# NOTE: This file depends on numpy.add.at(), which requires numpy v1.8.0
def downsample_pointcloud( pointcloud_csv_filepath,
output_filepath,
scale_xyz=None,
... |
franosincic/edx-platform | refs/heads/master | common/djangoapps/track/views/segmentio.py | 40 | """Handle events that were forwarded from the Segment webhook integration"""
import datetime
import json
import logging
from django.conf import settings
from django.contrib.auth.models import User
from django.http import HttpResponse
from django.views.decorators.http import require_POST
from django.views.decorators.c... |
MortimerGoro/servo | refs/heads/master | tests/wpt/css-tests/tools/gitignore/tests/__init__.py | 12133432 | |
dhoffman34/django | refs/heads/master | tests/admin_validation/__init__.py | 12133432 | |
DiptoDas8/Biponi | refs/heads/master | lib/python2.7/site-packages/django/contrib/humanize/templatetags/__init__.py | 12133432 | |
rrrene/django | refs/heads/master | tests/select_related_regress/__init__.py | 12133432 | |
gwiedeman/eadmachine | refs/heads/master | source/EADtoSpreadsheet/__init__.py | 12133432 | |
elysium001/zamboni | refs/heads/master | mkt/users/tests/__init__.py | 12133432 | |
ic-labs/django-icekit | refs/heads/develop | icekit/utils/__init__.py | 12133432 | |
ruslanloman/nova | refs/heads/master | nova/tests/unit/api/openstack/compute/contrib/__init__.py | 12133432 | |
okwow123/djangol2 | refs/heads/master | allauth/socialaccount/providers/persona/models.py | 12133432 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.