repo_name
stringlengths
5
100
ref
stringlengths
12
67
path
stringlengths
4
244
copies
stringlengths
1
8
content
stringlengths
0
1.05M
shownomercy/django
refs/heads/master
tests/expressions_case/__init__.py
12133432
mammique/django
refs/heads/tp_alpha
tests/regressiontests/templates/templatetags/subpackage/__init__.py
12133432
pygeek/django
refs/heads/master
django/contrib/sessions/backends/__init__.py
12133432
pygeek/django
refs/heads/master
django/conf/locale/km/__init__.py
12133432
nemunaire/nemubot
refs/heads/master
nemubot/tools/xmlparser/basic.py
2
# Nemubot is a smart and modulable IM bot. # Copyright (C) 2012-2016 Mercier Pierre-Olivier # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at yo...
ilay09/keystone
refs/heads/master
keystone/tests/unit/test_v3_federation.py
1
# 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 t...
yqm/sl4a
refs/heads/master
python/src/Lib/json/tests/test_pass3.py
55
from unittest import TestCase import json # from http://json.org/JSON_checker/test/pass3.json JSON = r''' { "JSON Test Pattern pass3": { "The outermost value": "must be an object or array.", "In this test": "It is an object." } } ''' class TestPass3(TestCase): def test_parse(self): ...
marissazhou/django
refs/heads/master
tests/lookup/tests.py
89
from __future__ import unicode_literals import collections from datetime import datetime from operator import attrgetter from unittest import skipUnless from django.core.exceptions import FieldError from django.db import connection from django.test import TestCase, TransactionTestCase, skipUnlessDBFeature from .mode...
yakky/django
refs/heads/master
tests/migrations/models.py
386
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.apps.registry import Apps from django.db import models from django.utils import six from django.utils.encoding import python_2_unicode_compatible class CustomModelBase(models.base.ModelBase): pass class ModelWithCustomBase(six.with_met...
jackrzhang/zulip
refs/heads/master
zerver/views/zephyr.py
2
from typing import Any, List, Dict, Optional, Callable, Tuple, Iterable, Sequence from django.conf import settings from django.http import HttpResponse, HttpRequest from django.utils.translation import ugettext as _ from zerver.decorator import authenticated_json_view from zerver.lib.ccache import make_ccache from zer...
zafarali/emdp
refs/heads/master
emdp/gridworld/plotting.py
1
from .helper_utilities import unflatten_state from .env import GridWorldMDP import numpy as np class GridWorldPlotter(object): def __init__(self, grid_size, has_absorbing_state=True): """ Utility to plot gridworlds :param grid_size: size of the gridworld :param has_absorbing_state: ...
opendatateam/udata
refs/heads/master
udata/models/taglist_field.py
2
from slugify import slugify from mongoengine.fields import ListField, StringField class TagListField(ListField): def __init__(self, **kwargs): self.tags = [] super(TagListField, self).__init__(StringField(), **kwargs) def clean(self, value): return sorted(list(set([slugify(v, to_lowe...
davidmontgom/pyvmomi-community-samples
refs/heads/master
samples/virtual_machine_device_info.py
10
#!/usr/bin/env python # VMware vSphere Python SDK # Copyright (c) 2008-2014 VMware, 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/lic...
broxtronix/thunder
refs/heads/master
python/thunder/rdds/fileio/tifffile.py
9
#!/usr/bin/env python # -*- coding: utf-8 -*- # tifffile.py # Copyright (c) 2008-2014, Christoph Gohlke # Copyright (c) 2008-2014, The Regents of the University of California # Produced at the Laboratory for Fluorescence Dynamics # All rights reserved. # # Redistribution and use in source and binary forms, with or wit...
popazerty/openblackhole-SH4
refs/heads/master
lib/python/Screens/InputBox.py
14
from enigma import getPrevAsciiCode from Screens.Screen import Screen from Screens.MessageBox import MessageBox from Components.ActionMap import NumberActionMap from Components.Label import Label from Components.Input import Input from Components.config import config from Tools.BoundFunction import boundFunction from T...
brownharryb/erpnext
refs/heads/develop
erpnext/selling/report/sales_person_wise_transaction_summary/sales_person_wise_transaction_summary.py
12
# Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors # License: GNU General Public License v3. See license.txt from __future__ import unicode_literals import frappe from frappe import msgprint, _ from frappe.utils import flt from erpnext import get_company_currency def execute(filters=None): if not f...
liangazhou/django-rdp
refs/heads/master
packages/eclipse/plugins/org.python.pydev.jython_4.4.0.201510052309/Lib/pydoc.py
11
#!/usr/bin/env python # -*- coding: latin-1 -*- """Generate Python documentation in HTML or text for interactive use. In the Python interpreter, do "from pydoc import help" to provide online help. Calling help(thing) on a Python object documents the object. Or, at the shell command line outside of Python: Run "pydo...
EricQAQ/Puck
refs/heads/master
puck/globals.py
1
from .local import LocalStack class Proxy(object): def __init__(self, local): # self.__local = local object.__setattr__(self, '__local', local) def _get_real_object(self): """Get the real object behind the Proxy. So that the users can operate the real things through the proxy...
davehunt/kuma
refs/heads/master
kuma/wiki/tests/test_content.py
9
# -*- coding: utf-8 -*- from urlparse import urljoin import bleach from cssselect.parser import SelectorSyntaxError from jinja2 import escape, Markup from nose.tools import eq_, ok_ from nose.plugins.attrib import attr from pyquery import PyQuery as pq from kuma.core.tests import KumaTestCase from kuma.users.tests im...
fighterCui/L4ReFiascoOC
refs/heads/master
l4/pkg/python/contrib/Lib/test/test_select.py
56
from test import test_support import unittest import select import os import sys class SelectTestCase(unittest.TestCase): class Nope: pass class Almost: def fileno(self): return 'fileno' def test_error_conditions(self): self.assertRaises(TypeError, select.select, 1, 2...
orchidinfosys/odoo
refs/heads/master
addons/website_mail_channel/controllers/main.py
29
# -*- coding: utf-8 -*- import datetime from dateutil import relativedelta from openerp import tools, SUPERUSER_ID from openerp.addons.web import http from openerp.addons.website.models.website import slug from openerp.addons.web.http import request class MailGroup(http.Controller): _thread_per_page = 20 _r...
mattvick/phantomjs
refs/heads/master
src/qt/qtwebkit/Tools/Scripts/webkitpy/tool/steps/runtests_unittest.py
123
# Copyright (C) 2011 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...
sagangwee/sagangwee.github.io
refs/heads/master
build/pygments/build/lib.linux-i686-2.7/pygments/styles/autumn.py
135
# -*- coding: utf-8 -*- """ pygments.styles.autumn ~~~~~~~~~~~~~~~~~~~~~~ A colorful style, inspired by the terminal highlighting style. :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ from pygments.style import Style from pygments.to...
hojel/calibre
refs/heads/master
src/calibre/ebooks/pdb/haodoo/reader.py
24
# -*- coding: utf-8 -*- ''' Read content from Haodoo.net pdb file. ''' __license__ = 'GPL v3' __copyright__ = '2012, Kan-Ru Chen <kanru@kanru.info>' __docformat__ = 'restructuredtext en' import struct import os from calibre import prepare_string_for_xml from calibre.ebooks.pdb.formatreader import FormatReader fr...
jiadaizhao/LeetCode
refs/heads/master
0101-0200/0116-Populating Next Right Pointers in Each Node/0116-Populating Next Right Pointers in Each Node.py
1
# Definition for a Node. class Node: def __init__(self, val: int = 0, left: 'Node' = None, right: 'Node' = None, next: 'Node' = None): self.val = val self.left = left self.right = right self.next = next class Solution: def connect(self, root: 'Node') -> 'Node': curr = ro...
earaujoassis/metaheuristics
refs/heads/master
scheduling/jobshop/suite/__init__.py
1
# -*- coding: utf-8 -*- # Copyright 2011-2015 Ewerton Assis # # 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 ...
plumgrid/plumgrid-nova
refs/heads/master
nova/db/sqlalchemy/migrate_repo/versions/160_fix_system_metadata_deleted.py
23
# Copyright 2013 Rackspace Hosting # # 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 ...
ProstoMaxim/incubator-airflow
refs/heads/master
airflow/macros/__init__.py
27
# -*- 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 ...
Ryezhang/scrapy
refs/heads/master
tests/test_responsetypes.py
27
# -*- coding: utf-8 -*- import unittest from scrapy.responsetypes import responsetypes from scrapy.http import Response, TextResponse, XmlResponse, HtmlResponse, Headers class ResponseTypesTest(unittest.TestCase): def test_from_filename(self): mappings = [ ('data.bin', Response), ...
josenavas/QiiTa
refs/heads/master
qiita_pet/uimodules/__init__.py
1
# ----------------------------------------------------------------------------- # Copyright (c) 2014--, The Qiita Development Team. # # Distributed under the terms of the BSD 3-clause License. # # The full license is in the file LICENSE, distributed with this software. # ------------------------------------------------...
herilalaina/scikit-learn
refs/heads/master
examples/cluster/plot_kmeans_assumptions.py
76
""" ==================================== Demonstration of k-means assumptions ==================================== This example is meant to illustrate situations where k-means will produce unintuitive and possibly unexpected clusters. In the first three plots, the input data does not conform to some implicit assumptio...
laslabs/odoo
refs/heads/9.0
addons/website_sale/controllers/__init__.py
42
# -*- coding: utf-8 -* import main import website_mail
samarthmed/emacs-config
refs/heads/master
.python-environments/default/lib/python2.7/site-packages/setuptools/command/install_scripts.py
505
from distutils import log import distutils.command.install_scripts as orig import os from pkg_resources import Distribution, PathMetadata, ensure_directory class install_scripts(orig.install_scripts): """Do normal script install, plus any egg_info wrapper scripts""" def initialize_options(self): ori...
heeraj123/oh-mainline
refs/heads/master
vendor/packages/django-assets/docs/conf.py
16
# -*- coding: utf-8 -*- # # django-assets documentation build configuration file, created by # sphinx-quickstart on Fri May 08 06:02:25 2009. # # 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...
alfcrisci/httpie
refs/heads/master
httpie/__init__.py
45
""" HTTPie - a CLI, cURL-like tool for humans. """ __author__ = 'Jakub Roztocil' __version__ = '1.0.0-dev' __licence__ = 'BSD' class ExitStatus: """Exit status code constants.""" OK = 0 ERROR = 1 ERROR_TIMEOUT = 2 # Used only when requested with --check-status: ERROR_HTTP_3XX = 3 ERROR_H...
bullapse/LED_strip_webservice
refs/heads/master
main.py
1
import led_service import config # import requests_toolbelt.adapters.appengine # Use the App Engine Requests adapter. This makes sure that Requests uses # URLFetch. # requests_toolbelt.adapters.appengine.monkeypatch() app = notspotify.create_app() if __name__ == "__main__": app.run(host='127.0.0.1',...
wilvk/ansible
refs/heads/devel
lib/ansible/modules/database/postgresql/__init__.py
12133432
dkerwin/ansible-modules-core
refs/heads/devel
database/__init__.py
12133432
mrkiwi-nz/django-helpdesk
refs/heads/master
helpdesk/templatetags/__init__.py
12133432
home-assistant/home-assistant
refs/heads/dev
tests/components/august/test_init.py
2
"""The tests for the august platform.""" import asyncio from unittest.mock import patch from aiohttp import ClientResponseError from yalexs.authenticator_common import AuthenticationState from yalexs.exceptions import AugustApiAIOHTTPError from homeassistant import setup from homeassistant.components.august.const imp...
tomkun/stem
refs/heads/DescReader
test/unit/version.py
5
""" Unit tests for the stem.version.Version parsing and class. """ import unittest import stem.util.system import stem.version from stem.version import Version from test import mocking TOR_VERSION_OUTPUT = """Mar 22 23:09:37.088 [notice] Tor v0.2.2.35 \ (git-73ff13ab3cc9570d). This is experimental software. Do not ...
devssay/newbook
refs/heads/master
bs4/builder/__init__.py
73
from collections import defaultdict import itertools import sys from bs4.element import ( CharsetMetaAttributeValue, ContentMetaAttributeValue, whitespace_re ) __all__ = [ 'HTMLTreeBuilder', 'SAXTreeBuilder', 'TreeBuilder', 'TreeBuilderRegistry', ] # Some useful features for a Tree...
juvoinc/airflow
refs/heads/master
airflow/utils/db.py
13
# -*- 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 ...
kirca/odoo
refs/heads/master
addons/website_sale/controllers/__init__.py
7372
import main
macs03/demo-cms
refs/heads/master
cms/lib/python2.7/site-packages/cms/test_utils/project/customuserapp/models.py
11
# -*- coding: utf-8 -*- from django.core.mail import send_mail from django.db import models from django.utils import timezone from django.utils.http import urlquote try: import re from django.contrib.auth.models import AbstractBaseUser, PermissionsMixin, UserManager from django.core import validators f...
opps/opps
refs/heads/master
opps/images/forms.py
3
#!/usr/bin/env python # -*- coding: utf-8 -*- from django import forms from django.utils.translation import ugettext_lazy as _ from opps.core.widgets import OppsEditor from .models import Image from .widgets import CropExample class ImageModelForm(forms.ModelForm): crop_example = forms.CharField(label=_('Crop E...
squirrelo/qiita
refs/heads/master
qiita_pet/uimodules/processed_data_tab.py
2
# ----------------------------------------------------------------------------- # Copyright (c) 2014--, The Qiita Development Team. # # Distributed under the terms of the BSD 3-clause License. # # The full license is in the file LICENSE, distributed with this software. # ------------------------------------------------...
ryfeus/lambda-packs
refs/heads/master
Tensorflow_Pandas_Numpy/source3.6/pandas/io/gbq.py
1
""" Google BigQuery support """ def _try_import(): # since pandas is a dependency of pandas-gbq # we need to import on first use try: import pandas_gbq except ImportError: # give a nice error message raise ImportError("Load data from Google BigQuery\n" ...
40223209/2015cdbg5_0420
refs/heads/master
static/Brython3.1.1-20150328-091302/Lib/signal.py
743
"""This module provides mechanisms to use signal handlers in Python. Functions: alarm() -- cause SIGALRM after a specified time [Unix only] setitimer() -- cause a signal (described below) after a specified float time and the timer may restart then [Unix only] getitimer() -- get current value of timer [...
atruberg/django-custom
refs/heads/master
django/contrib/gis/tests/geogapp/__init__.py
12133432
myles/dayone
refs/heads/master
tests/__init__.py
12133432
StrellaGroup/frappe
refs/heads/develop
frappe/docs/assets/img/app-development/__init__.py
12133432
adoosii/edx-platform
refs/heads/master
openedx/core/djangoapps/content/course_overviews/migrations/0002_add_days_early_for_beta.py
66
# -*- coding: utf-8 -*- from south.utils import datetime_utils as datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding field 'CourseOverview.days_early_for_beta' # The default value ...
brahle/I-Rcbot
refs/heads/master
irc/mysocket.py
1
#!/usr/bin/env python2.6 # Zeckviz IRC bot # Copyright (C) 2011 Bruno Rahle # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any la...
altsen/diandiyun-platform
refs/heads/master
cms/lib/xblock/mixin.py
25
""" Mixin defining common Studio functionality """ import datetime from xblock.fields import Scope, Field, Integer, XBlockMixin class DateTuple(Field): """ Field that stores datetime objects as time tuples """ def from_json(self, value): return datetime.datetime(*value[0:6]) def to_json...
sppalkia/weld
refs/heads/master
weld-python/weld/encoders/numpy.py
2
""" Implements encoders for NumPy values. The Weld package includes native convertors for NumPy arrays because NumPy is the standard way for interacting with C-like array data. The encoder in this package accepts ndarray or its subclasses. The decoder in this module returns a subclass of ndarray called `weldbasearray...
nxnfufunezn/servo
refs/heads/master
tests/wpt/web-platform-tests/websockets/handlers/empty-message_wsh.py
284
#!/usr/bin/python from mod_pywebsocket import msgutil def web_socket_do_extra_handshake(request): pass # Always accept. def web_socket_transfer_data(request): line = msgutil.receive_message(request) if line == "": msgutil.send_message(request, 'pass') else: msgutil.send_message(reque...
denys-duchier/django
refs/heads/master
django/middleware/http.py
39
from django.utils.cache import ( cc_delim_re, get_conditional_response, set_response_etag, ) from django.utils.deprecation import MiddlewareMixin from django.utils.http import parse_http_date_safe class ConditionalGetMiddleware(MiddlewareMixin): """ Handle conditional GET operations. If the response has a...
rhiever/bokeh
refs/heads/master
bokeh/crossfilter/plotting.py
42
from __future__ import absolute_import import numpy as np import pandas as pd from bokeh.models import ColumnDataSource, BoxSelectTool from ..plotting import figure def cross(start, facets): """Creates a unique combination of provided facets. A cross product of an initial set of starting facets with a new se...
delighted/delighted-python
refs/heads/master
test/__init__.py
1
import json import unittest from mock import Mock, patch import delighted get_headers = { 'Accept': 'application/json', 'Authorization': 'Basic YWJjMTIz', 'User-Agent': "Delighted Python %s" % delighted.__version__ } post_headers = get_headers.copy() post_headers.update({'Content-Type': 'application/jso...
RUFOTHEONE/RUFOTHEONE
refs/heads/master
genesisresolvers.py
266
# -*- coding: utf-8 -*- ''' Genesis Add-on Copyright (C) 2015 lambda 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 ...
wyojustin/clockthreesr
refs/heads/master
arduino/libraries/Time_X/Examples/pps/cumulative.py
11
from scipy import * from pylab import * from numpy import * f = open('uSec.csv') f.readline() for l in f.readlines(): try: x, y = l.split(',') float(x) float(y) except: print l raise dat = loadtxt('uSec.csv', skiprows=1, delimiter=",") # plot(dat[:,0]) # plot(dat[:,1]) ...
gdimitris/ChessPuzzler
refs/heads/master
Virtual_Environment/lib/python2.7/site-packages/werkzeug/_reloader.py
116
import os import sys import time import subprocess import threading from itertools import chain from werkzeug._internal import _log from werkzeug._compat import PY2, iteritems, text_type def _iter_module_files(): """This iterates over all relevant Python files. It goes through all loaded files from modules,...
gcallah/Indra
refs/heads/master
indraV1/models/standing_ovation_run.py
1
#!/usr/bin/env python """ This file runs the standing_ovation model. """ import indra.prop_args2 as props MODEL_NM = "standing_ovation" def run(prop_dict=None): pa = props.PropArgs.create_props(MODEL_NM, prop_dict) import indra.utils as utils import models.standing_ovation as wsm (prog...
eric-stanley/robotframework
refs/heads/master
atest/testdata/variables/extended_assign_vars.py
38
__all__ = ['VAR', 'JVAR'] class Demeter(object): loves = '' @property def hates(self): return self.loves.upper() class Variable(object): attr = 'value' _attr2 = 'v2' attr2 = property(lambda self: self._attr2, lambda self, value: setattr(self, '_attr2', value.uppe...
OriHoch/Open-Knesset
refs/heads/master
laws/migrations/0015_add_bill_content_html.py
15
# 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 'PrivateProposal.content_html' db.add_column('laws_privateproposal', 'content_html', self.g...
zding5/Microblog-Flask
refs/heads/master
flask/lib/python2.7/site-packages/sqlalchemy/sql/naming.py
21
# sqlalchemy/naming.py # Copyright (C) 2005-2015 the SQLAlchemy authors and contributors # <see AUTHORS file> # # This module is part of SQLAlchemy and is released under # the MIT License: http://www.opensource.org/licenses/mit-license.php """Establish constraint and index naming conventions. """ from .schema impor...
Frank-Wu/RamCloud
refs/heads/master
ft/server.py
20
# Copyright (c) 2010 Stanford University # # Permission to use, copy, modify, and distribute this software for any # purpose with or without fee is hereby granted, provided that the above # copyright notice and this permission notice appear in all copies. # # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR(S) DISCLAIM ...
bixbydev/Bixby
refs/heads/master
google/gdata-2.0.18/tests/gdata_tests/apps/emailsettings/live_client_test.py
23
#!/usr/bin/python # # Copyright 2010 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 b...
kubeflow/kfp-tekton-backend
refs/heads/master
samples/tutorials/Data passing in python components/Data passing in python components - Files.py
2
#!/usr/bin/env python3 # Copyright 2020 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or...
poiesisconsulting/openerp-restaurant
refs/heads/master
hr_timesheet_invoice/report/hr_timesheet_invoice_report.py
40
# -*- 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...
rjschwei/azure-sdk-for-python
refs/heads/master
azure-mgmt-network/azure/mgmt/network/models/load_balancer.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 ...
bfirsh/django-old
refs/heads/master
django/contrib/contenttypes/__init__.py
12133432
andymckay/addons-server
refs/heads/master
src/olympia/tags/management/__init__.py
12133432
jank3/django
refs/heads/master
tests/model_regress/__init__.py
12133432
napkindrawing/ansible
refs/heads/devel
test/units/modules/network/eos/__init__.py
12133432
gilt/nova
refs/heads/master
tests/__init__.py
12133432
vvv1559/intellij-community
refs/heads/master
python/testData/intentions/PyConvertToFStringIntentionTest/percentOperatorFallbackResolveResultForPositionalChunk.py
31
numbers = ('eins', 'zwei', 'drei') '%s %s %s' % nu<caret>mbers
ArcherSys/ArcherSys
refs/heads/master
Lib/site-packages/django/contrib/sitemaps/apps.py
590
from django.apps import AppConfig from django.utils.translation import ugettext_lazy as _ class SiteMapsConfig(AppConfig): name = 'django.contrib.sitemaps' verbose_name = _("Site Maps")
RachitKansal/scikit-learn
refs/heads/master
sklearn/tests/test_kernel_approximation.py
244
import numpy as np from scipy.sparse import csr_matrix from sklearn.utils.testing import assert_array_equal, assert_equal, assert_true from sklearn.utils.testing import assert_not_equal from sklearn.utils.testing import assert_array_almost_equal, assert_raises from sklearn.utils.testing import assert_less_equal from ...
technologiescollege/s2a_fr
refs/heads/portable
Snap!Files/Snap!Mobile/arduino/serial/rfc2217.py
141
#! python # # Python Serial Port Extension for Win32, Linux, BSD, Jython # see __init__.py # # This module implements a RFC2217 compatible client. RF2217 descibes a # protocol to access serial ports over TCP/IP and allows setting the baud rate, # modem control lines etc. # # (C) 2001-2013 Chris Liechti <cliechti@gmx.ne...
gavin-feng/odoo
refs/heads/8.0
addons/account_test/account_test.py
342
# -*- encoding: utf-8 -*- ############################################################################## # # Copyright (c) 2005-2006 TINY SPRL. (http://tiny.be) All Rights Reserved. # # $Id: product_expiry.py 4304 2006-10-25 09:54:51Z ged $ # # WARNING: This program as such is intended to be used by professional # prog...
sadatay/beets
refs/heads/master
beetsplug/bpd/__init__.py
23
# This file is part of beets. # Copyright 2015, Adrian Sampson. # # 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, ...
awkspace/ansible
refs/heads/devel
test/integration/targets/module_utils/library/test_override.py
263
#!/usr/bin/python from ansible.module_utils.basic import AnsibleModule from ansible.module_utils.facts import data results = {"data": data} AnsibleModule(argument_spec=dict()).exit_json(**results)
onceuponatimeforever/oh-mainline
refs/heads/master
vendor/packages/Django/tests/regressiontests/admin_scripts/custom_templates/project_template/project_name/settings.py
738
# Django settings for {{ project_name }} test project.
vmanoria/bluemix-hue-filebrowser
refs/heads/master
hue-3.8.1-bluemix/desktop/core/ext-py/Django-1.6.10/tests/admin_scripts/custom_templates/project_template/project_name/settings.py
738
# Django settings for {{ project_name }} test project.
patrickcurl/ztruck
refs/heads/master
dj/lib/python2.7/site-packages/django/core/serializers/__init__.py
121
""" Interfaces for serializing Django objects. Usage:: from django.core import serializers json = serializers.serialize("json", some_queryset) objects = list(serializers.deserialize("json", json)) To add your own serializers, use the SERIALIZATION_MODULES setting:: SERIALIZATION_MODULES = { ...
dahlstrom-g/intellij-community
refs/heads/master
python/testData/intentions/PyAnnotateVariableTypeIntentionTest/annotationNotPossibleForStructuralTypeInCallable.py
19
def func(x): x.foo() return x va<caret>r = func
kenshay/ImageScript
refs/heads/master
Script_Runner/PYTHON/Lib/lib2to3/pgen2/tokenize.py
5
# Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006 Python Software Foundation. # All rights reserved. """Tokenization help for Python programs. generate_tokens(readline) is a generator that breaks a stream of text into Python tokens. It accepts a readline-like method which is called repeatedly to get the next line o...
ibest/grcScripts2
refs/heads/master
inst/scripts/python/extract_unmapped_reads.py
1
#!/usr/bin/env python ''' Extract reads which aren't mapped from a SAM or SAM.gz file. Behavior for PE: -Write out PE only if both do not map (if either of the pair maps, neither is retained) Behavior for SE: -Write out SE if they don't map Iterate over a SAM or SAM.gz file. take everything where the 3rd and 4th ...
davidcbucher/heroku-buildpack-geo-python
refs/heads/master
vendor/distribute-0.6.34/setuptools/command/install.py
216
import setuptools, sys, glob from distutils.command.install import install as _install from distutils.errors import DistutilsArgError class install(_install): """Use easy_install to install the package, w/dependencies""" user_options = _install.user_options + [ ('old-and-unmanageable', None, "Try not ...
NeuralEnsemble/elephant
refs/heads/master
elephant/spike_train_dissimilarity.py
2
# -*- coding: utf-8 -*- """ In neuroscience one often wants to evaluate, how similar or dissimilar pairs or even large sets of spiketrains are. For this purpose various different spike train dissimilarity measures were introduced in the literature. They differ, e.g., by the properties of having the mathematical propert...
zenlambda/pip
refs/heads/develop
tests/functional/test_wheel.py
26
"""'pip wheel' tests""" import os import pytest from os.path import exists from pip.locations import write_delete_marker_file from pip.status_codes import PREVIOUS_BUILD_DIR_ERROR from tests.lib import pyversion def test_pip_wheel_fails_without_wheel(script, data): """ Test 'pip wheel' fails without wheel ...
allenta/varnish-bans-manager
refs/heads/master
varnish_bans_manager/filesystem/forms.py
1
# -*- coding: utf-8 -*- ''' :copyright: (c) 2012 by Allenta Consulting, see AUTHORS.txt for more details. :license: GPL, see LICENSE.txt for more details. ''' from __future__ import absolute_import from django.forms import ImageField as BaseImageField from django.forms.widgets import FileInput, CheckboxInput from dja...
sahiljain/catapult
refs/heads/master
third_party/py_vulcanize/third_party/rjsmin/_setup/py2/__init__.py
43
# -*- coding: ascii -*- # # Copyright 2007, 2008, 2009, 2010, 2011 # Andr\xe9 Malo or his licensors, as applicable # # 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.or...
gerddie/nipype
refs/heads/master
nipype/pipeline/plugins/slurm.py
9
''' Created on Aug 2, 2013 @author: chadcumba Parallel workflow execution with SLURM ''' import os import re import subprocess from time import sleep from .base import (SGELikeBatchManagerBase, logger, iflogger, logging) from nipype.interfaces.base import CommandLine class SLURMPlugin(SGELikeBatchManagerBase):...
csdevsc/mcs_website
refs/heads/master
tasks/__init__.py
12133432
baylee-d/osf.io
refs/heads/develop
api_tests/test/views/__init__.py
12133432
davehunt/kuma
refs/heads/master
vendor/packages/logilab/common/test/data/find_test/module.py
12133432
mcmaxwell/idea_digital_agency
refs/heads/master
idea/feincms/content/raw/__init__.py
12133432