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
aae737d4af1093249e36783d3f86d39e08de8761
use m3u8 entry protocol for m3u8 formats(closes #27400)
youtube_dl/extractor/slideslive.py
youtube_dl/extractor/slideslive.py
# coding: utf-8 from __future__ import unicode_literals from .common import InfoExtractor from ..utils import ( bool_or_none, smuggle_url, try_get, url_or_none, ) class SlidesLiveIE(InfoExtractor): _VALID_URL = r'https?://slideslive\.com/(?P<id>[0-9]+)' _TESTS = [{ # video_service_nam...
Python
0
@@ -3105,16 +3105,130 @@ ter.%25s'%0A + # use %60m3u8%60 entry_protocol until EXT-X-MAP is properly supported by %60m3u8_native%60 entry_protocol%0A @@ -3343,27 +3343,8 @@ 8'), - service_id, 'mp4', %0A @@ -3364,35 +3364,24 @@ -entry_protocol='m3u8_native +service_id, 'mp4 ', m
53e8c14d774131503dbdefe6528cd1e26adbf30b
Allow Travis to load tests and use azure-storage installed from pip at the same time
azure_nosetests.py
azure_nosetests.py
#!/usr/bin/env python import os.path, nose, glob, sys packages = [os.path.dirname(p) for p in glob.glob('azure*/setup.py')] sys.path += packages nose.main()
Python
0
@@ -47,16 +47,31 @@ lob, sys +, pkg_resources %0Apackage @@ -153,16 +153,135 @@ packages +%0A# Declare it manually, because %22azure-storage%22 is probably installed with pip%0Apkg_resources.declare_namespace('azure') %0A%0Anose.m
e56340f53c3acfc628644c90237cec249eea5c9c
add volunteer changes
volunteer.py
volunteer.py
from user import User from db import Base, Session from sqlalchemy import * from sqlalchemy.orm import relation, sessionmaker, relationship from sqlalchemy import ForeignKey import json from flask import json import itertools from datetime import datetime, date import enums from enums import EducationEnum from voluntee...
Python
0
@@ -1293,16 +1293,130 @@ enum%22))%0A + birthdate = Column(Date)%0A bio = Column(String(10000))%0A gender = Column(Enum('Male', 'Female', 'Other'))%0A %0A%0A @c @@ -2062,64 +2062,8 @@ one, -%0A birthdate=None, bio=None, gender=None, uho @@ -2116,16 +2116,55 @@ ion=None +, birthdate=Non...
c13445cc54b96b2524ea9df71e892d2fe6c8c34a
Make sure warning messages are logged on stdout
azurectl/logger.py
azurectl/logger.py
# Copyright (c) 2015 SUSE Linux GmbH. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable la...
Python
0.000002
@@ -1007,24 +1007,33 @@ d level INFO +, WARNING and DEBUG c @@ -1141,16 +1141,29 @@ lno in ( +%0A logging. @@ -1176,21 +1176,47 @@ logging. -DEBUG +WARNING, logging.DEBUG%0A )%0A%0A%0Aclas
de39815661cc8627e7b99b187936c23c0da68768
Bump version to 0.6.9
namebench.py
namebench.py
#!/usr/bin/env python # Copyright 2009 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
@@ -1109,17 +1109,17 @@ = '0.6. -8 +9 '%0A%0A# Det
270298cce11e90f7f8c0cc2f06b7ddbbfaad9f6b
Test the default URL shortener backend
zinnia/tests/test_url_shortener.py
zinnia/tests/test_url_shortener.py
"""Test cases for Zinnia's url_shortener""" import warnings from django.test import TestCase from zinnia.url_shortener import get_url_shortener from zinnia import url_shortener as us_settings from zinnia.url_shortener.backends.default import backend as default_backend class URLShortenerTestCase(TestCase): """Te...
Python
0.000001
@@ -225,50 +225,23 @@ ends -.default import backend as default_backend + import default %0A%0A%0Ac @@ -709,33 +709,33 @@ tener(), default -_ +. backend)%0A @@ -1180,33 +1180,33 @@ tener(), default -_ +. backend)%0A @@ -1578,17 +1578,17 @@ default -_ +. backend) @@ -1831,87 +1831,699 @@ %22%22%22...
270b2f9be8a3c5a191f77252d49fdd09925430d7
Fix missing type
rpmvenv/extensions/core.py
rpmvenv/extensions/core.py
"""Extension which accounts for the core RPM metadata fields.""" from __future__ import division from __future__ import absolute_import from __future__ import print_function from __future__ import unicode_literals from confpy.api import Configuration from confpy.api import IntegerOption from confpy.api import Namespa...
Python
0.999999
@@ -1977,32 +1977,65 @@ res=ListOption(%0A + option=StringOption,%0A desc @@ -2117,32 +2117,65 @@ des=ListOption(%0A + option=StringOption,%0A desc
4f490d6b4a85e4aeecf73a8f9f65ba1b562780f6
truncate win percentage
i3pystatus/dota2wins.py
i3pystatus/dota2wins.py
from dota2py import api from i3pystatus import IntervalModule class Dota2wins(IntervalModule): """ Displays the win/loss ratio of a given Dota account. Requires: dota2py """ settings = ( ("matches", "Number of recent matches to calculate"), ("steamid", "Steam ID or username to tra...
Python
0
@@ -3999,16 +3999,65 @@ ercent,%0A + %22win_percent%22: %22%25.2f%22 %25 win_percent,%0A
c87a1cbe903ef45acc7342ad9b2809ef61338429
Add fixes from Makespace
tone_matrix.py
tone_matrix.py
# tone_matrix.py 20/10/2016 D.J.Whale # # The main application of the tone matrix demonstration import user_interface import matrix import tones from Timer import Timer #----- CONFIG ----------------------------------------------------------------- DEFAULT_BPM = 159 # must be longer than the longest sample lengt...
Python
0
@@ -2090,17 +2090,22 @@ _change( -j +str(j) + %22,%22 + @@ -2105,17 +2105,22 @@ + %22,%22 + -i +str(i) + %22,0%22) @@ -3183,16 +3183,16 @@ ell( -col, row +row, col , st
cc32a7b1b40c54c98fb3bceda8f9bb3b3bea243a
Fix dst_ssh
specchio/main.py
specchio/main.py
#!/usr/bin/env python # -*- coding: utf-8 -*- import sys import time from watchdog.observers import Observer from specchio.handlers import SpecchioEventHandler from specchio.utils import init_logger, logger def main(): """Main function for specchio Example: specchio test/ user@host:test/ :return: Non...
Python
0.000002
@@ -602,19 +602,18 @@ ssh=dst_ -pat +ss h, dst_p
ff6f29f1f7084a326fb3d4f24806ba373e07736a
Use syspaths
salt/spm/pkgfiles/roots.py
salt/spm/pkgfiles/roots.py
# -*- coding: utf-8 -*- ''' This module allows SPM to use the local filesystem (``file_roots``) to install files for SPM. .. versionadded:: 2015.8.0 ''' from __future__ import absolute_import import os import os.path import logging # Get logging started log = logging.getLogger(__name__) def init(**kwargs): '''...
Python
0.000001
@@ -226,16 +226,37 @@ logging +%0Aimport salt.syspaths %0A%0A# Get @@ -1685,34 +1685,40 @@ th.join( -'/', 'etc', 'salt' +salt.syspaths.CONFIG_DIR , new_na @@ -2834,40 +2834,32 @@ h = -os.path.join('/', 'etc', 'salt') +salt.syspaths.CONFIG_DIR %0A%0A
328bcfc13a74e92105977590b180ef1acfd5a292
Update string format
fluxghost/http_handler.py
fluxghost/http_handler.py
import os from http.server import BaseHTTPRequestHandler from urllib.parse import urlparse from urllib.request import Request from urllib.request import urlopen import logging from fluxghost.http_websocket_route import get_match_ws_service from fluxghost import __version__ from io import StringIO import subprocess im...
Python
0.000003
@@ -1681,17 +1681,16 @@ r.debug( -f 'Start h @@ -1702,16 +1702,26 @@ ng GET %7B +%7D'.format( self.pat @@ -1721,18 +1721,17 @@ elf.path -%7D' +) )%0A
39ef94c4fc76930964b9635cc6fadeefbf8510c6
Update init
bamboo/__init__.py
bamboo/__init__.py
from core import wrap import bamboo.groups import bamboo.frames import bamboo.plotting __all__ = ['core', 'plotting', 'frames', 'groups', 'modeling']
Python
0
@@ -15,79 +15,9 @@ ort -wrap%0A%0Aimport bamboo.groups%0Aimport bamboo.frames%0Aimport bamboo.plotting%0A +* %0A%0A__ @@ -36,20 +36,8 @@ re', - 'plotting', 'fr
e0e5e662e950973e8a79ae876cc91119b91d9122
Update hoomd.md documentation
hoomd/md/__init__.py
hoomd/md/__init__.py
# Copyright (c) 2009-2019 The Regents of the University of Michigan # This file is part of the HOOMD-blue project, released under the BSD 3-Clause # License. """ Molecular Dynamics Perform Molecular Dynamics simulations with HOOMD-blue. .. rubric:: Stability :py:mod:`hoomd.md` is **stable**. When upgrading from ver...
Python
0
@@ -322,16 +322,16 @@ ion -2 +3 .x to -2 +3 .y (
54d6d76fc485b32fc14dec49c2e53a4bed3114cc
Add base tests
twext/who/test/test_aggregate.py
twext/who/test/test_aggregate.py
## # Copyright (c) 2013 Apple Inc. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or...
Python
0.000001
@@ -1736,8 +1736,99 @@ zzy'%3E%22)%0A +%0A%0A%0Aclass DirectoryServiceRealmTest(BaseTest, test_xml.DirectoryServiceRealmTest):%0A pass%0A
3a0b67d0f9407bdfad6c2c3bc5fed33532c7aa0a
handle not aggreagtion
bamboo/models/calculation.py
bamboo/models/calculation.py
from celery.task import task from bamboo.core.calculator import Calculator from bamboo.core.frame import DATASET_ID from bamboo.lib.async import call_async from bamboo.lib.exceptions import ArgumentError from bamboo.lib.schema_builder import make_unique from bamboo.models.abstract_model import AbstractModel class De...
Python
0.000091
@@ -1528,21 +1528,27 @@ ulation. -group +aggregation is not
9fe4f21b7b5ba557101d05fc8b50aa898738c5c9
Add -fPIC flag to compile. Needed for 64bits architecture.
pythran/interface.py
pythran/interface.py
'''This module contains all the stuff to make your way from python code to a dynamic library * cxx_generator transforms a python module to c++ code * compile transforms c++ code into a native module ''' import sys import os.path import distutils.sysconfig from cxxgen import * import ast from middlend import re...
Python
0
@@ -4822,16 +4822,47 @@ python') +%0A tc.ldflags.append('-fPIC') %0A%0A tc
2e922bbf0a4a0635ee0d9d5ecfac83da9ab0d702
Bump version
taggit_serializer/__init__.py
taggit_serializer/__init__.py
__version__ = '0.1.1'
Python
0.000024
@@ -12,10 +12,10 @@ = '0.1. -1 +2 '
f303fdb51c9dd94d0f929efaa7c845bb3c9a96bd
Make sure to output a string date
txircd/modules/rfc/cmd_whowas.py
txircd/modules/rfc/cmd_whowas.py
from twisted.plugin import IPlugin from twisted.words.protocols import irc from txircd.config import ConfigValidationError from txircd.module_interface import Command, ICommand, IModuleData, ModuleData from txircd.utils import durationToSeconds, ircLower, now, timestamp from zope.interface import implements from dateti...
Python
0.999999
@@ -3675,16 +3675,20 @@ rver%22%5D, +str( datetime @@ -3720,16 +3720,17 @@ when%22%5D)) +) %0A%09%09user.
67ce236814d5b8984fd0fa8353c3770c34fe54d5
clean up
hotdoc/core/links.py
hotdoc/core/links.py
# -*- coding: utf-8 -*- # # Copyright © 2015,2016 Mathieu Duponchelle <mathieu.duponchelle@opencreed.com> # Copyright © 2015,2016 Collabora Ltd # # This library is free software; you can redistribute it and/or modify it under # the terms of the GNU Lesser General Public License as published by the Free # Software Found...
Python
0
@@ -2403,16 +2403,8 @@ lver -(object) :%0A @@ -2431,24 +2431,25 @@ ana%0A %22%22%22%0A +%0A def __in @@ -4527,24 +4527,25 @@ n elink%0A +%0A elif not @@ -4536,18 +4536,16 @@ -el if not o
8fe79a52e8ad892296efc424bc44b434f9599d54
Use Memory Workspace
Scripts/DensityToVector.py
Scripts/DensityToVector.py
# -------------------------------- # Name: DensityToVector.py # Purpose: This script is intended to help aid the network/vector analysis process by computing weighted kernel densities on # list of incoming fields which represent weights for the KDE estimation. These estimations are then joined back to # a network featu...
Python
0
@@ -3070,27 +3070,24 @@ orkspace = %22 -in_ memory%22%0A @@ -3105,27 +3105,24 @@ t_sample = %22 -in_ memory/sampl @@ -3165,19 +3165,16 @@ ints = %22 -in_ memory/s
e26d6a17f82b253192a32d4684d1cf1618a1d49c
remove pandas import which is no longer needed, statsmodels accepts arrays as data
quantecon/estspec.py
quantecon/estspec.py
""" Filename: estspec.py Authors: Thomas Sargent, John Stachurski Functions for working with periodograms of scalar data. """ from __future__ import division, print_function import numpy as np from numpy.fft import fft from pandas import DataFrame import statsmodels.api as sm def smooth(x, window_len=7, window='h...
Python
0
@@ -220,37 +220,8 @@ fft%0A -from pandas import DataFrame%0A impo
55a93554e207854eb8f6202511f708cc267d2fab
verify True not true
toolset/run-tests.py
toolset/run-tests.py
#!/usr/bin/env python import argparse import ConfigParser import sys import os from pprint import pprint from benchmark.benchmarker import Benchmarker from setup.linux.unbuffered import Unbuffered ################################################################################################### # Main ##############...
Python
0.999999
@@ -3227,33 +3227,33 @@ host', required= -t +T rue, help='The a @@ -3321,33 +3321,33 @@ host', required= -t +T rue, help='The c @@ -3432,25 +3432,25 @@ ', required= -t +T rue, help='T @@ -3567,17 +3567,17 @@ equired= -t +T rue, des
0f5794bc369ea0039a5219fbc19323a522bd412e
Fix topology
topology/__init__.py
topology/__init__.py
from abc import * class Topology(ABCMeta): @abstractmethod def __init__(self): self.bonds = None self.angles = None self.
Python
0.000014
@@ -148,9 +148,25 @@ self. +dihedrals = None %0A
366a85f4bf98b60d6b6e5a38d9f6f833fba50086
delete organization owners when deleting an organization
bauble/model/organization.py
bauble/model/organization.py
from sqlalchemy import * from sqlalchemy.orm import * import sqlalchemy.event as event import bauble import bauble.db as db import bauble.types as types class Organization(db.SystemBase): __tablename__ = 'organization' name = Column(String) short_name = Column(String) # pg_user and pg_schema should ...
Python
0.000001
@@ -583,32 +583,62 @@ tionship('User', + cascade=%22all, delete-orphan%22, primaryjoin=%22an
0032c42fd5ab8c79d45587a3f1b9ff721d124701
Fix for PHP rendering (closes #1676). However, there seems to be too much space before (2 empty lines) and after (3 empty lines) the rendered code. Maybe a CSS issue?
trac/mimeview/php.py
trac/mimeview/php.py
# -*- coding: iso8859-1 -*- # # Copyright (C) 2005 Edgewall Software # Copyright (C) 2005 Christian Boos <cboos@bct-technology.com> # Copyright (C) 2005 Christopher Lenz <cmlenz@gmx.de> # # Trac is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License as # published...
Python
0.000023
@@ -2490,16 +2490,131 @@ header%0A + fst_nl = odata.find('%5Cn')%0A snd_nl = odata.find('%5Cn', fst_nl + 1)%0A odata = odata%5Bsnd_nl + 1:%5D%0A @@ -2652,24 +2652,8 @@ data -.splitlines()%5B1%5D )%0A
cf9106329c3a83fa40e171d7ea4f31ea76bef518
merge fix for #12312 from 1.0-stable
trac/tests/compat.py
trac/tests/compat.py
# -*- coding: utf-8 -*- # # Copyright (C) 2013 Edgewall Software # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. The terms # are also available at http://trac.edgewall.org/wiki/TracLicense. # # This software consists o...
Python
0.000001
@@ -650,16 +650,28 @@ ort sys%0A +import time%0A import u @@ -3004,16 +3004,25 @@ excinfo +, retry=1 ):%0A @@ -3366,21 +3366,296 @@ -function(path +try:%0A function(path)%0A except Exception:%0A # print %22%25d: %25s %25o%22 %25 (retry, path, os.stat(path).st_mod...
d01a7c63ab577a54213c956fb3de4b8d82323797
Add Heirloom and Artifact item quality.
battlenet/enums.py
battlenet/enums.py
RACE = { 1: 'Human', 2: 'Orc', 3: 'Dwarf', 4: 'Night Elf', 5: 'Undead', 6: 'Tauren', 7: 'Gnome', 8: 'Troll', 9: 'Goblin', 10: 'Blood Elf', 11: 'Draenei', 22: 'Worgen', 24: 'Pandaren', 25: 'Pandaren', 26: 'Pandaren', } CLASS = { 1: 'Warrior', 2: 'Palad...
Python
0
@@ -575,16 +575,54 @@ ndary',%0A + 6: 'Artifact',%0A 7: 'Heirloom',%0A %7D%0A%0ARACE_
741989719b1f84938b0367968ade81757d3710fd
Handle tags
bdd_tester/core.py
bdd_tester/core.py
from gherkin.parser import Parser as GherkinParser import six from .exceptions import StepException, UnknownStepException if six.PY3: from importlib.machinery import SourceFileLoader else: from imp import load_source class Feature: def __init__(self, name, tests): self.name = name self....
Python
0.000001
@@ -519,16 +519,22 @@ e, steps +, tags ):%0A @@ -579,16 +579,41 @@ = steps +%0A self.tags = tags %0A%0A de @@ -3586,16 +3586,82 @@ steps'%5D%0A + test_tags = %5Btag%5B'name'%5D%5B1:%5D for tag in test%5B'tags'%5D%5D%0A @@ -3950,16 +3950,27 @@ e, steps +, test_tags ))%0A
ba3029c82f3ddc431368148d34670ebe1fee652f
Update parse_output_gi.py
benchmark/parse_output_gi.py
benchmark/parse_output_gi.py
# ---------------------------------------------------------------------------- # Copyright (c) 2015--, The WGS-HGT Development Team. # # Distributed under the terms of the Modified BSD License. # # The full license is in the file COPYING.txt, distributed with this software. # -------------------------------------------...
Python
0.000011
@@ -887,34 +887,28 @@ gb. -interval_metadata.features +metadata%5B'FEATURES'%5D :%0A
8e4e2b07cae070d034a5ea91769dfc5dad28ce3e
Handle 79 character limit
troposphere/utils.py
troposphere/utils.py
import time def _tail_print(e): print("%s %s %s" % (e.resource_status, e.resource_type, e.event_id)) def get_events(conn, stackname): """Get the events in batches and return in chronological order""" next = None event_list = [] while 1: events = conn.describe_stack_events(stackname, next...
Python
0.000007
@@ -565,16 +565,25 @@ _time=5, +%0A include
9bfdecf9c104667bbaf923a0c6c01dcaf057b379
Add summary option
benchmark/timer.py
benchmark/timer.py
""" Taken from: https://gist.github.com/acdha/4068406 """ import sys from timeit import default_timer class Timer(object): """Context Manager to simplify timing Python code Usage: with Timer('key step'): ... do something ... """ def __init__(self, context=None): self.timer...
Python
0.000052
@@ -63,16 +63,31 @@ ort sys%0A +import inspect%0A from tim @@ -307,16 +307,30 @@ ext=None +, summary=True ):%0A @@ -359,25 +359,24 @@ t_timer%0A -%0A if conte @@ -371,54 +371,59 @@ -if context is None:%0A import inspect +self.summary = summary%0A%0A if context is None: %0A ...
949d42baaa2b60481233feb5db12c8f4777ebfba
fix name
biokit/converters/bed2bam.py
biokit/converters/bed2bam.py
class BED2BAM(object): """ """ def __init__(self, infile, outfile=None, *args, **kwargs): """.. rubric:: constructor :param str filename """ pass def __call__(self): pass
Python
0.019891
@@ -10,14 +10,14 @@ ss B -ED2BAM +am2Bed (obj @@ -217,16 +217,47 @@ (self):%0A + print(%22YOUPI !!!!!! %22)%0A
6d5eea1c4447b35ec095a6830682e9d8f384c3f3
Fix boolean config options
tvrenamr/cli/core.py
tvrenamr/cli/core.py
#!/usr/bin/env python from __future__ import absolute_import import functools import logging import os import sys import click from tvrenamr import __version__, errors from tvrenamr.cli.helpers import (build_file_list, get_config, start_dry_run, stop_dry_run) from tvrenamr.logs imp...
Python
0.004873
@@ -1780,19 +1780,19 @@ default= -Tru +Non e, help= @@ -2879,24 +2879,38 @@ s_flag=True, + default=None, help=%22Creat @@ -3027,24 +3027,38 @@ s_flag=True, + default=None, help=%22Set t @@ -5792,20 +5792,19 @@ default= -Fals +Tru e,%0A
3196a8d67baa450284b0d3fa9f7de0d537ace514
Move parser error handling to main run method
tvrenamr/frontend.py
tvrenamr/frontend.py
#!/usr/bin/env python import logging import os import sys from .config import Config from .errors import * from .logs import start_logging from .main import File, TvRenamr from .options import OptionParser log = logging.getLogger('FrontEnd') def build_file_list(paths, recursive=False, ignore_filelist=()): """...
Python
0.000001
@@ -837,78 +837,26 @@ -parser.error(%22'%7B0%7D' is not a file or directory. Ruh Roe!%22.format(args) +raise IOError(glob )%0A%0A @@ -4126,16 +4126,29 @@ tcwd()%5D%0A + try:%0A file @@ -4216,16 +4216,109 @@ ilelist) +%0A except IOError as e:%0A parser.error(%22'%7B0%7D' is not a file or ...
4dd6d40bdae2dc6fae89e512000f49e6dc0cb9d9
remove pytables context manager test
blaze/tests/test_pytables.py
blaze/tests/test_pytables.py
import numpy as np import datashape as ds import pytest from toolz import first from blaze import into from blaze.utils import tmpfile from blaze.compatibility import xfail from blaze import PyTables, discover, Data tb = pytest.importorskip('tables') now = np.datetime64('now').astype('datetime64[us]') @pytest.fix...
Python
0.000002
@@ -207,14 +207,8 @@ over -, Data %0A%0A%0At @@ -4893,283 +4893,8 @@ hs%0A%0A -%0A def test_context_manager(self, dt_tb, dt_data):%0A %22%22%22 check the context manager auto-closes the resources %22%22%22%0A%0A with Data(%22%7B0%7D::dt%22.format(dt_tb)) as t:%0A f = first(t._resources()....
959652ce1bb3ac9ff54ddc5f1f7500efdc5691b0
handle async-available peers by dropping new requests when old requests are still pending; add zmqrpc.async_multicall() for calling many peers and waiting for quorum or timeout
part1/zmqrpc.py
part1/zmqrpc.py
# Conrad Meyer <cemeyer@uw.edu> # 0824410 # CSE 550 Problem Set 3 # Thu Nov 10 2011 import threading import zmq class Server(threading.Thread): def __init__(self, zctx, endpoint, obj): threading.Thread.__init__(self) self.methods = {} for x in dir(obj): if not x.startswith("_"): self.metho...
Python
0
@@ -95,16 +95,28 @@ reading%0A +import time%0A import z @@ -830,107 +830,630 @@ nt)%0A -%0A class _Call:%0A def __init__( + self._needs_recv = False%0A%0A def _unblock(self):%0A try:%0A self._socket.recv(zmq.NOBLOCK)%0A except zmq.ZMQError as e:%0A if e.errno == zmq.EAGAIN:%0A return F...
937dcf5ff0198890f438047f6644e688e32a1a3f
fix the erro with fillDict
core/robot.py
core/robot.py
#!/usr/bin/env python #-*- coding:utf-8 -*- # TODO # testar tudo isso, deveria ter usado TDD nesse projeto :( from crawl import Crawl import threading from datetime import datetime from wrapdb import Db def fillDict(valDict): """ retorna valDict com os valeres preenchidos com a respectiva data de hoje ...
Python
0.999991
@@ -51,64 +51,8 @@ O%0A# -testar tudo isso, deveria ter usado TDD nesse projeto :( %0A%0Afr @@ -190,23 +190,26 @@ retorna -valDict +dicionario com os @@ -340,31 +340,47 @@ e.now()%0A -valDict +copy = valDict%0A copy %5B%22cmbAno%22%5D = @@ -407,31 +407,28 @@ e(ano))%0A -valDict +copy %5B%22cmbMes...
f8cefa3effb761b7f7130655f4903952bd862052
Update agate requirement from <1.6.2,>=1.6 to >=1.6,<1.6.4 in /core (#3585)
core/setup.py
core/setup.py
#!/usr/bin/env python import os import sys if sys.version_info < (3, 6): print('Error: dbt does not support this version of Python.') print('Please upgrade to Python 3.6 or higher.') sys.exit(1) from setuptools import setup try: from setuptools import find_namespace_packages except ImportError: #...
Python
0.000003
@@ -1501,17 +1501,17 @@ .6,%3C1.6. -2 +4 ',%0A
3e09ee5d8e7ca3bfc8dbfc0c60d75a1044f8442b
add check user examinations test
core/tests.py
core/tests.py
# -*- coding: utf-8 -*- import datetime from core.models import Department, Examination, Scheduler, User, UserExamination, Question, Answer, UserExaminationQuestionLog, UserExaminationAnswerLog from django.test import TestCase class MainTestCase(TestCase): def test_scheduler_get_datetime_for_check_period(self):...
Python
0.000001
@@ -1413,34 +1413,32 @@ t(), 0)%0A%0A - # scheduler = Sch @@ -1472,13 +1472,34 @@ -# +department=department, exa @@ -1530,32 +1530,44 @@ unt=1, period=1, +%0A unit=Scheduler. @@ -1611,29 +1611,18 @@ -# )%0A # +)%0A %0A # s @@ -1617,18 +1617,16 @@ %0A ...
ade2883bfd37b6ae7311d66d88d3426854166a93
Allow personal commands with fetched user
app/handlers/common.py
app/handlers/common.py
from telegram import Update, Bot, ReplyKeyboardMarkup, KeyboardButton from ..models import User commands_map = { # User-related commands 'start': 'start', 'status': 'status', 'activate': 'ready', 'deactivate': 'do_not_disturb', # Commands with activities 'activity_list': 'list_activities'...
Python
0.000001
@@ -954,19 +954,59 @@ : Update -):%0A +, user=None):%0A if not user:%0A @@ -1116,16 +1116,20 @@ + defaults @@ -1180,16 +1180,20 @@ me%7D)%5B0%5D%0A +
83bffee653bddda0f3a134933ecf69bfe1c697b4
Add version table
app/packages/models.py
app/packages/models.py
from app import db import datetime class Package(db.Model): id = db.Column(db.Integer, primary_key=True) name = db.Column(db.String(255), unique=True, nullable=False) author = db.Column(db.String(50)) link = db.Column(db.String(140)) description = db.Column(db.String()) downloads = db.relation...
Python
0.000001
@@ -365,16 +365,92 @@ ynamic') +%0A version = db.relationship('Version', backref='package', lazy='dynamic') %0A%0A de @@ -590,16 +590,396 @@ unt()%0A%0A%0A +class Version(db.Model):%0A id = db.Column(db.Integer, primary_key=True)%0A number = db.Column(db.String(50), nullable=False)%0A date = db.Column...
03b2b06e90f34e67fbda1172eab2c7de6dc8246a
Update time grain expressions for Spark >= 3.x (#18690)
superset/db_engine_specs/databricks.py
superset/db_engine_specs/databricks.py
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
Python
0
@@ -965,16 +965,626 @@ neSpec%0A%0A +time_grain_expressions = %7B%0A None: %22%7Bcol%7D%22,%0A %22PT1S%22: %22date_trunc('second', %7Bcol%7D)%22,%0A %22PT1M%22: %22date_trunc('minute', %7Bcol%7D)%22,%0A %22PT1H%22: %22date_trunc('hour', %7Bcol%7D)%22,%0A %22P1D%22: %22date_trunc('day', %7Bcol%7D)%22,%0A...
a0de4f40cfe566cb57b39bca9183fe7b8412150e
add coefficient as altenative for logFC
cpv/filter.py
cpv/filter.py
""" count the number of switches in sign in the regions. Since the region calculation is based on the p-value only, it could be that a region is discovered that has both high and low t-scores. This script will output the original region_bed intervals, along with sum of positive t-scores and the sum of negative t-scores...
Python
0.000089
@@ -3896,16 +3896,136 @@ = %22NA%22%0A + if 'p' + coef_col_name not in plist%5B0%5D and 'pcoefficient' in plist%5B0%5D:%0A coef_col_name = 'coefficient' %0A
bec2dd3c92352794fc5aacb141b69f159d32552c
Fix too long line in soc.models.user module.
app/soc/models/user.py
app/soc/models/user.py
#!/usr/bin/python2.5 # # Copyright 2008 the Melange 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 applicab...
Python
0
@@ -4653,32 +4653,47 @@ s been excluded +%0A #: from using the w
faafda086dd247e128fc6834eb9b14249fe75c80
Add i18n_fastgenerate
pavelib/i18n.py
pavelib/i18n.py
""" Internationalization tasks """ import sys import subprocess from path import path from paver.easy import task, cmdopts, needs, sh try: from pygments.console import colorize except ImportError: colorize = lambda color, text: text # pylint: disable-msg=invalid-name @task @needs( "pavelib.i18n.i18n_val...
Python
0
@@ -648,32 +648,206 @@ %0A%0A sh(cmd)%0A%0A%0A +@task%0Adef i18n_fastgenerate():%0A %22%22%22%0A Compile localizable strings from sources without re-extracting strings first.%0A %22%22%22%0A cmd = %22i18n_tool generate%22%0A sh(cmd)%0A%0A%0A @task%0A@needs(%22pa
ed9294c7ab0abf574f076464274d83f1e39b53cd
Handle and log exceptions. Render Response objects.
paws/handler.py
paws/handler.py
from .request import Request from .response import response class Handler(object): ''' Simple dispatcher class. ''' def __init__(self, event, context): self.request = Request(event, context) def __call__(self, event, context): func = getattr(self, self.event['httpMethod'], self.in...
Python
0
@@ -52,16 +52,68 @@ response +, Response%0A%0Aimport logging%0Alog = logging.getLogger() %0A%0A%0Aclass @@ -356,16 +356,24 @@ Method'%5D +.lower() , self.i @@ -388,22 +388,39 @@ -return +try:%0A resp = func(se @@ -466,38 +466,548 @@ '%5D)%0A -%0A def invalid(self, *args): + except ...
09482aae793a5ca98ef2f403fafbf0d749133e53
use utility function in LoginAndDomainAuthentication
corehq/apps/api/resources/auth.py
corehq/apps/api/resources/auth.py
import json from functools import wraps from django.core.exceptions import PermissionDenied from django.http import Http404, HttpResponse, HttpResponseForbidden from tastypie.authentication import Authentication from corehq.apps.api.odata.views import odata_permissions_check from corehq.apps.domain.auth import BASIC...
Python
0
@@ -426,157 +426,23 @@ auth -,%0A basic_auth_or_try_api_key_auth,%0A digest_auth,%0A login_or_api_key,%0A login_or_basic,%0A login_or_digest,%0A login_or_oauth2,%0A oauth2 +_or_try_api_key _aut @@ -3045,470 +3045,107 @@ -if allow_session_auth:%0A self.decorator_map = %7B%0A ...
9b265049999cffca755097ea6431780517ed6788
Add scrollbar
svs_interface.py
svs_interface.py
#!/usr/bin/env python import subprocess import Tkinter import tkFileDialog import tkSimpleDialog import os import datetime GPG = 'gpg2' SERVER_KEY = '' # replace with gpg key ID of server key DECRYPTED_PREFIX = 'decrypted' class GpgApp(object): def __init__(self, master): frame = Tkinter.Frame(master) ...
Python
0.000004
@@ -16,16 +16,264 @@ python%0A%0A +%0A%22%22%22%0AA simple GPG2 interface to batch encrypt/decrypt files.%0A%22%22%22%0A%0A# TODO:%0A# * Get the user passphrase in a prompt instead of making them type it in the%0A# terminal%0A# * Make output messages more helpful%0A# * Functionality for one-click secure wipes%0A%0A%0A...
c11cba7c33ca2a8e3a5195dbb3963b26d253ccdf
Bump task schedule by 1 minute.
app/taskqueue/celery.py
app/taskqueue/celery.py
# 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 later version. # # This program is distributed in the hope that it will be usefu...
Python
0
@@ -1865,17 +1865,17 @@ (minute= -0 +1 , hour=1
8996a5a28cf23f58d48549fc0cfc3b4a8464a3a5
Change version to 0.7.6-git
sympy/release.py
sympy/release.py
__version__ = "0.7.5-git"
Python
0.000001
@@ -16,9 +16,9 @@ 0.7. -5 +6 -git
923a1697e0fa06de4a712e8cb3d344a24b53c789
add sync_date to celery tasks
syncrss/tasks.py
syncrss/tasks.py
from celery.task import task from django.db import transaction from datetime import datetime from time import mktime import feedparser from .models import ResourceRSS, RawItem @task def update_rss(): for rec in ResourceRSS.objects.filter(status=True): print rec.link try: data =feedpars...
Python
0.000007
@@ -205,17 +205,22 @@ for re -c +source in Reso @@ -260,31 +260,8 @@ e):%0A - print rec.link%0A @@ -306,17 +306,22 @@ parse(re -c +source .link)%0A @@ -331,17 +331,16 @@ -# updated_ @@ -419,24 +419,19 @@ -#sync_date = rec +if resource .syn @@ -436,17 +436,19 @@ ync_date -( + %3C...
eaf68176a5a7c972b8109c5991306df15570351a
Version up.
applitools/__init__.py
applitools/__init__.py
import glob modules = glob.glob('*.py') try: modules.remove('__init__.py') except ValueError: pass __all__ = ['utils'] + modules VERSION = '3.10.1'
Python
0
@@ -149,12 +149,12 @@ = '3.10. -1 +2 '%0A%0A
4a08db393bfbc05d5b738ce950c546e950326f51
Remove mention of Couch from docstring
corehq/apps/case_importer/util.py
corehq/apps/case_importer/util.py
import json from collections import OrderedDict, namedtuple from contextlib import contextmanager from celery import states from celery.exceptions import Ignore from django.utils.functional import cached_property from django.utils.translation import ugettext_lazy as _ from memoized import memoized from corehq.apps.ca...
Python
0
@@ -4385,19 +4385,8 @@ ase -in CouchDB by t
e374a56401c283f0d4d5df72970ce1d7a6e2788a
remove redundant version
tensorflow_datasets/image/imagewang.py
tensorflow_datasets/image/imagewang.py
# coding=utf-8 # Copyright 2020 The TensorFlow Datasets 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 appl...
Python
0.804534
@@ -2620,47 +2620,8 @@ %22%22%0A%0A - VERSION = tfds.core.Version(%222.0.0%22)%0A BU
c258b15177a1bf8d4a160a04f040a59cbacc9ec3
use get_document
corehq/apps/change_feed/pillow.py
corehq/apps/change_feed/pillow.py
from casexml.apps.case.models import CommCareCase from corehq.apps.change_feed import data_sources from corehq.apps.change_feed.connection import get_kafka_client_or_none from corehq.apps.change_feed.document_types import get_doc_meta_object_from_document, \ change_meta_from_doc_meta_and_document from corehq.apps.c...
Python
0.000001
@@ -1320,16 +1320,61 @@ try:%0A + document = change.get_document()%0A @@ -1422,23 +1422,16 @@ ocument( -change. document @@ -1558,23 +1558,16 @@ ocument= -change. document
14d487588095ea92d29e8f18b136e78eec3d8714
Fix #BB-1175
apps/accounts/admin.py
apps/accounts/admin.py
from apps.accounts.models import BlueBottleUser from django import forms from django.contrib.auth.admin import UserAdmin from django.contrib.auth.forms import ReadOnlyPasswordHashField from django.contrib import admin from django.utils.translation import ugettext_lazy as _ from .models import UserAddress class UserAd...
Python
0.000001
@@ -3721,16 +3721,29 @@ elds': ( +'user_type', 'picture @@ -4686,16 +4686,90 @@ onForm%0A%0A + list_filter = ('user_type', 'is_active', 'is_staff', 'is_superuser')%0A%0A list
48a6a50b8ab636970a562092736e1e79379b15fa
fix campaign updating and saving
apps/emailer/models.py
apps/emailer/models.py
from django.conf import settings from django.core.exceptions import ValidationError from django.core.urlresolvers import get_callable from django.db import models from greatape import MailChimp import emailer from subscriptions.models import Subscriber mailchimp = MailChimp(settings.MAILCHIMP_API_KEY) class Email(...
Python
0
@@ -2625,23 +2625,30 @@ ue=self. +mailchimp_ list -_id )%0A @@ -2776,36 +2776,295 @@ ct)%0A -content = %7B%0A +updates = %7B%0A 'list_id': self.mailchimp_list,%0A 'subject': self.subject,%0A 'from_email': settings.DEFAULT_FROM_EMAIL,%0A 'from_name': s...
fac8e7d9b6eb1f4e4644dad1b5a8e67c3659ff37
Add name to Count task and fix parsing of tasks without arguments.
vumi/scripts/vumi_redis_tools.py
vumi/scripts/vumi_redis_tools.py
# -*- test-case-name: vumi.scripts.tests.test_vumi_redis_tools -*- import sys import yaml from twisted.python import usage from vumi.persist.redis_manager import RedisManager class TaskError(Exception): """Raised when an error is encoutered while using tasks.""" class Task(object): """ A task to perfo...
Python
0
@@ -689,16 +689,63 @@ params = + %7B%7D%0A if param_desc:%0A params = cls._pa @@ -1447,32 +1447,52 @@ er of keys.%22%22%22%0A%0A + name = %22count%22%0A%0A def __init__
fc9e1adfca9d2ab347c4a73e8ae86851b9f4ca58
Remove unused import
apps/profiles/models.py
apps/profiles/models.py
# -*- coding: utf-8 -*- from datetime import datetime import pytz from django.db import models from django.contrib.auth.models import AbstractUser from django.db.models.loading import get_model from django.utils.timezone import now, get_default_timezone, make_aware from django.core.urlresolvers import reverse_lazy fr...
Python
0.000001
@@ -415,39 +415,8 @@ as _ -%0Afrom django.db.models import Q %0A%0Afr
3e3c3d27657e8b4eb9ed4ad51e093bda4fbbbaae
Add note to sending lots of messages at once
apps/messages/views.py
apps/messages/views.py
# Amara, universalsubtitles.org # # Copyright (C) 2012 Participatory Culture Foundation # # 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 op...
Python
0
@@ -4007,16 +4007,126 @@ rmance?%0A + # Once we switch to Django 1.4, this should be replaced with%0A # %60bulk_create%60.%0A
22d590393a220dca7635dc57035e3ae8e226f08a
fix 500 in pagedemo app
apps/pagedemo/views.py
apps/pagedemo/views.py
# Universal Subtitles, universalsubtitles.org # # Copyright (C) 2010 Participatory Culture Foundation # # 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...
Python
0
@@ -1176,32 +1176,49 @@ request=None):%0A + try:%0A num = re @@ -1215,16 +1215,20 @@ num = +int( request. @@ -1250,13 +1250,71 @@ ems' -, +))%0A except (ValueError, TypeError):%0A num = 30 -) %0A
22617e95a76f78b6244b6ba2e6c987874587aca9
Use specific page when populating href
wagtail/wagtailcore/rich_text.py
wagtail/wagtailcore/rich_text.py
from __future__ import absolute_import, unicode_literals import re # parsing HTML with regexes LIKE A BOSS. from django.utils.encoding import python_2_unicode_compatible from django.utils.html import escape from django.utils.safestring import mark_safe from wagtail.wagtailcore import hooks from wagtail.wagtailcore....
Python
0
@@ -1912,16 +1912,25 @@ pe(page. +specific. url))%0A
617d7fdd51c79a2f38e9ffe3be671a942f6e7b73
Improve key mappings
plugin/vimap.py
plugin/vimap.py
# -*- coding: utf-8 -*- """VIMAP python functions""" import vim import six import imap_cli from imap_cli import config from imap_cli import fetch from imap_cli import search connect_conf = config.new_context_from_file(section='imap') current_dir = 'INBOX' display_conf = { 'format_list': u'{uid:>5} ▾ {from:<...
Python
0.000333
@@ -597,16 +597,20 @@ map.list +_dir (vim.cur @@ -816,16 +816,20 @@ map.list +_dir ()%3Ccr%3E')
0d04784af151de249bbbcbad51e6e8ad9af8f5a3
Refactor the functional test
test/functional/p2p_getaddr_caching.py
test/functional/p2p_getaddr_caching.py
#!/usr/bin/env python3 # Copyright (c) 2020 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test addr response caching""" import time from test_framework.messages import ( CAddress, NODE_NETW...
Python
0.9994
@@ -248,16 +248,17 @@ rt time%0A +%0A from tes @@ -289,78 +289,8 @@ ort -(%0A CAddress,%0A NODE_NETWORK,%0A NODE_WITNESS,%0A msg_addr,%0A msg_ @@ -296,19 +296,16 @@ _getaddr -,%0A) %0Afrom te @@ -485,460 +485,89 @@ %0A)%0A%0A -MAX_ADDR_TO_SEND = 1000%0A%0Adef gen_addrs(n):%0A addrs = %5B%5D%0...
d8343fcd6cc8d3d5dc39b1305096d8768ca08c85
Add 'roll' to dice.py's commands
plugins/dice.py
plugins/dice.py
""" dice.py: written by Scaevolus 2008, updated 2009 simulates dicerolls """ import re import random from util import hook whitespace_re = re.compile(r'\s+') valid_diceroll_re = re.compile(r'^[+-]?(\d+|\d*d\d+)([+-](\d+|\d*d\d+))*$', re.I) sign_re = re.compile(r'[+-]?(?:\d*d)?\d+', re...
Python
0.001195
@@ -908,16 +908,38 @@ command%0A +@hook.command('roll')%0A def dice
0ef2bb1379c62f32076d972738f6f3fc9f9c70b7
fix tests
apps/profiles/tests.py
apps/profiles/tests.py
# Universal Subtitles, universalsubtitles.org # # Copyright (C) 2010 Participatory Culture Foundation # # 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...
Python
0.000001
@@ -1651,14 +1651,30 @@ ': ' +new_username_for_ admin -1 ',%0A
285592f6d420ab57f8d183f4068e974ee4ea3d65
Add tests for hash plugin
plugins/hash.py
plugins/hash.py
import hashlib import sys class Plugin: def on_command(self, bot, msg): if len(sys.argv) >= 2: algorithm = sys.argv[1] contents = " ".join(sys.argv[2:]) if not contents: contents = sys.stdin.read().strip() h = hashlib.new(algorithm) ...
Python
0
@@ -1,12 +1,22 @@ +import io%0A import hashl @@ -25,19 +25,24 @@ %0Aimport -sys +unittest %0A%0A%0Aclass @@ -83,16 +83,38 @@ bot, msg +, stdin, stdout, reply ):%0A @@ -123,24 +123,27 @@ if len( -sys.argv +msg%5B%22args%22%5D ) %3E= 2:%0A @@ -166,24 +166,27 @@ rithm = -sys.argv +msg%5B%22args%22%5D %5B1...
d3b389c939b6661973ee3883ae2c1bf15d3b8639
change warning to info
plugins/koth.py
plugins/koth.py
import logging log = logging.getLogger(__name__) import collections import botologist.plugin class KothPlugin(botologist.plugin.Plugin): def __init__(self, bot, channel): super().__init__(bot, channel) self.is_active = False self.signups_open = False self.queue = None @botologist.plugin.command('koth') ...
Python
0
@@ -896,23 +896,20 @@ %0A%0A%09%09log. -warning +info ('Starti @@ -2390,15 +2390,12 @@ log. -warning +info ('KO
8bd2a0058a1728a0ceaaea333041f3c984208b40
make sure Activity average uses all results, not default 10
apps/search/helpers.py
apps/search/helpers.py
from django.core.cache import cache from elasticutils import S, F from jetpack.models import Package def package_search(searchq='', user=None, score_on=None, **filters): """This provides some sane defaults to filter on when searching Packages""" # This is a filtered query, that says we want to do a query, b...
Python
0.000001
@@ -2328,21 +2328,17 @@ ng.%0A -value +q s = Pack @@ -2350,16 +2350,55 @@ earch(). +filter(activity__gt=0)%0A values = qs. values(' @@ -2407,16 +2407,29 @@ tivity') +%5B:qs.count()%5D %0A num @@ -2505,27 +2505,19 @@ lues) / -len(values) +num %0A els
c95fe320ae4b923ae0164e4dda4139e202c225a7
Remove @expectedFailure decorator as the bug has been fixed.
test/macosx/universal/TestUniversal.py
test/macosx/universal/TestUniversal.py
"""Test aspects of lldb commands on universal binaries.""" import os, time import unittest2 import lldb from lldbtest import * class UniversalTestCase(TestBase): mydir = os.path.join("macosx", "universal") def setUp(self): # Call super's setUp(). TestBase.setUp(self) # Find the line ...
Python
0.000019
@@ -427,39 +427,8 @@ ')%0A%0A - @unittest2.expectedFailure%0A
c586bfb182198d08f5a6499b0a9c01b94c2f734d
fix typo
weboob/backends/phpbb/backend.py
weboob/backends/phpbb/backend.py
# -*- coding: utf-8 -*- # Copyright(C) 2010-2011 Romain Bignon # # This file is part of weboob. # # weboob is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at you...
Python
0.999991
@@ -4202,18 +4202,14 @@ RL: -%25s/ %25s' %25 -( self @@ -4263,17 +4263,16 @@ st.id))) -) %0A
a1d95536f9c4202015c6f07ea27e97e867d2f3a4
Fix test on Python 3: vault code expects bytes
test/units/parsing/vault/test_vault.py
test/units/parsing/vault/test_vault.py
# (c) 2012-2014, Michael DeHaan <michael.dehaan@gmail.com> # # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) an...
Python
0
@@ -3390,16 +3390,17 @@ sion == +b %229.9%22%0A%0A
48a4c7f1cc801523bd8305269c115edbed7e18cb
fix bug in weibo.py
ark/exts/oauth/weibo.py
ark/exts/oauth/weibo.py
import os from flask import session from ark.exts import oauth2 weibo_oauth = oauth2.remote_app( 'weibo', consumer_key=os.environ['ARK_WEIBO_CONSUMER_KEY'], consumer_secret=os.environ['ARK_WEIBO_CONSUMER_SECRET'], request_token_params={'scope': 'email,statuses_to_me_read'}, base_url='https://api...
Python
0
@@ -634,21 +634,21 @@ on.get(' -weibo +token _token')
33379c3ef7bb0cdc81830c4d9f0436cf211e5fa9
Increments version to 0.4.1
articlequality/about.py
articlequality/about.py
__name__ = "articlequality" __version__ = "0.4.0" __author__ = "Aaron Halfaker / Morten Warncke-Wang" __author_email__ = "ahalfaker@wikimedia.org" __description__ = "A library for performing automatic detection of " + \ "assessment classes of Wikipedia articles." __url__ = "https://github.com/wikimedi...
Python
0.998666
@@ -40,17 +40,17 @@ = %220.4. -0 +1 %22%0A__auth
40299b2f5f23c63349a651725410f108ebaa7571
Revert of Make telemetry_unittests.py work on Windows (patchset #1 id:1 of https://codereview.chromium.org/647103003/)
testing/scripts/telemetry_unittests.py
testing/scripts/telemetry_unittests.py
#!/usr/bin/env python # Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import json import os import sys import common def main_run(args): filter_tests = [] if args.filter_file: filter_tests = js...
Python
0.000004
@@ -423,32 +423,8 @@ d(%5B%0A - sys.executable,%0A
4d7303b5325bf07395c4822a752fcaffad511ae8
Remove function hg_version(), was not used
wger/workout_manager/__init__.py
wger/workout_manager/__init__.py
#!/usr/bin/env python # -*- coding: utf-8 -*- """ :copyright: 2011, 2012 by OpenSlides team, see AUTHORS. :license: GNU GPL, see LICENSE for more details. """ VERSION = (1, 2, 0, 'alpha', 1) RELEASE = False def get_version(version=None, release=None): """Derives a PEP386-compliant version number from VER...
Python
0.000009
@@ -1023,1226 +1023,4 @@ sub -%0A%0A%0Adef hg_version():%0A import socket%0A import os%0A from os.path import realpath, join, dirname%0A try:%0A from mercurial import ui as hgui%0A from mercurial.localrepo import localrepository%0A from mercurial.node import short as shorthex%0A ...
69d779feee29238fb2eaf7096cc748935e21ef3d
Add blank lines and fix indenting for flake8
tests/assertions/types/classes_vows.py
tests/assertions/types/classes_vows.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # pyvows testing engine # https://github.com/heynemann/pyvows # Licensed under the MIT license: # http://www.opensource.org/licenses/mit-license # Copyright (c) 2011 Bernardo Heynemann heynemann@gmail.com from pyvows import Vows, expect class SomeClass(object): pass cl...
Python
0.000001
@@ -305,22 +305,28 @@ object): +%0A pass%0A +%0A%0A class Ot @@ -342,23 +342,28 @@ object): +%0A pass%0A%0A +%0A @Vows.ba @@ -857,36 +857,32 @@ ror_message_of(%0A - @@ -971,16 +971,16 @@ , int))%0A + %0A cla @@ -1413,36 +1413,32 @@ - 'Expected topic( @@ -...
b5afdd604831f985427880537d37eb7a35addaa1
Fix test to cater for packages leaked into venv
tests/functional/test_python_option.py
tests/functional/test_python_option.py
import json import os from pathlib import Path from venv import EnvBuilder from tests.lib import PipTestEnvironment, TestData def test_python_interpreter( script: PipTestEnvironment, tmpdir: Path, shared_data: TestData, ) -> None: env_path = os.fsdecode(tmpdir / "venv") env = EnvBuilder(with_pip=...
Python
0
@@ -263,14 +263,12 @@ s.fs -decode +path (tmp @@ -411,38 +411,40 @@ rmat=json%22)%0A -assert +before = json.loads(resu @@ -453,22 +453,189 @@ .stdout) - +%0A%0A # Ideally we would assert that before == - %5B%5D +, but there's a problem in CI%0A # that means this isn't true. See https://github.com/py...
ee9f48c7c169876fad6e7e911a4ea0c459b2c232
Make master 2.4.0
astroid/__pkginfo__.py
astroid/__pkginfo__.py
# -*- coding: utf-8 -*- # Copyright (c) 2006-2014 LOGILAB S.A. (Paris, FRANCE) <contact@logilab.fr> # Copyright (c) 2014-2018 Claudiu Popa <pcmanticore@gmail.com> # Copyright (c) 2014 Google, Inc. # Copyright (c) 2015-2017 Ceridwen <ceridwenv@gmail.com> # Copyright (c) 2015 Florian Bruhin <me@the-compiler.org> # Copyri...
Python
0.00034
@@ -941,11 +941,11 @@ %222. -3.1 +4.0 %22%0Anu
ddabfc8e54a64ebe56714d839399020b36e79b3d
Add a missing import in the curve25519 implementation
asyncssh/curve25519.py
asyncssh/curve25519.py
# Copyright (c) 2014 by Ron Frederick <ronf@timeheart.net>. # All rights reserved. # # This program and the accompanying materials are made available under # the terms of the Eclipse Public License v1.0 which accompanies this # distribution and is available at: # # http://www.eclipse.org/legal/epl-v10.html # # Cont...
Python
0.000001
@@ -529,16 +529,42 @@ import * +%0Afrom .public_key import * %0A%0A# SSH
91f4399740a6ed3dfce8218b4184fe0e597ea9ee
Make gender readonly on partners
thankyou_letters/models/res_partner.py
thankyou_letters/models/res_partner.py
# -*- coding: utf-8 -*- ############################################################################## # # Copyright (C) 2016 Compassion CH (http://www.compassion.ch) # Releasing children from poverty in Jesus' name # @author: Emanuel Cino <ecino@compassion.ch> # # The licence is in the file __manifest__.py...
Python
0.000102
@@ -888,16 +888,31 @@ .gender' +, readonly=True )%0A th
95c4496364f5acc727c8aee843e7b11275690822
Add str and equality tests for ConventionDeRegister message.
thespian/system/messages/convention.py
thespian/system/messages/convention.py
"Messages exchanged between ActorSystems that are part of a Convention" from thespian.actors import ActorSystemMessage # ---------------------------------------------------------------------- # ActorSystem interaction # # Multiple ActorSystems can interact in a Convention. All # ActorSystems that can participate in ...
Python
0
@@ -1206,16 +1206,17 @@ ' +) ' %25 self @@ -1826,16 +1826,385 @@ etattr%0A%0A + def __str__(self):%0A return 'ConventionDeRegister(adminAddress=%25(adminAddress)s' %5C%0A ', preRegistered=%25(preRegistered)s' %5C%0A ')' %25 self.__dict__%0A%0A def __eq__(self, o):%0A ...
8b5160fa45257e625ed54732e6bfc07311888a2b
Fix presubmit var rename
PRESUBMIT.py
PRESUBMIT.py
# Copyright (c) 2012 The Native Client Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. # Documentation on PRESUBMIT.py can be found at: # http://www.chromium.org/developers/how-tos/depottools/presubmit-scripts import os.path import sy...
Python
0.004335
@@ -4197,23 +4197,17 @@ ySlaves( -project +_ , change @@ -4212,24 +4212,8 @@ ge): -%0A print project %0A%0A @@ -4559,16 +4559,26 @@ s_pnacl_ +toolchain_ only:%0A
6cf3d249139500ff315c958e9a221e748e2c79e3
Enable test for git_rebase_update on Windows
PRESUBMIT.py
PRESUBMIT.py
# Copyright (c) 2012 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Top-level presubmit script for depot tools. See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts for details on the presubmit ...
Python
0
@@ -2708,50 +2708,8 @@ $',%0A - r'.*git_rebase_update_test%5C.py$',%0A
7ef2ac94e5791b7e731996688525e4c2ef861cb3
Remove shbang line from PRESUBMIT.py.
PRESUBMIT.py
PRESUBMIT.py
#!/usr/bin/env python # Copyright (c) 2012 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """grit unittests presubmit script. See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts for details on the...
Python
0.000002
@@ -1,26 +1,4 @@ -#!/usr/bin/env python%0A # Co @@ -571,16 +571,17 @@ t_api)%0A%0A +%0A def Chec
19c8d5c35a3e7a7341124f3865a3a117985e7c08
Remove protected files from talk/PRESUBMIT.py.
PRESUBMIT.py
PRESUBMIT.py
# libjingle # Copyright 2013 Google Inc. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # 1. Redistributions of source code must retain the above copyright notice, # this list of conditions and the following dis...
Python
0.000002
@@ -1426,122 +1426,8 @@ E.%0A%0A -# List of files that should not be committed to%0ADO_NOT_SUBMIT_FILES = %5B%22talk/media/webrtc/webrtcvideoengine.cc%22%5D%0A%0A def @@ -3825,467 +3825,8 @@ er%0A%0A -def _ProtectedFiles(input_api, output_api):%0A results = %5B%5D%0A changed_files = %5B%5D%0A for f in input_api....
051c14f869594ff9c7a970aa5c400c9db94f74fe
fix imports
RandomMST.py
RandomMST.py
from ass2 import create_graph if __name__ == '__main__': # size can be between 30 - 50k if len(sys.argv) < 2: print('Please input a size argument!') exit() create_graph(int(sys.argv[1]), random, None) #create_graph(int(sys.argv[1]), None, randomWithinCircle)
Python
0.000002
@@ -22,16 +22,53 @@ te_graph +%0Afrom random import random%0Aimport sys %0A%0Aif __n
074bbd8b9247d2b9619737cb6444015b8894cfe2
add jobCheckForCancellation to DBJobSource
lava_scheduler_daemon/dbjobsource.py
lava_scheduler_daemon/dbjobsource.py
import datetime import json import logging from django.core.files.base import ContentFile from django.db import connection from django.db import IntegrityError, transaction from django.db.models import Q from django.db.utils import DatabaseError from twisted.internet.threads import deferToThread from zope.interface ...
Python
0
@@ -5066,32 +5066,326 @@ rent_job = None%0A + if job.status == TestJob.RUNNING:%0A job.status = TestJob.COMPLETE%0A elif job.status == TestJob.CANCELING:%0A job.status = TestJob.CANCELED%0A else:%0A self.logger.error(%0A %22Unexpected job state in jo...
b9da4ae0096e68e4dff00c4ad90aba824e964e4d
fix parser for isomirs
mirna/genome_based_mirna_annotation/ann_parser.py
mirna/genome_based_mirna_annotation/ann_parser.py
from collections import Counter import pysam H = "seq known t5 t3 mut add correct mapped amb tool" def read_sim_fa(fn): sim = {} with open(fn) as in_handle: for line in in_handle: if line.startswith(">"): name = line.strip()[1:] sim[name] = get_name(name) ...
Python
0.000007
@@ -363,24 +363,60 @@ mapped = %7B%7D%0A + if fn_name.endswith('bam'):%0A fn = pys @@ -447,16 +447,20 @@ , 'rb')%0A + for @@ -473,16 +473,20 @@ in fn:%0A + @@ -537,24 +537,210 @@ query_name)%0A + else:%0A with open(fn_name) as in_handle:%0A for line in in_ha...
4c986e7cedde18530745dca072e06659f1fb20a9
Remove numpy.compat._pep440 from default imports
numpy/compat/__init__.py
numpy/compat/__init__.py
""" Compatibility module. This module contains duplicated code from Python itself or 3rd party extensions, which may be included for the following reasons: * compatibility * we may only need a small subset of the copied library/module """ from . import _inspect from . import _pep440 from . import py3k from ._ins...
Python
0.000001
@@ -266,30 +266,8 @@ ect%0A -from . import _pep440%0A from
14d45e22dbd7372275f5a73792c497063842b99c
add back .h5 generation
install_data.py
install_data.py
#!/usr/bin/env python from optparse import OptionParser import glob import os import subprocess import sys ################################################################################ # install_data.py # # Download and arrange pre-trained models and data. ###########################################################...
Python
0.000002
@@ -3157,82 +3157,15 @@ -'''%0A if not options.restart or not os.path.isfile('encode_roadmap.h5'): + ''' %0A @@ -3444,32 +3444,44 @@ cmd, shell=True) +%0A ''' %0A%0A # make @@ -3826,23 +3826,16 @@ l=True)%0A - ''' %0A%0A%0A#####
38e5ba04c3f1eefbbe16089b208217e32752307d
Fix a broken usage error in the client code
ikdisplay/client/tap.py
ikdisplay/client/tap.py
""" ikDisplay Live Stream service. """ from twisted.application import strports, service from twisted.python import usage from twisted.words.protocols.jabber.jid import internJID as JID from anymeta import manhole from ikdisplay import xmpp from ikdisplay.client import notifier STYLES = ('beamer', 'beamer_all', 'sc...
Python
0.000253
@@ -1499,15 +1499,28 @@ %22 %25 +(%22, %22.join( STYLES) +)) %0A%0A%0A%0A
2ae2a950e752fd971045f841ba36000d3a23845e
runInThread = True
Commands/Sed.py
Commands/Sed.py
# -*- coding: utf-8 -*- """ Created on Feb 14, 2014 @author: Tyranic-Moron """ import copy import re import sre_constants from IRCMessage import IRCMessage from IRCResponse import IRCResponse, ResponseType from CommandInterface import CommandInterface class Sed(CommandInterface): triggers = ['sed'] accepte...
Python
0.999815
@@ -344,16 +344,39 @@ CTION'%5D%0A + runInThread = True%0A %0A
cc7966022ead516869ec8479d2071ece755fabfc
Use print function, display better paths
numpylint/numpylinter.py
numpylint/numpylinter.py
#!/usr/bin/env python import os.path import tempfile from argparse import ArgumentParser from rope.base.project import Project from rope.base import libutils from rope.refactor.restructure import Restructure from numpylint.lintbits import LINTBITS def lint(filepath, proj, orig_path, opts): mod = proj.get_file(file...
Python
0.000005
@@ -15,16 +15,54 @@ python%0A +from __future__ import print_function%0A import o @@ -438,23 +438,35 @@ rint - file +('Skipping', orig_ path, ' -is +( not @@ -478,17 +478,19 @@ hon file -' +)') %0A ret @@ -493,16 +493,67 @@ return%0A + if opts.verbose:%0A print('Linting', orig_path)%0A # Thes @@ ...
5722e1f04d549f27816f91fb76f2a91e01f8145b
Bump version to 0.0.4
aws_status/__init__.py
aws_status/__init__.py
# -*- coding: utf-8 -*- from __future__ import absolute_import from .status_page import StatusPage from .feed import Feed __version__ = "0.0.3"
Python
0.000001
@@ -140,7 +140,7 @@ 0.0. -3 +4 %22%0A
9608fff697e4692d8a76db2c1658850233059126
fix fucking zero base
Worksheet.py
Worksheet.py
import Range from DataTypes import DataTypes class Worksheet(object): def __init__(self, name, workbook, data=None): self._columns = 0 # cache this for speed self._name = name self._cells = {} self._parent = workbook self._merges = [] # list of Range objects self._attributes = {} if data != None: for...
Python
0
@@ -338,16 +338,19 @@ ate(data +, 1 ):%0A%09%09%09%09f @@ -376,16 +376,19 @@ rate(row +, 1 ):%0A%09%09%09%09%09
18d367a490225202649cfd08a6c7ab14db2b8e5f
change hour of day comparision for 10:30am report
lambda_function.py
lambda_function.py
import time from lxml import html import requests import boto3 import os.path # pip install lxml && pip install requests # http://docs.python-requests.org/en/latest/user/quickstart/ # build a Lambda package # python -m pip install -U lxml -t /Users/kenbritton/Desktop/FindCampsiteVacancies # python -m pip install -U ...
Python
0
@@ -2207,16 +2207,17 @@ OfDay) %3E += 10):%0A
a21a86ec93dd5964bf51f1996be050562244e2e1
move `Fighter.replace_on_insert` to class
cogs/smash/models/fighter.py
cogs/smash/models/fighter.py
from functools import lru_cache import re from discord.ext import commands from ..data import fighters as _fighters from .errors import SmashError WORD = re.compile(r'\W+') def find_ngrams(text: str, number: int = 3) -> set: """https://stackoverflow.com/a/52389482 returns a set of ngrams for the given stri...
Python
0.000001
@@ -1157,16 +1157,46 @@ ers = %5B%5D +%0A replace_on_insert = False %0A%0A as @@ -1471,47 +1471,8 @@ ses%0A - self.replace_on_insert = False%0A
9d2cab53fb1590d5c6f60b5f9e62140c11fb676f
Bump version to 0.2.0.dev
machina/__init__.py
machina/__init__.py
# -*- coding: utf-8 -*- from __future__ import unicode_literals import os __version__ = '0.1.2.dev' MACHINA_VANILLA_APPS = [ 'machina', 'machina.apps.forum', 'machina.apps.forum_conversation', 'machina.apps.forum_conversation.forum_attachments', 'machina.apps.forum_conversation.forum_polls', ...
Python
0
@@ -90,11 +90,11 @@ '0. -1.2 +2.0 .dev