commit
stringlengths
40
40
subject
stringlengths
1
3.25k
old_file
stringlengths
4
311
new_file
stringlengths
4
311
old_contents
stringlengths
0
26.3k
lang
stringclasses
3 values
proba
float64
0
1
diff
stringlengths
0
7.82k
c372d7197afef840e5a1f550f947ecbc2c931573
Correct name for mediatailor
tests/functional/test_endpoints.py
tests/functional/test_endpoints.py
# Copyright 2016 Amazon.com, Inc. or its affiliates. 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. A copy of # the License is located at # # http://aws.amazon.com/apache2.0/ # # or in the "license" file accompa...
Python
0.000006
@@ -1836,16 +1836,54 @@ 'rds',%0A + 'mediatailor': 'api.mediatailor',%0A %7D%0A%0ABLACK
932e7ea649dad6b9b563eaac90bfc617ba3d10ca
Add ResourceTest
cal/tests/unit/test_wsgi.py
cal/tests/unit/test_wsgi.py
""" Test WSGI basics and provide some helper functions for other WSGI tests. """ import routes import webob import webob.exc from cal import wsgi from cal.tests import base class Test(base.NoDBTestCase): def test_debug(self): class Application(wsgi.Application): """Dummy application to tes...
Python
0
@@ -4043,8 +4043,1425 @@ ed_body) +%0A%0A%0Aclass ResouceTest(base.NoDBTestCase):%0A%0A def setUp(self):%0A super(ResouceTest, self).setUp()%0A self.resource = wsgi.Resource(self.Controller())%0A%0A class Controller(object):%0A def index(self, req, index=None):%0A return index%0A%...
587c4603d3ab379e4ee22f2dcda7d7798cd35dcf
fix spacing around arguments
db_credentials/DBCredentials.py
db_credentials/DBCredentials.py
#! /usr/local/bin/python import sys import re class DBCredentials: def __init__( self ): self.creds = { 'host':'', 'port':'', 'username':'', 'password':'', 'database':'', } return; # Load credentials from a file: no input ...
Python
0.000151
@@ -80,22 +80,20 @@ _init__( - self - ):%0A%0A @@ -347,17 +347,16 @@ ad_file( - self, fi @@ -361,17 +361,16 @@ filename - ):%0A%0A @@ -382,17 +382,16 @@ = open( - filename @@ -395,17 +395,16 @@ ame, 'r' - )%0A @@ -487,17 +487,16 @@ findall( - r'(%5Cw+)= @@ -510,17 +510,16 @@ )', text...
b939558f3d4bd0fa90f3f467ca85f698c4813046
Update __init__.py
comps/__init__.py
comps/__init__.py
""" A simple application that provides an entry point for integrating front end designers into a django project """ __version__ = '0.2.0'
Python
0.000001
@@ -131,9 +131,9 @@ '0. -2 +3 .0'%0A
ebcf8afa86caa243148397645870f35f51bb0739
Move imgur config to be a CMD argument
cats4all/cats_downloader.py
cats4all/cats_downloader.py
import os import time import imgurpython import requests import sqlite3 import itertools from collections import namedtuple import json import argparse DIR_NAME_FRMT = 'cats-%s' tags = ['cat', 'cats', 'lolcat', 'lolcats'] DEFAULT_DB_FILE_PATH = './cats2.db' ImageData = namedtuple('ImageData', ['id', 'link', 'title', ...
Python
0.000001
@@ -251,16 +251,60 @@ ats2.db' +%0ADEFAULT_IMGUR_CONFIG_PATH = './config.json' %0A%0AImageD @@ -464,31 +464,41 @@ ig_path= -'./config.json' +DEFAULT_IMGUR_CONFIG_PATH ):%0A w @@ -4954,24 +4954,207 @@ pictures.')%0A + parser.add_argument('--imgur-config', dest='imgur_config_path', default=DEFAULT_IMGUR_CONFIG...
86f143863fd9f0786fe83a5038b970b4782306ce
Check table exist
erpnext/patches/v7_0/update_missing_employee_in_timesheet.py
erpnext/patches/v7_0/update_missing_employee_in_timesheet.py
from __future__ import unicode_literals import frappe def execute(): timesheet = frappe.db.sql("""select tl.employee as employee, ts.name as name, tl.modified as modified, tl.modified_by as modified_by, tl.creation as creation, tl.owner as owner from `tabTimesheet` ts, `tabTimesheet Detail` tsd, `tabTime Log...
Python
0
@@ -63,16 +63,57 @@ cute():%0A +%09if frappe.db.table_exists(%22Time Log%22):%0A%09 %09timeshe @@ -186,16 +186,17 @@ ame,%0A%09%09%09 +%09 tl.modif @@ -292,14 +292,16 @@ r%0A%09%09 +%09 from %0A +%09 %09%09%09%60 @@ -362,16 +362,17 @@ Log%60 tl%0A +%09 %09%09where @@ -375,16 +375,17 @@ ere %0A%09%09%09 +%09 ...
2d3b97e150f96ed4e7295d4e5b288951c3a7ee50
fix freq-check plug&play problem
catsnapshot/snapschedule.py
catsnapshot/snapschedule.py
import time,schedule,datetime import signal,os,sys task_list = list() write_list = [] feqcheck_list = [] def clean_task_list(): global task_list global write_list for i in range(len(task_list)): task_list[i] = None write_list = [] class schedule_sig_handler(object): def __init__(self,s...
Python
0.000001
@@ -1871,24 +1871,63 @@ (snapmang):%0A + sleep(10) # waiting device%0A
5ffc79ca3d431eaaa3795f8297790997082b49c8
fix bug of generate password
genpass/lib/person.py
genpass/lib/person.py
# coding=utf-8 from __future__ import print_function import re from itertools import product from genpass.rules import combinations __all__ = ['Person'] class Person(object): source_dict = {} def __init__(self, information=None, field_map=()): self.information = {} if information is None else infor...
Python
0.000003
@@ -4592,16 +4592,35 @@ t_keys)) + and dependent_keys :%0A
14bc45b6447424da4c84f84c40f2d897198c73ab
use proper end boundary
custom/icds_reports/utils/aggregation_helpers/aww_incentive.py
custom/icds_reports/utils/aggregation_helpers/aww_incentive.py
from __future__ import absolute_import from __future__ import unicode_literals from corehq.apps.userreports.models import StaticDataSourceConfiguration, get_datasource_config from corehq.apps.userreports.util import get_table_name from custom.icds_reports.const import AWW_INCENTIVE_TABLE from custom.icds_reports.util...
Python
0.000083
@@ -2914,17 +2914,16 @@ ::DATE %3E -= %25(month
f04a7d6ac961f1ebb5ac065c8e87d7b45119c288
Add an integration test for charmhub.list_resources
tests/integration/test_charmhub.py
tests/integration/test_charmhub.py
import pytest from .. import base from juju.errors import JujuAPIError, JujuError from juju import jasyncio @base.bootstrapped @pytest.mark.asyncio async def test_info(event_loop): async with base.CleanModel() as model: _, name = await model.charmhub.get_charm_id("hello-juju") assert name == "hel...
Python
0
@@ -3231,20 +3231,280 @@ en(app2.units) == 0%0A +%0A%0A@base.bootstrapped%0A@pytest.mark.asyncio%0Aasync def test_list_resources(event_loop):%0A async with base.CleanModel() as model:%0A resources = await model.charmhub.list_resources('postgresql')%0A assert type(resources) == list and len(resources) ...
ff03fb51d751c3dc820c2aee9b8ba2a7c45f1f0b
Split up assertions in `user_create` test #580
tests/lib/user/test_create_user.py
tests/lib/user/test_create_user.py
import dataclasses from datetime import date import pytest from pycroft.lib.user import create_user from tests import factories from .assertions import assert_account_name, assert_membership_groups, assert_logmessage_startswith @dataclasses.dataclass class UserData: name: str login: str email: str m...
Python
0.002351
@@ -1753,22 +1753,25 @@ st_user_ -create +base_data (self, n @@ -1794,136 +1794,14 @@ ta, -member_group, user_mail_capture):%0A # needs: new_user, self.user (the initiating data),%0A # self.config.member_group +room): %0A @@ -1941,16 +1941,77 @@ ta.email +%0A%0A def test_user_address(self, new...
f2060ccfb3aecceef027031a42e0f8367d3c2618
Handle the corner case when there are no user inputs
emission/analysis/classification/inference/labels/inferrers.py
emission/analysis/classification/inference/labels/inferrers.py
# This file encapsulates the various prediction algorithms that take a trip and return a label data structure # Named "inferrers.py" instead of "predictors.py" to avoid a name collection in our abbreviated import convention import logging import random import emission.analysis.modelling.tour_model.load_predict as lp ...
Python
0.998659
@@ -5904,16 +5904,71 @@ input%22)%0A + if len(unique_user_inputs) == 0:%0A return %5B%5D%0A rand
b8c05a7ea6abefa3014f8703864031876c211679
Add link for total malaria cases for year 2015 for Indonesia
src/data/download_scripts/ID_malaria_down.py
src/data/download_scripts/ID_malaria_down.py
# This script downloads yearly malaria statistics from data.go.id # It uses urllib and is compatible with both Python 2 and 3 import os import sys import logging #logs what goes on DIRECTORY = '../../Data/raw/disease_ID' OUTFILE = "yearly-malaria.csv" URL = "http://data.go.id/dataset/cef9b348-91a9-4270-be1d-3cf64eb9d...
Python
0
@@ -390,16 +390,206 @@ ia.csv%22%0A +URL2015 = %22http://data.go.id/dataset/cef9b348-91a9-4270-be1d-3cf64eb9d5b0/resource/2965b760-0f7f-4bd7-9dbe-8d261729e12f/download/jumlahkasusangkakesakitanmalariaper1000pendudukberisiko.xlsx%22 %0Alogger
193cc8025910b92f764e6e1339ce2ec213b20cc5
Fix duck punching unit test.
tests/qtcore/duck_punching_test.py
tests/qtcore/duck_punching_test.py
#!/usr/bin/python '''Test case for duck punching new implementations of C++ virtual methods into object instances.''' import unittest import types from PySide.QtCore import QObject, QEvent from helper import UsesQCoreApplication class Duck(QObject): def __init__(self): QObject.__init__(self) def chil...
Python
0
@@ -1099,33 +1099,38 @@ %0A parent. -e +childE vent = types.Met @@ -1658,17 +1658,22 @@ parent. -e +childE vent = t
f7f754c4280858305c42699c46dccdfb939e01fb
allow setting which plugins should be used via config
voltverine/app.py
voltverine/app.py
import argparse import inspect import logging import os import sys import yaml import voltverine.plugins import voltverine.actions logging.basicConfig(level=logging.INFO) logger = logging.getLogger(__name__) _PLUGIN_BLACKLIST = ['BasePlugin', 'BaseDbusPlugin'] _DEFAULT_CONFIG = {'action': 'LogindPoweroff'} class Vo...
Python
0
@@ -301,16 +301,31 @@ oweroff' +, 'plugins': %5B%5D %7D%0A%0A%0Aclas @@ -2333,21 +2333,21 @@ -self. +found _plugins @@ -2543,16 +2543,203 @@ ACKLIST) +%0A if self.config%5B'plugins'%5D:%0A self._plugins = %5Bp for p in found_plugins if p%5B0%5D in self.config%5B'plugins'%5D.keys()%5D%0A ...
b95c5dfad2956eca7b0891d3692c140a54b9db84
Fix tests.
tests/test_google_image_handler.py
tests/test_google_image_handler.py
# -*- coding: utf-8 -*- """ robo.tests.test_handler_google_image ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Tests for robo.handlers.google_image :copyright: (c) 2015 Shinya Ohyanagi, All rights reserved. :license: BSD, see LICENSE for more details. """ import os import logging import requests from mock...
Python
0
@@ -1576,19 +1576,16 @@ th('http -:// '))%0A%0A @@ -1911,20 +1911,12 @@ ue(' -unescapedUrl +link ' in
3d237a6bf3a3dff684e08496f800a8957a9e3352
Fix pep error.
hr_contract_hourly_rate/models/hr_hourly_rate_class.py
hr_contract_hourly_rate/models/hr_hourly_rate_class.py
# -*- coding:utf-8 -*- ############################################################################## # # Copyright (C) 2014 Savoir-faire Linux. All Rights Reserved. # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as publish...
Python
0.000001
@@ -1852,32 +1852,53 @@ r1.date_end and +%5C%0A (r1.date_start %3C
fa00db22832d43cfb4ed5b79be32e31153a5e570
Include new app
core/settings.py
core/settings.py
""" Django settings for core project. For more information on this file, see https://docs.djangoproject.com/en/1.7/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.7/ref/settings/ """ # Build paths inside the project like this: os.path.join(BASE_DIR, ...) impor...
Python
0
@@ -1042,24 +1042,73 @@ .flatpages', +%0A%0A # 3rd Party%0A%0A # Own Apps%0A 'fineants', %0A 'polls'
f5fd631cb4571930cf71513db2622861fb4fcc39
simplify put requests
lib/test_util.py
lib/test_util.py
import hashlib from lettuce import world from tornado.escape import json_decode from tornado.httpclient import HTTPClient, HTTPRequest from newebe.settings import TORNADO_PORT from newebe.profile.models import UserManager, User ROOT_URL = "http://localhost:%d/" % TORNADO_PORT class NewebeClient(HTTPClient): '''...
Python
0.000002
@@ -1938,32 +1938,127 @@ t.%0A '''%0A%0A + if hasattr(self, %22root_url%22) and self.root_url:%0A url = self.root_url + url%0A%0A request @@ -2197,32 +2197,45 @@ %5D = self.cookie%0A + %0A return H
469b20ebd9d9287c8b956555374523cf083eb11a
create optional argument group and change --bucket-id argument to --bucket-name
aws_ir/cli.py
aws_ir/cli.py
#!/usr/bin/env python import datetime import pprint import sys import argparse import logging import json #Add the AWS_IR Object import aws_ir #Support for multiple incident plans coming soon from plans import key from plans import host """Basic arg parser for AWS_IR cli""" class cli(): def __init__(self): ...
Python
0.000001
@@ -983,32 +983,48 @@ )%0A%0A + optional_args = parser.add_argu @@ -1031,27 +1031,53 @@ ment -(%0A '-n', +_group()%0A%0A optional_args.add_argument( %0A @@ -1257,38 +1257,45 @@ )%0A%0A -parser +optional_args .add_argument(%0A @@ -1297,26 +1297,8 @@ nt(%0A - ...
d818d497fdf2f361d5ea4160061440b6329d6ee4
Fix clang-format vim integration issue with non-ascii characters
tools/clang-format/clang-format.py
tools/clang-format/clang-format.py
# This file is a minimal clang-format vim-integration. To install: # - Change 'binary' if clang-format is not on the path (see below). # - Add to your .vimrc: # # map <C-I> :pyf <path-to-this-file>/clang-format.py<cr> # imap <C-I> <c-o>:pyf <path-to-this-file>/clang-format.py<cr> # # The first line enables clang-fo...
Python
0.999972
@@ -2106,16 +2106,24 @@ text = +unicode( '%5Cn'.joi @@ -2128,16 +2128,27 @@ oin(buf) +, encoding) %0A%0A # De
c88314f935d9bf1e65c2a4f6d3eb6931fee5c4f5
fix evaluate.py
Utils/py/BallDetection/RegressionNetwork/evaluate.py
Utils/py/BallDetection/RegressionNetwork/evaluate.py
#!/usr/bin/env python3 import argparse import pickle import tensorflow.keras as keras import numpy as np parser = argparse.ArgumentParser(description='Train the network given ') parser.add_argument('-b', '--database-path', dest='imgdb_path', help='Path to the image database containing test data.'...
Python
0.000002
@@ -99,17 +99,227 @@ y as np%0A -%0A +from pathlib import Path%0A%0ADATA_DIR = Path(Path(__file__).parent.absolute() / %22data%22).resolve()%0AMODEL_DIR = Path(Path(__file__).parent.absolute() / %22models/best_models%22).resolve()%0A%0Aif __name__ == '__main__':%0A parser = @@ -360,13 +360,16 @@ on=' -Train +Eva...
cc7e3e5ef9d9c59b6b1ac80826445839ede73092
Revert mast dev host change
astroquery/mast/__init__.py
astroquery/mast/__init__.py
# Licensed under a 3-clause BSD style license - see LICENSE.rst """ MAST Query Tool =============== This module contains various methods for querying the MAST Portal. """ from astropy import config as _config class Conf(_config.ConfigNamespace): """ Configuration parameters for `astroquery.mast`. """ ...
Python
0
@@ -370,11 +370,8 @@ mast -dev .sts
3ef82203daebd532af2f8effebe8fa31cec11e76
fix error message encoding
atest/robot/tidy/TidyLib.py
atest/robot/tidy/TidyLib.py
from __future__ import with_statement import os from os.path import abspath, dirname, join from subprocess import call, STDOUT import tempfile from robot.utils.asserts import assert_equals ROBOT_SRC = join(dirname(abspath(__file__)), '..', '..', '..', 'src') class TidyLib(object): def __init__(self, interpret...
Python
0.000001
@@ -1819,32 +1819,122 @@ decode('UTF-8')%0A + result_lines = result.splitlines()%0A expected_lines = expected.splitlines()%0A for line @@ -1955,29 +1955,22 @@ p(result -.split +_ lines -() , expect @@ -1971,29 +1971,22 @@ expected -.split +_ lines -() ):%0A
3904a7ac75318de08452fcea1a49b6d6e681da4e
remove debug.
lib/acli/output/route53.py
lib/acli/output/route53.py
# -*- coding: utf-8 -*- from __future__ import (absolute_import, print_function, unicode_literals) from acli.output import (output_ascii_table, dash_if_none) def output_route53_list(output_media=None, zones=None): """ @type output_media: unicode @type zones: list | dict """ if isinstance(zones, di...
Python
0
@@ -1516,55 +1516,8 @@ %22%22%22%0A - print(resource_records.__class__.__name__)%0A
ce1169df5393588dea1f6d4abfea99b03d5b732c
Fix a sorting bug
bank2ynab.pyw
bank2ynab.pyw
from pathlib import Path from tkinter import Tk, StringVar, Toplevel, Message from tkinter.ttk import Combobox, Frame, Button, Label from tkinter.filedialog import askopenfilename from src.converter import bank2ynab from src.config import BankConfig PADX = 12 PADY = 10 BANK_DIR = Path('./banks') ####################...
Python
0
@@ -1218,29 +1218,24 @@ er)%0A -self. banks = %5BBan @@ -1307,16 +1307,84 @@ .toml'%5D%0A + banks.sort(key=lambda b: b.name)%0A self.banks = banks%0A @@ -1580,23 +1580,36 @@ s = -self.getNames() +%5Bb.name for b in self.banks%5D %0A @@ -2446,120 +2446,8 @@ e)%0A%0A - def get...
fe67796130854d83b3dfaa085d67d9eabe35a155
Allow getdate for Energy Point Rule condition
frappe/social/doctype/energy_point_rule/energy_point_rule.py
frappe/social/doctype/energy_point_rule/energy_point_rule.py
# -*- coding: utf-8 -*- # Copyright (c) 2018, Frappe Technologies and contributors # For license information, please see license.txt from __future__ import unicode_literals import frappe from frappe import _ import frappe.cache_manager from frappe.model.document import Document from frappe.social.doctype.energy_point_...
Python
0
@@ -724,16 +724,68 @@ , doc):%0A +%09%09whitelisted_globals = %7B%0A%09%09%09%22getdate%22: getdate%0A%09%09%7D%0A %09%09if fra @@ -818,12 +818,27 @@ on, -None +whitelisted_globals , %7B'
09a075891cf881571055538d7b18cb2e684e7d9e
Use log.exception instead of traceback module in hook.py
libqtile/hook.py
libqtile/hook.py
import traceback import utils subscriptions = {} SKIPLOG = set() qtile = None def init(q): global qtile qtile = q def clear(): subscriptions.clear() class Subscribe: def __init__(self): hooks = set([]) for i in dir(self): if not i.startswith("_"): hooks...
Python
0.000001
@@ -1,21 +1,4 @@ -import traceback%0A impo @@ -6087,23 +6087,8 @@ cept - Exception as e :%0A @@ -6108,20 +6108,24 @@ le.log.e -rror +xception (%22Error @@ -6138,63 +6138,18 @@ k %25s -:%5Cn%25s%22 %25 (%0A event, traceback.format_exc() +%22 %25 (event, ))%0A
6236ee8344add06f6adbfef9df5ab224ea19b1fe
Remove unused import
moocng/courses/backends.py
moocng/courses/backends.py
# Copyright (C) 2010-2012 Yaco Sistemas (http://www.yaco.es) # Copyright (C) 2009 Lorenzo Gil Sanchez <lorenzo.gil.sanchez@gmail.com> # # 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 # # ...
Python
0.000001
@@ -893,49 +893,8 @@ end%0A -from moocng.courses.models import Course%0A from
aa8e55858997d30ca507091672951a99f5fc4ef4
Remove mozaik_event_barcode from mozaik_all to be able to uninstall it
mozaik_all/__manifest__.py
mozaik_all/__manifest__.py
# Copyright 2018 ACSONE SA/NV # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). { "name": "Mozaik: All Modules Loader", "summary": """ Loads all Mozaik modules""", "version": "14.0.1.1.9", "license": "AGPL-3", "author": "ACSONE SA/NV", "website": "https://github.com/OCA/moz...
Python
0
@@ -962,32 +962,34 @@ filter%22,%0A + # %22mozaik_event_b
096f45694c741a03d444b4a83bc2d1386c11b0d5
Fix data entry backend
datapoints/api/resources/base_model.py
datapoints/api/resources/base_model.py
import json from django.http import HttpResponse from tastypie.authorization import Authorization from tastypie.authentication import ApiKeyAuthentication, MultiAuthentication from tastypie.resources import ModelResource from tastypie import http from datapoints.models import LocationPermission from datapoints.api.s...
Python
0.000054
@@ -3288,18 +3288,16 @@ %0A - # deseria @@ -3412,18 +3412,16 @@ %0A - # self.up
6a2a0667179a78e2c56dff551b0d010db6ed0150
fix imports
chainerrl/initializers/__init__.py
chainerrl/initializers/__init__.py
from chainerrl.initializers.constant import VarianceScalingConstant # NOQA from chainerrl.initializers.normal import LeCunNormal # NOQA
Python
0.000002
@@ -123,16 +123,90 @@ nNormal # NOQA%0A +from chainerrl.initializers.uniform import VarianceScalingUniform # NOQA%0A
863629f65bf151afa0b37bc3485ec37c9dcea84d
Disable logging until optional
changes_lxc_wrapper/cli/wrapper.py
changes_lxc_wrapper/cli/wrapper.py
#!/usr/bin/env python3 import argparse import logging import sys from raven.handlers.logging import SentryHandler from threading import Thread from uuid import UUID from ..api import ChangesApi from ..container import Container from ..log_reporter import LogReporter DESCRIPTION = "LXC Wrapper for running Changes j...
Python
0.000001
@@ -3646,24 +3646,26 @@ %0A + # self.patch_
6da77c8ae7d16e2afc24f0b0e906fe5ff86ef6fd
put the destory in the right place
channelguide/guide/views/submit.py
channelguide/guide/views/submit.py
from django.conf import settings from channelguide import util from channelguide.guide import forms from channelguide.guide.auth import login_required from channelguide.guide.models import Channel SESSION_KEY = 'submitted-feed' def destroy_submit_url_session(request): if SESSION_KEY in request.session: d...
Python
0.99976
@@ -3322,102 +3322,29 @@ -destroy_submit_url_session(request)%0A return util.redirect(settings.BASE_URL_FULL + +return util.redirect( %22sub @@ -3857,16 +3857,56 @@ cribe'%5D%0A + destroy_submit_url_session(request)%0A def
fb19411797ae7ac00e022a9409459c0f42969a91
Remove unused code
backend/api/helpers/i18n.py
backend/api/helpers/i18n.py
from typing import Optional from django.conf import settings from django.utils import translation def make_localized_resolver(field_name: str): def resolver(root, info, language: Optional[str] = None) -> str: language = language or translation.get_language() or settings.LANGUAGE_CODE return geta...
Python
0.000006
@@ -379,321 +379,4 @@ ver%0A -%0A%0Adef make_dict_localized_resolver(field_name: str):%0A def resolver(root, info, language: Optional%5Bstr%5D = None) -%3E str:%0A language = language or translation.get_language() or settings.LANGUAGE_CODE%0A field = getattr(root, field_name)%0A return field.ge...
2af841027c17256964ce92b0459d32a9c210e357
remove unneeded check
mythril/analysis/solver.py
mythril/analysis/solver.py
from z3 import Solver, simplify, sat, unknown, FuncInterp, UGE from mythril.exceptions import UnsatError from mythril.laser.ethereum.transaction.transaction_models import ( ContractCreationTransaction, ) import logging def get_model(constraints): s = Solver() s.set("timeout", 100000) for constraint i...
Python
0.000001
@@ -2697,16 +2697,45 @@ d.name() +%0A logging.warn(d.name) %0A%0A @@ -3015,92 +3015,103 @@ -tx_id = name.replace(%22caller%22, %22%22)%0A if not tx_id in creation_tx_ids:%0A +# caller is 'creator' for creation transactions%0A tx_id = name.replace(%22caller%22, %22%22)%0A ...
77a53584062e0a0b51d972b1fe08b2efa12b90a8
Remove get_notebook_list function
nbgrader/html/formgrade.py
nbgrader/html/formgrade.py
import json import os import glob from flask import Flask, request, abort, redirect, url_for, render_template app = Flask(__name__, static_url_path='/static') def get_notebook_list(): suffix = ".autograded.html" notebooks = glob.glob(os.path.join(app.notebook_dir, "*{}".format(suffix))) notebooks = [os.p...
Python
0.000031
@@ -18,20 +18,8 @@ t os -%0Aimport glob %0A%0Afr @@ -147,248 +147,8 @@ )%0A%0A%0A -def get_notebook_list():%0A suffix = %22.autograded.html%22%0A notebooks = glob.glob(os.path.join(app.notebook_dir, %22*%7B%7D%22.format(suffix)))%0A notebooks = %5Bos.path.split(x)%5B1%5D%5B:-len(suffix)%5D for x in notebook...
8054d460bd22c8301d234f8165f906b5b60c34c6
Fix incorrect data being sent in judge_flask
judge/judge_flask.py
judge/judge_flask.py
from flask import * import threading import lcm import forseti2 as fs2 import sys sys.path.append('../src') import settings import util import time import datetime app = Flask(__name__) @app.route('/') def serve_console(): return render_template('judge_console.html') @app.route('/clock') def serve_clock(): r...
Python
0.000563
@@ -2566,36 +2566,36 @@ m.gold_total, m. -blue +gold _autonomous_poin
3f8be6be92c69acb71f1fbff2510fcbc2d9d6bf6
move topic when there is no ns
june/models/topic.py
june/models/topic.py
# coding: utf-8 from datetime import datetime from werkzeug import cached_property from ._base import db, JuneQuery from ..markdown import rich_markdown from .account import Account from .node import Node, NodeStatus __all__ = ['Topic', 'Reply'] class Topic(db.Model): query_class = JuneQuery id = db.Colum...
Python
0.000002
@@ -2181,19 +2181,21 @@ -pre +node1 = Node. @@ -2226,19 +2226,21 @@ -pre +node1 .topic_c @@ -2272,19 +2272,21 @@ ion.add( -pre +node1 )%0A @@ -2287,22 +2287,19 @@ -pre_ ns +1 = NodeS @@ -2408,22 +2408,19 @@ -pre_ ns +1 .topic_c @@ -2456,14 +2456,11 @@ add( -pre_ ...
91b51267f0290ebfaf09da3d2e2ff385a2dc7ce7
Test api user detail endpoint with delete method is not public
billjobs/tests/tests_api.py
billjobs/tests/tests_api.py
from django.urls import reverse from django.test import TestCase from django.contrib.auth.models import User from rest_framework import status from rest_framework.test import APIClient class APIStatusCode(TestCase): """ Test user API response status code """ fixtures=['test_api_user.yaml'] def se...
Python
0.000001
@@ -5084,28 +5084,387 @@ atus.HTTP_401_UNAUTHORIZED)%0A +%0A def test_api_user_detail_delete_is_not_public(self):%0A %22%22%22%0A Test api user detail endpoint with DELETE method is not public%0A Anonymous user can not delete an user instance%0A %22%22%22%0A response = self.client...
b3c41e891252504954dcf08d1cfe909375af63be
Add alias for gettext as underscore to fix graders with translated msgs.
grader_support/run.py
grader_support/run.py
#!/usr/bin/env python """ Run a set of tests on a submission, printing the outputs to stdout as a json string. Note: this command will run student code, so should be run in a sandbox, or (and!) the code should be sanitized first. Because this just runs the code on various sample inputs, and does not have answers, bad...
Python
0
@@ -915,16 +915,34 @@ UAGE%5D%0A)%0A +_ = trans.gettext%0A trans.in
4563e383962690cc196f4551f217d488501b660e
support for mysql as well
bin/count_users_in_rooms.py
bin/count_users_in_rooms.py
import sys import os import yaml import redis import psycopg2 dino_env = sys.argv[1] dino_home = sys.argv[2] if dino_home is None: raise RuntimeError('need environment variable DINO_HOME') if dino_env is None: raise RuntimeError('need environment variable DINO_ENVIRONMENT') def load_secrets_file(config_dic...
Python
0
@@ -43,24 +43,8 @@ dis%0A -import psycopg2%0A %0A%0Adi @@ -1143,16 +1143,31 @@ type'%5D%0A%0A +the_count = 0%0A%0A if dbtyp @@ -1180,16 +1180,60 @@ rdbms':%0A + dbdriver = config%5B'database'%5D%5B'driver'%5D%0A dbna @@ -1427,28 +1427,84 @@ word'%5D%0A%0A -try: +if dbdriver.startswith('postgres'):%0A ...
952a342cc160f7b994e7a06c7836d1319414a30e
Fix bitcointxn.disassemble so it actually works
bitcointxn.py
bitcointxn.py
from bitcoinvarlen import varlenDecode, varlenEncode from util import dblsha from struct import pack, unpack _nullprev = b'\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0' class Txn: def __init__(self, data=None): if data: self.data = data self.idhash() @classmethod def new(cls): o = c...
Python
0.000001
@@ -954,24 +954,27 @@ %09%09(sigScript +Len , data) = va @@ -1021,24 +1021,27 @@ a%5B:sigScript +Len %5D%0A%09%09%09seqno = @@ -1068,16 +1068,19 @@ igScript +Len :sigScri @@ -1077,24 +1077,27 @@ en:sigScript +Len + 4%5D)%5B0%5D%0A%09%09 @@ -1118,16 +1118,19 @@ igScript +Len + 4:%5D%0A%09 @@ -1235,37 +1235,2...
33acc8d495e5a71a6d8ef99162920d5076e40db5
shorten the text in the wordpress post button
blog/admin.py
blog/admin.py
from django.contrib import admin from django.core.urlresolvers import reverse from django.utils.html import format_html from django.conf.urls import url from django import forms from django.http import HttpResponseRedirect from django.template.response import TemplateResponse from mptt.admin import MPTTModelAdmin fro...
Python
0.999999
@@ -2120,23 +2120,8 @@ View - Wordpress Post %3C/a%3E
81de62d46d7daefb2e1eef0d0cc4f5ca5c8aef2f
Use GCBV queryset to get PostGetMixin obj.
blog/utils.py
blog/utils.py
from django.shortcuts import get_object_or_404 from .models import Post class PostGetMixin: date_field = 'pub_date' month_url_kwarg = 'month' year_url_kwarg = 'year' errors = { 'url_kwargs': "Generic view {} must be called with " "year, month, and slug.", } d...
Python
0
@@ -116,16 +116,33 @@ b_date'%0A + model = Post%0A mont @@ -318,16 +318,81 @@ slug.%22,%0A + 'not_exist':%0A %22No %7B%7D by that date and slug.%22,%0A %7D%0A%0A @@ -1090,63 +1090,380 @@ -return get_object_or_404(%0A Post, **filter_dict) +if queryset is None:%0A ...
146dc2567b7349c807fbef3b2c812c04c46d7525
Fix abbreviation test on nix
keyboard/keyboard.py
keyboard/keyboard.py
# -*- coding: utf-8 -*- import time import platform if platform.system() == 'Windows': from. import winkeyboard as os_keyboard else: from. import nixkeyboard as os_keyboard from .keyboard_event import KeyboardEvent, KEY_DOWN, KEY_UP, normalize_name from .generic import GenericListener _pressed_events = {...
Python
0.000024
@@ -7667,24 +7667,25 @@ ation('tm', +u '%E2%84%A2')%0A inp
2b419d499c37597094379f524d8347f35eeda57c
Fix tinycss css validator
src/checker/plugin/checkers/tinycss_css_validator_plugin.py
src/checker/plugin/checkers/tinycss_css_validator_plugin.py
from common import PluginType import tinycss from yapsy.IPlugin import IPlugin import logging class CssValidator(IPlugin): category = PluginType.CHECKER id = "tinycss" def __init__(self): self.journal = None def setJournal(self, journal): self.journal = journal def...
Python
0.000209
@@ -456,16 +456,135 @@ page3')%0A + c = transaction.getContent()%0A if type(c) == str:%0A data = c%0A else:%0A
08f9575a0de95432729cbf1a9649148998030e17
fix error output on windows (#50)
cmake/legacy/wafstyleout.py
cmake/legacy/wafstyleout.py
#!/usr/bin/env python import subprocess import sys import os import argparse def unicodeWrite(out, str): try: out.write(str) except UnicodeEncodeError: bytes = str.encode(out.encoding or 'ascii', 'replace') if hasattr(sys.stdout, 'buffer'): out.buffer.write(bytes) e...
Python
0
@@ -70,16 +70,32 @@ argparse +%0Aimport platform %0A%0Adef un @@ -2393,16 +2393,18 @@ str = u' +%7B%7D %5B%7B%7D (%7B%7D) @@ -2440,16 +2440,64 @@ .format( +'%5Cn' if platform.system() == 'Windows' else '', src_str,
b4764268302c71481e6a9194b4def0617b7af74d
version 0.4.1
cmscloud_client/__init__.py
cmscloud_client/__init__.py
# -*- coding: utf-8 -*- __version__ = '0.4.0'
Python
0.000002
@@ -36,11 +36,11 @@ = '0.4. -0 +1 '%0A
04a255e5747a76cbc4a29626a3ecc23dd23b42b3
Add stop words dictionary
code/helper/dictionaries.py
code/helper/dictionaries.py
#! /usr/bin/env python3 from helper.easierlife import BASE_DIR # Load an example dictionary # First column is doc id, second is sentence id, third is entity def load_examples_dictionary(filename): examples = set() with open(filename, 'rt') as examples_dict_file: for line in examples_dict_file: ...
Python
0.999373
@@ -2564,16 +2564,84 @@ sf.tsv%22%0A +STOPWORDS_DICT_FILENAME = BASE_DIR + %22/dicts/english_stopwords.tsv%22%0A POS_GENE @@ -3458,32 +3458,96 @@ NAME, load_set%5D%0A +dictionaries%5B%22stopwords%22%5D = %5BSTOPWORDS_DICT_FILENAME, load_set%5D%0A dictionaries%5B%22po
6f926d405028c849192003dfec46401728850bde
Fix the isdict_containing matcher to be ordered when checking
src/hamcrest/library/collection/isdict_containingentries.py
src/hamcrest/library/collection/isdict_containingentries.py
from hamcrest.core.base_matcher import BaseMatcher from hamcrest.core.helpers.hasmethod import hasmethod from hamcrest.core.helpers.wrap_matcher import wrap_matcher __author__ = "Jon Reid" __copyright__ = "Copyright 2011 hamcrest.org" __license__ = "BSD, see License.txt" class IsDictContainingEntries(BaseMatcher): ...
Python
0.000005
@@ -383,16 +383,23 @@ chers = +sorted( value_ma @@ -404,16 +404,25 @@ matchers +.items()) %0A%0A de @@ -748,32 +748,47 @@ %0A for key +, value_matcher in self.value_m @@ -1362,61 +1362,8 @@ n)%0A%0A - value_matcher = self.value_matchers%5Bkey%5D%0A @@ -2116,16 +2116,23 @@ , index, +...
88dd48eab612e89b956dea5600a999c78c61d5fb
fix lpproj algorithm
lpproj/lpproj.py
lpproj/lpproj.py
import numpy as np from sklearn.neighbors import kneighbors_graph from sklearn.utils import check_array from sklearn.base import BaseEstimator, TransformerMixin class LocalityPreservingProjection(BaseEstimator, TransformerMixin):: def __init__(self, n_neighbors=5, n_components=2, eigen_solver='auto', ...
Python
0.000012
@@ -12,16 +12,42 @@ y as np%0A +from scipy import linalg%0A%0A from skl @@ -84,16 +84,34 @@ rs_graph +, NearestNeighbors %0Afrom sk @@ -268,17 +268,16 @@ rMixin): -: %0A def @@ -391,12 +391,30 @@ uto' +, kernel_width=None ):%0A -%0A @@ -584,16 +584,57 @@ lgorithm +%0A self.kernel_width = kernel...
8e58d7cccb837254cc433c7533bff119cc19645d
Use json instead of django.utils.simplejson.
javascript_settings/templatetags/javascript_settings_tags.py
javascript_settings/templatetags/javascript_settings_tags.py
from django import template from django.utils import simplejson from javascript_settings.configuration_builder import \ DEFAULT_CONFIGURATION_BUILDER register = template.Library() @register.tag(name='javascript_settings') def do_javascript_settings(parser, token): """ Returns a node with generated c...
Python
0
@@ -1,31 +1,16 @@ -from django import template +import json%0A %0Afro @@ -21,22 +21,16 @@ ango -.utils import simp @@ -25,26 +25,24 @@ import -simplejson +template %0A%0Afrom j @@ -661,14 +661,8 @@ ' + -simple json
afafb47d77fd673abf8d8ce9baa9824b985a943a
Add create_class_wrapper and class_wrapper
undecorate.py
undecorate.py
"""Allow your decorations to be un-decorated. In some cases, such as when testing, it can be useful to access the decorated class or function directly, so as to not to use the behavior or interface that the decorator might introduce. Example: >>> from functools import wraps >>> from undecorate import unwrap, unwrapp...
Python
0.000021
@@ -788,16 +788,25 @@ rt wraps +, partial %0A%0A%0Adef u @@ -1443,16 +1443,2041 @@ ation%0A%0A%0A +CLASS_WRAPPER_DELETES = ('__dict__', '__doc__', '__weakref__')%0ACLASS_WRAPPER_ASSIGNMENTS = ('__module__',)%0A%0A%0Adef create_class_wrapper(wrapper,%0A wrapped,%0A dele...
fd8cf4ec0705df9df192d66f444a927109da17c7
Use f-string
src/python/grpcio_tests/tests_aio/unit/timeout_test.py
src/python/grpcio_tests/tests_aio/unit/timeout_test.py
# Copyright 2020 The gRPC 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 License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writ...
Python
0.001188
@@ -3048,16 +3048,17 @@ return +f 'localho @@ -3064,18 +3064,15 @@ ost: -%25d' %25 +%7B port +%7D' , se
551c4b971f1d18e232ba193cf486300d3490224b
add log
api/photo2song.py
api/photo2song.py
import asyncio from collections import Counter from api.bluemix_vision_recognition import VisionRecognizer from api.echonest import Echonest from api.spotify import Spotify from machines.machine_loader import MachineLoader import machines.photo_mood def convert(image_urls): vr = VisionRecognizer() ec = Echone...
Python
0.000002
@@ -553,16 +553,29 @@ ebrate'%5D +%0A log = %5B%5D %0A%0A # @@ -588,16 +588,59 @@ e moode%0A + log.append(%22begin vision recognition%22)%0A mood @@ -955,16 +955,60 @@ om mood%0A + log.append(%22begin search song by mood%22)%0A trac @@ -1142,16 +1142,62 @@ fy(sp)%0A%0A + log.append(%22beg...
c59c0911c5022291b38774bf407ca83557c78cc5
test login and logout views.
user/tests.py
user/tests.py
from django.test import TestCase class ViewsTest(TestCase): """ TestCase to test all exposed views for anonymous users. """ def setUp(self): pass def testHome(self): response = self.client.get('/user/') self.assertEquals(response.status_code, 200) def testLogin(self)...
Python
0
@@ -352,16 +352,21 @@ t.get('/ +user/ login/') @@ -483,16 +483,21 @@ t.get('/ +user/ logout/'
c6536da7fc1eda82922b286c096412e4371f6d4c
Bump version
graphysio/__init__.py
graphysio/__init__.py
"""Graphical time series visualizer and analyzer.""" __version__ = '2021.07.14' __all__ = [ 'algorithms', 'dialogs', 'exporter', 'legend', 'mainui', 'puplot', 'tsplot', 'utils', 'types', 'ui', 'transformations', ]
Python
0
@@ -72,16 +72,18 @@ 21.07.14 +.1 '%0A%0A__all
23cdb0d62e44797f84aee61f1a4c2909df8221b0
Fix settings import and add an option to DjangoAppEngineMiddleware to allow setting up of signals on init
main/__init__.py
main/__init__.py
import logging import os def validate_models(): """ Since BaseRunserverCommand is only run once, we need to call model valdidation here to ensure it is run every time the code changes. """ from django.core.management.validation import get_validation_errors try: from cStringIO import...
Python
0
@@ -17,16 +17,65 @@ mport os +%0Afrom django.utils.importlib import import_module %0A%0Adef va @@ -887,42 +887,8 @@ ()%0A%0A -from django.conf import settings%0A%0A clas @@ -942,16 +942,37 @@ elf, app +, setup_signals=False ):%0A @@ -1107,16 +1107,405 @@ _env()%0A%0A + from django.conf import setting...
7b2e39a19865e72510f818033727a25ed2c7bf3a
Add function to create symlinks to npm/bower package dirs outside of the project git repo
blues/node.py
blues/node.py
""" Node.js Blueprint ================= **Fabric environment:** .. code-block:: yaml blueprints: - blues.node settings: node: # version: latest # Install latest node version packages: # List of npm packages to install (Optional) # - coffee-script ...
Python
0
@@ -350,16 +350,28 @@ ss%0A%0A%22%22%22%0A +import json%0A import o @@ -448,16 +448,8 @@ t cd -, prefix %0Afro @@ -688,22 +688,8 @@ ath, - project_home, %5C%0A @@ -4947,12 +4947,649 @@ ive=false')%0A +%0A%0Adef create_symlinks(npm_path='../node_modules',%0A bower_path='../bower_components'):...
e4ad2863236cd36e5860f1d17a06ca05e30216d5
Store more stuff about songs in the queue
make_database.py
make_database.py
import sqlite3 CREATE_SONG_QUEUE = ''' CREATE TABLE IF NOT EXISTS jukebox_song_queue ( spotify_uri TEXT, has_played INTEGER DEFAULT 0 ); ''' if __name__ == '__main__': conn = sqlite3.connect('jukebox.db') cursor = conn.cursor() cursor.execute(CREATE_SONG_QUEUE) conn.commit() conn.close...
Python
0
@@ -137,16 +137,160 @@ EFAULT 0 +,%0A name TEXT,%0A artist_name TEXT,%0A artist_uri TEXT,%0A artist_image TEXT,%0A album_name TEXT,%0A album_uri TEXT,%0A album_image TEXT %0A);%0A'''%0A
43712c77f58ba49bbb34e1f1a6f6df8b993f7a39
Fix MSA agent.
bioagents/msa/msa_module.py
bioagents/msa/msa_module.py
import os import sys import re import pickle import requests import logging from kqml import KQMLPerformative from indra.sources.trips.processor import TripsProcessor from bioagents import Bioagent logging.basicConfig(format='%(levelname)s: %(name)s - %(message)s', level=logging.INFO) logger = ...
Python
0.000001
@@ -42,24 +42,8 @@ kle%0A -import requests%0A impo @@ -53,16 +53,16 @@ logging%0A + %0Afrom kq @@ -145,16 +145,45 @@ rocessor +%0Afrom indra import has_config %0A%0Afrom b @@ -357,37 +357,8 @@ )%0A%0A%0A -from indra import has_config%0A if h @@ -409,16 +409,17 @@ g('INDRA +_ DB_REST_ @@ -437,36 +437,17 @@ ...
fd83aaa43e5ae59555ce8c259365d22adeb7bd90
Include results_file among dubins_traffic parameters
domains/dubins_traffic/trial-runner.py
domains/dubins_traffic/trial-runner.py
#!/usr/bin/env python """Run trials and collect results for the Problem domain: Traffic network of Dubins cars. """ from __future__ import print_function import argparse import random import json import tempfile import subprocess import os import sys from time import gmtime, strftime from fmrb import dubins_traffic ...
Python
0
@@ -331,16 +331,27 @@ slaunch( +trialconf, worldsdf @@ -371,25 +371,37 @@ d_path, -trialconf +results_filename=None ):%0A n @@ -998,16 +998,205 @@ _path)%0A%0A + if results_filename is not None:%0A results_path = os.path.abspath(results_filename)%0A output += ' %3Cparam name=%22dubins_traffi...
8ff38f6eed889b2e5ab2bb04279fe57e8743bf0a
move input tools to vertical row
bokeh_plot.py
bokeh_plot.py
from bokeh.io import vform from bokeh.models import CustomJS, ColumnDataSource from bokeh.models import Select, Button #, MultiSelect from bokeh.plotting import Figure, output_file, save import shutil # import pandas as pd # Usage: import do_a_plot and feed it a table # currently takes Pandas DataFrame as input; have...
Python
0
@@ -115,23 +115,24 @@ tton - #, MultiSelect +, HBox, VBoxForm %0Afro @@ -180,16 +180,44 @@ le, save +%0Afrom bokeh.io import curdoc %0A%0Aimport @@ -1356,18 +1356,18 @@ t_width= +6 5 -0 0, plot_ @@ -1373,18 +1373,18 @@ _height= +6 5 -0 0)%0A%09scat @@ -2881,32 +2881,251 @@ =main_callback)%0A +%09select_c = S...
939ba609e6e7a527ef3325c4dd5b0a51c97d1af9
fix #29
djangocms_reversion2/signals.py
djangocms_reversion2/signals.py
# -*- coding: utf-8 -*- from django.db.models import signals def make_page_version_dirty(page, language): pv = page.page_versions.filter(active=True, language=language) if pv.count() > 0: pv = pv.first() if not pv.dirty: pv.dirty = True pv.save() def mark_title_dirt...
Python
0.000001
@@ -17,16 +17,75 @@ f-8 -*-%0A +from cms.operations import REVERT_PAGE_TRANSLATION_TO_LIVE%0A from dja @@ -113,16 +113,16 @@ signals%0A - %0A%0A%0A%0Adef @@ -1411,24 +1411,809 @@ pass%0A%0A%0A +def handle_page_reverted_to_live(**kwargs):%0A page = kwargs.get('obj')%0A translation = kwargs.get('translat...
70448c7f4ea132376a6d3547edb99ec616501171
Implement Gref#parents in terms of Gref#direct_parents
groundstation/gref.py
groundstation/gref.py
import os import groundstation.objects.object_factory as object_factory from groundstation.objects.update_object import UpdateObject from groundstation.objects.root_object import RootObject import logger log = logger.getLogger(__name__) class Gref(object): def __init__(self, store, channel, identifier): ...
Python
0.002283
@@ -2131,18 +2131,21 @@ rents = -%5B%5D +set() %0A @@ -2145,26 +2145,27 @@ -for tip in +this_iter = (tips o @@ -2178,17 +2178,16 @@ .tips()) -: %0A @@ -2191,190 +2191,105 @@ - obj = object_factory.hydrate_object(self.store%5Btip%5D.data)%0A if isinstance(obj, UpdateObj...
f3195d0d41232c7655250dea15ba4ecbe1a7b036
append http:// if protocol is missing, sanitize the return value
Commands/Slurp.py
Commands/Slurp.py
# -*- coding: utf-8 -*- """ Created on Aug 31, 2015 @author: Tyranic-Moron """ from IRCMessage import IRCMessage from IRCResponse import IRCResponse, ResponseType from CommandInterface import CommandInterface from Utils import WebUtils from bs4 import BeautifulSoup class Slurp(CommandInterface): triggers = ['...
Python
0.000015
@@ -72,16 +72,44 @@ oron%0A%22%22%22 +%0Aimport HTMLParser%0Aimport re %0A%0Afrom I @@ -471,16 +471,58 @@ n url%22%0A%0A + htmlParser = HTMLParser.HTMLParser()%0A%0A def @@ -890,16 +890,103 @@ %5B2:%5D))%0A%0A + if not re.match(ur'%5E%5Cw+://', url):%0A url = u%22http://%7B%7D%22.format(u...
d475bf4da5af06e6b40e51e8d14df3fe31b5491b
Define a function for python version check
bindings/python-examples/sentence-check.py
bindings/python-examples/sentence-check.py
#!/usr/bin/env python """ Demo: Find unlinked or unknown words. These demo is extremely simplified. It can only work with link-grammar library version >= 5.3.10. Input: English sentences, one per line. Output: If there are any []-marked words in the linkage results, the output contains unique combinations of the input ...
Python
0.999478
@@ -1134,67 +1134,36 @@ g)%0A%0A -get_input = input%0A# If this is Python 2, use raw_input()%0Aif +def is_python2():%0A return sys @@ -1181,26 +1181,20 @@ fo%5B: -2%5D %3C +1%5D = = (2, - 7):%0A +)%0A%0A get_ @@ -1210,16 +1210,43 @@ aw_input + if is_python2() else input %0A%0Adef ns @@ -5225,32 +5225,19 ...
ed97f1cdbcc5a00c2bf597ad921b17da652b0b07
add annotations to _pytesttester.py
bottleneck/_pytesttester.py
bottleneck/_pytesttester.py
""" Generic test utilities. Based on scipy._libs._testutils """ from __future__ import division, print_function, absolute_import import os import sys __all__ = ["PytestTester"] class PytestTester(object): """ Pytest test runner entry point. """ def __init__(self, module_name): self.modul...
Python
0.000002
@@ -63,94 +63,62 @@ %22%22%0A%0A -from __future__ import division, print_function, absolute_import%0A%0Aimport os%0Aimport sys +import os%0Aimport sys%0Afrom typing import Optional, List %0A%0A%0A_ @@ -260,17 +260,30 @@ ule_name -) +: str) -%3E None :%0A @@ -361,17 +361,24 @@ label -= +: str = %22fast%2...
16ddf7225bab12bf373bb7d5251713d58c7616c5
support linux mint package manager
lib/dotinstall/packages.py
lib/dotinstall/packages.py
import logging import re import sys from dotinstall import util logger = logging.getLogger(__name__) class CygwinPackageInstaller: name = "cygwin" @property def supported(self): return util.has_executable("apt-cyg") def has_installed(self, package): return ( len(util.ru...
Python
0.000001
@@ -630,32 +630,464 @@ l%22, package%5D)%0A%0A%0A +class AptPackageInstaller:%0A name = %22apt%22%0A%0A @property%0A def supported(self):%0A return util.has_executable(%22apt%22)%0A%0A def has_installed(self, package):%0A return util.run_silent(%5B%22dpkg%22, %22-l%22, package%5D)%5B0%5D%0A%0...
d333135c42b43a7d55acbc3c34a12cc7c4fbc40f
replace write_log func with logging module and upto Python3
Dailyv2ex/v2ex.py
Dailyv2ex/v2ex.py
#!/usr/bin/env python # coding:utf-8 import re import sys import logging import requests from bs4 import BeautifulSoup def _log(): logging.basicConfig(level=logging.DEBUG, filename='V2EX.log', format='[%(levelname)s]: [%(asctime)s]: %(message)s', ...
Python
0.000002
@@ -1252,35 +1252,28 @@ ogin.text, ' -html.parser +lxml ')%0A u @@ -1843,35 +1843,28 @@ html.text, ' -html.parser +lxml ')%0A e @@ -2625,19 +2625,12 @@ t, ' -html.parser +lxml ')%0A
b0da39d309d0ca348f608e4954dc7cd23e75e02c
change default keystone service to httpd
packstack/plugins/keystone_100.py
packstack/plugins/keystone_100.py
# -*- coding: utf-8 -*- """ Installs and configures Keystone """ import logging import uuid from packstack.installer import validators from packstack.installer import processors from packstack.installer import basedefs from packstack.installer import utils from packstack.modules.ospluginutils import (getManifestTem...
Python
0.000001
@@ -4162,24 +4162,21 @@ ALUE%22: %22 -keystone +httpd %22,%0A
075c06a6360d8b88745e3bffd4883beead36c59b
Add orders_script
config_example.py
config_example.py
CHROMEDRIVER_PATH = '/usr/lib/chromium-browser/chromedriver' FACEBOOK = { 'email': '', 'password': '', } HIPMENU = { 'restaurant_url': 'https://www.hipmenu.ro/#p1/rg/cluj-prod/group/98254//', } SKYPE = { 'username': '', 'password': '', 'conversation_title': '', } NEXMO = { 'api_key': '',...
Python
0.000001
@@ -386,8 +386,648 @@ = True%0A +%0Aorders_script = %22%22%22%0Avar orders = %5B%5D;%0Avar my_name = document.querySelector('#h-profilename').textContent;%0Avar name_tags = Array.prototype.slice.call(document.querySelectorAll('.container-white-rounded .header-left p'));%0Avar price_tags = Array.prototype.slice.call(d...
60890b614132a8cfd48be3e001114275752e9ac4
fix typo
megnet/config.py
megnet/config.py
"""Data types""" import numpy as np import tensorflow as tf DTYPES = {'float32': {'numpy': np.float32, 'tf': tf.float32}, 'float16': {'numpy': np.float16, 'tf': tf.float16}, 'int32': {'numpy': np.int32, 'tf': tf.int32}, 'int16': {'numpy': np.int32, 'tf': tf.int32}} class DataType: ...
Python
0.999991
@@ -262,34 +262,34 @@ %7B'numpy': np.int -32 +16 , 'tf': tf.int32 @@ -286,18 +286,18 @@ : tf.int -32 +16 %7D%7D%0A%0A%0Acla
2b622f2f0675581b63837bff568858b27a19a4a3
Move golden ratio as global variable.
latexipy/latexipy.py
latexipy/latexipy.py
''' Automatically change matplotlib figures to LaTeX figures. ''' from contextlib import contextmanager import errno import logging import math from pathlib import Path import sys import warnings import matplotlib.pyplot as plt logger = logging.getLogger('latexipy') INCH_PER_POINT = 1/72.27 MAX_HEIGHT_INCH = 8 F...
Python
0
@@ -291,16 +291,55 @@ 1/72.27%0A +GOLDEN_RATIO = (math.sqrt(5)-1.0)/2.0%0A%0A MAX_HEIG @@ -350,17 +350,16 @@ NCH = 8%0A -%0A FONT_SIZ @@ -3007,80 +3007,32 @@ -golden_mean = (math.sqrt(5)-1.0)/2.0%0A fig_ratio = golden_mean +fig_ratio = GOLDEN_RATIO %0A
5eb2c6f7e1bf0cc1b73b167a08085fccf77974fe
Tidy up and doc-comment AWSInstanceEnv class
app/config/aws.py
app/config/aws.py
from boto import ec2, utils import credstash class AWSIntanceEnv(object): def __init__(self): metadata = utils.get_instance_metadata() self.instance_id = metadata['instance-id'] self.region = metadata['placement']['availability-zone'][:-1] conn = ec2.connect_to_region(self.region...
Python
0
@@ -1,8 +1,102 @@ +# -*- coding: utf-8 -*-%0A%22%22%22%0ADictionary-like class for config settings from AWS credstash%0A%22%22%22%0A%0A from bot @@ -679,41 +679,47 @@ ble= -%22credential-store%22, context=None, +None, context=None, profile_name=None): %0A @@ -723,24 +723,28 @@ +%22%22%22%0A ...
9642b8f3d2f14b3a61054f68f05f4ef8eaca0803
add validation
molo/core/management/commands/add_translated_pages_to_pages.py
molo/core/management/commands/add_translated_pages_to_pages.py
from __future__ import absolute_import, unicode_literals from django.core.management.base import BaseCommand from molo.core.models import PageTranslation, SiteLanguage, Page class Command(BaseCommand): def handle(self, *args, **options): # first add all the translations to the main language Page ...
Python
0.000001
@@ -1638,16 +1638,50 @@ 2, 3%5D):%0A + if page.language:%0A @@ -1742,32 +1742,36 @@ + for translated_p @@ -1773,24 +1773,54 @@ ted_page in +%5C%0A page.specifi @@ -1845,16 +1845,20 @@ .all():%0A + @@ -1947,16 +1947,20 @@ ...
cb4c91e3d109c939236f9581691f837fa0709108
Delete manage hackathon detail router
open-hackathon-client/src/client/views/route_manage.py
open-hackathon-client/src/client/views/route_manage.py
# -*- coding: utf-8 -*- """ Copyright (c) Microsoft Open Technologies (Shanghai) Co. Ltd.  All rights reserved. The MIT 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 res...
Python
0
@@ -1579,233 +1579,8 @@ )%0A%0A%0A -# get registered user list of a hackathon%0A%0A# @app.route(%22/manage/%3Chackathon_name%3E%22)%0A# @login_required%0A# def hackathon_manage_detail(hackathon_name):%0A# return render(%22/manage/detail.html%22, hackathon_name=hackathon_name)%0A%0A%0A @app
58d7592c603509f2bb625e4e2e5cb31ada4a8194
Change test for make_kernel(kerneltype='airy') from class to function
astropy/nddata/convolution/tests/test_make_kernel.py
astropy/nddata/convolution/tests/test_make_kernel.py
# Licensed under a 3-clause BSD style license - see LICENSE.rst import numpy as np from numpy.testing import assert_allclose, assert_equal from ....tests.helper import pytest from ..make_kernel import make_kernel try: import scipy HAS_SCIPY = True except ImportError: HAS_SCIPY = False class TestMakeKern...
Python
0.000001
@@ -121,22 +121,8 @@ lose -, assert_equal %0A%0Afr @@ -285,93 +285,8 @@ se%0A%0A -class TestMakeKernel(object):%0A %22%22%22%0A Test the make_kernel function%0A %22%22%22%0A%0A @pyt @@ -318,20 +318,16 @@ SCIPY')%0A - def test @@ -336,31 +336,19 @@ iry( -self ):%0A - - %22%22%22%0A - ...
e7647da318b2fc5f973080446882347a287aec3a
use same cache for custom domain redirect
openedx/core/djangoapps/appsembler/sites/middleware.py
openedx/core/djangoapps/appsembler/sites/middleware.py
from django.conf import settings from django.core.cache import cache from django.contrib.redirects.models import Redirect from django.shortcuts import redirect from .models import AlternativeDomain import logging log = logging.getLogger(__name__) class CustomDomainsRedirectMiddleware(object): def process_reque...
Python
0
@@ -61,17 +61,25 @@ rt cache +, caches %0A - from dja @@ -336,25 +336,66 @@ , request):%0A + cache_general = caches%5B'general'%5D %0A - host @@ -617,32 +617,40 @@ m_domain = cache +_general .get(cache_key)%0A @@ -980,16 +980,16 @@ in = %22%22%0A - @@ -993,32 +993,40 @@ cac...
21850d8ab44981b2bb02cb50386db717aacc730b
Fix poor coverage
paystackapi/tests/test_product.py
paystackapi/tests/test_product.py
import httpretty from paystackapi.tests.base_test_case import BaseTestCase from paystackapi.product import Product class TestProduct(BaseTestCase): @httpretty.activate def test_product_create(self): """Method defined to test product creation.""" httpretty.register_uri( httpretty....
Python
0.002037
@@ -1292,36 +1292,37 @@ to test Product -list +fetch method.%22%22%22%0A @@ -1708,37 +1708,38 @@ ef test_product_ -fetch +update (self):%0A @@ -1766,36 +1766,38 @@ to test Product -list +update method.%22%22%22%0A
c11b5b2181434651e1979c6db328ba81ed19566d
Add debug to see why test-meson-helloworld.
meson_install.py
meson_install.py
#!/usr/bin/env python3 # Copyright 2015 wink saville # # 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 ...
Python
0
@@ -1389,16 +1389,56 @@ try:%0A + print('dst_dir =', dst_dir)%0A @@ -1476,32 +1476,64 @@ self.args.app)%0A + print('dst =', dst)%0A outp @@ -1636,118 +1636,368 @@ -if output is None:%0A output = b''%0A except BaseException as err:%0A ...
9c0ab20e62f8eb67001dcd165b55d30cf2f912c7
add refresh in update_ui_lang
wxbreads/utils.py
wxbreads/utils.py
#!/usr/bin/env python # -*- coding: utf-8 -*- from __future__ import unicode_literals, division import time from datetime import datetime import wx import wx.richtext as rt import windbreads.utils as wdu RTC_ALIGNS = dict(default=wx.TEXT_ALIGNMENT_DEFAULT, left=wx.TEXT_ALIGNMENT_LEFT, ...
Python
0.000001
@@ -5488,16 +5488,30 @@ ang(self +, refresh=True ):%0A i @@ -5849,8 +5849,116 @@ label))%0A +%0A if refresh:%0A if getattr(self, 'panel'):%0A self.panel.Layout()%0A%0A self.Refresh()%0A
396fbb31fdfe212da9c531e5aa6240c554f0d86f
Refactor logging to use recommended pylint format
xboxapi/client.py
xboxapi/client.py
#-*- coding: utf-8 -*- import requests import logging import json import os # Local libraries from .gamer import Gamer import xboxapi logging.basicConfig() class Client(object): def __init__(self, api_key=None, timeout=None, lang=None): self.api_key = api_key self.timeout = timeout s...
Python
0
@@ -719,29 +719,16 @@ .getenv( -%0A 'XBOXAPI @@ -754,16 +754,16 @@ ng.INFO%0A + @@ -1689,30 +1689,24 @@ .debug(' -%7B%7D %7B%7D'.format( +%25s %25s', 'GET', u @@ -1700,33 +1700,32 @@ %25s', 'GET', url) -) %0A self.lo @@ -1745,35 +1745,29 @@ eaders: -%7B%7D'.format( +%25s', heade...
460c89f57875e06427ad15759065c219a600044e
Add missing import
byceps/blueprints/ticketing_admin/views.py
byceps/blueprints/ticketing_admin/views.py
""" byceps.blueprints.ticketing_admin.views ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ :Copyright: 2006-2018 Jochen Kupperschmidt :License: Modified BSD, see LICENSE for details. """ from flask import abort, g, redirect, request, url_for from ...services.party import service as party_service from ...services.shop.order...
Python
0.000466
@@ -449,32 +449,67 @@ ticket_service, + ticket_user_checkin_service, %5C%0A ticket_user_man
2726ec1c400a212b1cac13f20d65c1b43eb042b0
Fix formatting in download-google-smart-card-client-library.py
example_js_standalone_smart_card_client_app/download-google-smart-card-client-library.py
example_js_standalone_smart_card_client_app/download-google-smart-card-client-library.py
#!/usr/bin/env python # Copyright 2017 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 ...
Python
0.999998
@@ -1925,26 +1925,24 @@ ile__):%0A - output_file_ @@ -1962,18 +1962,16 @@ h.join(%0A - @@ -2040,18 +2040,16 @@ else:%0A - outp
83549f9549a253fb7a86e8c051bd24fab91a0f5f
Make the output a little better
conda_build/main_inspect.py
conda_build/main_inspect.py
# (c) Continuum Analytics, Inc. / http://continuum.io # All Rights Reserved # # conda is distributed under the terms of the BSD 3-clause license. # Consult LICENSE.txt or http://opensource.org/licenses/BSD-3-Clause. from __future__ import absolute_import, division, print_function import sys import argparse from colle...
Python
0.999998
@@ -1194,16 +1194,24 @@ print( +%22%25s:%22 %25 dep)%0A @@ -1232,16 +1232,23 @@ path in +sorted( depmap%5Bd @@ -1250,16 +1250,17 @@ map%5Bdep%5D +) :%0A @@ -1272,16 +1272,18 @@ print(%22 + %25s =%3E
ff9e3c6ef604a47a616e111ee2a90fda77692977
Bump version to 3.3.2
src/jukeboxmaya/__init__.py
src/jukeboxmaya/__init__.py
__author__ = 'David Zuber' __email__ = 'zuber.david@gmx.de' __version__ = '3.3.1' STANDALONE_INITIALIZED = None """After calling :func:`init` this is True, if maya standalone has been initialized or False, if you are running from within maya. It is None, if initialized has not been called yet. """
Python
0.000002
@@ -76,9 +76,9 @@ 3.3. -1 +2 '%0A%0A%0A
94abb4f44fe9965053990265f79e0dc0356c2bad
Add default for bear_dirs
coalib/collecting/BearCollector.py
coalib/collecting/BearCollector.py
""" 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 version. This program is distributed in the hope that it will be useful, but WITHOUT...
Python
0
@@ -733,16 +733,72 @@ llector%0A +from coalib.misc.StringConstants import StringConstants%0A from coa @@ -953,32 +953,68 @@ bear_dirs +=%5BStringConstants.coalib_bears_root%5D ,%0A
a9c7a6e441159bdf1fd13d70bcc91617dee93f03
revert revert.
lib/kodi65/selectdialog.py
lib/kodi65/selectdialog.py
# -*- coding: utf8 -*- # Copyright (C) 2015 - Philipp Temminghoff <phil65@kodi.tv> # This program is Free Software see LICENSE file for details import xbmcgui import xbmc from kodi65 import addon C_LIST_SIMPLE = 3 C_LIST_DETAIL = 6 C_BUTTON_GET_MORE = 5 C_LABEL_HEADER = 1 class SelectDialog(xbmcgui.WindowXMLDialo...
Python
0.00001
@@ -814,100 +814,8 @@ e()%0A - elif len(self.listitems) == 1:%0A self.index == 0%0A self.close()%0A
7a83a9be7e2a986979cc898c3fd3aa3bb49442cc
modify dx model
cea/technologies/direct_expansion_units.py
cea/technologies/direct_expansion_units.py
# -*- coding: utf-8 -*- """ direct expansion units """ from __future__ import division from scipy.interpolate import interp1d from math import log, ceil import pandas as pd from cea.constants import HEAT_CAPACITY_OF_WATER_JPERKGK __author__ = "Shanshan Hsieh" __copyright__ = "Copyright 2015, Architecture and Building...
Python
0
@@ -167,16 +167,35 @@ s as pd%0A +import numpy as np%0A from cea @@ -597,11 +597,9 @@ = 1. -373 +6 #US @@ -695,9 +695,9 @@ = 2. -7 +3 %0A%0A @@ -751,24 +751,95 @@ , T_re_K):%0A%0A + if np.isclose(mdot_kgpers, 0.0):%0A%0A wdot_W = 0%0A else:%0A q_chw_W @@ -907,16 +907,20 @@ sup_K)%0A%0A...
8b359d97e59d759bfd7711c8aacf9abc657fe457
fix demo
pipeline/demo/pipeline-homo-data-split-demo.py
pipeline/demo/pipeline-homo-data-split-demo.py
from pipeline.component.homo_data_split import HomoDataSplit from pipeline.backend.config import Backend from pipeline.backend.config import WorkMode from pipeline.backend.pipeline import PipeLine from pipeline.component.dataio import DataIO from pipeline.component.input import Input from pipeline.interface.data impor...
Python
0
@@ -1645,368 +1645,8 @@ %7D)%0A%0A -# predict%0A%0Apipeline.predict(backend=Backend.EGGROLL, work_mode=WorkMode.STANDALONE,%0A feed_dict=%7Binput_0:%0A %7B%22guest%22: %7B9999: guest_train_data%7D,%0A %22host%22: %7B%0A 10000...
7ad707e722eabefc989cfa41fbf17c8315d948fd
Add optional parameters for Django fields.
oauth2client/django_orm.py
oauth2client/django_orm.py
# Copyright (C) 2010 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writ...
Python
0
@@ -962,32 +962,49 @@ def db_type(self +, connection=None ):%0A return 'V @@ -1380,24 +1380,41 @@ db_type(self +, connection=None ):%0A retur
ed48555984886ff5ade23aeb23ad5f85e77e5b69
fix docs
chainercv/transforms/image/pca_lighting.py
chainercv/transforms/image/pca_lighting.py
import numpy def pca_lighting(img, sigma, eigen_value=None, eigen_vector=None): """Alter the intensities of input image using PCA. This is used in training of AlexNet [Krizhevsky]_. .. [Krizhevsky] Alex Krizhevsky, Ilya Sutskever, Geoffrey E. Hinton. \ ImageNet Classification with Deep Convolutional...
Python
0.000001
@@ -812,26 +812,27 @@ ImageNet -is +are used.%0A @@ -1004,18 +1004,19 @@ mageNet -is +are used.%0A%0A
6f04f1ed35635c08836f1eee67983abf9735f5db
handle more exceptions
channelstream/wsgi_views/error_handlers.py
channelstream/wsgi_views/error_handlers.py
from pyramid.view import exception_view_config @exception_view_config(context='marshmallow.ValidationError', renderer='json') def marshmallow_invalid_data(context, request): request.response.status = 422 return context.messages @exception_view_config(context='itsdangerous.BadTimeSignature', renderer='json')...
Python
0.000002
@@ -310,24 +310,101 @@ rer='json')%0A +@exception_view_config(context='itsdangerous.BadSignature', renderer='json')%0A def itsdange
155fd9ae952a4eba53521739589d5e3462108ed2
remove default statement per Gunther's comment
chatterbot/ext/django_chatterbot/models.py
chatterbot/ext/django_chatterbot/models.py
from django.db import models class Statement(models.Model): """A short (<255) chat message, tweet, forum post, etc""" text = models.CharField( unique=True, blank=False, null=False, default='<empty>', max_length=255 ) def __str__(self): if len(self.text...
Python
0
@@ -213,35 +213,8 @@ se,%0A - default='%3Cempty%3E',%0A
4d81c88627b0f71c765112b9a814fe876239bcc5
Print stats for constant points to.
src/main/copper/analysis.py
src/main/copper/analysis.py
import os from .project import ProjectManager from .analysis_steps import * from .analysis_stats import AnalysisStatisticsBuilder as StatBuilder class Analysis(object): def __init__(self, config, projects=ProjectManager()): self.logger = logging.getLogger(__name__) self._config = config se...
Python
0
@@ -1875,32 +1875,95 @@ var-points-to')%0A + .count('constant_points_to', 'constant-points-to')%0A .cou
76ec40ba3bcdd6805ac043d5cf3298ba312a15d7
Make sure Scatter Redistribute takes only one constraint
op_scatter/scatter_func.py
op_scatter/scatter_func.py
# ##### BEGIN GPL LICENSE BLOCK ##### # # JewelCraft jewelry design toolkit for Blender. # Copyright (C) 2015-2020 Mikhail Rachinskiy # # 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, eith...
Python
0
@@ -1438,16 +1438,17 @@ obs = %5B +%5D %0A @@ -1456,38 +1456,26 @@ - (ob, con, con.offset)%0A +app = obs.append%0A%0A @@ -1516,16 +1516,17 @@ _objects +: %0A @@ -1559,17 +1559,20 @@ straints -%0A +:%0A @@ -1571,32 +1571,34 @@ + if con.type == %22 @...
ffe5b45cc1040357d517e63a7e46fe64705f60d1
Enable test (#17585)
python/ray/experimental/workflow/tests/test_virtual_actor_3.py
python/ray/experimental/workflow/tests/test_virtual_actor_3.py
import pytest import ray from ray import workflow from typing import Optional, Dict, Tuple, List @ray.workflow.virtual_actor class InventoryPrice: def __init__(self): self._prices: Dict[str, float] = {} @ray.workflow.virtual_actor.readonly def get_price(self, name) -> Optional[float]: re...
Python
0
@@ -3730,8 +3730,96 @@ (5, %5B%5D)%0A +%0A%0Aif __name__ == %22__main__%22:%0A import sys%0A sys.exit(pytest.main(%5B%22-v%22, __file__%5D))%0A
97dcb530c92d7f62eb69e5bea7696b8733cb326f
Fix StringIO call
src/crammit/__init__.py
src/crammit/__init__.py
############################################################################### # # Copyright (c) 2012 Ruslan Spivak # # 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, inc...
Python
0.00001
@@ -3414,17 +3414,8 @@ r = -StringIO. Stri