commit
stringlengths
40
40
old_file
stringlengths
4
118
new_file
stringlengths
4
118
old_contents
stringlengths
0
2.94k
new_contents
stringlengths
1
4.43k
subject
stringlengths
15
444
message
stringlengths
16
3.45k
lang
stringclasses
1 value
license
stringclasses
13 values
repos
stringlengths
5
43.2k
prompt
stringlengths
17
4.58k
response
stringlengths
1
4.43k
prompt_tagged
stringlengths
58
4.62k
response_tagged
stringlengths
1
4.43k
text
stringlengths
132
7.29k
text_tagged
stringlengths
173
7.33k
87f44bb68af64f2654c68fb60bf93a34ac6095a6
pylearn2/scripts/dbm/dbm_metrics.py
pylearn2/scripts/dbm/dbm_metrics.py
#!/usr/bin/env python import argparse if __name__ == '__main__': # Argument parsing parser = argparse.ArgumentParser() parser.add_argument("metric", help="the desired metric", choices=["ais"]) parser.add_argument("model_path", help="path to the pickled DBM model") args = par...
#!/usr/bin/env python import argparse from pylearn2.utils import serial def compute_ais(model): pass if __name__ == '__main__': # Possible metrics metrics = {'ais': compute_ais} # Argument parsing parser = argparse.ArgumentParser() parser.add_argument("metric", help="the desired metric", ...
Make the script recuperate the correct method
Make the script recuperate the correct method
Python
bsd-3-clause
fyffyt/pylearn2,daemonmaker/pylearn2,se4u/pylearn2,hyqneuron/pylearn2-maxsom,abergeron/pylearn2,fyffyt/pylearn2,skearnes/pylearn2,w1kke/pylearn2,matrogers/pylearn2,TNick/pylearn2,msingh172/pylearn2,shiquanwang/pylearn2,pkainz/pylearn2,fishcorn/pylearn2,chrish42/pylearn,kose-y/pylearn2,Refefer/pylearn2,lunyang/pylearn2,...
#!/usr/bin/env python import argparse if __name__ == '__main__': # Argument parsing parser = argparse.ArgumentParser() parser.add_argument("metric", help="the desired metric", choices=["ais"]) parser.add_argument("model_path", help="path to the pickled DBM model") args = par...
#!/usr/bin/env python import argparse from pylearn2.utils import serial def compute_ais(model): pass if __name__ == '__main__': # Possible metrics metrics = {'ais': compute_ais} # Argument parsing parser = argparse.ArgumentParser() parser.add_argument("metric", help="the desired metric", ...
<commit_before>#!/usr/bin/env python import argparse if __name__ == '__main__': # Argument parsing parser = argparse.ArgumentParser() parser.add_argument("metric", help="the desired metric", choices=["ais"]) parser.add_argument("model_path", help="path to the pickled DBM model")...
#!/usr/bin/env python import argparse from pylearn2.utils import serial def compute_ais(model): pass if __name__ == '__main__': # Possible metrics metrics = {'ais': compute_ais} # Argument parsing parser = argparse.ArgumentParser() parser.add_argument("metric", help="the desired metric", ...
#!/usr/bin/env python import argparse if __name__ == '__main__': # Argument parsing parser = argparse.ArgumentParser() parser.add_argument("metric", help="the desired metric", choices=["ais"]) parser.add_argument("model_path", help="path to the pickled DBM model") args = par...
<commit_before>#!/usr/bin/env python import argparse if __name__ == '__main__': # Argument parsing parser = argparse.ArgumentParser() parser.add_argument("metric", help="the desired metric", choices=["ais"]) parser.add_argument("model_path", help="path to the pickled DBM model")...
31073969ed99dd6f57ff1959c050fd0f8f59f58c
tests/scipy_argrelextrema.py
tests/scipy_argrelextrema.py
#!/usr/bin/env python # -*- coding: utf-8 -*- import numpy as np from vector import vector, plot_peaks import scipy.signal print('Detect peaks without any filters (maxima).') indexes = scipy.signal.argrelextrema( np.array(vector), comparator=np.greater ) print('Peaks are: %s' % (indexes[0])) plot_peaks( np...
#!/usr/bin/env python # -*- coding: utf-8 -*- import numpy as np from vector import vector, plot_peaks import scipy.signal print('Detect peaks without any filters (maxima).') indexes = scipy.signal.argrelextrema( np.array(vector), comparator=np.greater ) print('Peaks are: %s' % (indexes[0])) # To get number of...
Add eg to get number of peaks
Add eg to get number of peaks
Python
mit
MonsieurV/py-findpeaks,MonsieurV/py-findpeaks
#!/usr/bin/env python # -*- coding: utf-8 -*- import numpy as np from vector import vector, plot_peaks import scipy.signal print('Detect peaks without any filters (maxima).') indexes = scipy.signal.argrelextrema( np.array(vector), comparator=np.greater ) print('Peaks are: %s' % (indexes[0])) plot_peaks( np...
#!/usr/bin/env python # -*- coding: utf-8 -*- import numpy as np from vector import vector, plot_peaks import scipy.signal print('Detect peaks without any filters (maxima).') indexes = scipy.signal.argrelextrema( np.array(vector), comparator=np.greater ) print('Peaks are: %s' % (indexes[0])) # To get number of...
<commit_before>#!/usr/bin/env python # -*- coding: utf-8 -*- import numpy as np from vector import vector, plot_peaks import scipy.signal print('Detect peaks without any filters (maxima).') indexes = scipy.signal.argrelextrema( np.array(vector), comparator=np.greater ) print('Peaks are: %s' % (indexes[0])) plo...
#!/usr/bin/env python # -*- coding: utf-8 -*- import numpy as np from vector import vector, plot_peaks import scipy.signal print('Detect peaks without any filters (maxima).') indexes = scipy.signal.argrelextrema( np.array(vector), comparator=np.greater ) print('Peaks are: %s' % (indexes[0])) # To get number of...
#!/usr/bin/env python # -*- coding: utf-8 -*- import numpy as np from vector import vector, plot_peaks import scipy.signal print('Detect peaks without any filters (maxima).') indexes = scipy.signal.argrelextrema( np.array(vector), comparator=np.greater ) print('Peaks are: %s' % (indexes[0])) plot_peaks( np...
<commit_before>#!/usr/bin/env python # -*- coding: utf-8 -*- import numpy as np from vector import vector, plot_peaks import scipy.signal print('Detect peaks without any filters (maxima).') indexes = scipy.signal.argrelextrema( np.array(vector), comparator=np.greater ) print('Peaks are: %s' % (indexes[0])) plo...
84062292b62d68a14981bcebf18c01feda26fb01
src/plotter/comparison_plotter.py
src/plotter/comparison_plotter.py
#!/usr/bin/env python import matplotlib.pyplot as plt from .constants import PLOT class ComparisonPlotter: def __init__(self, data_list): self.trajectory_fig, self.trajectory_plot = plt.subplots(1, 1) self.position_fig, self.position_plot = plt.subplots(2, 1, sharex=True) self.position_er...
#!/usr/bin/env python import matplotlib.pyplot as plt from .plotter import Plotter from .constants import PLOT class ComparisonPlotter(Plotter): def __init__(self, data_list): temp_data = data_list[0] Plotter.__init__(self, temp_data['t'], temp_data['zeros']) self.trajectory_fig, self.tr...
Make class ComparisonPlotter inherit from Plotter
feat: Make class ComparisonPlotter inherit from Plotter
Python
mit
bit0001/trajectory_tracking,bit0001/trajectory_tracking
#!/usr/bin/env python import matplotlib.pyplot as plt from .constants import PLOT class ComparisonPlotter: def __init__(self, data_list): self.trajectory_fig, self.trajectory_plot = plt.subplots(1, 1) self.position_fig, self.position_plot = plt.subplots(2, 1, sharex=True) self.position_er...
#!/usr/bin/env python import matplotlib.pyplot as plt from .plotter import Plotter from .constants import PLOT class ComparisonPlotter(Plotter): def __init__(self, data_list): temp_data = data_list[0] Plotter.__init__(self, temp_data['t'], temp_data['zeros']) self.trajectory_fig, self.tr...
<commit_before>#!/usr/bin/env python import matplotlib.pyplot as plt from .constants import PLOT class ComparisonPlotter: def __init__(self, data_list): self.trajectory_fig, self.trajectory_plot = plt.subplots(1, 1) self.position_fig, self.position_plot = plt.subplots(2, 1, sharex=True) s...
#!/usr/bin/env python import matplotlib.pyplot as plt from .plotter import Plotter from .constants import PLOT class ComparisonPlotter(Plotter): def __init__(self, data_list): temp_data = data_list[0] Plotter.__init__(self, temp_data['t'], temp_data['zeros']) self.trajectory_fig, self.tr...
#!/usr/bin/env python import matplotlib.pyplot as plt from .constants import PLOT class ComparisonPlotter: def __init__(self, data_list): self.trajectory_fig, self.trajectory_plot = plt.subplots(1, 1) self.position_fig, self.position_plot = plt.subplots(2, 1, sharex=True) self.position_er...
<commit_before>#!/usr/bin/env python import matplotlib.pyplot as plt from .constants import PLOT class ComparisonPlotter: def __init__(self, data_list): self.trajectory_fig, self.trajectory_plot = plt.subplots(1, 1) self.position_fig, self.position_plot = plt.subplots(2, 1, sharex=True) s...
4c0d88fe4d3fb935c5040fa39c5db10f74e6908f
pinax/stripe/utils.py
pinax/stripe/utils.py
import datetime import decimal from django.utils import timezone def convert_tstamp(response, field_name=None): try: if field_name and response[field_name]: return datetime.datetime.fromtimestamp( response[field_name], timezone.utc ) if not ...
import datetime import decimal from django.utils import timezone def convert_tstamp(response, field_name=None): try: if field_name and response[field_name]: return datetime.datetime.fromtimestamp( response[field_name], timezone.utc ) if resp...
Handle case when response is None
Handle case when response is None
Python
mit
pinax/django-stripe-payments
import datetime import decimal from django.utils import timezone def convert_tstamp(response, field_name=None): try: if field_name and response[field_name]: return datetime.datetime.fromtimestamp( response[field_name], timezone.utc ) if not ...
import datetime import decimal from django.utils import timezone def convert_tstamp(response, field_name=None): try: if field_name and response[field_name]: return datetime.datetime.fromtimestamp( response[field_name], timezone.utc ) if resp...
<commit_before>import datetime import decimal from django.utils import timezone def convert_tstamp(response, field_name=None): try: if field_name and response[field_name]: return datetime.datetime.fromtimestamp( response[field_name], timezone.utc ) ...
import datetime import decimal from django.utils import timezone def convert_tstamp(response, field_name=None): try: if field_name and response[field_name]: return datetime.datetime.fromtimestamp( response[field_name], timezone.utc ) if resp...
import datetime import decimal from django.utils import timezone def convert_tstamp(response, field_name=None): try: if field_name and response[field_name]: return datetime.datetime.fromtimestamp( response[field_name], timezone.utc ) if not ...
<commit_before>import datetime import decimal from django.utils import timezone def convert_tstamp(response, field_name=None): try: if field_name and response[field_name]: return datetime.datetime.fromtimestamp( response[field_name], timezone.utc ) ...
a7ba6ece76e768e642a6ed264791e3987f7c7629
apps/user_app/forms.py
apps/user_app/forms.py
from django import forms from django.core import validators from django.contrib.auth.models import User from django.contrib.auth.forms import UserCreationForm class RegistrationForm(UserCreationForm): username = forms.CharField(label='username', max_length=30, required=True,) #validators=[self.isValidU...
from django import forms from django.core.exceptions import ValidationError from django.contrib.auth.models import User from django.contrib.auth.forms import UserCreationForm def isValidUserName(username): try: User.objects.get(username=username) except User.DoesNotExist: return raise ValidationError('The usern...
Implement validation to the username field.
Implement validation to the username field.
Python
mit
pedrolinhares/po-po-modoro,pedrolinhares/po-po-modoro
from django import forms from django.core import validators from django.contrib.auth.models import User from django.contrib.auth.forms import UserCreationForm class RegistrationForm(UserCreationForm): username = forms.CharField(label='username', max_length=30, required=True,) #validators=[self.isValidU...
from django import forms from django.core.exceptions import ValidationError from django.contrib.auth.models import User from django.contrib.auth.forms import UserCreationForm def isValidUserName(username): try: User.objects.get(username=username) except User.DoesNotExist: return raise ValidationError('The usern...
<commit_before>from django import forms from django.core import validators from django.contrib.auth.models import User from django.contrib.auth.forms import UserCreationForm class RegistrationForm(UserCreationForm): username = forms.CharField(label='username', max_length=30, required=True,) #validators...
from django import forms from django.core.exceptions import ValidationError from django.contrib.auth.models import User from django.contrib.auth.forms import UserCreationForm def isValidUserName(username): try: User.objects.get(username=username) except User.DoesNotExist: return raise ValidationError('The usern...
from django import forms from django.core import validators from django.contrib.auth.models import User from django.contrib.auth.forms import UserCreationForm class RegistrationForm(UserCreationForm): username = forms.CharField(label='username', max_length=30, required=True,) #validators=[self.isValidU...
<commit_before>from django import forms from django.core import validators from django.contrib.auth.models import User from django.contrib.auth.forms import UserCreationForm class RegistrationForm(UserCreationForm): username = forms.CharField(label='username', max_length=30, required=True,) #validators...
5553481f8cc8537febbf24fbfea4315a3b61548f
corehq/apps/commtrack/management/commands/check_multiple_parentage.py
corehq/apps/commtrack/management/commands/check_multiple_parentage.py
from django.core.management.base import BaseCommand from corehq.apps.domain.models import Domain class Command(BaseCommand): def handle(self, *args, **options): self.stdout.write("Populating site codes...\n") domains = Domain.get_all() for d in domains: if d.commtrack_enabled...
from django.core.management.base import BaseCommand from corehq.apps.domain.models import Domain from corehq.apps.locations.models import Location import csv class Command(BaseCommand): def handle(self, *args, **options): with open('parentage_results.csv', 'wb+') as csvfile: csv_writer = csv.w...
Switch to CSV and add important info
Switch to CSV and add important info
Python
bsd-3-clause
puttarajubr/commcare-hq,dimagi/commcare-hq,SEL-Columbia/commcare-hq,qedsoftware/commcare-hq,SEL-Columbia/commcare-hq,qedsoftware/commcare-hq,qedsoftware/commcare-hq,puttarajubr/commcare-hq,puttarajubr/commcare-hq,puttarajubr/commcare-hq,SEL-Columbia/commcare-hq,qedsoftware/commcare-hq,dimagi/commcare-hq,qedsoftware/com...
from django.core.management.base import BaseCommand from corehq.apps.domain.models import Domain class Command(BaseCommand): def handle(self, *args, **options): self.stdout.write("Populating site codes...\n") domains = Domain.get_all() for d in domains: if d.commtrack_enabled...
from django.core.management.base import BaseCommand from corehq.apps.domain.models import Domain from corehq.apps.locations.models import Location import csv class Command(BaseCommand): def handle(self, *args, **options): with open('parentage_results.csv', 'wb+') as csvfile: csv_writer = csv.w...
<commit_before>from django.core.management.base import BaseCommand from corehq.apps.domain.models import Domain class Command(BaseCommand): def handle(self, *args, **options): self.stdout.write("Populating site codes...\n") domains = Domain.get_all() for d in domains: if d.co...
from django.core.management.base import BaseCommand from corehq.apps.domain.models import Domain from corehq.apps.locations.models import Location import csv class Command(BaseCommand): def handle(self, *args, **options): with open('parentage_results.csv', 'wb+') as csvfile: csv_writer = csv.w...
from django.core.management.base import BaseCommand from corehq.apps.domain.models import Domain class Command(BaseCommand): def handle(self, *args, **options): self.stdout.write("Populating site codes...\n") domains = Domain.get_all() for d in domains: if d.commtrack_enabled...
<commit_before>from django.core.management.base import BaseCommand from corehq.apps.domain.models import Domain class Command(BaseCommand): def handle(self, *args, **options): self.stdout.write("Populating site codes...\n") domains = Domain.get_all() for d in domains: if d.co...
adb0bffd6586fa380a077f1ec0b950c6ae5d8b4f
bin/reporting-api.py
bin/reporting-api.py
#!/usr/bin/python """ Start the Reporting API application using Paste Deploy. """ import sys import os from paste.deploy import loadapp, loadserver import logging import argparse def parse_args(): parser = argparse.ArgumentParser() parser.add_argument('-c', '--confdir', action='store', required=True, help="S...
#!/usr/bin/python """ Start the Reporting API application using Paste Deploy. """ import sys import os from paste.deploy import loadapp, loadserver import logging import argparse def parse_args(): REALFILE = os.path.realpath(__file__) REALDIR = os.path.dirname(REALFILE) PARDIR = os.path.realpath(os.path....
Make the confdir option optional, with default value the conf subdir in the source tree. Wrap long lines. Add a -l alias for option --logfile.
Make the confdir option optional, with default value the conf subdir in the source tree. Wrap long lines. Add a -l alias for option --logfile.
Python
apache-2.0
NCI-Cloud/reporting-api,NeCTAR-RC/reporting-api,NCI-Cloud/reporting-api,NeCTAR-RC/reporting-api
#!/usr/bin/python """ Start the Reporting API application using Paste Deploy. """ import sys import os from paste.deploy import loadapp, loadserver import logging import argparse def parse_args(): parser = argparse.ArgumentParser() parser.add_argument('-c', '--confdir', action='store', required=True, help="S...
#!/usr/bin/python """ Start the Reporting API application using Paste Deploy. """ import sys import os from paste.deploy import loadapp, loadserver import logging import argparse def parse_args(): REALFILE = os.path.realpath(__file__) REALDIR = os.path.dirname(REALFILE) PARDIR = os.path.realpath(os.path....
<commit_before>#!/usr/bin/python """ Start the Reporting API application using Paste Deploy. """ import sys import os from paste.deploy import loadapp, loadserver import logging import argparse def parse_args(): parser = argparse.ArgumentParser() parser.add_argument('-c', '--confdir', action='store', require...
#!/usr/bin/python """ Start the Reporting API application using Paste Deploy. """ import sys import os from paste.deploy import loadapp, loadserver import logging import argparse def parse_args(): REALFILE = os.path.realpath(__file__) REALDIR = os.path.dirname(REALFILE) PARDIR = os.path.realpath(os.path....
#!/usr/bin/python """ Start the Reporting API application using Paste Deploy. """ import sys import os from paste.deploy import loadapp, loadserver import logging import argparse def parse_args(): parser = argparse.ArgumentParser() parser.add_argument('-c', '--confdir', action='store', required=True, help="S...
<commit_before>#!/usr/bin/python """ Start the Reporting API application using Paste Deploy. """ import sys import os from paste.deploy import loadapp, loadserver import logging import argparse def parse_args(): parser = argparse.ArgumentParser() parser.add_argument('-c', '--confdir', action='store', require...
6b92c4d155d066fb6f4e9180acb4ad07d7fc313d
pskb_website/utils.py
pskb_website/utils.py
import re from unicodedata import normalize _punct_re = re.compile(r'[\t !"#$%&\'()*\-/<=>?@\[\\\]^_`{|},.]+') # From http://flask.pocoo.org/snippets/5/ def slugify(text, delim=u'-'): """Generates an slightly worse ASCII-only slug.""" result = [] for word in _punct_re.split(text.lower()): word ...
import re from unicodedata import normalize _punct_re = re.compile(r'[\t !"#$%&\'()*\-/<=>?@\[\\\]^_`{|},.:]+') # From http://flask.pocoo.org/snippets/5/ def slugify(text, delim=u'-'): """Generates an slightly worse ASCII-only slug.""" result = [] for word in _punct_re.split(text.lower()): word...
Change ":" in titles to "-" for better SEO
Change ":" in titles to "-" for better SEO
Python
agpl-3.0
paulocheque/guides-cms,paulocheque/guides-cms,pluralsight/guides-cms,paulocheque/guides-cms,pluralsight/guides-cms,pluralsight/guides-cms
import re from unicodedata import normalize _punct_re = re.compile(r'[\t !"#$%&\'()*\-/<=>?@\[\\\]^_`{|},.]+') # From http://flask.pocoo.org/snippets/5/ def slugify(text, delim=u'-'): """Generates an slightly worse ASCII-only slug.""" result = [] for word in _punct_re.split(text.lower()): word ...
import re from unicodedata import normalize _punct_re = re.compile(r'[\t !"#$%&\'()*\-/<=>?@\[\\\]^_`{|},.:]+') # From http://flask.pocoo.org/snippets/5/ def slugify(text, delim=u'-'): """Generates an slightly worse ASCII-only slug.""" result = [] for word in _punct_re.split(text.lower()): word...
<commit_before>import re from unicodedata import normalize _punct_re = re.compile(r'[\t !"#$%&\'()*\-/<=>?@\[\\\]^_`{|},.]+') # From http://flask.pocoo.org/snippets/5/ def slugify(text, delim=u'-'): """Generates an slightly worse ASCII-only slug.""" result = [] for word in _punct_re.split(text.lower())...
import re from unicodedata import normalize _punct_re = re.compile(r'[\t !"#$%&\'()*\-/<=>?@\[\\\]^_`{|},.:]+') # From http://flask.pocoo.org/snippets/5/ def slugify(text, delim=u'-'): """Generates an slightly worse ASCII-only slug.""" result = [] for word in _punct_re.split(text.lower()): word...
import re from unicodedata import normalize _punct_re = re.compile(r'[\t !"#$%&\'()*\-/<=>?@\[\\\]^_`{|},.]+') # From http://flask.pocoo.org/snippets/5/ def slugify(text, delim=u'-'): """Generates an slightly worse ASCII-only slug.""" result = [] for word in _punct_re.split(text.lower()): word ...
<commit_before>import re from unicodedata import normalize _punct_re = re.compile(r'[\t !"#$%&\'()*\-/<=>?@\[\\\]^_`{|},.]+') # From http://flask.pocoo.org/snippets/5/ def slugify(text, delim=u'-'): """Generates an slightly worse ASCII-only slug.""" result = [] for word in _punct_re.split(text.lower())...
e3db38f0de04ab3e1126f3417fcdd99ab7d2e81c
flask_ldap_login/check.py
flask_ldap_login/check.py
""" Check that application ldap creds are set up correctly. """ from argparse import ArgumentParser from pprint import pprint from werkzeug.utils import import_string def main(): parser = ArgumentParser(description=__doc__) parser.add_argument('app_module', metavar='APP_MODULE', ...
""" Check that application ldap creds are set up correctly. """ from argparse import ArgumentParser from pprint import pprint import getpass from werkzeug.utils import import_string def main(): parser = ArgumentParser(description=__doc__) parser.add_argument('app_module', metavar='APP...
Use getpass to get password
Use getpass to get password
Python
bsd-2-clause
ContinuumIO/flask-ldap-login,ContinuumIO/flask-ldap-login
""" Check that application ldap creds are set up correctly. """ from argparse import ArgumentParser from pprint import pprint from werkzeug.utils import import_string def main(): parser = ArgumentParser(description=__doc__) parser.add_argument('app_module', metavar='APP_MODULE', ...
""" Check that application ldap creds are set up correctly. """ from argparse import ArgumentParser from pprint import pprint import getpass from werkzeug.utils import import_string def main(): parser = ArgumentParser(description=__doc__) parser.add_argument('app_module', metavar='APP...
<commit_before>""" Check that application ldap creds are set up correctly. """ from argparse import ArgumentParser from pprint import pprint from werkzeug.utils import import_string def main(): parser = ArgumentParser(description=__doc__) parser.add_argument('app_module', metavar='APP...
""" Check that application ldap creds are set up correctly. """ from argparse import ArgumentParser from pprint import pprint import getpass from werkzeug.utils import import_string def main(): parser = ArgumentParser(description=__doc__) parser.add_argument('app_module', metavar='APP...
""" Check that application ldap creds are set up correctly. """ from argparse import ArgumentParser from pprint import pprint from werkzeug.utils import import_string def main(): parser = ArgumentParser(description=__doc__) parser.add_argument('app_module', metavar='APP_MODULE', ...
<commit_before>""" Check that application ldap creds are set up correctly. """ from argparse import ArgumentParser from pprint import pprint from werkzeug.utils import import_string def main(): parser = ArgumentParser(description=__doc__) parser.add_argument('app_module', metavar='APP...
f735b7801b68f44a40d5aa2068213ffe94f5a0b9
polling_stations/apps/data_collection/management/commands/import_high_peak.py
polling_stations/apps/data_collection/management/commands/import_high_peak.py
from data_collection.management.commands import BaseShpStationsShpDistrictsImporter class Command(BaseShpStationsShpDistrictsImporter): srid = 27700 council_id = 'E07000037' districts_name = 'High Peak Polling Districts' stations_name = 'High Peak Polling Districts.shp' elections = [ 'local...
from data_collection.management.commands import BaseShpStationsShpDistrictsImporter class Command(BaseShpStationsShpDistrictsImporter): srid = 27700 council_id = 'E07000037' districts_name = 'High Peak Polling Districts' stations_name = 'High Peak Polling Districts.shp' elections = [ 'local...
Remove High Peak election id (complaint from user)
Remove High Peak election id (complaint from user)
Python
bsd-3-clause
DemocracyClub/UK-Polling-Stations,chris48s/UK-Polling-Stations,DemocracyClub/UK-Polling-Stations,chris48s/UK-Polling-Stations,DemocracyClub/UK-Polling-Stations,chris48s/UK-Polling-Stations
from data_collection.management.commands import BaseShpStationsShpDistrictsImporter class Command(BaseShpStationsShpDistrictsImporter): srid = 27700 council_id = 'E07000037' districts_name = 'High Peak Polling Districts' stations_name = 'High Peak Polling Districts.shp' elections = [ 'local...
from data_collection.management.commands import BaseShpStationsShpDistrictsImporter class Command(BaseShpStationsShpDistrictsImporter): srid = 27700 council_id = 'E07000037' districts_name = 'High Peak Polling Districts' stations_name = 'High Peak Polling Districts.shp' elections = [ 'local...
<commit_before>from data_collection.management.commands import BaseShpStationsShpDistrictsImporter class Command(BaseShpStationsShpDistrictsImporter): srid = 27700 council_id = 'E07000037' districts_name = 'High Peak Polling Districts' stations_name = 'High Peak Polling Districts.shp' elections = [...
from data_collection.management.commands import BaseShpStationsShpDistrictsImporter class Command(BaseShpStationsShpDistrictsImporter): srid = 27700 council_id = 'E07000037' districts_name = 'High Peak Polling Districts' stations_name = 'High Peak Polling Districts.shp' elections = [ 'local...
from data_collection.management.commands import BaseShpStationsShpDistrictsImporter class Command(BaseShpStationsShpDistrictsImporter): srid = 27700 council_id = 'E07000037' districts_name = 'High Peak Polling Districts' stations_name = 'High Peak Polling Districts.shp' elections = [ 'local...
<commit_before>from data_collection.management.commands import BaseShpStationsShpDistrictsImporter class Command(BaseShpStationsShpDistrictsImporter): srid = 27700 council_id = 'E07000037' districts_name = 'High Peak Polling Districts' stations_name = 'High Peak Polling Districts.shp' elections = [...
7ed188bcaf38a25fb63fbb1ed3b070428ff95759
setuptools/tests/test_setopt.py
setuptools/tests/test_setopt.py
# coding: utf-8 from __future__ import unicode_literals import io import six from setuptools.command import setopt from setuptools.extern.six.moves import configparser class TestEdit: @staticmethod def parse_config(filename): parser = configparser.ConfigParser() with io.open(filename, enco...
# coding: utf-8 from __future__ import unicode_literals import io import six from setuptools.command import setopt from setuptools.extern.six.moves import configparser class TestEdit: @staticmethod def parse_config(filename): parser = configparser.ConfigParser() with io.open(filename, enco...
Correct cyrillic to match preferred pronunciation.
Correct cyrillic to match preferred pronunciation.
Python
mit
pypa/setuptools,pypa/setuptools,pypa/setuptools
# coding: utf-8 from __future__ import unicode_literals import io import six from setuptools.command import setopt from setuptools.extern.six.moves import configparser class TestEdit: @staticmethod def parse_config(filename): parser = configparser.ConfigParser() with io.open(filename, enco...
# coding: utf-8 from __future__ import unicode_literals import io import six from setuptools.command import setopt from setuptools.extern.six.moves import configparser class TestEdit: @staticmethod def parse_config(filename): parser = configparser.ConfigParser() with io.open(filename, enco...
<commit_before># coding: utf-8 from __future__ import unicode_literals import io import six from setuptools.command import setopt from setuptools.extern.six.moves import configparser class TestEdit: @staticmethod def parse_config(filename): parser = configparser.ConfigParser() with io.open...
# coding: utf-8 from __future__ import unicode_literals import io import six from setuptools.command import setopt from setuptools.extern.six.moves import configparser class TestEdit: @staticmethod def parse_config(filename): parser = configparser.ConfigParser() with io.open(filename, enco...
# coding: utf-8 from __future__ import unicode_literals import io import six from setuptools.command import setopt from setuptools.extern.six.moves import configparser class TestEdit: @staticmethod def parse_config(filename): parser = configparser.ConfigParser() with io.open(filename, enco...
<commit_before># coding: utf-8 from __future__ import unicode_literals import io import six from setuptools.command import setopt from setuptools.extern.six.moves import configparser class TestEdit: @staticmethod def parse_config(filename): parser = configparser.ConfigParser() with io.open...
1d74ba63dda5193a5287a45c9570a7c2ece6fb42
moksha/apps/metrics/moksha/apps/metrics/consumers/metrics_consumer.py
moksha/apps/metrics/moksha/apps/metrics/consumers/metrics_consumer.py
# This file is part of Moksha. # Copyright (C) 2008-2009 Red Hat, Inc. # # 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 ...
# This file is part of Moksha. # Copyright (C) 2008-2009 Red Hat, Inc. # # 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 ...
Fix the data format of our metrics consumer
Fix the data format of our metrics consumer
Python
apache-2.0
mokshaproject/moksha,mokshaproject/moksha,pombredanne/moksha,ralphbean/moksha,ralphbean/moksha,pombredanne/moksha,pombredanne/moksha,lmacken/moksha,lmacken/moksha,ralphbean/moksha,lmacken/moksha,mokshaproject/moksha,mokshaproject/moksha,pombredanne/moksha
# This file is part of Moksha. # Copyright (C) 2008-2009 Red Hat, Inc. # # 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 ...
# This file is part of Moksha. # Copyright (C) 2008-2009 Red Hat, Inc. # # 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 ...
<commit_before># This file is part of Moksha. # Copyright (C) 2008-2009 Red Hat, Inc. # # 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 opt...
# This file is part of Moksha. # Copyright (C) 2008-2009 Red Hat, Inc. # # 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 ...
# This file is part of Moksha. # Copyright (C) 2008-2009 Red Hat, Inc. # # 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 ...
<commit_before># This file is part of Moksha. # Copyright (C) 2008-2009 Red Hat, Inc. # # 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 opt...
8257a9478fcf30c28bce91a8f12b63d8e1dab955
readinglist2pocket.py
readinglist2pocket.py
#!/usr/bin/env python # Requires https://github.com/samuelkordik/pocketlib from readinglistlib import ReadingListReader from pocket.pocket import Pocket import argparse import sys # Configure and consume command line arguments. ap = argparse.ArgumentParser(description='This script adds your Safari Reading List art...
#!/usr/bin/env python # Requires https://github.com/samuelkordik/pocketlib from readinglistlib import ReadingListReader from pocket.pocket import Pocket import argparse import sys # Configure and consume command line arguments. ap = argparse.ArgumentParser(description='This script adds your Safari Reading List art...
Add functional Pocket auth and bulk_add
Add functional Pocket auth and bulk_add
Python
mit
anoved/ReadingListReader
#!/usr/bin/env python # Requires https://github.com/samuelkordik/pocketlib from readinglistlib import ReadingListReader from pocket.pocket import Pocket import argparse import sys # Configure and consume command line arguments. ap = argparse.ArgumentParser(description='This script adds your Safari Reading List art...
#!/usr/bin/env python # Requires https://github.com/samuelkordik/pocketlib from readinglistlib import ReadingListReader from pocket.pocket import Pocket import argparse import sys # Configure and consume command line arguments. ap = argparse.ArgumentParser(description='This script adds your Safari Reading List art...
<commit_before>#!/usr/bin/env python # Requires https://github.com/samuelkordik/pocketlib from readinglistlib import ReadingListReader from pocket.pocket import Pocket import argparse import sys # Configure and consume command line arguments. ap = argparse.ArgumentParser(description='This script adds your Safari R...
#!/usr/bin/env python # Requires https://github.com/samuelkordik/pocketlib from readinglistlib import ReadingListReader from pocket.pocket import Pocket import argparse import sys # Configure and consume command line arguments. ap = argparse.ArgumentParser(description='This script adds your Safari Reading List art...
#!/usr/bin/env python # Requires https://github.com/samuelkordik/pocketlib from readinglistlib import ReadingListReader from pocket.pocket import Pocket import argparse import sys # Configure and consume command line arguments. ap = argparse.ArgumentParser(description='This script adds your Safari Reading List art...
<commit_before>#!/usr/bin/env python # Requires https://github.com/samuelkordik/pocketlib from readinglistlib import ReadingListReader from pocket.pocket import Pocket import argparse import sys # Configure and consume command line arguments. ap = argparse.ArgumentParser(description='This script adds your Safari R...
8ddb8217759a18874b9b147cbe77a0103556251e
order/order_2_login_system_by_https.py
order/order_2_login_system_by_https.py
import json import requests """ Order 2: Login system by https This is the code which use curl to login system ``` curl -k https://192.168.105.88/axapi/v3/auth -H "Content-type:application/json" -d '{ "credentials": { "username": "admin", "password": "a10" } }' ``` """ class LoginSystemByHt...
import json import requests """ Order 2: Login system by https This is the code which use curl to login system ``` curl -k https://192.168.105.88/axapi/v3/auth -H "Content-type:application/json" -d '{ "credentials": { "username": "admin", "password": "a10" } }' ``` """ class LoginSystemByHt...
Order 2: Login system by https
[Order] Order 2: Login system by https
Python
mit
flyingSprite/spinelle
import json import requests """ Order 2: Login system by https This is the code which use curl to login system ``` curl -k https://192.168.105.88/axapi/v3/auth -H "Content-type:application/json" -d '{ "credentials": { "username": "admin", "password": "a10" } }' ``` """ class LoginSystemByHt...
import json import requests """ Order 2: Login system by https This is the code which use curl to login system ``` curl -k https://192.168.105.88/axapi/v3/auth -H "Content-type:application/json" -d '{ "credentials": { "username": "admin", "password": "a10" } }' ``` """ class LoginSystemByHt...
<commit_before>import json import requests """ Order 2: Login system by https This is the code which use curl to login system ``` curl -k https://192.168.105.88/axapi/v3/auth -H "Content-type:application/json" -d '{ "credentials": { "username": "admin", "password": "a10" } }' ``` """ class ...
import json import requests """ Order 2: Login system by https This is the code which use curl to login system ``` curl -k https://192.168.105.88/axapi/v3/auth -H "Content-type:application/json" -d '{ "credentials": { "username": "admin", "password": "a10" } }' ``` """ class LoginSystemByHt...
import json import requests """ Order 2: Login system by https This is the code which use curl to login system ``` curl -k https://192.168.105.88/axapi/v3/auth -H "Content-type:application/json" -d '{ "credentials": { "username": "admin", "password": "a10" } }' ``` """ class LoginSystemByHt...
<commit_before>import json import requests """ Order 2: Login system by https This is the code which use curl to login system ``` curl -k https://192.168.105.88/axapi/v3/auth -H "Content-type:application/json" -d '{ "credentials": { "username": "admin", "password": "a10" } }' ``` """ class ...
c5d0595acb080bdc33efdc95a5781ed6b87b0a2e
warehouse/packages/models.py
warehouse/packages/models.py
from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals from sqlalchemy import event from sqlalchemy.schema import FetchedValue from sqlalchemy.dialects import postgresql as pg from warehouse import db from warehouse.databases.mixins import UUIDPrimaryKeyMixin fr...
from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals from sqlalchemy.schema import FetchedValue from sqlalchemy.dialects import postgresql as pg from sqlalchemy.ext.declarative import declared_attr from warehouse import db from warehouse.database.mixins import...
Refactor Project to use new mixins and methods
Refactor Project to use new mixins and methods
Python
bsd-2-clause
davidfischer/warehouse
from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals from sqlalchemy import event from sqlalchemy.schema import FetchedValue from sqlalchemy.dialects import postgresql as pg from warehouse import db from warehouse.databases.mixins import UUIDPrimaryKeyMixin fr...
from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals from sqlalchemy.schema import FetchedValue from sqlalchemy.dialects import postgresql as pg from sqlalchemy.ext.declarative import declared_attr from warehouse import db from warehouse.database.mixins import...
<commit_before>from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals from sqlalchemy import event from sqlalchemy.schema import FetchedValue from sqlalchemy.dialects import postgresql as pg from warehouse import db from warehouse.databases.mixins import UUIDPri...
from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals from sqlalchemy.schema import FetchedValue from sqlalchemy.dialects import postgresql as pg from sqlalchemy.ext.declarative import declared_attr from warehouse import db from warehouse.database.mixins import...
from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals from sqlalchemy import event from sqlalchemy.schema import FetchedValue from sqlalchemy.dialects import postgresql as pg from warehouse import db from warehouse.databases.mixins import UUIDPrimaryKeyMixin fr...
<commit_before>from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals from sqlalchemy import event from sqlalchemy.schema import FetchedValue from sqlalchemy.dialects import postgresql as pg from warehouse import db from warehouse.databases.mixins import UUIDPri...
f44bd61809d2d965359ad4795b3839aa9a56bfec
src/sentry/monkey.py
src/sentry/monkey.py
from __future__ import absolute_import def register_scheme(name): from six.moves.urllib import parse as urlparse uses = urlparse.uses_netloc, urlparse.uses_query, urlparse.uses_relative, urlparse.uses_fragment for use in uses: if name not in use: use.append(name) register_scheme('app...
from __future__ import absolute_import def register_scheme(name): try: import urlparse # NOQA except ImportError: from urllib import parse as urlparse # NOQA uses = urlparse.uses_netloc, urlparse.uses_query, urlparse.uses_relative, urlparse.uses_fragment for use in uses: if n...
Remove six.moves and disable linter
Remove six.moves and disable linter
Python
bsd-3-clause
gencer/sentry,ifduyue/sentry,jean/sentry,looker/sentry,jean/sentry,gencer/sentry,mvaled/sentry,JamesMura/sentry,JamesMura/sentry,JamesMura/sentry,jean/sentry,BuildingLink/sentry,looker/sentry,looker/sentry,beeftornado/sentry,JackDanger/sentry,BuildingLink/sentry,JackDanger/sentry,jean/sentry,mvaled/sentry,beeftornado/s...
from __future__ import absolute_import def register_scheme(name): from six.moves.urllib import parse as urlparse uses = urlparse.uses_netloc, urlparse.uses_query, urlparse.uses_relative, urlparse.uses_fragment for use in uses: if name not in use: use.append(name) register_scheme('app...
from __future__ import absolute_import def register_scheme(name): try: import urlparse # NOQA except ImportError: from urllib import parse as urlparse # NOQA uses = urlparse.uses_netloc, urlparse.uses_query, urlparse.uses_relative, urlparse.uses_fragment for use in uses: if n...
<commit_before>from __future__ import absolute_import def register_scheme(name): from six.moves.urllib import parse as urlparse uses = urlparse.uses_netloc, urlparse.uses_query, urlparse.uses_relative, urlparse.uses_fragment for use in uses: if name not in use: use.append(name) regis...
from __future__ import absolute_import def register_scheme(name): try: import urlparse # NOQA except ImportError: from urllib import parse as urlparse # NOQA uses = urlparse.uses_netloc, urlparse.uses_query, urlparse.uses_relative, urlparse.uses_fragment for use in uses: if n...
from __future__ import absolute_import def register_scheme(name): from six.moves.urllib import parse as urlparse uses = urlparse.uses_netloc, urlparse.uses_query, urlparse.uses_relative, urlparse.uses_fragment for use in uses: if name not in use: use.append(name) register_scheme('app...
<commit_before>from __future__ import absolute_import def register_scheme(name): from six.moves.urllib import parse as urlparse uses = urlparse.uses_netloc, urlparse.uses_query, urlparse.uses_relative, urlparse.uses_fragment for use in uses: if name not in use: use.append(name) regis...
87a4c494c18039a296775dab8acf910f83fb59b8
djangoappengine/utils.py
djangoappengine/utils.py
from google.appengine.api import apiproxy_stub_map import os have_appserver = bool(apiproxy_stub_map.apiproxy.GetStub('datastore_v3')) if have_appserver: appid = os.environ.get('APPLICATION_ID') else: try: from google.appengine.tools import dev_appserver from .boot import PROJECT_DIR a...
from google.appengine.api import apiproxy_stub_map import os have_appserver = bool(apiproxy_stub_map.apiproxy.GetStub('datastore_v3')) if have_appserver: appid = os.environ.get('APPLICATION_ID') else: try: from google.appengine.tools import dev_appserver from .boot import PROJECT_DIR t...
Make prosthetic-runner work with GAE SDK 1.6
Make prosthetic-runner work with GAE SDK 1.6
Python
mit
philterphactory/prosthetic-runner,philterphactory/prosthetic-runner,philterphactory/prosthetic-runner
from google.appengine.api import apiproxy_stub_map import os have_appserver = bool(apiproxy_stub_map.apiproxy.GetStub('datastore_v3')) if have_appserver: appid = os.environ.get('APPLICATION_ID') else: try: from google.appengine.tools import dev_appserver from .boot import PROJECT_DIR a...
from google.appengine.api import apiproxy_stub_map import os have_appserver = bool(apiproxy_stub_map.apiproxy.GetStub('datastore_v3')) if have_appserver: appid = os.environ.get('APPLICATION_ID') else: try: from google.appengine.tools import dev_appserver from .boot import PROJECT_DIR t...
<commit_before>from google.appengine.api import apiproxy_stub_map import os have_appserver = bool(apiproxy_stub_map.apiproxy.GetStub('datastore_v3')) if have_appserver: appid = os.environ.get('APPLICATION_ID') else: try: from google.appengine.tools import dev_appserver from .boot import PROJEC...
from google.appengine.api import apiproxy_stub_map import os have_appserver = bool(apiproxy_stub_map.apiproxy.GetStub('datastore_v3')) if have_appserver: appid = os.environ.get('APPLICATION_ID') else: try: from google.appengine.tools import dev_appserver from .boot import PROJECT_DIR t...
from google.appengine.api import apiproxy_stub_map import os have_appserver = bool(apiproxy_stub_map.apiproxy.GetStub('datastore_v3')) if have_appserver: appid = os.environ.get('APPLICATION_ID') else: try: from google.appengine.tools import dev_appserver from .boot import PROJECT_DIR a...
<commit_before>from google.appengine.api import apiproxy_stub_map import os have_appserver = bool(apiproxy_stub_map.apiproxy.GetStub('datastore_v3')) if have_appserver: appid = os.environ.get('APPLICATION_ID') else: try: from google.appengine.tools import dev_appserver from .boot import PROJEC...
076e0a765958101f22acc04f313895dc67fdbc9f
tests/test_project/settings.py
tests/test_project/settings.py
# Django settings for test_project project DEBUG = True # We are not really using a relational database, but tests fail without # defining it because flush command is being run, which expects it DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME': ':memory:', } } # Make ...
# Django settings for test_project project DEBUG = True # We are not really using a relational database, but tests fail without # defining it because flush command is being run, which expects it DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME': ':memory:', } } # Make ...
Set Mongoengine user for Django 1.5 in tests.
Set Mongoengine user for Django 1.5 in tests.
Python
agpl-3.0
wlanslovenija/django-tastypie-mongoengine
# Django settings for test_project project DEBUG = True # We are not really using a relational database, but tests fail without # defining it because flush command is being run, which expects it DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME': ':memory:', } } # Make ...
# Django settings for test_project project DEBUG = True # We are not really using a relational database, but tests fail without # defining it because flush command is being run, which expects it DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME': ':memory:', } } # Make ...
<commit_before># Django settings for test_project project DEBUG = True # We are not really using a relational database, but tests fail without # defining it because flush command is being run, which expects it DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME': ':memory:', ...
# Django settings for test_project project DEBUG = True # We are not really using a relational database, but tests fail without # defining it because flush command is being run, which expects it DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME': ':memory:', } } # Make ...
# Django settings for test_project project DEBUG = True # We are not really using a relational database, but tests fail without # defining it because flush command is being run, which expects it DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME': ':memory:', } } # Make ...
<commit_before># Django settings for test_project project DEBUG = True # We are not really using a relational database, but tests fail without # defining it because flush command is being run, which expects it DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME': ':memory:', ...
0e1c9c09bdf60fce3e9dbb8051db079687709fe0
blah/commands.py
blah/commands.py
import os import blah.repositories import blah.fetcher class WhatIsThisCommand(object): def create_parser(self, subparser): subparser.add_argument("directory", nargs="?") def execute(self, args): directory = args.directory if args.directory is not None else os.getcwd() repository ...
import os import argparse import blah.repositories import blah.fetcher class WhatIsThisCommand(object): def create_parser(self, subparser): subparser.add_argument("directory", nargs="?") def execute(self, args): directory = args.directory if args.directory is not None else os.getcwd() ...
Fix and hide --use-cache option
Fix and hide --use-cache option
Python
bsd-2-clause
mwilliamson/mayo
import os import blah.repositories import blah.fetcher class WhatIsThisCommand(object): def create_parser(self, subparser): subparser.add_argument("directory", nargs="?") def execute(self, args): directory = args.directory if args.directory is not None else os.getcwd() repository ...
import os import argparse import blah.repositories import blah.fetcher class WhatIsThisCommand(object): def create_parser(self, subparser): subparser.add_argument("directory", nargs="?") def execute(self, args): directory = args.directory if args.directory is not None else os.getcwd() ...
<commit_before>import os import blah.repositories import blah.fetcher class WhatIsThisCommand(object): def create_parser(self, subparser): subparser.add_argument("directory", nargs="?") def execute(self, args): directory = args.directory if args.directory is not None else os.getcwd() ...
import os import argparse import blah.repositories import blah.fetcher class WhatIsThisCommand(object): def create_parser(self, subparser): subparser.add_argument("directory", nargs="?") def execute(self, args): directory = args.directory if args.directory is not None else os.getcwd() ...
import os import blah.repositories import blah.fetcher class WhatIsThisCommand(object): def create_parser(self, subparser): subparser.add_argument("directory", nargs="?") def execute(self, args): directory = args.directory if args.directory is not None else os.getcwd() repository ...
<commit_before>import os import blah.repositories import blah.fetcher class WhatIsThisCommand(object): def create_parser(self, subparser): subparser.add_argument("directory", nargs="?") def execute(self, args): directory = args.directory if args.directory is not None else os.getcwd() ...
59e454f0272725c46d06f3d5f32edafa866f578b
registration/admin.py
registration/admin.py
from django.contrib import admin from registration.models import RegistrationProfile class RegistrationAdmin(admin.ModelAdmin): list_display = ('__unicode__', 'activation_key_expired') search_fields = ('user__username', 'user__first_name') admin.site.register(RegistrationProfile, RegistrationAdmin)
from django.contrib import admin from registration.models import RegistrationProfile class RegistrationAdmin(admin.ModelAdmin): list_display = ('__unicode__', 'activation_key_expired') raw_id_fields = ['user'] search_fields = ('user__username', 'user__first_name') admin.site.register(RegistrationProfil...
Use raw_id_fields for the relation from RegistrationProfile to User, for sites which have huge numbers of users.
Use raw_id_fields for the relation from RegistrationProfile to User, for sites which have huge numbers of users.
Python
bsd-3-clause
remarkablerocket/django-mailinglist-registration,remarkablerocket/django-mailinglist-registration
from django.contrib import admin from registration.models import RegistrationProfile class RegistrationAdmin(admin.ModelAdmin): list_display = ('__unicode__', 'activation_key_expired') search_fields = ('user__username', 'user__first_name') admin.site.register(RegistrationProfile, RegistrationAdmin) Use raw...
from django.contrib import admin from registration.models import RegistrationProfile class RegistrationAdmin(admin.ModelAdmin): list_display = ('__unicode__', 'activation_key_expired') raw_id_fields = ['user'] search_fields = ('user__username', 'user__first_name') admin.site.register(RegistrationProfil...
<commit_before>from django.contrib import admin from registration.models import RegistrationProfile class RegistrationAdmin(admin.ModelAdmin): list_display = ('__unicode__', 'activation_key_expired') search_fields = ('user__username', 'user__first_name') admin.site.register(RegistrationProfile, Registratio...
from django.contrib import admin from registration.models import RegistrationProfile class RegistrationAdmin(admin.ModelAdmin): list_display = ('__unicode__', 'activation_key_expired') raw_id_fields = ['user'] search_fields = ('user__username', 'user__first_name') admin.site.register(RegistrationProfil...
from django.contrib import admin from registration.models import RegistrationProfile class RegistrationAdmin(admin.ModelAdmin): list_display = ('__unicode__', 'activation_key_expired') search_fields = ('user__username', 'user__first_name') admin.site.register(RegistrationProfile, RegistrationAdmin) Use raw...
<commit_before>from django.contrib import admin from registration.models import RegistrationProfile class RegistrationAdmin(admin.ModelAdmin): list_display = ('__unicode__', 'activation_key_expired') search_fields = ('user__username', 'user__first_name') admin.site.register(RegistrationProfile, Registratio...
03b180bf1dad2f7f82dec177b1fece369bdcf5e6
build/oggm/run_test.py
build/oggm/run_test.py
#!/usr/bin/env python import os os.environ["MPLBACKEND"] = 'agg' import matplotlib matplotlib.use('agg') import pytest import pytest_mpl.plugin import oggm import sys import ssl ssl._create_default_https_context = ssl._create_unverified_context initial_dir = os.getcwd() oggm_file = os.path.abspath(oggm.__file__) o...
#!/usr/bin/env python import os os.environ["MPLBACKEND"] = 'agg' import matplotlib matplotlib.use('agg') import pytest import oggm import sys import ssl ssl._create_default_https_context = ssl._create_unverified_context initial_dir = os.getcwd() oggm_file = os.path.abspath(oggm.__file__) oggm_dir = os.path.dirname...
Revert "Try to fix mpl invocation"
Revert "Try to fix mpl invocation" This reverts commit c5f0e32eb12ae7809b9fde0371bfb73ec86d47a3.
Python
mit
OGGM/OGGM-Anaconda
#!/usr/bin/env python import os os.environ["MPLBACKEND"] = 'agg' import matplotlib matplotlib.use('agg') import pytest import pytest_mpl.plugin import oggm import sys import ssl ssl._create_default_https_context = ssl._create_unverified_context initial_dir = os.getcwd() oggm_file = os.path.abspath(oggm.__file__) o...
#!/usr/bin/env python import os os.environ["MPLBACKEND"] = 'agg' import matplotlib matplotlib.use('agg') import pytest import oggm import sys import ssl ssl._create_default_https_context = ssl._create_unverified_context initial_dir = os.getcwd() oggm_file = os.path.abspath(oggm.__file__) oggm_dir = os.path.dirname...
<commit_before>#!/usr/bin/env python import os os.environ["MPLBACKEND"] = 'agg' import matplotlib matplotlib.use('agg') import pytest import pytest_mpl.plugin import oggm import sys import ssl ssl._create_default_https_context = ssl._create_unverified_context initial_dir = os.getcwd() oggm_file = os.path.abspath(o...
#!/usr/bin/env python import os os.environ["MPLBACKEND"] = 'agg' import matplotlib matplotlib.use('agg') import pytest import oggm import sys import ssl ssl._create_default_https_context = ssl._create_unverified_context initial_dir = os.getcwd() oggm_file = os.path.abspath(oggm.__file__) oggm_dir = os.path.dirname...
#!/usr/bin/env python import os os.environ["MPLBACKEND"] = 'agg' import matplotlib matplotlib.use('agg') import pytest import pytest_mpl.plugin import oggm import sys import ssl ssl._create_default_https_context = ssl._create_unverified_context initial_dir = os.getcwd() oggm_file = os.path.abspath(oggm.__file__) o...
<commit_before>#!/usr/bin/env python import os os.environ["MPLBACKEND"] = 'agg' import matplotlib matplotlib.use('agg') import pytest import pytest_mpl.plugin import oggm import sys import ssl ssl._create_default_https_context = ssl._create_unverified_context initial_dir = os.getcwd() oggm_file = os.path.abspath(o...
695b7cabdc46f3f90b116fa63380bff2ecbfab0c
json_settings/__init__.py
json_settings/__init__.py
import json import logging import os import sys def json_patch(path): logging.warn("Attempting to load local settings from %r" % (path,)) try: d = json.load(open(path)) except IOError: logging.exception("Unable to open json settings in %r" % (path,)) raise SystemExit(-1) except...
import json import logging import os import sys def json_patch(path): logging.warn("Attempting to load local settings from %r" % (path,)) try: d = json.load(open(path)) except IOError: logging.exception("Unable to open json settings in %r" % (path,)) raise SystemExit(-1) except...
Patch to make work like we expect
Patch to make work like we expect
Python
apache-2.0
coolshop-com/django-json-settings
import json import logging import os import sys def json_patch(path): logging.warn("Attempting to load local settings from %r" % (path,)) try: d = json.load(open(path)) except IOError: logging.exception("Unable to open json settings in %r" % (path,)) raise SystemExit(-1) except...
import json import logging import os import sys def json_patch(path): logging.warn("Attempting to load local settings from %r" % (path,)) try: d = json.load(open(path)) except IOError: logging.exception("Unable to open json settings in %r" % (path,)) raise SystemExit(-1) except...
<commit_before>import json import logging import os import sys def json_patch(path): logging.warn("Attempting to load local settings from %r" % (path,)) try: d = json.load(open(path)) except IOError: logging.exception("Unable to open json settings in %r" % (path,)) raise SystemExit...
import json import logging import os import sys def json_patch(path): logging.warn("Attempting to load local settings from %r" % (path,)) try: d = json.load(open(path)) except IOError: logging.exception("Unable to open json settings in %r" % (path,)) raise SystemExit(-1) except...
import json import logging import os import sys def json_patch(path): logging.warn("Attempting to load local settings from %r" % (path,)) try: d = json.load(open(path)) except IOError: logging.exception("Unable to open json settings in %r" % (path,)) raise SystemExit(-1) except...
<commit_before>import json import logging import os import sys def json_patch(path): logging.warn("Attempting to load local settings from %r" % (path,)) try: d = json.load(open(path)) except IOError: logging.exception("Unable to open json settings in %r" % (path,)) raise SystemExit...
df9124765a53379626f516ca87e2a19678cd31b6
pm/utils/filesystem.py
pm/utils/filesystem.py
""" Filesystem utilities """ import contextlib import os RUN_RE = '\d{6}_[a-zA-Z\d\-]+_\d{4}_[AB][A-Z\d]{9}' @contextlib.contextmanager def chdir(new_dir): """Context manager to temporarily change to a new directory. """ cur_dir = os.getcwd() # This is weird behavior. I'm removing and and we'll see if...
""" Filesystem utilities """ import contextlib import os RUN_RE = '\d{6}_[a-zA-Z\d\-]+_\d{4}_[AB0][A-Z\d]' @contextlib.contextmanager def chdir(new_dir): """Context manager to temporarily change to a new directory. """ cur_dir = os.getcwd() # This is weird behavior. I'm removing and and we'll see if a...
Modify regexp to pick up MiSeqs as well. Thanks @senthil10
Modify regexp to pick up MiSeqs as well. Thanks @senthil10
Python
mit
vezzi/TACA,guillermo-carrasco/TACA,vezzi/TACA,senthil10/TACA,kate-v-stepanova/TACA,senthil10/TACA,kate-v-stepanova/TACA,SciLifeLab/TACA,guillermo-carrasco/TACA,SciLifeLab/TACA,b97pla/TACA,SciLifeLab/TACA,b97pla/TACA
""" Filesystem utilities """ import contextlib import os RUN_RE = '\d{6}_[a-zA-Z\d\-]+_\d{4}_[AB][A-Z\d]{9}' @contextlib.contextmanager def chdir(new_dir): """Context manager to temporarily change to a new directory. """ cur_dir = os.getcwd() # This is weird behavior. I'm removing and and we'll see if...
""" Filesystem utilities """ import contextlib import os RUN_RE = '\d{6}_[a-zA-Z\d\-]+_\d{4}_[AB0][A-Z\d]' @contextlib.contextmanager def chdir(new_dir): """Context manager to temporarily change to a new directory. """ cur_dir = os.getcwd() # This is weird behavior. I'm removing and and we'll see if a...
<commit_before>""" Filesystem utilities """ import contextlib import os RUN_RE = '\d{6}_[a-zA-Z\d\-]+_\d{4}_[AB][A-Z\d]{9}' @contextlib.contextmanager def chdir(new_dir): """Context manager to temporarily change to a new directory. """ cur_dir = os.getcwd() # This is weird behavior. I'm removing and a...
""" Filesystem utilities """ import contextlib import os RUN_RE = '\d{6}_[a-zA-Z\d\-]+_\d{4}_[AB0][A-Z\d]' @contextlib.contextmanager def chdir(new_dir): """Context manager to temporarily change to a new directory. """ cur_dir = os.getcwd() # This is weird behavior. I'm removing and and we'll see if a...
""" Filesystem utilities """ import contextlib import os RUN_RE = '\d{6}_[a-zA-Z\d\-]+_\d{4}_[AB][A-Z\d]{9}' @contextlib.contextmanager def chdir(new_dir): """Context manager to temporarily change to a new directory. """ cur_dir = os.getcwd() # This is weird behavior. I'm removing and and we'll see if...
<commit_before>""" Filesystem utilities """ import contextlib import os RUN_RE = '\d{6}_[a-zA-Z\d\-]+_\d{4}_[AB][A-Z\d]{9}' @contextlib.contextmanager def chdir(new_dir): """Context manager to temporarily change to a new directory. """ cur_dir = os.getcwd() # This is weird behavior. I'm removing and a...
d6be1dfbd9124ed1c35c32a0819bbfa3d9e6759a
scripts/linux/cura.py
scripts/linux/cura.py
#!/usr/bin/python import os, sys try: import OpenGL import wx import serial import numpy import power except ImportError as e: module = e.message.lstrip('No module named ') print 'Requires ' + module if module == 'power': print "Install from: https://github.com/GreatFruitOmsk/...
#!/usr/bin/python import os, sys try: import OpenGL import wx import serial import numpy import power except ImportError as e: module = e.message.lstrip('No module named ') if module == 'OpenGL': module = 'PyOpenGL' elif module == 'serial': module = 'pyserial' ...
Add py prefix to OpenGL and serial. Exit when error.
Add py prefix to OpenGL and serial. Exit when error.
Python
agpl-3.0
alephobjects/Cura,alephobjects/Cura,alephobjects/Cura
#!/usr/bin/python import os, sys try: import OpenGL import wx import serial import numpy import power except ImportError as e: module = e.message.lstrip('No module named ') print 'Requires ' + module if module == 'power': print "Install from: https://github.com/GreatFruitOmsk/...
#!/usr/bin/python import os, sys try: import OpenGL import wx import serial import numpy import power except ImportError as e: module = e.message.lstrip('No module named ') if module == 'OpenGL': module = 'PyOpenGL' elif module == 'serial': module = 'pyserial' ...
<commit_before>#!/usr/bin/python import os, sys try: import OpenGL import wx import serial import numpy import power except ImportError as e: module = e.message.lstrip('No module named ') print 'Requires ' + module if module == 'power': print "Install from: https://github.com/...
#!/usr/bin/python import os, sys try: import OpenGL import wx import serial import numpy import power except ImportError as e: module = e.message.lstrip('No module named ') if module == 'OpenGL': module = 'PyOpenGL' elif module == 'serial': module = 'pyserial' ...
#!/usr/bin/python import os, sys try: import OpenGL import wx import serial import numpy import power except ImportError as e: module = e.message.lstrip('No module named ') print 'Requires ' + module if module == 'power': print "Install from: https://github.com/GreatFruitOmsk/...
<commit_before>#!/usr/bin/python import os, sys try: import OpenGL import wx import serial import numpy import power except ImportError as e: module = e.message.lstrip('No module named ') print 'Requires ' + module if module == 'power': print "Install from: https://github.com/...
f4ff7e557e1ca3409ebe64eafb723fad10d89812
coverage/version.py
coverage/version.py
# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 # For details: https://bitbucket.org/ned/coveragepy/src/default/NOTICE.txt """The version and URL for coverage.py""" # This file is exec'ed in setup.py, don't import anything! # Same semantics as sys.version_info. version_info = (4, 2, 0,...
# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 # For details: https://bitbucket.org/ned/coveragepy/src/default/NOTICE.txt """The version and URL for coverage.py""" # This file is exec'ed in setup.py, don't import anything! # Same semantics as sys.version_info. version_info = (4, 2, 0,...
Make a beta of 4.2
Make a beta of 4.2
Python
apache-2.0
blueyed/coveragepy,nedbat/coveragepy,nedbat/coveragepy,nedbat/coveragepy,hugovk/coveragepy,blueyed/coveragepy,blueyed/coveragepy,nedbat/coveragepy,hugovk/coveragepy,hugovk/coveragepy,blueyed/coveragepy,nedbat/coveragepy,hugovk/coveragepy,blueyed/coveragepy,hugovk/coveragepy
# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 # For details: https://bitbucket.org/ned/coveragepy/src/default/NOTICE.txt """The version and URL for coverage.py""" # This file is exec'ed in setup.py, don't import anything! # Same semantics as sys.version_info. version_info = (4, 2, 0,...
# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 # For details: https://bitbucket.org/ned/coveragepy/src/default/NOTICE.txt """The version and URL for coverage.py""" # This file is exec'ed in setup.py, don't import anything! # Same semantics as sys.version_info. version_info = (4, 2, 0,...
<commit_before># Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 # For details: https://bitbucket.org/ned/coveragepy/src/default/NOTICE.txt """The version and URL for coverage.py""" # This file is exec'ed in setup.py, don't import anything! # Same semantics as sys.version_info. version_i...
# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 # For details: https://bitbucket.org/ned/coveragepy/src/default/NOTICE.txt """The version and URL for coverage.py""" # This file is exec'ed in setup.py, don't import anything! # Same semantics as sys.version_info. version_info = (4, 2, 0,...
# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 # For details: https://bitbucket.org/ned/coveragepy/src/default/NOTICE.txt """The version and URL for coverage.py""" # This file is exec'ed in setup.py, don't import anything! # Same semantics as sys.version_info. version_info = (4, 2, 0,...
<commit_before># Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 # For details: https://bitbucket.org/ned/coveragepy/src/default/NOTICE.txt """The version and URL for coverage.py""" # This file is exec'ed in setup.py, don't import anything! # Same semantics as sys.version_info. version_i...
56aba3ab7a23dd8bf322a9d577fa64e686dfc9ef
serrano/middleware.py
serrano/middleware.py
class SessionMiddleware(object): def process_request(self, request): if getattr(request, 'user', None) and request.user.is_authenticated(): return session = request.session # Ensure the session is created view processing, but only if a cookie # had been previously set. Th...
from .tokens import get_request_token class SessionMiddleware(object): def process_request(self, request): if getattr(request, 'user', None) and request.user.is_authenticated(): return # Token-based authentication is attempting to be used, bypass CSRF # check if get_re...
Update SessionMiddleware to bypass CSRF if request token is present
Update SessionMiddleware to bypass CSRF if request token is present For non-session-based authentication, Serrano resources handle authenticating using a token based approach. If it is present, CSRF must be turned off to exempt the resources from the check.
Python
bsd-2-clause
rv816/serrano_night,chop-dbhi/serrano,chop-dbhi/serrano,rv816/serrano_night
class SessionMiddleware(object): def process_request(self, request): if getattr(request, 'user', None) and request.user.is_authenticated(): return session = request.session # Ensure the session is created view processing, but only if a cookie # had been previously set. Th...
from .tokens import get_request_token class SessionMiddleware(object): def process_request(self, request): if getattr(request, 'user', None) and request.user.is_authenticated(): return # Token-based authentication is attempting to be used, bypass CSRF # check if get_re...
<commit_before>class SessionMiddleware(object): def process_request(self, request): if getattr(request, 'user', None) and request.user.is_authenticated(): return session = request.session # Ensure the session is created view processing, but only if a cookie # had been pre...
from .tokens import get_request_token class SessionMiddleware(object): def process_request(self, request): if getattr(request, 'user', None) and request.user.is_authenticated(): return # Token-based authentication is attempting to be used, bypass CSRF # check if get_re...
class SessionMiddleware(object): def process_request(self, request): if getattr(request, 'user', None) and request.user.is_authenticated(): return session = request.session # Ensure the session is created view processing, but only if a cookie # had been previously set. Th...
<commit_before>class SessionMiddleware(object): def process_request(self, request): if getattr(request, 'user', None) and request.user.is_authenticated(): return session = request.session # Ensure the session is created view processing, but only if a cookie # had been pre...
bdc2cf7264897edba7fe84e4707aa83459aa8cf5
run.py
run.py
__author__ = 'matt' import datetime import blockbuster blockbuster.app.debug = blockbuster.config.debug_mode blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@") blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@ BlockBuster " + blockbuster.__version__ + " @@@@@@@@@@@@...
__author__ = 'matt' import datetime import blockbuster blockbuster.app.debug = blockbuster.config.debug_mode blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@") blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@ BlockBuster " + blockbuster.config.app_version + " " ...
Use the version in the config file
Use the version in the config file
Python
mit
mattstibbs/blockbuster-server,mattstibbs/blockbuster-server
__author__ = 'matt' import datetime import blockbuster blockbuster.app.debug = blockbuster.config.debug_mode blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@") blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@ BlockBuster " + blockbuster.__version__ + " @@@@@@@@@@@@...
__author__ = 'matt' import datetime import blockbuster blockbuster.app.debug = blockbuster.config.debug_mode blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@") blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@ BlockBuster " + blockbuster.config.app_version + " " ...
<commit_before>__author__ = 'matt' import datetime import blockbuster blockbuster.app.debug = blockbuster.config.debug_mode blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@") blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@ BlockBuster " + blockbuster.__version__ +...
__author__ = 'matt' import datetime import blockbuster blockbuster.app.debug = blockbuster.config.debug_mode blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@") blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@ BlockBuster " + blockbuster.config.app_version + " " ...
__author__ = 'matt' import datetime import blockbuster blockbuster.app.debug = blockbuster.config.debug_mode blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@") blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@ BlockBuster " + blockbuster.__version__ + " @@@@@@@@@@@@...
<commit_before>__author__ = 'matt' import datetime import blockbuster blockbuster.app.debug = blockbuster.config.debug_mode blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@") blockbuster.bb_logging.logger.info("@@@@@@@@@@@@@@@@@@ BlockBuster " + blockbuster.__version__ +...
7e373bd4b3c111b38d983e809aa443ff242860db
tests/test_pipelines/test_python.py
tests/test_pipelines/test_python.py
# -*- coding: utf-8 -*- """ .. module:: tests.test_pipeline.test_python :synopsis: Tests for bundled python pipelines """ from mock import patch, PropertyMock from .. import BaseTestCase class TestPythonVirtualenv(BaseTestCase): def setUp(self): # Mocking State patcher = patch('facio.pipeli...
# -*- coding: utf-8 -*- """ .. module:: tests.test_pipeline.test_python :synopsis: Tests for bundled python pipelines """ from facio.pipeline.python.virtualenv import Virtualenv from mock import patch, PropertyMock from .. import BaseTestCase class TestPythonVirtualenv(BaseTestCase): def setUp(self): ...
Test for getting virtualenv name, prompting the user
Test for getting virtualenv name, prompting the user
Python
bsd-3-clause
krak3n/Facio,krak3n/Facio,krak3n/Facio,krak3n/Facio,krak3n/Facio
# -*- coding: utf-8 -*- """ .. module:: tests.test_pipeline.test_python :synopsis: Tests for bundled python pipelines """ from mock import patch, PropertyMock from .. import BaseTestCase class TestPythonVirtualenv(BaseTestCase): def setUp(self): # Mocking State patcher = patch('facio.pipeli...
# -*- coding: utf-8 -*- """ .. module:: tests.test_pipeline.test_python :synopsis: Tests for bundled python pipelines """ from facio.pipeline.python.virtualenv import Virtualenv from mock import patch, PropertyMock from .. import BaseTestCase class TestPythonVirtualenv(BaseTestCase): def setUp(self): ...
<commit_before># -*- coding: utf-8 -*- """ .. module:: tests.test_pipeline.test_python :synopsis: Tests for bundled python pipelines """ from mock import patch, PropertyMock from .. import BaseTestCase class TestPythonVirtualenv(BaseTestCase): def setUp(self): # Mocking State patcher = patc...
# -*- coding: utf-8 -*- """ .. module:: tests.test_pipeline.test_python :synopsis: Tests for bundled python pipelines """ from facio.pipeline.python.virtualenv import Virtualenv from mock import patch, PropertyMock from .. import BaseTestCase class TestPythonVirtualenv(BaseTestCase): def setUp(self): ...
# -*- coding: utf-8 -*- """ .. module:: tests.test_pipeline.test_python :synopsis: Tests for bundled python pipelines """ from mock import patch, PropertyMock from .. import BaseTestCase class TestPythonVirtualenv(BaseTestCase): def setUp(self): # Mocking State patcher = patch('facio.pipeli...
<commit_before># -*- coding: utf-8 -*- """ .. module:: tests.test_pipeline.test_python :synopsis: Tests for bundled python pipelines """ from mock import patch, PropertyMock from .. import BaseTestCase class TestPythonVirtualenv(BaseTestCase): def setUp(self): # Mocking State patcher = patc...
bf228943ed149bc5ffea867d40b9a666a9707364
powerline/bindings/qtile/widget.py
powerline/bindings/qtile/widget.py
# vim:fileencoding=utf-8:noet from __future__ import (unicode_literals, division, absolute_import, print_function) from libqtile.bar import CALCULATED from libqtile.widget import TextBox from powerline import Powerline class QTilePowerline(Powerline): def do_setup(self, obj): obj.powerline = self class Powerli...
# vim:fileencoding=utf-8:noet from __future__ import (unicode_literals, division, absolute_import, print_function) from libqtile.bar import CALCULATED from libqtile.widget import TextBox from powerline import Powerline class QTilePowerline(Powerline): def do_setup(self, obj): obj.powerline = self class Powerli...
Allow it to configure side
Allow it to configure side
Python
mit
junix/powerline,prvnkumar/powerline,xfumihiro/powerline,IvanAli/powerline,bartvm/powerline,dragon788/powerline,EricSB/powerline,darac/powerline,QuLogic/powerline,DoctorJellyface/powerline,bezhermoso/powerline,Luffin/powerline,IvanAli/powerline,S0lll0s/powerline,s0undt3ch/powerline,cyrixhero/powerline,s0undt3ch/powerlin...
# vim:fileencoding=utf-8:noet from __future__ import (unicode_literals, division, absolute_import, print_function) from libqtile.bar import CALCULATED from libqtile.widget import TextBox from powerline import Powerline class QTilePowerline(Powerline): def do_setup(self, obj): obj.powerline = self class Powerli...
# vim:fileencoding=utf-8:noet from __future__ import (unicode_literals, division, absolute_import, print_function) from libqtile.bar import CALCULATED from libqtile.widget import TextBox from powerline import Powerline class QTilePowerline(Powerline): def do_setup(self, obj): obj.powerline = self class Powerli...
<commit_before># vim:fileencoding=utf-8:noet from __future__ import (unicode_literals, division, absolute_import, print_function) from libqtile.bar import CALCULATED from libqtile.widget import TextBox from powerline import Powerline class QTilePowerline(Powerline): def do_setup(self, obj): obj.powerline = self ...
# vim:fileencoding=utf-8:noet from __future__ import (unicode_literals, division, absolute_import, print_function) from libqtile.bar import CALCULATED from libqtile.widget import TextBox from powerline import Powerline class QTilePowerline(Powerline): def do_setup(self, obj): obj.powerline = self class Powerli...
# vim:fileencoding=utf-8:noet from __future__ import (unicode_literals, division, absolute_import, print_function) from libqtile.bar import CALCULATED from libqtile.widget import TextBox from powerline import Powerline class QTilePowerline(Powerline): def do_setup(self, obj): obj.powerline = self class Powerli...
<commit_before># vim:fileencoding=utf-8:noet from __future__ import (unicode_literals, division, absolute_import, print_function) from libqtile.bar import CALCULATED from libqtile.widget import TextBox from powerline import Powerline class QTilePowerline(Powerline): def do_setup(self, obj): obj.powerline = self ...
c5cadfb774e7d18da656087a113e9d2f9fec4e48
lacrm/_version.py
lacrm/_version.py
__version_info__ = (0, 1, 5) __version__ = '.'.join(map(str, __version_info__))
__version_info__ = (1, 0, 0) __version__ = '.'.join(map(str, __version_info__))
Bump version number to 1.0.0
Bump version number to 1.0.0
Python
mit
HighMileage/lacrm
__version_info__ = (0, 1, 5) __version__ = '.'.join(map(str, __version_info__)) Bump version number to 1.0.0
__version_info__ = (1, 0, 0) __version__ = '.'.join(map(str, __version_info__))
<commit_before>__version_info__ = (0, 1, 5) __version__ = '.'.join(map(str, __version_info__)) <commit_msg>Bump version number to 1.0.0<commit_after>
__version_info__ = (1, 0, 0) __version__ = '.'.join(map(str, __version_info__))
__version_info__ = (0, 1, 5) __version__ = '.'.join(map(str, __version_info__)) Bump version number to 1.0.0__version_info__ = (1, 0, 0) __version__ = '.'.join(map(str, __version_info__))
<commit_before>__version_info__ = (0, 1, 5) __version__ = '.'.join(map(str, __version_info__)) <commit_msg>Bump version number to 1.0.0<commit_after>__version_info__ = (1, 0, 0) __version__ = '.'.join(map(str, __version_info__))
2f6e53a12975dc4e15ba8b85e4df409868ec4df9
tests/test_utils.py
tests/test_utils.py
# Copyright 2013 OpenStack LLC. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
# Copyright 2013 OpenStack LLC. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
Remove unused test code in test_util.py
Remove unused test code in test_util.py This doesn't seem to do anything Change-Id: Ieba6b5f7229680146f9b3f2ae2f3f2d2b1354376
Python
apache-2.0
citrix-openstack-build/python-ceilometerclient,citrix-openstack-build/python-ceilometerclient
# Copyright 2013 OpenStack LLC. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
# Copyright 2013 OpenStack LLC. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
<commit_before># Copyright 2013 OpenStack LLC. # 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 # # Un...
# Copyright 2013 OpenStack LLC. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
# Copyright 2013 OpenStack LLC. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
<commit_before># Copyright 2013 OpenStack LLC. # 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 # # Un...
b4b7185a054d07097e743664abda44e121674b8b
talks_keeper/forms.py
talks_keeper/forms.py
from django import forms from .models import Label, Talk class TalkForm(forms.ModelForm): def __init__(self, *args, **kwargs): super(TalkForm, self).__init__(*args, **kwargs) labels = Label.objects.all() for label_ in labels: self.fields.update({ 'label_{}'.fo...
from django import forms from .models import Label, Talk class TalkForm(forms.ModelForm): def __init__(self, *args, **kwargs): super(TalkForm, self).__init__(*args, **kwargs) instance = kwargs['instance'] labels = Label.objects.all() for label_ in labels: if instance ...
Update TalkForm to use checked labels
Update TalkForm to use checked labels
Python
mit
samitnuk/talks_keeper,samitnuk/talks_keeper,samitnuk/talks_keeper
from django import forms from .models import Label, Talk class TalkForm(forms.ModelForm): def __init__(self, *args, **kwargs): super(TalkForm, self).__init__(*args, **kwargs) labels = Label.objects.all() for label_ in labels: self.fields.update({ 'label_{}'.fo...
from django import forms from .models import Label, Talk class TalkForm(forms.ModelForm): def __init__(self, *args, **kwargs): super(TalkForm, self).__init__(*args, **kwargs) instance = kwargs['instance'] labels = Label.objects.all() for label_ in labels: if instance ...
<commit_before>from django import forms from .models import Label, Talk class TalkForm(forms.ModelForm): def __init__(self, *args, **kwargs): super(TalkForm, self).__init__(*args, **kwargs) labels = Label.objects.all() for label_ in labels: self.fields.update({ ...
from django import forms from .models import Label, Talk class TalkForm(forms.ModelForm): def __init__(self, *args, **kwargs): super(TalkForm, self).__init__(*args, **kwargs) instance = kwargs['instance'] labels = Label.objects.all() for label_ in labels: if instance ...
from django import forms from .models import Label, Talk class TalkForm(forms.ModelForm): def __init__(self, *args, **kwargs): super(TalkForm, self).__init__(*args, **kwargs) labels = Label.objects.all() for label_ in labels: self.fields.update({ 'label_{}'.fo...
<commit_before>from django import forms from .models import Label, Talk class TalkForm(forms.ModelForm): def __init__(self, *args, **kwargs): super(TalkForm, self).__init__(*args, **kwargs) labels = Label.objects.all() for label_ in labels: self.fields.update({ ...
6df1e7a7f0987efc8e34c521e8c4de9a75f9dfde
troposphere/auth.py
troposphere/auth.py
import logging from troposphere.query import only_current_tokens logger = logging.getLogger(__name__) def has_valid_token(user): """ Returns boolean indicating if there are non-expired authentication tokens associated with the user. """ logger.info(hasattr(user, "auth_tokens")) non_expired_...
import logging from troposphere.query import only_current_tokens logger = logging.getLogger(__name__) def has_valid_token(user): """ Returns boolean indicating if there are non-expired authentication tokens associated with the user. """ logger.info("user has auth_tokens attributes? %s" % ...
Use exists() check from QuerySet; give logger-info context
Use exists() check from QuerySet; give logger-info context
Python
apache-2.0
CCI-MOC/GUI-Frontend,CCI-MOC/GUI-Frontend,CCI-MOC/GUI-Frontend,CCI-MOC/GUI-Frontend,CCI-MOC/GUI-Frontend
import logging from troposphere.query import only_current_tokens logger = logging.getLogger(__name__) def has_valid_token(user): """ Returns boolean indicating if there are non-expired authentication tokens associated with the user. """ logger.info(hasattr(user, "auth_tokens")) non_expired_...
import logging from troposphere.query import only_current_tokens logger = logging.getLogger(__name__) def has_valid_token(user): """ Returns boolean indicating if there are non-expired authentication tokens associated with the user. """ logger.info("user has auth_tokens attributes? %s" % ...
<commit_before>import logging from troposphere.query import only_current_tokens logger = logging.getLogger(__name__) def has_valid_token(user): """ Returns boolean indicating if there are non-expired authentication tokens associated with the user. """ logger.info(hasattr(user, "auth_tokens")) ...
import logging from troposphere.query import only_current_tokens logger = logging.getLogger(__name__) def has_valid_token(user): """ Returns boolean indicating if there are non-expired authentication tokens associated with the user. """ logger.info("user has auth_tokens attributes? %s" % ...
import logging from troposphere.query import only_current_tokens logger = logging.getLogger(__name__) def has_valid_token(user): """ Returns boolean indicating if there are non-expired authentication tokens associated with the user. """ logger.info(hasattr(user, "auth_tokens")) non_expired_...
<commit_before>import logging from troposphere.query import only_current_tokens logger = logging.getLogger(__name__) def has_valid_token(user): """ Returns boolean indicating if there are non-expired authentication tokens associated with the user. """ logger.info(hasattr(user, "auth_tokens")) ...
8dcf6c373316d21399fa1edd276cea357fea75fb
groundstation/sockets/stream_socket.py
groundstation/sockets/stream_socket.py
import socket import groundstation.logger log = groundstation.logger.getLogger(__name__) from groundstation.peer_socket import PeerSocket class StreamSocket(object): """Wraps a TCP socket""" def __init__(self): self._sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) # XXX Implement the...
import socket import groundstation.logger log = groundstation.logger.getLogger(__name__) from groundstation.peer_socket import PeerSocket class StreamSocket(object): """Wraps a TCP socket""" def __init__(self): self._sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) # XXX Implement the...
Support being given protobuf Messages
Support being given protobuf Messages
Python
mit
richo/groundstation,richo/groundstation,richo/groundstation,richo/groundstation,richo/groundstation
import socket import groundstation.logger log = groundstation.logger.getLogger(__name__) from groundstation.peer_socket import PeerSocket class StreamSocket(object): """Wraps a TCP socket""" def __init__(self): self._sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) # XXX Implement the...
import socket import groundstation.logger log = groundstation.logger.getLogger(__name__) from groundstation.peer_socket import PeerSocket class StreamSocket(object): """Wraps a TCP socket""" def __init__(self): self._sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) # XXX Implement the...
<commit_before>import socket import groundstation.logger log = groundstation.logger.getLogger(__name__) from groundstation.peer_socket import PeerSocket class StreamSocket(object): """Wraps a TCP socket""" def __init__(self): self._sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) # XX...
import socket import groundstation.logger log = groundstation.logger.getLogger(__name__) from groundstation.peer_socket import PeerSocket class StreamSocket(object): """Wraps a TCP socket""" def __init__(self): self._sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) # XXX Implement the...
import socket import groundstation.logger log = groundstation.logger.getLogger(__name__) from groundstation.peer_socket import PeerSocket class StreamSocket(object): """Wraps a TCP socket""" def __init__(self): self._sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) # XXX Implement the...
<commit_before>import socket import groundstation.logger log = groundstation.logger.getLogger(__name__) from groundstation.peer_socket import PeerSocket class StreamSocket(object): """Wraps a TCP socket""" def __init__(self): self._sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) # XX...
90a933fcfa52c6ebc41e810b3c851cca696f1e71
project/apps/api/management/commands/denormalize.py
project/apps/api/management/commands/denormalize.py
from django.core.management.base import ( BaseCommand, ) from apps.api.models import ( Convention, Contest, Contestant, Performance, ) class Command(BaseCommand): help = "Command to denormailze data." def handle(self, *args, **options): vs = Convention.objects.all() for v...
from django.core.management.base import ( BaseCommand, ) from apps.api.models import ( Convention, Contest, Contestant, Performance, ) class Command(BaseCommand): help = "Command to denormailze data." def handle(self, *args, **options): vs = Convention.objects.all() for v...
Remove ranking from denormalization command
Remove ranking from denormalization command
Python
bsd-2-clause
barberscore/barberscore-api,dbinetti/barberscore-django,barberscore/barberscore-api,dbinetti/barberscore-django,dbinetti/barberscore,dbinetti/barberscore,barberscore/barberscore-api,barberscore/barberscore-api
from django.core.management.base import ( BaseCommand, ) from apps.api.models import ( Convention, Contest, Contestant, Performance, ) class Command(BaseCommand): help = "Command to denormailze data." def handle(self, *args, **options): vs = Convention.objects.all() for v...
from django.core.management.base import ( BaseCommand, ) from apps.api.models import ( Convention, Contest, Contestant, Performance, ) class Command(BaseCommand): help = "Command to denormailze data." def handle(self, *args, **options): vs = Convention.objects.all() for v...
<commit_before>from django.core.management.base import ( BaseCommand, ) from apps.api.models import ( Convention, Contest, Contestant, Performance, ) class Command(BaseCommand): help = "Command to denormailze data." def handle(self, *args, **options): vs = Convention.objects.all(...
from django.core.management.base import ( BaseCommand, ) from apps.api.models import ( Convention, Contest, Contestant, Performance, ) class Command(BaseCommand): help = "Command to denormailze data." def handle(self, *args, **options): vs = Convention.objects.all() for v...
from django.core.management.base import ( BaseCommand, ) from apps.api.models import ( Convention, Contest, Contestant, Performance, ) class Command(BaseCommand): help = "Command to denormailze data." def handle(self, *args, **options): vs = Convention.objects.all() for v...
<commit_before>from django.core.management.base import ( BaseCommand, ) from apps.api.models import ( Convention, Contest, Contestant, Performance, ) class Command(BaseCommand): help = "Command to denormailze data." def handle(self, *args, **options): vs = Convention.objects.all(...
68bc2d2b50e754d50f1a2f85fa7dbde0ca8a6a12
qual/tests/test_iso.py
qual/tests/test_iso.py
import unittest from hypothesis import given from hypothesis.strategies import integers from hypothesis.extra.datetime import datetimes import qual from datetime import date, MINYEAR, MAXYEAR class TestIsoUtils(unittest.TestCase): @given(datetimes(timezones=[])) def test_round_trip_date(self, dt): d ...
import unittest from hypothesis import given from hypothesis.strategies import integers from hypothesis.extra.datetime import datetimes import qual from datetime import date, MINYEAR, MAXYEAR class TestIsoUtils(unittest.TestCase): @given(datetimes(timezones=[])) def test_round_trip_date(self, dt): d ...
Add a new passing test for invalid week numbers.
Add a new passing test for invalid week numbers.
Python
apache-2.0
jwg4/calexicon,jwg4/qual
import unittest from hypothesis import given from hypothesis.strategies import integers from hypothesis.extra.datetime import datetimes import qual from datetime import date, MINYEAR, MAXYEAR class TestIsoUtils(unittest.TestCase): @given(datetimes(timezones=[])) def test_round_trip_date(self, dt): d ...
import unittest from hypothesis import given from hypothesis.strategies import integers from hypothesis.extra.datetime import datetimes import qual from datetime import date, MINYEAR, MAXYEAR class TestIsoUtils(unittest.TestCase): @given(datetimes(timezones=[])) def test_round_trip_date(self, dt): d ...
<commit_before>import unittest from hypothesis import given from hypothesis.strategies import integers from hypothesis.extra.datetime import datetimes import qual from datetime import date, MINYEAR, MAXYEAR class TestIsoUtils(unittest.TestCase): @given(datetimes(timezones=[])) def test_round_trip_date(self, ...
import unittest from hypothesis import given from hypothesis.strategies import integers from hypothesis.extra.datetime import datetimes import qual from datetime import date, MINYEAR, MAXYEAR class TestIsoUtils(unittest.TestCase): @given(datetimes(timezones=[])) def test_round_trip_date(self, dt): d ...
import unittest from hypothesis import given from hypothesis.strategies import integers from hypothesis.extra.datetime import datetimes import qual from datetime import date, MINYEAR, MAXYEAR class TestIsoUtils(unittest.TestCase): @given(datetimes(timezones=[])) def test_round_trip_date(self, dt): d ...
<commit_before>import unittest from hypothesis import given from hypothesis.strategies import integers from hypothesis.extra.datetime import datetimes import qual from datetime import date, MINYEAR, MAXYEAR class TestIsoUtils(unittest.TestCase): @given(datetimes(timezones=[])) def test_round_trip_date(self, ...
c1a1c976642fa1d8f17f89732f6c4fe5bd76d0de
devito/dimension.py
devito/dimension.py
import cgen from sympy import Symbol __all__ = ['Dimension', 'x', 'y', 'z', 't', 'p'] class Dimension(Symbol): """Index object that represents a problem dimension and thus defines a potential iteration space. :param size: Optional, size of the array dimension. :param buffered: Optional, boolean flag...
import cgen import numpy as np from sympy import Symbol __all__ = ['Dimension', 'x', 'y', 'z', 't', 'p'] class Dimension(Symbol): """Index object that represents a problem dimension and thus defines a potential iteration space. :param size: Optional, size of the array dimension. :param buffered: O...
Add dtype of iteration variable
Dimension: Add dtype of iteration variable
Python
mit
opesci/devito,opesci/devito
import cgen from sympy import Symbol __all__ = ['Dimension', 'x', 'y', 'z', 't', 'p'] class Dimension(Symbol): """Index object that represents a problem dimension and thus defines a potential iteration space. :param size: Optional, size of the array dimension. :param buffered: Optional, boolean flag...
import cgen import numpy as np from sympy import Symbol __all__ = ['Dimension', 'x', 'y', 'z', 't', 'p'] class Dimension(Symbol): """Index object that represents a problem dimension and thus defines a potential iteration space. :param size: Optional, size of the array dimension. :param buffered: O...
<commit_before>import cgen from sympy import Symbol __all__ = ['Dimension', 'x', 'y', 'z', 't', 'p'] class Dimension(Symbol): """Index object that represents a problem dimension and thus defines a potential iteration space. :param size: Optional, size of the array dimension. :param buffered: Optiona...
import cgen import numpy as np from sympy import Symbol __all__ = ['Dimension', 'x', 'y', 'z', 't', 'p'] class Dimension(Symbol): """Index object that represents a problem dimension and thus defines a potential iteration space. :param size: Optional, size of the array dimension. :param buffered: O...
import cgen from sympy import Symbol __all__ = ['Dimension', 'x', 'y', 'z', 't', 'p'] class Dimension(Symbol): """Index object that represents a problem dimension and thus defines a potential iteration space. :param size: Optional, size of the array dimension. :param buffered: Optional, boolean flag...
<commit_before>import cgen from sympy import Symbol __all__ = ['Dimension', 'x', 'y', 'z', 't', 'p'] class Dimension(Symbol): """Index object that represents a problem dimension and thus defines a potential iteration space. :param size: Optional, size of the array dimension. :param buffered: Optiona...
2737723b9f0bae0166e63a7a79d4d89bac3a82d9
test_passwd_change.py
test_passwd_change.py
#!/usr/bin/env python3 from passwd_change import passwd_change, shadow_change, mails_delete from unittest import TestCase, TestLoader, TextTestRunner import os import subprocess class PasswdChange_Test(TestCase): def setUp(self): """ Preconditions """ subprocess.call(['mkdir', 't...
#!/usr/bin/env python3 from passwd_change import passwd_change, shadow_change, mails_delete from unittest import TestCase, TestLoader, TextTestRunner import os import subprocess class PasswdChange_Test(TestCase): def setUp(self): """ Preconditions """ subprocess.call(['mkdir', 't...
Fix error - rm test dir command is not executed in correct branch.
Fix error - rm test dir command is not executed in correct branch.
Python
mit
maxsocl/oldmailer
#!/usr/bin/env python3 from passwd_change import passwd_change, shadow_change, mails_delete from unittest import TestCase, TestLoader, TextTestRunner import os import subprocess class PasswdChange_Test(TestCase): def setUp(self): """ Preconditions """ subprocess.call(['mkdir', 't...
#!/usr/bin/env python3 from passwd_change import passwd_change, shadow_change, mails_delete from unittest import TestCase, TestLoader, TextTestRunner import os import subprocess class PasswdChange_Test(TestCase): def setUp(self): """ Preconditions """ subprocess.call(['mkdir', 't...
<commit_before>#!/usr/bin/env python3 from passwd_change import passwd_change, shadow_change, mails_delete from unittest import TestCase, TestLoader, TextTestRunner import os import subprocess class PasswdChange_Test(TestCase): def setUp(self): """ Preconditions """ subprocess.ca...
#!/usr/bin/env python3 from passwd_change import passwd_change, shadow_change, mails_delete from unittest import TestCase, TestLoader, TextTestRunner import os import subprocess class PasswdChange_Test(TestCase): def setUp(self): """ Preconditions """ subprocess.call(['mkdir', 't...
#!/usr/bin/env python3 from passwd_change import passwd_change, shadow_change, mails_delete from unittest import TestCase, TestLoader, TextTestRunner import os import subprocess class PasswdChange_Test(TestCase): def setUp(self): """ Preconditions """ subprocess.call(['mkdir', 't...
<commit_before>#!/usr/bin/env python3 from passwd_change import passwd_change, shadow_change, mails_delete from unittest import TestCase, TestLoader, TextTestRunner import os import subprocess class PasswdChange_Test(TestCase): def setUp(self): """ Preconditions """ subprocess.ca...
432abeacb5496c37bbdaabf7469a6df71e90376e
testing/test_BioID.py
testing/test_BioID.py
#!/usr/bin/env python # ---------------------------------------------------------------------------------------------- # Created by: Lee & Matt # # Description: Contains unit test for BioID Class # ---------------------------------------------------------------------------------------------- # ========================...
#!/usr/bin/env python # ---------------------------------------------------------------------------------------------- # Created by: Lee & Matt # # Description: Contains unit test for BioID Class # ---------------------------------------------------------------------------------------------- # ========================...
Set testing script to use YAML file (oops)
Set testing script to use YAML file (oops)
Python
mit
LeeBergstrand/BioMagick,LeeBergstrand/BioMagick
#!/usr/bin/env python # ---------------------------------------------------------------------------------------------- # Created by: Lee & Matt # # Description: Contains unit test for BioID Class # ---------------------------------------------------------------------------------------------- # ========================...
#!/usr/bin/env python # ---------------------------------------------------------------------------------------------- # Created by: Lee & Matt # # Description: Contains unit test for BioID Class # ---------------------------------------------------------------------------------------------- # ========================...
<commit_before>#!/usr/bin/env python # ---------------------------------------------------------------------------------------------- # Created by: Lee & Matt # # Description: Contains unit test for BioID Class # ---------------------------------------------------------------------------------------------- # =========...
#!/usr/bin/env python # ---------------------------------------------------------------------------------------------- # Created by: Lee & Matt # # Description: Contains unit test for BioID Class # ---------------------------------------------------------------------------------------------- # ========================...
#!/usr/bin/env python # ---------------------------------------------------------------------------------------------- # Created by: Lee & Matt # # Description: Contains unit test for BioID Class # ---------------------------------------------------------------------------------------------- # ========================...
<commit_before>#!/usr/bin/env python # ---------------------------------------------------------------------------------------------- # Created by: Lee & Matt # # Description: Contains unit test for BioID Class # ---------------------------------------------------------------------------------------------- # =========...
7072389221f7e287328cecc695b93a77d04c69ba
tests/basecli_test.py
tests/basecli_test.py
from unittest import TestCase from ass2m.cli import CLI from tempfile import mkdtemp import shutil class BaseCLITest(TestCase): def setUp(self): self.root = mkdtemp(prefix='ass2m_test_root') self.app = CLI(self.root) def tearDown(self): if self.root: shutil.rmtree(self.root...
from unittest import TestCase from ass2m.cli import CLI from tempfile import mkdtemp import shutil import sys import re from StringIO import StringIO class BaseCLITest(TestCase): def setUp(self): self.root = mkdtemp(prefix='ass2m_test_root') self.app = CLI(self.root) def tearDown(self): ...
Test and capture the CLI output
Test and capture the CLI output
Python
agpl-3.0
laurentb/assnet,laurentb/assnet
from unittest import TestCase from ass2m.cli import CLI from tempfile import mkdtemp import shutil class BaseCLITest(TestCase): def setUp(self): self.root = mkdtemp(prefix='ass2m_test_root') self.app = CLI(self.root) def tearDown(self): if self.root: shutil.rmtree(self.root...
from unittest import TestCase from ass2m.cli import CLI from tempfile import mkdtemp import shutil import sys import re from StringIO import StringIO class BaseCLITest(TestCase): def setUp(self): self.root = mkdtemp(prefix='ass2m_test_root') self.app = CLI(self.root) def tearDown(self): ...
<commit_before>from unittest import TestCase from ass2m.cli import CLI from tempfile import mkdtemp import shutil class BaseCLITest(TestCase): def setUp(self): self.root = mkdtemp(prefix='ass2m_test_root') self.app = CLI(self.root) def tearDown(self): if self.root: shutil.r...
from unittest import TestCase from ass2m.cli import CLI from tempfile import mkdtemp import shutil import sys import re from StringIO import StringIO class BaseCLITest(TestCase): def setUp(self): self.root = mkdtemp(prefix='ass2m_test_root') self.app = CLI(self.root) def tearDown(self): ...
from unittest import TestCase from ass2m.cli import CLI from tempfile import mkdtemp import shutil class BaseCLITest(TestCase): def setUp(self): self.root = mkdtemp(prefix='ass2m_test_root') self.app = CLI(self.root) def tearDown(self): if self.root: shutil.rmtree(self.root...
<commit_before>from unittest import TestCase from ass2m.cli import CLI from tempfile import mkdtemp import shutil class BaseCLITest(TestCase): def setUp(self): self.root = mkdtemp(prefix='ass2m_test_root') self.app = CLI(self.root) def tearDown(self): if self.root: shutil.r...
926d5333c1556850a3eda6025ac8cf471b67c0a3
condor/probes/setup.py
condor/probes/setup.py
#!/usr/bin/env python # Copyright 2015 University of Chicago # Available under Apache 2.0 License from distutils.core import setup setup(name='htcondor-es-probes', version='0.6.3', description='HTCondor probes for Elasticsearch analytics', author='Suchandra Thapa', author_email='sthapa@ci.uch...
#!/usr/bin/env python # Copyright 2015 University of Chicago # Available under Apache 2.0 License from distutils.core import setup setup(name='htcondor-es-probes', version='0.6.3', description='HTCondor probes for Elasticsearch analytics', author='Suchandra Thapa', author_email='sthapa@ci.uch...
Add directory for state files
Add directory for state files
Python
apache-2.0
DHTC-Tools/logstash-confs,DHTC-Tools/logstash-confs,DHTC-Tools/logstash-confs
#!/usr/bin/env python # Copyright 2015 University of Chicago # Available under Apache 2.0 License from distutils.core import setup setup(name='htcondor-es-probes', version='0.6.3', description='HTCondor probes for Elasticsearch analytics', author='Suchandra Thapa', author_email='sthapa@ci.uch...
#!/usr/bin/env python # Copyright 2015 University of Chicago # Available under Apache 2.0 License from distutils.core import setup setup(name='htcondor-es-probes', version='0.6.3', description='HTCondor probes for Elasticsearch analytics', author='Suchandra Thapa', author_email='sthapa@ci.uch...
<commit_before>#!/usr/bin/env python # Copyright 2015 University of Chicago # Available under Apache 2.0 License from distutils.core import setup setup(name='htcondor-es-probes', version='0.6.3', description='HTCondor probes for Elasticsearch analytics', author='Suchandra Thapa', author_email...
#!/usr/bin/env python # Copyright 2015 University of Chicago # Available under Apache 2.0 License from distutils.core import setup setup(name='htcondor-es-probes', version='0.6.3', description='HTCondor probes for Elasticsearch analytics', author='Suchandra Thapa', author_email='sthapa@ci.uch...
#!/usr/bin/env python # Copyright 2015 University of Chicago # Available under Apache 2.0 License from distutils.core import setup setup(name='htcondor-es-probes', version='0.6.3', description='HTCondor probes for Elasticsearch analytics', author='Suchandra Thapa', author_email='sthapa@ci.uch...
<commit_before>#!/usr/bin/env python # Copyright 2015 University of Chicago # Available under Apache 2.0 License from distutils.core import setup setup(name='htcondor-es-probes', version='0.6.3', description='HTCondor probes for Elasticsearch analytics', author='Suchandra Thapa', author_email...
2d102e049ceb4ac6d9892313e78b82fc91f9e84c
tests/test_filters.py
tests/test_filters.py
from unittest import TestCase import numpy as np from hrv.filters import moving_average class Filter(TestCase): def test_moving_average_order_3(self): fake_rri = np.array([810, 830, 860, 790, 804]) rri_filt = moving_average(fake_rri, order=3) expected = [810, 833.33, 826.66, 818, 804] ...
from unittest import TestCase import numpy as np from hrv.filters import moving_average class Filter(TestCase): def test_moving_average_order_3(self): fake_rri = np.array([810, 830, 860, 790, 804]) rri_filt = moving_average(fake_rri, order=3) expected = [810, 833.33, 826.66, 818, 804] ...
Test moving average filter for 5th order
Test moving average filter for 5th order
Python
bsd-3-clause
rhenanbartels/hrv
from unittest import TestCase import numpy as np from hrv.filters import moving_average class Filter(TestCase): def test_moving_average_order_3(self): fake_rri = np.array([810, 830, 860, 790, 804]) rri_filt = moving_average(fake_rri, order=3) expected = [810, 833.33, 826.66, 818, 804] ...
from unittest import TestCase import numpy as np from hrv.filters import moving_average class Filter(TestCase): def test_moving_average_order_3(self): fake_rri = np.array([810, 830, 860, 790, 804]) rri_filt = moving_average(fake_rri, order=3) expected = [810, 833.33, 826.66, 818, 804] ...
<commit_before>from unittest import TestCase import numpy as np from hrv.filters import moving_average class Filter(TestCase): def test_moving_average_order_3(self): fake_rri = np.array([810, 830, 860, 790, 804]) rri_filt = moving_average(fake_rri, order=3) expected = [810, 833.33, 826...
from unittest import TestCase import numpy as np from hrv.filters import moving_average class Filter(TestCase): def test_moving_average_order_3(self): fake_rri = np.array([810, 830, 860, 790, 804]) rri_filt = moving_average(fake_rri, order=3) expected = [810, 833.33, 826.66, 818, 804] ...
from unittest import TestCase import numpy as np from hrv.filters import moving_average class Filter(TestCase): def test_moving_average_order_3(self): fake_rri = np.array([810, 830, 860, 790, 804]) rri_filt = moving_average(fake_rri, order=3) expected = [810, 833.33, 826.66, 818, 804] ...
<commit_before>from unittest import TestCase import numpy as np from hrv.filters import moving_average class Filter(TestCase): def test_moving_average_order_3(self): fake_rri = np.array([810, 830, 860, 790, 804]) rri_filt = moving_average(fake_rri, order=3) expected = [810, 833.33, 826...
e1c57cb41c59c118648602ff9837418e5d4baad4
saleor/dashboard/category/forms.py
saleor/dashboard/category/forms.py
from django import forms from ...product.models import Category class CategoryForm(forms.ModelForm): class Meta: model = Category exclude = []
from django import forms from django.utils.translation import ugettext_lazy as _ from ...product.models import Category class CategoryForm(forms.ModelForm): class Meta: model = Category exclude = [] def clean_parent(self): parent = self.cleaned_data['parent'] if parent == sel...
Add validation on category parent field
Add validation on category parent field
Python
bsd-3-clause
itbabu/saleor,rchav/vinerack,avorio/saleor,HyperManTT/ECommerceSaleor,laosunhust/saleor,itbabu/saleor,josesanch/saleor,Drekscott/Motlaesaleor,maferelo/saleor,taedori81/saleor,rchav/vinerack,avorio/saleor,rodrigozn/CW-Shop,avorio/saleor,maferelo/saleor,arth-co/saleor,paweltin/saleor,jreigel/saleor,paweltin/saleor,Dreksc...
from django import forms from ...product.models import Category class CategoryForm(forms.ModelForm): class Meta: model = Category exclude = []Add validation on category parent field
from django import forms from django.utils.translation import ugettext_lazy as _ from ...product.models import Category class CategoryForm(forms.ModelForm): class Meta: model = Category exclude = [] def clean_parent(self): parent = self.cleaned_data['parent'] if parent == sel...
<commit_before>from django import forms from ...product.models import Category class CategoryForm(forms.ModelForm): class Meta: model = Category exclude = []<commit_msg>Add validation on category parent field<commit_after>
from django import forms from django.utils.translation import ugettext_lazy as _ from ...product.models import Category class CategoryForm(forms.ModelForm): class Meta: model = Category exclude = [] def clean_parent(self): parent = self.cleaned_data['parent'] if parent == sel...
from django import forms from ...product.models import Category class CategoryForm(forms.ModelForm): class Meta: model = Category exclude = []Add validation on category parent fieldfrom django import forms from django.utils.translation import ugettext_lazy as _ from ...product.models import Cate...
<commit_before>from django import forms from ...product.models import Category class CategoryForm(forms.ModelForm): class Meta: model = Category exclude = []<commit_msg>Add validation on category parent field<commit_after>from django import forms from django.utils.translation import ugettext_lazy...
7b9206d7c3fcf91c6ac16b54b9e1d13b92f7802a
tests/test_testing.py
tests/test_testing.py
# Copyright (c) 2019 MetPy Developers. # Distributed under the terms of the BSD 3-Clause License. # SPDX-License-Identifier: BSD-3-Clause """Test MetPy's testing utilities.""" import numpy as np import pytest from metpy.testing import assert_array_almost_equal # Test #1183: numpy.testing.assert_array* ignores an...
# Copyright (c) 2019 MetPy Developers. # Distributed under the terms of the BSD 3-Clause License. # SPDX-License-Identifier: BSD-3-Clause """Test MetPy's testing utilities.""" import warnings import numpy as np import pytest from metpy.deprecation import MetpyDeprecationWarning from metpy.testing import assert_arr...
Add explicit test for deprecation decorator
MNT: Add explicit test for deprecation decorator
Python
bsd-3-clause
dopplershift/MetPy,ShawnMurd/MetPy,ahaberlie/MetPy,Unidata/MetPy,Unidata/MetPy,ahaberlie/MetPy,dopplershift/MetPy
# Copyright (c) 2019 MetPy Developers. # Distributed under the terms of the BSD 3-Clause License. # SPDX-License-Identifier: BSD-3-Clause """Test MetPy's testing utilities.""" import numpy as np import pytest from metpy.testing import assert_array_almost_equal # Test #1183: numpy.testing.assert_array* ignores an...
# Copyright (c) 2019 MetPy Developers. # Distributed under the terms of the BSD 3-Clause License. # SPDX-License-Identifier: BSD-3-Clause """Test MetPy's testing utilities.""" import warnings import numpy as np import pytest from metpy.deprecation import MetpyDeprecationWarning from metpy.testing import assert_arr...
<commit_before># Copyright (c) 2019 MetPy Developers. # Distributed under the terms of the BSD 3-Clause License. # SPDX-License-Identifier: BSD-3-Clause """Test MetPy's testing utilities.""" import numpy as np import pytest from metpy.testing import assert_array_almost_equal # Test #1183: numpy.testing.assert_ar...
# Copyright (c) 2019 MetPy Developers. # Distributed under the terms of the BSD 3-Clause License. # SPDX-License-Identifier: BSD-3-Clause """Test MetPy's testing utilities.""" import warnings import numpy as np import pytest from metpy.deprecation import MetpyDeprecationWarning from metpy.testing import assert_arr...
# Copyright (c) 2019 MetPy Developers. # Distributed under the terms of the BSD 3-Clause License. # SPDX-License-Identifier: BSD-3-Clause """Test MetPy's testing utilities.""" import numpy as np import pytest from metpy.testing import assert_array_almost_equal # Test #1183: numpy.testing.assert_array* ignores an...
<commit_before># Copyright (c) 2019 MetPy Developers. # Distributed under the terms of the BSD 3-Clause License. # SPDX-License-Identifier: BSD-3-Clause """Test MetPy's testing utilities.""" import numpy as np import pytest from metpy.testing import assert_array_almost_equal # Test #1183: numpy.testing.assert_ar...
fd39c97cd1cab3e55ba6aa067127af93e41af506
tests/travis-setup.py
tests/travis-setup.py
import bcrypt import sys import os sys.path.insert(0, "..") from timpani import database connection = database.DatabaseConnection() hashedpassword = bcrypt.hashpw(bytes("password", "utf-8"), bcrypt.gensalt()).decode("utf-8") user = database.tables.User(username = "tests", password = hashedpassword, full_name = "Timpan...
import bcrypt import sys import os sys.path.insert(0, "..") from timpani import database connection = database.DatabaseConnection() hashedpassword = bcrypt.hashpw(bytes("password", "utf-8"), bcrypt.gensalt()).decode("utf-8") user = database.tables.User(username = "tests", password = hashedpassword, full_name = "Timpan...
Create index on session_id in order to speed tests
Create index on session_id in order to speed tests It seems that session querying has been the longest component of all my tests, and adding one test raised my test time signifigantly. Hopefully this smooths somet of that out.
Python
mit
ollien/Timpani,ollien/Timpani,ollien/Timpani
import bcrypt import sys import os sys.path.insert(0, "..") from timpani import database connection = database.DatabaseConnection() hashedpassword = bcrypt.hashpw(bytes("password", "utf-8"), bcrypt.gensalt()).decode("utf-8") user = database.tables.User(username = "tests", password = hashedpassword, full_name = "Timpan...
import bcrypt import sys import os sys.path.insert(0, "..") from timpani import database connection = database.DatabaseConnection() hashedpassword = bcrypt.hashpw(bytes("password", "utf-8"), bcrypt.gensalt()).decode("utf-8") user = database.tables.User(username = "tests", password = hashedpassword, full_name = "Timpan...
<commit_before>import bcrypt import sys import os sys.path.insert(0, "..") from timpani import database connection = database.DatabaseConnection() hashedpassword = bcrypt.hashpw(bytes("password", "utf-8"), bcrypt.gensalt()).decode("utf-8") user = database.tables.User(username = "tests", password = hashedpassword, full...
import bcrypt import sys import os sys.path.insert(0, "..") from timpani import database connection = database.DatabaseConnection() hashedpassword = bcrypt.hashpw(bytes("password", "utf-8"), bcrypt.gensalt()).decode("utf-8") user = database.tables.User(username = "tests", password = hashedpassword, full_name = "Timpan...
import bcrypt import sys import os sys.path.insert(0, "..") from timpani import database connection = database.DatabaseConnection() hashedpassword = bcrypt.hashpw(bytes("password", "utf-8"), bcrypt.gensalt()).decode("utf-8") user = database.tables.User(username = "tests", password = hashedpassword, full_name = "Timpan...
<commit_before>import bcrypt import sys import os sys.path.insert(0, "..") from timpani import database connection = database.DatabaseConnection() hashedpassword = bcrypt.hashpw(bytes("password", "utf-8"), bcrypt.gensalt()).decode("utf-8") user = database.tables.User(username = "tests", password = hashedpassword, full...
f745a1cd6b5f8b0991c7af4f631b8b5c09bf79f5
tailorscad/tests/test_arg_parser.py
tailorscad/tests/test_arg_parser.py
import unittest from tailorscad.arg_parser import parse_args class TestArgParser(unittest.TestCase): def test_parse_args_none(self): args = [] argv = [] args = parse_args(argv) self.assertFalse(args.config) def test_parse_args_inknown(self): args = [] ar...
import unittest from tailorscad.arg_parser import parse_args # TODO: Making the config require required some changes I don't like to this class TestArgParser(unittest.TestCase): def test_parse_args_known(self): args = [] argv = ['-c', 'test'] args = parse_args(argv) self.asse...
Remove some tests because of new required arg
Remove some tests because of new required arg
Python
mit
savorywatt/tailorSCAD
import unittest from tailorscad.arg_parser import parse_args class TestArgParser(unittest.TestCase): def test_parse_args_none(self): args = [] argv = [] args = parse_args(argv) self.assertFalse(args.config) def test_parse_args_inknown(self): args = [] ar...
import unittest from tailorscad.arg_parser import parse_args # TODO: Making the config require required some changes I don't like to this class TestArgParser(unittest.TestCase): def test_parse_args_known(self): args = [] argv = ['-c', 'test'] args = parse_args(argv) self.asse...
<commit_before> import unittest from tailorscad.arg_parser import parse_args class TestArgParser(unittest.TestCase): def test_parse_args_none(self): args = [] argv = [] args = parse_args(argv) self.assertFalse(args.config) def test_parse_args_inknown(self): args ...
import unittest from tailorscad.arg_parser import parse_args # TODO: Making the config require required some changes I don't like to this class TestArgParser(unittest.TestCase): def test_parse_args_known(self): args = [] argv = ['-c', 'test'] args = parse_args(argv) self.asse...
import unittest from tailorscad.arg_parser import parse_args class TestArgParser(unittest.TestCase): def test_parse_args_none(self): args = [] argv = [] args = parse_args(argv) self.assertFalse(args.config) def test_parse_args_inknown(self): args = [] ar...
<commit_before> import unittest from tailorscad.arg_parser import parse_args class TestArgParser(unittest.TestCase): def test_parse_args_none(self): args = [] argv = [] args = parse_args(argv) self.assertFalse(args.config) def test_parse_args_inknown(self): args ...
25133d90fe267dba522c9b87eb0bd614ae8556dd
web_433Mhz/views.py
web_433Mhz/views.py
from web_433Mhz import app from flask import render_template @app.route('/', methods=['GET', 'POST']) def index(): return render_template('index.html')
from web_433Mhz import app from flask import render_template, jsonify import subprocess import os @app.route('/', methods=['GET', 'POST']) def index(): return render_template('index.html') @app.route('/api/get_code', methods=['GET']) def get_code(): proc = subprocess.Popen(os.path.abspath('../433Mhz'),\ ...
Add api call to open binary and grab stdout
Add api call to open binary and grab stdout
Python
agpl-3.0
tuxxy/433Mhz_web,tuxxy/433Mhz_web,tuxxy/433Mhz_web,tuxxy/433Mhz_web
from web_433Mhz import app from flask import render_template @app.route('/', methods=['GET', 'POST']) def index(): return render_template('index.html') Add api call to open binary and grab stdout
from web_433Mhz import app from flask import render_template, jsonify import subprocess import os @app.route('/', methods=['GET', 'POST']) def index(): return render_template('index.html') @app.route('/api/get_code', methods=['GET']) def get_code(): proc = subprocess.Popen(os.path.abspath('../433Mhz'),\ ...
<commit_before>from web_433Mhz import app from flask import render_template @app.route('/', methods=['GET', 'POST']) def index(): return render_template('index.html') <commit_msg>Add api call to open binary and grab stdout<commit_after>
from web_433Mhz import app from flask import render_template, jsonify import subprocess import os @app.route('/', methods=['GET', 'POST']) def index(): return render_template('index.html') @app.route('/api/get_code', methods=['GET']) def get_code(): proc = subprocess.Popen(os.path.abspath('../433Mhz'),\ ...
from web_433Mhz import app from flask import render_template @app.route('/', methods=['GET', 'POST']) def index(): return render_template('index.html') Add api call to open binary and grab stdoutfrom web_433Mhz import app from flask import render_template, jsonify import subprocess import os @app.route('/', meth...
<commit_before>from web_433Mhz import app from flask import render_template @app.route('/', methods=['GET', 'POST']) def index(): return render_template('index.html') <commit_msg>Add api call to open binary and grab stdout<commit_after>from web_433Mhz import app from flask import render_template, jsonify import s...
7d28f4e101200515152f3281aafdda1315d290fc
scheduler/schedule.py
scheduler/schedule.py
import sys import time import logging logging.basicConfig(level=logging.DEBUG) from redis import StrictRedis from rq import Queue from apscheduler.schedulers.blocking import BlockingScheduler from d1lod import jobs conn = StrictRedis(host='redis', port='6379') q = Queue(connection=conn) sched = BlockingScheduler() ...
import sys import time import logging logging.basicConfig(level=logging.DEBUG) from redis import StrictRedis from rq import Queue from apscheduler.schedulers.blocking import BlockingScheduler from d1lod import jobs conn = StrictRedis(host='redis', port='6379') q = Queue(connection=conn) sched = BlockingScheduler() ...
Increase timeout of update_graph job to 7 days
Increase timeout of update_graph job to 7 days
Python
apache-2.0
ec-geolink/d1lod,ec-geolink/d1lod,ec-geolink/d1lod,ec-geolink/d1lod
import sys import time import logging logging.basicConfig(level=logging.DEBUG) from redis import StrictRedis from rq import Queue from apscheduler.schedulers.blocking import BlockingScheduler from d1lod import jobs conn = StrictRedis(host='redis', port='6379') q = Queue(connection=conn) sched = BlockingScheduler() ...
import sys import time import logging logging.basicConfig(level=logging.DEBUG) from redis import StrictRedis from rq import Queue from apscheduler.schedulers.blocking import BlockingScheduler from d1lod import jobs conn = StrictRedis(host='redis', port='6379') q = Queue(connection=conn) sched = BlockingScheduler() ...
<commit_before>import sys import time import logging logging.basicConfig(level=logging.DEBUG) from redis import StrictRedis from rq import Queue from apscheduler.schedulers.blocking import BlockingScheduler from d1lod import jobs conn = StrictRedis(host='redis', port='6379') q = Queue(connection=conn) sched = Block...
import sys import time import logging logging.basicConfig(level=logging.DEBUG) from redis import StrictRedis from rq import Queue from apscheduler.schedulers.blocking import BlockingScheduler from d1lod import jobs conn = StrictRedis(host='redis', port='6379') q = Queue(connection=conn) sched = BlockingScheduler() ...
import sys import time import logging logging.basicConfig(level=logging.DEBUG) from redis import StrictRedis from rq import Queue from apscheduler.schedulers.blocking import BlockingScheduler from d1lod import jobs conn = StrictRedis(host='redis', port='6379') q = Queue(connection=conn) sched = BlockingScheduler() ...
<commit_before>import sys import time import logging logging.basicConfig(level=logging.DEBUG) from redis import StrictRedis from rq import Queue from apscheduler.schedulers.blocking import BlockingScheduler from d1lod import jobs conn = StrictRedis(host='redis', port='6379') q = Queue(connection=conn) sched = Block...
5c30173731d058b51d7a94238a3ccf5984e2e790
echo_server.py
echo_server.py
#!/usr/bin/env python import socket def main(): server_socket = socket.socket(socket.AF_INET, socket.SOCK_STREAM, socket.IPPROTO_IP) server_socket.bind(('127.0.0.1', 50000)) server_socket.listen(1) conn, addr = server_socket.accept() msg = conn.recv(1024) conn...
#!/usr/bin/env python import socket def main(): server_socket = socket.socket( socket.AF_INET, socket.SOCK_STREAM, socket.IPPROTO_IP) server_socket.bind(('127.0.0.1', 50000)) server_socket.listen(1) conn, addr = server_socket.accept() msg = conn.recv(1024) conn.sendall(...
Change format to satify pedantic linter
Change format to satify pedantic linter
Python
mit
charlieRode/network_tools
#!/usr/bin/env python import socket def main(): server_socket = socket.socket(socket.AF_INET, socket.SOCK_STREAM, socket.IPPROTO_IP) server_socket.bind(('127.0.0.1', 50000)) server_socket.listen(1) conn, addr = server_socket.accept() msg = conn.recv(1024) conn...
#!/usr/bin/env python import socket def main(): server_socket = socket.socket( socket.AF_INET, socket.SOCK_STREAM, socket.IPPROTO_IP) server_socket.bind(('127.0.0.1', 50000)) server_socket.listen(1) conn, addr = server_socket.accept() msg = conn.recv(1024) conn.sendall(...
<commit_before>#!/usr/bin/env python import socket def main(): server_socket = socket.socket(socket.AF_INET, socket.SOCK_STREAM, socket.IPPROTO_IP) server_socket.bind(('127.0.0.1', 50000)) server_socket.listen(1) conn, addr = server_socket.accept() msg = conn.recv...
#!/usr/bin/env python import socket def main(): server_socket = socket.socket( socket.AF_INET, socket.SOCK_STREAM, socket.IPPROTO_IP) server_socket.bind(('127.0.0.1', 50000)) server_socket.listen(1) conn, addr = server_socket.accept() msg = conn.recv(1024) conn.sendall(...
#!/usr/bin/env python import socket def main(): server_socket = socket.socket(socket.AF_INET, socket.SOCK_STREAM, socket.IPPROTO_IP) server_socket.bind(('127.0.0.1', 50000)) server_socket.listen(1) conn, addr = server_socket.accept() msg = conn.recv(1024) conn...
<commit_before>#!/usr/bin/env python import socket def main(): server_socket = socket.socket(socket.AF_INET, socket.SOCK_STREAM, socket.IPPROTO_IP) server_socket.bind(('127.0.0.1', 50000)) server_socket.listen(1) conn, addr = server_socket.accept() msg = conn.recv...
76ecb6a4b71d1a248b21cf1671360514dc6c3be2
mobile/backends/twilio.py
mobile/backends/twilio.py
# encoding: utf-8 from twilio.rest import TwilioRestClient from mobile.backends.base import BaseBackend class Backend(BaseBackend): """Twilio Gate Backend.""" class SMS: @classmethod def send(self, recipient, sender, message): """ Send an SMS and return its initial de...
# encoding: utf-8 import twilio.twiml from django.http import QueryDict from twilio.rest import TwilioRestClient from mobile.backends.base import BaseBackend import mobile.models class Backend(BaseBackend): """Twilio Gate Backend.""" class SMS: @classmethod def send(self, recipient, sender...
Add receive support to Twilio backend
Add receive support to Twilio backend
Python
mit
hyperoslo/django-mobile
# encoding: utf-8 from twilio.rest import TwilioRestClient from mobile.backends.base import BaseBackend class Backend(BaseBackend): """Twilio Gate Backend.""" class SMS: @classmethod def send(self, recipient, sender, message): """ Send an SMS and return its initial de...
# encoding: utf-8 import twilio.twiml from django.http import QueryDict from twilio.rest import TwilioRestClient from mobile.backends.base import BaseBackend import mobile.models class Backend(BaseBackend): """Twilio Gate Backend.""" class SMS: @classmethod def send(self, recipient, sender...
<commit_before># encoding: utf-8 from twilio.rest import TwilioRestClient from mobile.backends.base import BaseBackend class Backend(BaseBackend): """Twilio Gate Backend.""" class SMS: @classmethod def send(self, recipient, sender, message): """ Send an SMS and return...
# encoding: utf-8 import twilio.twiml from django.http import QueryDict from twilio.rest import TwilioRestClient from mobile.backends.base import BaseBackend import mobile.models class Backend(BaseBackend): """Twilio Gate Backend.""" class SMS: @classmethod def send(self, recipient, sender...
# encoding: utf-8 from twilio.rest import TwilioRestClient from mobile.backends.base import BaseBackend class Backend(BaseBackend): """Twilio Gate Backend.""" class SMS: @classmethod def send(self, recipient, sender, message): """ Send an SMS and return its initial de...
<commit_before># encoding: utf-8 from twilio.rest import TwilioRestClient from mobile.backends.base import BaseBackend class Backend(BaseBackend): """Twilio Gate Backend.""" class SMS: @classmethod def send(self, recipient, sender, message): """ Send an SMS and return...
a6e868803e1336d83ee8863d15896880603fc777
tornwamp/customize.py
tornwamp/customize.py
""" TornWAMP user-configurable structures. """ from tornwamp.processors import GoodbyeProcessor, HelloProcessor, pubsub, rpc from tornwamp.messages import Code processors = { Code.HELLO: HelloProcessor, Code.GOODBYE: GoodbyeProcessor, Code.SUBSCRIBE: pubsub.SubscribeProcessor, Code.CALL: rpc.CallProces...
""" TornWAMP user-configurable structures. """ from tornwamp.processors import GoodbyeProcessor, HelloProcessor, pubsub, rpc from tornwamp.messages import Code processors = { Code.HELLO: HelloProcessor, Code.GOODBYE: GoodbyeProcessor, Code.SUBSCRIBE: pubsub.SubscribeProcessor, Code.CALL: rpc.CallProces...
Add PublishProcessor to processors' list
Add PublishProcessor to processors' list
Python
apache-2.0
ef-ctx/tornwamp
""" TornWAMP user-configurable structures. """ from tornwamp.processors import GoodbyeProcessor, HelloProcessor, pubsub, rpc from tornwamp.messages import Code processors = { Code.HELLO: HelloProcessor, Code.GOODBYE: GoodbyeProcessor, Code.SUBSCRIBE: pubsub.SubscribeProcessor, Code.CALL: rpc.CallProces...
""" TornWAMP user-configurable structures. """ from tornwamp.processors import GoodbyeProcessor, HelloProcessor, pubsub, rpc from tornwamp.messages import Code processors = { Code.HELLO: HelloProcessor, Code.GOODBYE: GoodbyeProcessor, Code.SUBSCRIBE: pubsub.SubscribeProcessor, Code.CALL: rpc.CallProces...
<commit_before>""" TornWAMP user-configurable structures. """ from tornwamp.processors import GoodbyeProcessor, HelloProcessor, pubsub, rpc from tornwamp.messages import Code processors = { Code.HELLO: HelloProcessor, Code.GOODBYE: GoodbyeProcessor, Code.SUBSCRIBE: pubsub.SubscribeProcessor, Code.CALL:...
""" TornWAMP user-configurable structures. """ from tornwamp.processors import GoodbyeProcessor, HelloProcessor, pubsub, rpc from tornwamp.messages import Code processors = { Code.HELLO: HelloProcessor, Code.GOODBYE: GoodbyeProcessor, Code.SUBSCRIBE: pubsub.SubscribeProcessor, Code.CALL: rpc.CallProces...
""" TornWAMP user-configurable structures. """ from tornwamp.processors import GoodbyeProcessor, HelloProcessor, pubsub, rpc from tornwamp.messages import Code processors = { Code.HELLO: HelloProcessor, Code.GOODBYE: GoodbyeProcessor, Code.SUBSCRIBE: pubsub.SubscribeProcessor, Code.CALL: rpc.CallProces...
<commit_before>""" TornWAMP user-configurable structures. """ from tornwamp.processors import GoodbyeProcessor, HelloProcessor, pubsub, rpc from tornwamp.messages import Code processors = { Code.HELLO: HelloProcessor, Code.GOODBYE: GoodbyeProcessor, Code.SUBSCRIBE: pubsub.SubscribeProcessor, Code.CALL:...
b2e0a123631d326f06192a01758ebe581284dbdf
src/pip/_internal/operations/generate_metadata.py
src/pip/_internal/operations/generate_metadata.py
"""Metadata generation logic for source distributions. """ def get_metadata_generator(install_req): if install_req.use_pep517: return install_req.prepare_pep517_metadata else: return install_req.run_egg_info
"""Metadata generation logic for source distributions. """ def get_metadata_generator(install_req): if not install_req.use_pep517: return install_req.run_egg_info return install_req.prepare_pep517_metadata
Return early for legacy processes
Return early for legacy processes
Python
mit
xavfernandez/pip,pfmoore/pip,rouge8/pip,rouge8/pip,pradyunsg/pip,rouge8/pip,pfmoore/pip,sbidoul/pip,xavfernandez/pip,pypa/pip,pradyunsg/pip,xavfernandez/pip,pypa/pip,sbidoul/pip
"""Metadata generation logic for source distributions. """ def get_metadata_generator(install_req): if install_req.use_pep517: return install_req.prepare_pep517_metadata else: return install_req.run_egg_info Return early for legacy processes
"""Metadata generation logic for source distributions. """ def get_metadata_generator(install_req): if not install_req.use_pep517: return install_req.run_egg_info return install_req.prepare_pep517_metadata
<commit_before>"""Metadata generation logic for source distributions. """ def get_metadata_generator(install_req): if install_req.use_pep517: return install_req.prepare_pep517_metadata else: return install_req.run_egg_info <commit_msg>Return early for legacy processes<commit_after>
"""Metadata generation logic for source distributions. """ def get_metadata_generator(install_req): if not install_req.use_pep517: return install_req.run_egg_info return install_req.prepare_pep517_metadata
"""Metadata generation logic for source distributions. """ def get_metadata_generator(install_req): if install_req.use_pep517: return install_req.prepare_pep517_metadata else: return install_req.run_egg_info Return early for legacy processes"""Metadata generation logic for source distributions...
<commit_before>"""Metadata generation logic for source distributions. """ def get_metadata_generator(install_req): if install_req.use_pep517: return install_req.prepare_pep517_metadata else: return install_req.run_egg_info <commit_msg>Return early for legacy processes<commit_after>"""Metadata ...
6456cfa00361a16fe53dfd62052d03567bcd66c0
clifford/_version.py
clifford/_version.py
# Package versioning solution originally found here: # http://stackoverflow.com/q/458550 # Store the version here so: # 1) we don't load dependencies by storing it in __init__.py # 2) we can import it in setup.py for the same reason # 3) we can import it into your module __version__ = '1.2.0'
# Package versioning solution originally found here: # http://stackoverflow.com/q/458550 # Store the version here so: # 1) we don't load dependencies by storing it in __init__.py # 2) we can import it in setup.py for the same reason # 3) we can import it into your module __version__ = '1.3.0dev0'
Create a pre-release version for PyPI, to test the new readme format.
Create a pre-release version for PyPI, to test the new readme format.
Python
bsd-3-clause
arsenovic/clifford,arsenovic/clifford
# Package versioning solution originally found here: # http://stackoverflow.com/q/458550 # Store the version here so: # 1) we don't load dependencies by storing it in __init__.py # 2) we can import it in setup.py for the same reason # 3) we can import it into your module __version__ = '1.2.0' Create a pre-release vers...
# Package versioning solution originally found here: # http://stackoverflow.com/q/458550 # Store the version here so: # 1) we don't load dependencies by storing it in __init__.py # 2) we can import it in setup.py for the same reason # 3) we can import it into your module __version__ = '1.3.0dev0'
<commit_before># Package versioning solution originally found here: # http://stackoverflow.com/q/458550 # Store the version here so: # 1) we don't load dependencies by storing it in __init__.py # 2) we can import it in setup.py for the same reason # 3) we can import it into your module __version__ = '1.2.0' <commit_ms...
# Package versioning solution originally found here: # http://stackoverflow.com/q/458550 # Store the version here so: # 1) we don't load dependencies by storing it in __init__.py # 2) we can import it in setup.py for the same reason # 3) we can import it into your module __version__ = '1.3.0dev0'
# Package versioning solution originally found here: # http://stackoverflow.com/q/458550 # Store the version here so: # 1) we don't load dependencies by storing it in __init__.py # 2) we can import it in setup.py for the same reason # 3) we can import it into your module __version__ = '1.2.0' Create a pre-release vers...
<commit_before># Package versioning solution originally found here: # http://stackoverflow.com/q/458550 # Store the version here so: # 1) we don't load dependencies by storing it in __init__.py # 2) we can import it in setup.py for the same reason # 3) we can import it into your module __version__ = '1.2.0' <commit_ms...
99b668594582882bb1fbca3b3793ff452edac2c1
updatebot/__init__.py
updatebot/__init__.py
# # Copyright (c) SAS Institute, 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 ...
# # Copyright (c) SAS Institute, 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 ...
Remove import of missing module
Remove import of missing module
Python
apache-2.0
sassoftware/mirrorball,sassoftware/mirrorball
# # Copyright (c) SAS Institute, 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 ...
# # Copyright (c) SAS Institute, 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 ...
<commit_before># # Copyright (c) SAS Institute, 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 o...
# # Copyright (c) SAS Institute, 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 ...
# # Copyright (c) SAS Institute, 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 ...
<commit_before># # Copyright (c) SAS Institute, 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 o...
f4777e994a29a8dbc704950411156cca4ff59ac3
oscar/core/compat.py
oscar/core/compat.py
from django.conf import settings from django.contrib.auth.models import User def get_user_model(): """ Return the User model Using this function instead of Django 1.5's get_user_model allows backwards compatibility with Django 1.4. """ try: # Django 1.5+ from django.contrib.au...
from django.conf import settings from django.contrib.auth.models import User from django.core.exceptions import ImproperlyConfigured def get_user_model(): """ Return the User model Using this function instead of Django 1.5's get_user_model allows backwards compatibility with Django 1.4. """ t...
Use better exception for AUTH_USER_MODEL
Use better exception for AUTH_USER_MODEL If AUTH_USER_MODEL is improperly configured as 'project.customer.User', the error is: ValueError: too many values to unpack Use rather standard Django's error: ImproperlyConfigured: AUTH_USER_MODEL must be of the form 'app_label.model_name'
Python
bsd-3-clause
faratro/django-oscar,rocopartners/django-oscar,thechampanurag/django-oscar,spartonia/django-oscar,vovanbo/django-oscar,saadatqadri/django-oscar,sasha0/django-oscar,pdonadeo/django-oscar,monikasulik/django-oscar,bschuon/django-oscar,mexeniz/django-oscar,jinnykoo/christmas,QLGu/django-oscar,manevant/django-oscar,jinnykoo...
from django.conf import settings from django.contrib.auth.models import User def get_user_model(): """ Return the User model Using this function instead of Django 1.5's get_user_model allows backwards compatibility with Django 1.4. """ try: # Django 1.5+ from django.contrib.au...
from django.conf import settings from django.contrib.auth.models import User from django.core.exceptions import ImproperlyConfigured def get_user_model(): """ Return the User model Using this function instead of Django 1.5's get_user_model allows backwards compatibility with Django 1.4. """ t...
<commit_before>from django.conf import settings from django.contrib.auth.models import User def get_user_model(): """ Return the User model Using this function instead of Django 1.5's get_user_model allows backwards compatibility with Django 1.4. """ try: # Django 1.5+ from dj...
from django.conf import settings from django.contrib.auth.models import User from django.core.exceptions import ImproperlyConfigured def get_user_model(): """ Return the User model Using this function instead of Django 1.5's get_user_model allows backwards compatibility with Django 1.4. """ t...
from django.conf import settings from django.contrib.auth.models import User def get_user_model(): """ Return the User model Using this function instead of Django 1.5's get_user_model allows backwards compatibility with Django 1.4. """ try: # Django 1.5+ from django.contrib.au...
<commit_before>from django.conf import settings from django.contrib.auth.models import User def get_user_model(): """ Return the User model Using this function instead of Django 1.5's get_user_model allows backwards compatibility with Django 1.4. """ try: # Django 1.5+ from dj...
e280ae4d1780448c8940b060d151c0668c205f91
parquet/bitstring.py
parquet/bitstring.py
SINGLE_BIT_MASK = [1 << x for x in range(7, -1, -1)] class BitString(object): def __init__(self, bytes, length=None, offset=None): self.bytes = bytes self.offset = offset if offset is not None else 0 self.length = length if length is not None else 8 * len(data) - self.offset def __getitem__(self, key): ...
SINGLE_BIT_MASK = [1 << x for x in range(7, -1, -1)] class BitString(object): def __init__(self, bytes, length=None, offset=None): self.bytes = bytes self.offset = offset if offset is not None else 0 self.length = length if length is not None else 8 * len(data) - self.offset def __getitem__(self, key): ...
Add closing paren to tuple expression
Add closing paren to tuple expression Under Python 2.7.6, this file didn't compile for me as-is. I still need to clone and rerun the test suite, but I thought I'd try Github's nifty "fork and edit online" feature. Will comment again when the tests pass.
Python
apache-2.0
cloudera/hue,cloudera/hue,lumig242/Hue-Integration-with-CDAP,kawamon/hue,xq262144/hue,lumig242/Hue-Integration-with-CDAP,fangxingli/hue,Peddle/hue,h4ck3rm1k3/parquet-python,todaychi/hue,kawamon/hue,cloudera/hue,cloudera/hue,todaychi/hue,xq262144/hue,Peddle/hue,jjmleiro/hue,jjmleiro/hue,jjmleiro/hue,jcrobak/parquet-pyth...
SINGLE_BIT_MASK = [1 << x for x in range(7, -1, -1)] class BitString(object): def __init__(self, bytes, length=None, offset=None): self.bytes = bytes self.offset = offset if offset is not None else 0 self.length = length if length is not None else 8 * len(data) - self.offset def __getitem__(self, key): ...
SINGLE_BIT_MASK = [1 << x for x in range(7, -1, -1)] class BitString(object): def __init__(self, bytes, length=None, offset=None): self.bytes = bytes self.offset = offset if offset is not None else 0 self.length = length if length is not None else 8 * len(data) - self.offset def __getitem__(self, key): ...
<commit_before> SINGLE_BIT_MASK = [1 << x for x in range(7, -1, -1)] class BitString(object): def __init__(self, bytes, length=None, offset=None): self.bytes = bytes self.offset = offset if offset is not None else 0 self.length = length if length is not None else 8 * len(data) - self.offset def __getitem_...
SINGLE_BIT_MASK = [1 << x for x in range(7, -1, -1)] class BitString(object): def __init__(self, bytes, length=None, offset=None): self.bytes = bytes self.offset = offset if offset is not None else 0 self.length = length if length is not None else 8 * len(data) - self.offset def __getitem__(self, key): ...
SINGLE_BIT_MASK = [1 << x for x in range(7, -1, -1)] class BitString(object): def __init__(self, bytes, length=None, offset=None): self.bytes = bytes self.offset = offset if offset is not None else 0 self.length = length if length is not None else 8 * len(data) - self.offset def __getitem__(self, key): ...
<commit_before> SINGLE_BIT_MASK = [1 << x for x in range(7, -1, -1)] class BitString(object): def __init__(self, bytes, length=None, offset=None): self.bytes = bytes self.offset = offset if offset is not None else 0 self.length = length if length is not None else 8 * len(data) - self.offset def __getitem_...
690c70db9717bcc538db4e35597145870106844f
versioning/signals.py
versioning/signals.py
import sha from django.contrib.contenttypes.models import ContentType from versioning import _registry from versioning.diff import unified_diff from versioning.models import Revision def pre_save(instance, **kwargs): """ """ model = kwargs["sender"] fields = _registry[model] original = mode...
import sha from django.contrib.contenttypes.models import ContentType from versioning import _registry from versioning.diff import unified_diff from versioning.models import Revision def pre_save(instance, **kwargs): """ """ model = kwargs["sender"] fields = _registry[model] original = mode...
Use splitlines instead of hard-coding the line endings.
Use splitlines instead of hard-coding the line endings. git-svn-id: 15b99a5ef70b6649222be30eb13433ba2eb40757@14 cdb1d5cb-5653-0410-9e46-1b5f511687a6
Python
bsd-3-clause
luzfcb/django-versioning,luzfcb/django-versioning
import sha from django.contrib.contenttypes.models import ContentType from versioning import _registry from versioning.diff import unified_diff from versioning.models import Revision def pre_save(instance, **kwargs): """ """ model = kwargs["sender"] fields = _registry[model] original = mode...
import sha from django.contrib.contenttypes.models import ContentType from versioning import _registry from versioning.diff import unified_diff from versioning.models import Revision def pre_save(instance, **kwargs): """ """ model = kwargs["sender"] fields = _registry[model] original = mode...
<commit_before> import sha from django.contrib.contenttypes.models import ContentType from versioning import _registry from versioning.diff import unified_diff from versioning.models import Revision def pre_save(instance, **kwargs): """ """ model = kwargs["sender"] fields = _registry[model] ...
import sha from django.contrib.contenttypes.models import ContentType from versioning import _registry from versioning.diff import unified_diff from versioning.models import Revision def pre_save(instance, **kwargs): """ """ model = kwargs["sender"] fields = _registry[model] original = mode...
import sha from django.contrib.contenttypes.models import ContentType from versioning import _registry from versioning.diff import unified_diff from versioning.models import Revision def pre_save(instance, **kwargs): """ """ model = kwargs["sender"] fields = _registry[model] original = mode...
<commit_before> import sha from django.contrib.contenttypes.models import ContentType from versioning import _registry from versioning.diff import unified_diff from versioning.models import Revision def pre_save(instance, **kwargs): """ """ model = kwargs["sender"] fields = _registry[model] ...
c79d040cb952e8e37c231caf90eda92d152978b8
openfisca_country_template/__init__.py
openfisca_country_template/__init__.py
# -*- coding: utf-8 -*- import os from openfisca_core.taxbenefitsystems import TaxBenefitSystem from . import entities COUNTRY_DIR = os.path.dirname(os.path.abspath(__file__)) # Our country tax and benefit class inherits from the general TaxBenefitSystem class. # The name CountryTaxBenefitSystem must not be chan...
# -*- coding: utf-8 -*- import os from openfisca_core.taxbenefitsystems import TaxBenefitSystem from . import entities COUNTRY_DIR = os.path.dirname(os.path.abspath(__file__)) # Our country tax and benefit class inherits from the general TaxBenefitSystem class. # The name CountryTaxBenefitSystem must not be chan...
Use YAML params instead of XML params
Use YAML params instead of XML params
Python
agpl-3.0
openfisca/country-template,openfisca/country-template
# -*- coding: utf-8 -*- import os from openfisca_core.taxbenefitsystems import TaxBenefitSystem from . import entities COUNTRY_DIR = os.path.dirname(os.path.abspath(__file__)) # Our country tax and benefit class inherits from the general TaxBenefitSystem class. # The name CountryTaxBenefitSystem must not be chan...
# -*- coding: utf-8 -*- import os from openfisca_core.taxbenefitsystems import TaxBenefitSystem from . import entities COUNTRY_DIR = os.path.dirname(os.path.abspath(__file__)) # Our country tax and benefit class inherits from the general TaxBenefitSystem class. # The name CountryTaxBenefitSystem must not be chan...
<commit_before># -*- coding: utf-8 -*- import os from openfisca_core.taxbenefitsystems import TaxBenefitSystem from . import entities COUNTRY_DIR = os.path.dirname(os.path.abspath(__file__)) # Our country tax and benefit class inherits from the general TaxBenefitSystem class. # The name CountryTaxBenefitSystem m...
# -*- coding: utf-8 -*- import os from openfisca_core.taxbenefitsystems import TaxBenefitSystem from . import entities COUNTRY_DIR = os.path.dirname(os.path.abspath(__file__)) # Our country tax and benefit class inherits from the general TaxBenefitSystem class. # The name CountryTaxBenefitSystem must not be chan...
# -*- coding: utf-8 -*- import os from openfisca_core.taxbenefitsystems import TaxBenefitSystem from . import entities COUNTRY_DIR = os.path.dirname(os.path.abspath(__file__)) # Our country tax and benefit class inherits from the general TaxBenefitSystem class. # The name CountryTaxBenefitSystem must not be chan...
<commit_before># -*- coding: utf-8 -*- import os from openfisca_core.taxbenefitsystems import TaxBenefitSystem from . import entities COUNTRY_DIR = os.path.dirname(os.path.abspath(__file__)) # Our country tax and benefit class inherits from the general TaxBenefitSystem class. # The name CountryTaxBenefitSystem m...
07bd41f4588570a3b026efad0a70d979f4bf8e5b
esis/__init__.py
esis/__init__.py
# -*- coding: utf-8 -*- """Elastic Search Index & Search.""" __author__ = 'Javier Collado' __email__ = 'jcollado@nowsecure.com' __version__ = '0.2.0'
# -*- coding: utf-8 -*- """Elastic Search Index & Search.""" __author__ = 'Javier Collado' __email__ = 'jcollado@nowsecure.com' __version__ = '0.2.0' from esis.es import Client
Make client available at the package level
Make client available at the package level This will make imports easier for anyone willing to use esis as a library
Python
mit
jcollado/esis
# -*- coding: utf-8 -*- """Elastic Search Index & Search.""" __author__ = 'Javier Collado' __email__ = 'jcollado@nowsecure.com' __version__ = '0.2.0' Make client available at the package level This will make imports easier for anyone willing to use esis as a library
# -*- coding: utf-8 -*- """Elastic Search Index & Search.""" __author__ = 'Javier Collado' __email__ = 'jcollado@nowsecure.com' __version__ = '0.2.0' from esis.es import Client
<commit_before># -*- coding: utf-8 -*- """Elastic Search Index & Search.""" __author__ = 'Javier Collado' __email__ = 'jcollado@nowsecure.com' __version__ = '0.2.0' <commit_msg>Make client available at the package level This will make imports easier for anyone willing to use esis as a library<commit_after>
# -*- coding: utf-8 -*- """Elastic Search Index & Search.""" __author__ = 'Javier Collado' __email__ = 'jcollado@nowsecure.com' __version__ = '0.2.0' from esis.es import Client
# -*- coding: utf-8 -*- """Elastic Search Index & Search.""" __author__ = 'Javier Collado' __email__ = 'jcollado@nowsecure.com' __version__ = '0.2.0' Make client available at the package level This will make imports easier for anyone willing to use esis as a library# -*- coding: utf-8 -*- """Elastic Search Index & Se...
<commit_before># -*- coding: utf-8 -*- """Elastic Search Index & Search.""" __author__ = 'Javier Collado' __email__ = 'jcollado@nowsecure.com' __version__ = '0.2.0' <commit_msg>Make client available at the package level This will make imports easier for anyone willing to use esis as a library<commit_after># -*- codin...
8f5f31ef9543ad345c894103dbda94358a5e4eee
apps/storybase_user/models.py
apps/storybase_user/models.py
from django.contrib.auth.models import User from django.db import models from uuidfield.fields import UUIDField from storybase.fields import ShortTextField class Organization(models.Model): """ An organization or a community group that users and stories can be associated with. """ organization_id = UUIDField(a...
from django.contrib.auth.models import User from django.db import models from uuidfield.fields import UUIDField from storybase.fields import ShortTextField class Organization(models.Model): """ An organization or a community group that users and stories can be associated with. """ organization_id = UUIDField(a...
Revert "Revert "Updated fields for Project model.""
Revert "Revert "Updated fields for Project model."" This reverts commit 726662d102453f7c7be5fb31499a8c4d5ab34444.
Python
mit
denverfoundation/storybase,denverfoundation/storybase,denverfoundation/storybase,denverfoundation/storybase
from django.contrib.auth.models import User from django.db import models from uuidfield.fields import UUIDField from storybase.fields import ShortTextField class Organization(models.Model): """ An organization or a community group that users and stories can be associated with. """ organization_id = UUIDField(a...
from django.contrib.auth.models import User from django.db import models from uuidfield.fields import UUIDField from storybase.fields import ShortTextField class Organization(models.Model): """ An organization or a community group that users and stories can be associated with. """ organization_id = UUIDField(a...
<commit_before>from django.contrib.auth.models import User from django.db import models from uuidfield.fields import UUIDField from storybase.fields import ShortTextField class Organization(models.Model): """ An organization or a community group that users and stories can be associated with. """ organization_i...
from django.contrib.auth.models import User from django.db import models from uuidfield.fields import UUIDField from storybase.fields import ShortTextField class Organization(models.Model): """ An organization or a community group that users and stories can be associated with. """ organization_id = UUIDField(a...
from django.contrib.auth.models import User from django.db import models from uuidfield.fields import UUIDField from storybase.fields import ShortTextField class Organization(models.Model): """ An organization or a community group that users and stories can be associated with. """ organization_id = UUIDField(a...
<commit_before>from django.contrib.auth.models import User from django.db import models from uuidfield.fields import UUIDField from storybase.fields import ShortTextField class Organization(models.Model): """ An organization or a community group that users and stories can be associated with. """ organization_i...
cc3f28e74145729c8b572fd9d2ed04d8fb297360
Testing/TestDICOMPython.py
Testing/TestDICOMPython.py
#! /usr/bin/env python2 import sys import vtk import vtkDICOMPython # put everything into the vtk namespace for a in dir(vtkDICOMPython): if a[0] != '_': setattr(vtk, a, getattr(vtkDICOMPython, a)) m = vtk.vtkDICOMMetaData() m.SetAttributeValue(vtk.vtkDICOMTag(0x0008, 0x0005), 'ISO_IR 100') v = m.GetAtt...
#! /usr/bin/env python2 import sys import vtk import vtkDICOMPython # put everything into the vtk namespace for a in dir(vtkDICOMPython): if a[0] != '_': setattr(vtk, a, getattr(vtkDICOMPython, a)) m = vtk.vtkDICOMMetaData() if vtk.vtkVersion.GetVTKMajorVersion() < 6: sys.stderr.write("This test req...
Modify python test for VTK 5.
Modify python test for VTK 5.
Python
bsd-3-clause
dgobbi/vtk-dicom,dgobbi/vtk-dicom,hendradarwin/vtk-dicom,dgobbi/vtk-dicom,hendradarwin/vtk-dicom,hendradarwin/vtk-dicom
#! /usr/bin/env python2 import sys import vtk import vtkDICOMPython # put everything into the vtk namespace for a in dir(vtkDICOMPython): if a[0] != '_': setattr(vtk, a, getattr(vtkDICOMPython, a)) m = vtk.vtkDICOMMetaData() m.SetAttributeValue(vtk.vtkDICOMTag(0x0008, 0x0005), 'ISO_IR 100') v = m.GetAtt...
#! /usr/bin/env python2 import sys import vtk import vtkDICOMPython # put everything into the vtk namespace for a in dir(vtkDICOMPython): if a[0] != '_': setattr(vtk, a, getattr(vtkDICOMPython, a)) m = vtk.vtkDICOMMetaData() if vtk.vtkVersion.GetVTKMajorVersion() < 6: sys.stderr.write("This test req...
<commit_before>#! /usr/bin/env python2 import sys import vtk import vtkDICOMPython # put everything into the vtk namespace for a in dir(vtkDICOMPython): if a[0] != '_': setattr(vtk, a, getattr(vtkDICOMPython, a)) m = vtk.vtkDICOMMetaData() m.SetAttributeValue(vtk.vtkDICOMTag(0x0008, 0x0005), 'ISO_IR 100'...
#! /usr/bin/env python2 import sys import vtk import vtkDICOMPython # put everything into the vtk namespace for a in dir(vtkDICOMPython): if a[0] != '_': setattr(vtk, a, getattr(vtkDICOMPython, a)) m = vtk.vtkDICOMMetaData() if vtk.vtkVersion.GetVTKMajorVersion() < 6: sys.stderr.write("This test req...
#! /usr/bin/env python2 import sys import vtk import vtkDICOMPython # put everything into the vtk namespace for a in dir(vtkDICOMPython): if a[0] != '_': setattr(vtk, a, getattr(vtkDICOMPython, a)) m = vtk.vtkDICOMMetaData() m.SetAttributeValue(vtk.vtkDICOMTag(0x0008, 0x0005), 'ISO_IR 100') v = m.GetAtt...
<commit_before>#! /usr/bin/env python2 import sys import vtk import vtkDICOMPython # put everything into the vtk namespace for a in dir(vtkDICOMPython): if a[0] != '_': setattr(vtk, a, getattr(vtkDICOMPython, a)) m = vtk.vtkDICOMMetaData() m.SetAttributeValue(vtk.vtkDICOMTag(0x0008, 0x0005), 'ISO_IR 100'...
5d9fa1838ffe7ffedb59453a0eca520b5f8d5849
pyscf/ci/__init__.py
pyscf/ci/__init__.py
from pyscf.ci.cisd import CISD
from pyscf.ci import cisd def CISD(mf, frozen=[], mo_coeff=None, mo_occ=None): from pyscf import scf if isinstance(mf, (scf.uhf.UHF, scf.rohf.ROHF)): raise NotImplementedError('RO-CISD, UCISD are not available in this pyscf version') return cisd.CISD(mf, frozen, mo_coeff, mo_occ)
Revert accidental changes to ci
Revert accidental changes to ci
Python
apache-2.0
gkc1000/pyscf,gkc1000/pyscf,gkc1000/pyscf,sunqm/pyscf,sunqm/pyscf,sunqm/pyscf,gkc1000/pyscf,gkc1000/pyscf,sunqm/pyscf
from pyscf.ci.cisd import CISD Revert accidental changes to ci
from pyscf.ci import cisd def CISD(mf, frozen=[], mo_coeff=None, mo_occ=None): from pyscf import scf if isinstance(mf, (scf.uhf.UHF, scf.rohf.ROHF)): raise NotImplementedError('RO-CISD, UCISD are not available in this pyscf version') return cisd.CISD(mf, frozen, mo_coeff, mo_occ)
<commit_before>from pyscf.ci.cisd import CISD <commit_msg>Revert accidental changes to ci<commit_after>
from pyscf.ci import cisd def CISD(mf, frozen=[], mo_coeff=None, mo_occ=None): from pyscf import scf if isinstance(mf, (scf.uhf.UHF, scf.rohf.ROHF)): raise NotImplementedError('RO-CISD, UCISD are not available in this pyscf version') return cisd.CISD(mf, frozen, mo_coeff, mo_occ)
from pyscf.ci.cisd import CISD Revert accidental changes to cifrom pyscf.ci import cisd def CISD(mf, frozen=[], mo_coeff=None, mo_occ=None): from pyscf import scf if isinstance(mf, (scf.uhf.UHF, scf.rohf.ROHF)): raise NotImplementedError('RO-CISD, UCISD are not available in this pyscf version')...
<commit_before>from pyscf.ci.cisd import CISD <commit_msg>Revert accidental changes to ci<commit_after>from pyscf.ci import cisd def CISD(mf, frozen=[], mo_coeff=None, mo_occ=None): from pyscf import scf if isinstance(mf, (scf.uhf.UHF, scf.rohf.ROHF)): raise NotImplementedError('RO-CISD, UCISD ...
f957a71b65336c403e876fc04eb45779b873c511
hapi/events.py
hapi/events.py
from base import BaseClient EVENTS_API_VERSION = 'v1' class EventsClient(BaseClient): def _get_path(self, subpath): return 'events/%s/%s' % (EVENTS_API_VERSION, subpath) def get_events(self, **options): return self._call('events', **options) def create_event(self, description,...
from base import BaseClient EVENTS_API_VERSION = 'v1' class EventsClient(BaseClient): def _get_path(self, subpath): return 'events/%s/%s' % (EVENTS_API_VERSION, subpath) def get_events(self, **options): return self._call('events', **options) def get_event(self, event_id, **optio...
Add method to fetch a single event
Add method to fetch a single event
Python
apache-2.0
jonathan-s/happy,CurataEng/hapipy,HubSpot/hapipy,CBitLabs/hapipy
from base import BaseClient EVENTS_API_VERSION = 'v1' class EventsClient(BaseClient): def _get_path(self, subpath): return 'events/%s/%s' % (EVENTS_API_VERSION, subpath) def get_events(self, **options): return self._call('events', **options) def create_event(self, description,...
from base import BaseClient EVENTS_API_VERSION = 'v1' class EventsClient(BaseClient): def _get_path(self, subpath): return 'events/%s/%s' % (EVENTS_API_VERSION, subpath) def get_events(self, **options): return self._call('events', **options) def get_event(self, event_id, **optio...
<commit_before>from base import BaseClient EVENTS_API_VERSION = 'v1' class EventsClient(BaseClient): def _get_path(self, subpath): return 'events/%s/%s' % (EVENTS_API_VERSION, subpath) def get_events(self, **options): return self._call('events', **options) def create_event(sel...
from base import BaseClient EVENTS_API_VERSION = 'v1' class EventsClient(BaseClient): def _get_path(self, subpath): return 'events/%s/%s' % (EVENTS_API_VERSION, subpath) def get_events(self, **options): return self._call('events', **options) def get_event(self, event_id, **optio...
from base import BaseClient EVENTS_API_VERSION = 'v1' class EventsClient(BaseClient): def _get_path(self, subpath): return 'events/%s/%s' % (EVENTS_API_VERSION, subpath) def get_events(self, **options): return self._call('events', **options) def create_event(self, description,...
<commit_before>from base import BaseClient EVENTS_API_VERSION = 'v1' class EventsClient(BaseClient): def _get_path(self, subpath): return 'events/%s/%s' % (EVENTS_API_VERSION, subpath) def get_events(self, **options): return self._call('events', **options) def create_event(sel...
2428dcc620fae28e3f7f5ed268ff4bffb96c4501
owney/managers.py
owney/managers.py
from django.db.models import Manager class ShipmentManager(Manager): """Returns Shipments that are not delivered""" def undelivered(self): return self.get_query_set().exclude(status__exact='delivered')
from django.db.models import Manager class ShipmentManager(Manager): """Returns Shipments that are not delivered""" def undelivered(self): return self.get_query_set().exclude(status='delivered')
Change filter syntax to be more direct.
Change filter syntax to be more direct.
Python
mit
JohnSpeno/owney
from django.db.models import Manager class ShipmentManager(Manager): """Returns Shipments that are not delivered""" def undelivered(self): return self.get_query_set().exclude(status__exact='delivered') Change filter syntax to be more direct.
from django.db.models import Manager class ShipmentManager(Manager): """Returns Shipments that are not delivered""" def undelivered(self): return self.get_query_set().exclude(status='delivered')
<commit_before>from django.db.models import Manager class ShipmentManager(Manager): """Returns Shipments that are not delivered""" def undelivered(self): return self.get_query_set().exclude(status__exact='delivered') <commit_msg>Change filter syntax to be more direct.<commit_after>
from django.db.models import Manager class ShipmentManager(Manager): """Returns Shipments that are not delivered""" def undelivered(self): return self.get_query_set().exclude(status='delivered')
from django.db.models import Manager class ShipmentManager(Manager): """Returns Shipments that are not delivered""" def undelivered(self): return self.get_query_set().exclude(status__exact='delivered') Change filter syntax to be more direct.from django.db.models import Manager class...
<commit_before>from django.db.models import Manager class ShipmentManager(Manager): """Returns Shipments that are not delivered""" def undelivered(self): return self.get_query_set().exclude(status__exact='delivered') <commit_msg>Change filter syntax to be more direct.<commit_after>from djan...
37d6c62e510c591a428d43bc6de8f7346de3781f
setmagic/__init__.py
setmagic/__init__.py
from setmagic.wrapper import SettingsWrapper # Initialize the magic settings = SettingsWrapper()
from setmagic.wrapper import SettingsWrapper # Initialize the magic setmagic = SettingsWrapper() # Support for backwards compatibility # @TODO: Drop at 0.4 settings = setmagic
Rename the built-in wrapper from "settings" to "setmagic"
Rename the built-in wrapper from "settings" to "setmagic"
Python
mit
7ws/django-setmagic
from setmagic.wrapper import SettingsWrapper # Initialize the magic settings = SettingsWrapper() Rename the built-in wrapper from "settings" to "setmagic"
from setmagic.wrapper import SettingsWrapper # Initialize the magic setmagic = SettingsWrapper() # Support for backwards compatibility # @TODO: Drop at 0.4 settings = setmagic
<commit_before>from setmagic.wrapper import SettingsWrapper # Initialize the magic settings = SettingsWrapper() <commit_msg>Rename the built-in wrapper from "settings" to "setmagic"<commit_after>
from setmagic.wrapper import SettingsWrapper # Initialize the magic setmagic = SettingsWrapper() # Support for backwards compatibility # @TODO: Drop at 0.4 settings = setmagic
from setmagic.wrapper import SettingsWrapper # Initialize the magic settings = SettingsWrapper() Rename the built-in wrapper from "settings" to "setmagic"from setmagic.wrapper import SettingsWrapper # Initialize the magic setmagic = SettingsWrapper() # Support for backwards compatibility # @TODO: Drop at 0.4 setti...
<commit_before>from setmagic.wrapper import SettingsWrapper # Initialize the magic settings = SettingsWrapper() <commit_msg>Rename the built-in wrapper from "settings" to "setmagic"<commit_after>from setmagic.wrapper import SettingsWrapper # Initialize the magic setmagic = SettingsWrapper() # Support for backwards...
7eb71da0822cdf6ea724a87662952fe90e65a6f6
UM/Operations/ScaleOperation.py
UM/Operations/ScaleOperation.py
# Copyright (c) 2015 Ultimaker B.V. # Uranium is released under the terms of the AGPLv3 or higher. from . import Operation from UM.Scene.SceneNode import SceneNode class ScaleOperation(Operation.Operation): def __init__(self, node, scale, **kwargs): super().__init__() self._node = node sel...
# Copyright (c) 2015 Ultimaker B.V. # Uranium is released under the terms of the AGPLv3 or higher. from . import Operation from UM.Scene.SceneNode import SceneNode class ScaleOperation(Operation.Operation): def __init__(self, node, scale, **kwargs): super().__init__() self._node = node sel...
Convert ScaleTool to use add_scale
Convert ScaleTool to use add_scale Contributes to Ultimaker/Uranium/#73 Contributes to Ultimaker/Cura/#493 contributes to #CURA-287 contributes to #CURA-235
Python
agpl-3.0
onitake/Uranium,onitake/Uranium
# Copyright (c) 2015 Ultimaker B.V. # Uranium is released under the terms of the AGPLv3 or higher. from . import Operation from UM.Scene.SceneNode import SceneNode class ScaleOperation(Operation.Operation): def __init__(self, node, scale, **kwargs): super().__init__() self._node = node sel...
# Copyright (c) 2015 Ultimaker B.V. # Uranium is released under the terms of the AGPLv3 or higher. from . import Operation from UM.Scene.SceneNode import SceneNode class ScaleOperation(Operation.Operation): def __init__(self, node, scale, **kwargs): super().__init__() self._node = node sel...
<commit_before># Copyright (c) 2015 Ultimaker B.V. # Uranium is released under the terms of the AGPLv3 or higher. from . import Operation from UM.Scene.SceneNode import SceneNode class ScaleOperation(Operation.Operation): def __init__(self, node, scale, **kwargs): super().__init__() self._node = n...
# Copyright (c) 2015 Ultimaker B.V. # Uranium is released under the terms of the AGPLv3 or higher. from . import Operation from UM.Scene.SceneNode import SceneNode class ScaleOperation(Operation.Operation): def __init__(self, node, scale, **kwargs): super().__init__() self._node = node sel...
# Copyright (c) 2015 Ultimaker B.V. # Uranium is released under the terms of the AGPLv3 or higher. from . import Operation from UM.Scene.SceneNode import SceneNode class ScaleOperation(Operation.Operation): def __init__(self, node, scale, **kwargs): super().__init__() self._node = node sel...
<commit_before># Copyright (c) 2015 Ultimaker B.V. # Uranium is released under the terms of the AGPLv3 or higher. from . import Operation from UM.Scene.SceneNode import SceneNode class ScaleOperation(Operation.Operation): def __init__(self, node, scale, **kwargs): super().__init__() self._node = n...
920c1cd03645bd04df59bdb1f52aab07c710746b
fabtools/__init__.py
fabtools/__init__.py
# Keep imports sorted alphabetically import fabtools.arch import fabtools.cron import fabtools.deb import fabtools.files import fabtools.git import fabtools.group import fabtools.mysql import fabtools.network import fabtools.nginx import fabtools.nodejs import fabtools.openvz import fabtools.pkg import fabtools.postgre...
# Keep imports sorted alphabetically import fabtools.arch import fabtools.cron import fabtools.deb import fabtools.disk import fabtools.files import fabtools.git import fabtools.group import fabtools.mysql import fabtools.network import fabtools.nginx import fabtools.nodejs import fabtools.openvz import fabtools.pkg im...
Add missing import for new disk module
Add missing import for new disk module
Python
bsd-2-clause
ahnjungho/fabtools,badele/fabtools,wagigi/fabtools-python,fabtools/fabtools,davidcaste/fabtools,AMOSoft/fabtools,prologic/fabtools,ronnix/fabtools,n0n0x/fabtools-python,pombredanne/fabtools,sociateru/fabtools,hagai26/fabtools,bitmonk/fabtools
# Keep imports sorted alphabetically import fabtools.arch import fabtools.cron import fabtools.deb import fabtools.files import fabtools.git import fabtools.group import fabtools.mysql import fabtools.network import fabtools.nginx import fabtools.nodejs import fabtools.openvz import fabtools.pkg import fabtools.postgre...
# Keep imports sorted alphabetically import fabtools.arch import fabtools.cron import fabtools.deb import fabtools.disk import fabtools.files import fabtools.git import fabtools.group import fabtools.mysql import fabtools.network import fabtools.nginx import fabtools.nodejs import fabtools.openvz import fabtools.pkg im...
<commit_before># Keep imports sorted alphabetically import fabtools.arch import fabtools.cron import fabtools.deb import fabtools.files import fabtools.git import fabtools.group import fabtools.mysql import fabtools.network import fabtools.nginx import fabtools.nodejs import fabtools.openvz import fabtools.pkg import f...
# Keep imports sorted alphabetically import fabtools.arch import fabtools.cron import fabtools.deb import fabtools.disk import fabtools.files import fabtools.git import fabtools.group import fabtools.mysql import fabtools.network import fabtools.nginx import fabtools.nodejs import fabtools.openvz import fabtools.pkg im...
# Keep imports sorted alphabetically import fabtools.arch import fabtools.cron import fabtools.deb import fabtools.files import fabtools.git import fabtools.group import fabtools.mysql import fabtools.network import fabtools.nginx import fabtools.nodejs import fabtools.openvz import fabtools.pkg import fabtools.postgre...
<commit_before># Keep imports sorted alphabetically import fabtools.arch import fabtools.cron import fabtools.deb import fabtools.files import fabtools.git import fabtools.group import fabtools.mysql import fabtools.network import fabtools.nginx import fabtools.nodejs import fabtools.openvz import fabtools.pkg import f...
7d28400cc11fec86f542f1a0b03df6b6ed0086ea
dipy/stats/__init__.py
dipy/stats/__init__.py
# code support tractometric statistical analysis for dipy
# code support tractometric statistical analysis for dipy import warnings w_string = "The `dipy.stats` module is still under heavy development " w_string += "and functionality, as well as the API is likely to change " w_string += "in future versions of the software" warnings.warn(w_string)
Add a warning about future changes that will happen in dipy.stats.
Add a warning about future changes that will happen in dipy.stats.
Python
bsd-3-clause
FrancoisRheaultUS/dipy,FrancoisRheaultUS/dipy
# code support tractometric statistical analysis for dipy Add a warning about future changes that will happen in dipy.stats.
# code support tractometric statistical analysis for dipy import warnings w_string = "The `dipy.stats` module is still under heavy development " w_string += "and functionality, as well as the API is likely to change " w_string += "in future versions of the software" warnings.warn(w_string)
<commit_before># code support tractometric statistical analysis for dipy <commit_msg>Add a warning about future changes that will happen in dipy.stats.<commit_after>
# code support tractometric statistical analysis for dipy import warnings w_string = "The `dipy.stats` module is still under heavy development " w_string += "and functionality, as well as the API is likely to change " w_string += "in future versions of the software" warnings.warn(w_string)
# code support tractometric statistical analysis for dipy Add a warning about future changes that will happen in dipy.stats.# code support tractometric statistical analysis for dipy import warnings w_string = "The `dipy.stats` module is still under heavy development " w_string += "and functionality, as well as the API...
<commit_before># code support tractometric statistical analysis for dipy <commit_msg>Add a warning about future changes that will happen in dipy.stats.<commit_after># code support tractometric statistical analysis for dipy import warnings w_string = "The `dipy.stats` module is still under heavy development " w_string ...
887c90bbe82fb0ddc85af0a2a9a294bd38677bda
test/lib/test_util.py
test/lib/test_util.py
import unittest import amara from amara.lib import util class Test_util(unittest.TestCase): def test_trim_word_count(self): x = amara.parse('<a>one two <b>three four </b><c>five <d>six seven</d> eight</c> nine</a>') for i in range(1, 11): trimmed_tree = util.trim_word_count(x, i) ...
import unittest import amara from amara.lib import util class Test_trim_word_count(unittest.TestCase): 'Testing amara.lib.util.trim_word_count' def test_flat_doc(self): 'Input doc with just top-level text' x = amara.parse('<a>one two three four five six seven eight nine</a>') for i in ...
Expand trim_word_count test a bit
Expand trim_word_count test a bit
Python
apache-2.0
zepheira/amara,zepheira/amara,zepheira/amara,zepheira/amara,zepheira/amara,zepheira/amara
import unittest import amara from amara.lib import util class Test_util(unittest.TestCase): def test_trim_word_count(self): x = amara.parse('<a>one two <b>three four </b><c>five <d>six seven</d> eight</c> nine</a>') for i in range(1, 11): trimmed_tree = util.trim_word_count(x, i) ...
import unittest import amara from amara.lib import util class Test_trim_word_count(unittest.TestCase): 'Testing amara.lib.util.trim_word_count' def test_flat_doc(self): 'Input doc with just top-level text' x = amara.parse('<a>one two three four five six seven eight nine</a>') for i in ...
<commit_before> import unittest import amara from amara.lib import util class Test_util(unittest.TestCase): def test_trim_word_count(self): x = amara.parse('<a>one two <b>three four </b><c>five <d>six seven</d> eight</c> nine</a>') for i in range(1, 11): trimmed_tree = util.trim_word_c...
import unittest import amara from amara.lib import util class Test_trim_word_count(unittest.TestCase): 'Testing amara.lib.util.trim_word_count' def test_flat_doc(self): 'Input doc with just top-level text' x = amara.parse('<a>one two three four five six seven eight nine</a>') for i in ...
import unittest import amara from amara.lib import util class Test_util(unittest.TestCase): def test_trim_word_count(self): x = amara.parse('<a>one two <b>three four </b><c>five <d>six seven</d> eight</c> nine</a>') for i in range(1, 11): trimmed_tree = util.trim_word_count(x, i) ...
<commit_before> import unittest import amara from amara.lib import util class Test_util(unittest.TestCase): def test_trim_word_count(self): x = amara.parse('<a>one two <b>three four </b><c>five <d>six seven</d> eight</c> nine</a>') for i in range(1, 11): trimmed_tree = util.trim_word_c...
19fd2795e1cd909bb969a4c4e514d8cb1fd884f5
plugins/XmlMaterialProfile/__init__.py
plugins/XmlMaterialProfile/__init__.py
# Copyright (c) 2016 Ultimaker B.V. # Cura is released under the terms of the AGPLv3 or higher. from . import XmlMaterialProfile from UM.MimeTypeDatabase import MimeType, MimeTypeDatabase from UM.i18n import i18nCatalog catalog = i18nCatalog("cura") def getMetaData(): return { "plugin": { "na...
# Copyright (c) 2016 Ultimaker B.V. # Cura is released under the terms of the AGPLv3 or higher. from . import XmlMaterialProfile from UM.MimeTypeDatabase import MimeType, MimeTypeDatabase from UM.i18n import i18nCatalog catalog = i18nCatalog("cura") def getMetaData(): return { "plugin": { "na...
Mark XmlMaterialProfile as type "material" so the import/export code can find it
Mark XmlMaterialProfile as type "material" so the import/export code can find it Contributes to CURA-341
Python
agpl-3.0
senttech/Cura,fieldOfView/Cura,totalretribution/Cura,hmflash/Cura,Curahelper/Cura,totalretribution/Cura,fieldOfView/Cura,hmflash/Cura,ynotstartups/Wanhao,ynotstartups/Wanhao,senttech/Cura,Curahelper/Cura
# Copyright (c) 2016 Ultimaker B.V. # Cura is released under the terms of the AGPLv3 or higher. from . import XmlMaterialProfile from UM.MimeTypeDatabase import MimeType, MimeTypeDatabase from UM.i18n import i18nCatalog catalog = i18nCatalog("cura") def getMetaData(): return { "plugin": { "na...
# Copyright (c) 2016 Ultimaker B.V. # Cura is released under the terms of the AGPLv3 or higher. from . import XmlMaterialProfile from UM.MimeTypeDatabase import MimeType, MimeTypeDatabase from UM.i18n import i18nCatalog catalog = i18nCatalog("cura") def getMetaData(): return { "plugin": { "na...
<commit_before># Copyright (c) 2016 Ultimaker B.V. # Cura is released under the terms of the AGPLv3 or higher. from . import XmlMaterialProfile from UM.MimeTypeDatabase import MimeType, MimeTypeDatabase from UM.i18n import i18nCatalog catalog = i18nCatalog("cura") def getMetaData(): return { "plugin": { ...
# Copyright (c) 2016 Ultimaker B.V. # Cura is released under the terms of the AGPLv3 or higher. from . import XmlMaterialProfile from UM.MimeTypeDatabase import MimeType, MimeTypeDatabase from UM.i18n import i18nCatalog catalog = i18nCatalog("cura") def getMetaData(): return { "plugin": { "na...
# Copyright (c) 2016 Ultimaker B.V. # Cura is released under the terms of the AGPLv3 or higher. from . import XmlMaterialProfile from UM.MimeTypeDatabase import MimeType, MimeTypeDatabase from UM.i18n import i18nCatalog catalog = i18nCatalog("cura") def getMetaData(): return { "plugin": { "na...
<commit_before># Copyright (c) 2016 Ultimaker B.V. # Cura is released under the terms of the AGPLv3 or higher. from . import XmlMaterialProfile from UM.MimeTypeDatabase import MimeType, MimeTypeDatabase from UM.i18n import i18nCatalog catalog = i18nCatalog("cura") def getMetaData(): return { "plugin": { ...
79c38342193a1ae9a2f12e4b45ccc30cda212c18
indico/modules/events/papers/settings.py
indico/modules/events/papers/settings.py
# This file is part of Indico. # Copyright (C) 2002 - 2016 European Organization for Nuclear Research (CERN). # # Indico 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 (a...
# This file is part of Indico. # Copyright (C) 2002 - 2016 European Organization for Nuclear Research (CERN). # # Indico 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 (a...
Add setting to optionally enforce PR deadlines
Add setting to optionally enforce PR deadlines
Python
mit
OmeGak/indico,ThiefMaster/indico,OmeGak/indico,ThiefMaster/indico,pferreir/indico,pferreir/indico,indico/indico,pferreir/indico,OmeGak/indico,indico/indico,ThiefMaster/indico,mvidalgarcia/indico,DirkHoffmann/indico,pferreir/indico,mic4ael/indico,mic4ael/indico,mvidalgarcia/indico,mic4ael/indico,ThiefMaster/indico,DirkH...
# This file is part of Indico. # Copyright (C) 2002 - 2016 European Organization for Nuclear Research (CERN). # # Indico 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 (a...
# This file is part of Indico. # Copyright (C) 2002 - 2016 European Organization for Nuclear Research (CERN). # # Indico 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 (a...
<commit_before># This file is part of Indico. # Copyright (C) 2002 - 2016 European Organization for Nuclear Research (CERN). # # Indico 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 #...
# This file is part of Indico. # Copyright (C) 2002 - 2016 European Organization for Nuclear Research (CERN). # # Indico 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 (a...
# This file is part of Indico. # Copyright (C) 2002 - 2016 European Organization for Nuclear Research (CERN). # # Indico 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 (a...
<commit_before># This file is part of Indico. # Copyright (C) 2002 - 2016 European Organization for Nuclear Research (CERN). # # Indico 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 #...
11a19916c084b5ceee32180988eee9c2e1ebff05
django_payzen/admin.py
django_payzen/admin.py
from django.contrib import admin from . import models class PaymentRequestAdmin(admin.ModelAdmin): model = models.PaymentRequest list_display = ("vads_amount", "get_vads_currency_display", "vads_trans_id", "vads_trans_date") class PaymentResponseAdmin(admin.ModelAdmin): model = mode...
from django.contrib import admin from . import models class PaymentRequestAdmin(admin.ModelAdmin): model = models.PaymentRequest list_display = ("vads_trans_id", "vads_trans_date", "vads_amount", "get_vads_currency_display") class PaymentResponseAdmin(admin.ModelAdmin): model = mode...
Reorder list dispay in RequestPayment and RequestResponse lists.
Reorder list dispay in RequestPayment and RequestResponse lists.
Python
mit
zehome/django-payzen,bsvetchine/django-payzen,zehome/django-payzen,bsvetchine/django-payzen
from django.contrib import admin from . import models class PaymentRequestAdmin(admin.ModelAdmin): model = models.PaymentRequest list_display = ("vads_amount", "get_vads_currency_display", "vads_trans_id", "vads_trans_date") class PaymentResponseAdmin(admin.ModelAdmin): model = mode...
from django.contrib import admin from . import models class PaymentRequestAdmin(admin.ModelAdmin): model = models.PaymentRequest list_display = ("vads_trans_id", "vads_trans_date", "vads_amount", "get_vads_currency_display") class PaymentResponseAdmin(admin.ModelAdmin): model = mode...
<commit_before>from django.contrib import admin from . import models class PaymentRequestAdmin(admin.ModelAdmin): model = models.PaymentRequest list_display = ("vads_amount", "get_vads_currency_display", "vads_trans_id", "vads_trans_date") class PaymentResponseAdmin(admin.ModelAdmin): ...
from django.contrib import admin from . import models class PaymentRequestAdmin(admin.ModelAdmin): model = models.PaymentRequest list_display = ("vads_trans_id", "vads_trans_date", "vads_amount", "get_vads_currency_display") class PaymentResponseAdmin(admin.ModelAdmin): model = mode...
from django.contrib import admin from . import models class PaymentRequestAdmin(admin.ModelAdmin): model = models.PaymentRequest list_display = ("vads_amount", "get_vads_currency_display", "vads_trans_id", "vads_trans_date") class PaymentResponseAdmin(admin.ModelAdmin): model = mode...
<commit_before>from django.contrib import admin from . import models class PaymentRequestAdmin(admin.ModelAdmin): model = models.PaymentRequest list_display = ("vads_amount", "get_vads_currency_display", "vads_trans_id", "vads_trans_date") class PaymentResponseAdmin(admin.ModelAdmin): ...
565ff4653b0dca4bb4831d263dae118d044b6b9c
test/test_molecule.py
test/test_molecule.py
import pytest import os import shutil from subprocess import call from cookiecutter.main import cookiecutter playbook_setup_commands = ['pip install -r requirements.txt'] playbook_setup_success = 0 playbook_test_command = "molecule test" playbook_test_success = 0 @pytest.mark.parametrize('role_name', ['tree']) def ...
import pytest import os import shutil from subprocess import call from cookiecutter.main import cookiecutter playbook_setup_commands = ['pip install -r https://raw.githubusercontent.com/nephelaiio/ansible-role-requirements/master/requirements.txt'] playbook_setup_success = 0 playbook_test_command = "molecule test" pl...
Fix broken requirements file references
Fix broken requirements file references
Python
mit
nephelaiio/cookiecutter-ansible-role
import pytest import os import shutil from subprocess import call from cookiecutter.main import cookiecutter playbook_setup_commands = ['pip install -r requirements.txt'] playbook_setup_success = 0 playbook_test_command = "molecule test" playbook_test_success = 0 @pytest.mark.parametrize('role_name', ['tree']) def ...
import pytest import os import shutil from subprocess import call from cookiecutter.main import cookiecutter playbook_setup_commands = ['pip install -r https://raw.githubusercontent.com/nephelaiio/ansible-role-requirements/master/requirements.txt'] playbook_setup_success = 0 playbook_test_command = "molecule test" pl...
<commit_before>import pytest import os import shutil from subprocess import call from cookiecutter.main import cookiecutter playbook_setup_commands = ['pip install -r requirements.txt'] playbook_setup_success = 0 playbook_test_command = "molecule test" playbook_test_success = 0 @pytest.mark.parametrize('role_name',...
import pytest import os import shutil from subprocess import call from cookiecutter.main import cookiecutter playbook_setup_commands = ['pip install -r https://raw.githubusercontent.com/nephelaiio/ansible-role-requirements/master/requirements.txt'] playbook_setup_success = 0 playbook_test_command = "molecule test" pl...
import pytest import os import shutil from subprocess import call from cookiecutter.main import cookiecutter playbook_setup_commands = ['pip install -r requirements.txt'] playbook_setup_success = 0 playbook_test_command = "molecule test" playbook_test_success = 0 @pytest.mark.parametrize('role_name', ['tree']) def ...
<commit_before>import pytest import os import shutil from subprocess import call from cookiecutter.main import cookiecutter playbook_setup_commands = ['pip install -r requirements.txt'] playbook_setup_success = 0 playbook_test_command = "molecule test" playbook_test_success = 0 @pytest.mark.parametrize('role_name',...
fc4b36c34f8f9edbb688ff4d5ab1d50b4f8c6dac
armstrong/core/arm_layout/utils.py
armstrong/core/arm_layout/utils.py
import warnings from django.conf import settings from armstrong.utils.backends import GenericBackend NEW = "ARMSTRONG_LAYOUT_BACKEND" OLD = "ARMSTRONG_RENDER_MODEL_BACKEND" render_model = (GenericBackend(NEW, defaults="armstrong.core.arm_layout.backends.BasicLayoutBackend") .get_backend()) if hasattr(set...
import warnings from django.conf import settings from armstrong.utils.backends import GenericBackend NEW = "ARMSTRONG_LAYOUT_BACKEND" OLD = "ARMSTRONG_RENDER_MODEL_BACKEND" render_model = (GenericBackend(NEW, defaults="armstrong.core.arm_layout.backends.BasicLayoutBackend") .get_backend()) if hasattr(set...
Use older style string formatting for Python 2.6
Use older style string formatting for Python 2.6
Python
apache-2.0
armstrong/armstrong.core.arm_layout,armstrong/armstrong.core.arm_layout
import warnings from django.conf import settings from armstrong.utils.backends import GenericBackend NEW = "ARMSTRONG_LAYOUT_BACKEND" OLD = "ARMSTRONG_RENDER_MODEL_BACKEND" render_model = (GenericBackend(NEW, defaults="armstrong.core.arm_layout.backends.BasicLayoutBackend") .get_backend()) if hasattr(set...
import warnings from django.conf import settings from armstrong.utils.backends import GenericBackend NEW = "ARMSTRONG_LAYOUT_BACKEND" OLD = "ARMSTRONG_RENDER_MODEL_BACKEND" render_model = (GenericBackend(NEW, defaults="armstrong.core.arm_layout.backends.BasicLayoutBackend") .get_backend()) if hasattr(set...
<commit_before>import warnings from django.conf import settings from armstrong.utils.backends import GenericBackend NEW = "ARMSTRONG_LAYOUT_BACKEND" OLD = "ARMSTRONG_RENDER_MODEL_BACKEND" render_model = (GenericBackend(NEW, defaults="armstrong.core.arm_layout.backends.BasicLayoutBackend") .get_backend()) ...
import warnings from django.conf import settings from armstrong.utils.backends import GenericBackend NEW = "ARMSTRONG_LAYOUT_BACKEND" OLD = "ARMSTRONG_RENDER_MODEL_BACKEND" render_model = (GenericBackend(NEW, defaults="armstrong.core.arm_layout.backends.BasicLayoutBackend") .get_backend()) if hasattr(set...
import warnings from django.conf import settings from armstrong.utils.backends import GenericBackend NEW = "ARMSTRONG_LAYOUT_BACKEND" OLD = "ARMSTRONG_RENDER_MODEL_BACKEND" render_model = (GenericBackend(NEW, defaults="armstrong.core.arm_layout.backends.BasicLayoutBackend") .get_backend()) if hasattr(set...
<commit_before>import warnings from django.conf import settings from armstrong.utils.backends import GenericBackend NEW = "ARMSTRONG_LAYOUT_BACKEND" OLD = "ARMSTRONG_RENDER_MODEL_BACKEND" render_model = (GenericBackend(NEW, defaults="armstrong.core.arm_layout.backends.BasicLayoutBackend") .get_backend()) ...
877f59134c64f3c2e50436289b1cd676d471f66f
src/gramcore/features/tests/test_descriptors.py
src/gramcore/features/tests/test_descriptors.py
"""Tests for module gramcore.features.descriptors""" import numpy from nose.tools import assert_equal from gramcore.features import descriptors def test_hog_size(): """Create a fixture and check hog result size Creates a square array and inputs it to hog. For simplicity the blocks and the cells are squ...
"""Tests for module gramcore.features.descriptors""" import numpy from nose.tools import assert_equal from gramcore.features import descriptors def test_hog_size(): """Create a fixture and check hog result size There are already enough tests in skimage for this, just adding so to document how many valu...
Add note in hog test doc string
Add note in hog test doc string
Python
mit
cpsaltis/pythogram-core
"""Tests for module gramcore.features.descriptors""" import numpy from nose.tools import assert_equal from gramcore.features import descriptors def test_hog_size(): """Create a fixture and check hog result size Creates a square array and inputs it to hog. For simplicity the blocks and the cells are squ...
"""Tests for module gramcore.features.descriptors""" import numpy from nose.tools import assert_equal from gramcore.features import descriptors def test_hog_size(): """Create a fixture and check hog result size There are already enough tests in skimage for this, just adding so to document how many valu...
<commit_before>"""Tests for module gramcore.features.descriptors""" import numpy from nose.tools import assert_equal from gramcore.features import descriptors def test_hog_size(): """Create a fixture and check hog result size Creates a square array and inputs it to hog. For simplicity the blocks and th...
"""Tests for module gramcore.features.descriptors""" import numpy from nose.tools import assert_equal from gramcore.features import descriptors def test_hog_size(): """Create a fixture and check hog result size There are already enough tests in skimage for this, just adding so to document how many valu...
"""Tests for module gramcore.features.descriptors""" import numpy from nose.tools import assert_equal from gramcore.features import descriptors def test_hog_size(): """Create a fixture and check hog result size Creates a square array and inputs it to hog. For simplicity the blocks and the cells are squ...
<commit_before>"""Tests for module gramcore.features.descriptors""" import numpy from nose.tools import assert_equal from gramcore.features import descriptors def test_hog_size(): """Create a fixture and check hog result size Creates a square array and inputs it to hog. For simplicity the blocks and th...
e77cb240d522da47208b60384c40f03f5c9182e3
tests/test_encoder.py
tests/test_encoder.py
# -*- coding: utf-8 -*- import os import glob import pvl DATA_DIR = os.path.join(os.path.dirname(__file__), 'data/') PDS_DATA_DIR = os.path.join(os.path.dirname(__file__), 'data', 'pds3') def test_dump(): files = glob.glob(os.path.join(PDS_DATA_DIR, "*.lbl")) for infile in files: label = pvl.load(i...
# -*- coding: utf-8 -*- import os import glob import pvl DATA_DIR = os.path.join(os.path.dirname(__file__), 'data/') PDS_DATA_DIR = os.path.join(os.path.dirname(__file__), 'data', 'pds3') def test_dump(): files = glob.glob(os.path.join(PDS_DATA_DIR, "*.lbl")) for infile in files: label = pvl.load(i...
Add tests for cube and isis encoders.
Add tests for cube and isis encoders.
Python
bsd-3-clause
pbvarga1/pvl,bvnayak/pvl,wtolson/pvl,planetarypy/pvl
# -*- coding: utf-8 -*- import os import glob import pvl DATA_DIR = os.path.join(os.path.dirname(__file__), 'data/') PDS_DATA_DIR = os.path.join(os.path.dirname(__file__), 'data', 'pds3') def test_dump(): files = glob.glob(os.path.join(PDS_DATA_DIR, "*.lbl")) for infile in files: label = pvl.load(i...
# -*- coding: utf-8 -*- import os import glob import pvl DATA_DIR = os.path.join(os.path.dirname(__file__), 'data/') PDS_DATA_DIR = os.path.join(os.path.dirname(__file__), 'data', 'pds3') def test_dump(): files = glob.glob(os.path.join(PDS_DATA_DIR, "*.lbl")) for infile in files: label = pvl.load(i...
<commit_before># -*- coding: utf-8 -*- import os import glob import pvl DATA_DIR = os.path.join(os.path.dirname(__file__), 'data/') PDS_DATA_DIR = os.path.join(os.path.dirname(__file__), 'data', 'pds3') def test_dump(): files = glob.glob(os.path.join(PDS_DATA_DIR, "*.lbl")) for infile in files: lab...
# -*- coding: utf-8 -*- import os import glob import pvl DATA_DIR = os.path.join(os.path.dirname(__file__), 'data/') PDS_DATA_DIR = os.path.join(os.path.dirname(__file__), 'data', 'pds3') def test_dump(): files = glob.glob(os.path.join(PDS_DATA_DIR, "*.lbl")) for infile in files: label = pvl.load(i...
# -*- coding: utf-8 -*- import os import glob import pvl DATA_DIR = os.path.join(os.path.dirname(__file__), 'data/') PDS_DATA_DIR = os.path.join(os.path.dirname(__file__), 'data', 'pds3') def test_dump(): files = glob.glob(os.path.join(PDS_DATA_DIR, "*.lbl")) for infile in files: label = pvl.load(i...
<commit_before># -*- coding: utf-8 -*- import os import glob import pvl DATA_DIR = os.path.join(os.path.dirname(__file__), 'data/') PDS_DATA_DIR = os.path.join(os.path.dirname(__file__), 'data', 'pds3') def test_dump(): files = glob.glob(os.path.join(PDS_DATA_DIR, "*.lbl")) for infile in files: lab...
710a2a6d9c462041bae6c41f0578d99262c6a861
tests/test_execute.py
tests/test_execute.py
import asyncpg from asyncpg import _testbase as tb class TestExecuteScript(tb.ConnectedTestCase): async def test_execute_script_1(self): r = await self.con.execute(''' SELECT 1; SELECT true FROM pg_type WHERE false = true; SELECT 2; ''') self.assertIs...
import asyncpg from asyncpg import _testbase as tb class TestExecuteScript(tb.ConnectedTestCase): async def test_execute_script_1(self): r = await self.con.execute(''' SELECT 1; SELECT true FROM pg_type WHERE false = true; SELECT 2; ''') self.assertIs...
Test that con.execute() propagate Postgres exceptions
Test that con.execute() propagate Postgres exceptions
Python
apache-2.0
MagicStack/asyncpg,MagicStack/asyncpg
import asyncpg from asyncpg import _testbase as tb class TestExecuteScript(tb.ConnectedTestCase): async def test_execute_script_1(self): r = await self.con.execute(''' SELECT 1; SELECT true FROM pg_type WHERE false = true; SELECT 2; ''') self.assertIs...
import asyncpg from asyncpg import _testbase as tb class TestExecuteScript(tb.ConnectedTestCase): async def test_execute_script_1(self): r = await self.con.execute(''' SELECT 1; SELECT true FROM pg_type WHERE false = true; SELECT 2; ''') self.assertIs...
<commit_before>import asyncpg from asyncpg import _testbase as tb class TestExecuteScript(tb.ConnectedTestCase): async def test_execute_script_1(self): r = await self.con.execute(''' SELECT 1; SELECT true FROM pg_type WHERE false = true; SELECT 2; ''') ...
import asyncpg from asyncpg import _testbase as tb class TestExecuteScript(tb.ConnectedTestCase): async def test_execute_script_1(self): r = await self.con.execute(''' SELECT 1; SELECT true FROM pg_type WHERE false = true; SELECT 2; ''') self.assertIs...
import asyncpg from asyncpg import _testbase as tb class TestExecuteScript(tb.ConnectedTestCase): async def test_execute_script_1(self): r = await self.con.execute(''' SELECT 1; SELECT true FROM pg_type WHERE false = true; SELECT 2; ''') self.assertIs...
<commit_before>import asyncpg from asyncpg import _testbase as tb class TestExecuteScript(tb.ConnectedTestCase): async def test_execute_script_1(self): r = await self.con.execute(''' SELECT 1; SELECT true FROM pg_type WHERE false = true; SELECT 2; ''') ...
d95d817bdb1fba7eb0ce0cdabcd64a9908796d2a
tests/unit/test_ls.py
tests/unit/test_ls.py
from tests.framework.cli_testcase import CliTestCase from tests.framework.constants import GO_EP1_ID class LsTests(CliTestCase): """ Tests globus ls command """ def test_path(self): """ Does an ls on EP1:/, confirms expected results. """ path = "/" output = sel...
from tests.framework.cli_testcase import CliTestCase from tests.framework.constants import GO_EP1_ID class LsTests(CliTestCase): """ Tests globus ls command """ def test_path(self): """ Does an ls on EP1:/, confirms expected results. """ path = "/" output = sel...
Fix concurrency bug in ls tests
Fix concurrency bug in ls tests
Python
apache-2.0
globus/globus-cli,globus/globus-cli
from tests.framework.cli_testcase import CliTestCase from tests.framework.constants import GO_EP1_ID class LsTests(CliTestCase): """ Tests globus ls command """ def test_path(self): """ Does an ls on EP1:/, confirms expected results. """ path = "/" output = sel...
from tests.framework.cli_testcase import CliTestCase from tests.framework.constants import GO_EP1_ID class LsTests(CliTestCase): """ Tests globus ls command """ def test_path(self): """ Does an ls on EP1:/, confirms expected results. """ path = "/" output = sel...
<commit_before>from tests.framework.cli_testcase import CliTestCase from tests.framework.constants import GO_EP1_ID class LsTests(CliTestCase): """ Tests globus ls command """ def test_path(self): """ Does an ls on EP1:/, confirms expected results. """ path = "/" ...
from tests.framework.cli_testcase import CliTestCase from tests.framework.constants import GO_EP1_ID class LsTests(CliTestCase): """ Tests globus ls command """ def test_path(self): """ Does an ls on EP1:/, confirms expected results. """ path = "/" output = sel...
from tests.framework.cli_testcase import CliTestCase from tests.framework.constants import GO_EP1_ID class LsTests(CliTestCase): """ Tests globus ls command """ def test_path(self): """ Does an ls on EP1:/, confirms expected results. """ path = "/" output = sel...
<commit_before>from tests.framework.cli_testcase import CliTestCase from tests.framework.constants import GO_EP1_ID class LsTests(CliTestCase): """ Tests globus ls command """ def test_path(self): """ Does an ls on EP1:/, confirms expected results. """ path = "/" ...
71e2bc7976dcb4230c20e2c60a7e23634c38603f
apps/references/autoref.py
apps/references/autoref.py
import os.path import string import urllib, re from datetime import datetime from xml.dom.minidom import parse, parseString # Django from django.core import serializers from django.conf import settings from django.db import models # Methodmint def pubmed(keywords, latest_query=None): # Get matching publications f...
import os.path import string import urllib, re from datetime import datetime from xml.dom.minidom import parse, parseString # Django from django.core import serializers from django.conf import settings from django.db import models # Methodmint def pubmed(keywords, latest_query=None): # Get matching publications f...
Change publication date to Epub; more up-to-date
Change publication date to Epub; more up-to-date
Python
bsd-3-clause
mfitzp/django-golifescience
import os.path import string import urllib, re from datetime import datetime from xml.dom.minidom import parse, parseString # Django from django.core import serializers from django.conf import settings from django.db import models # Methodmint def pubmed(keywords, latest_query=None): # Get matching publications f...
import os.path import string import urllib, re from datetime import datetime from xml.dom.minidom import parse, parseString # Django from django.core import serializers from django.conf import settings from django.db import models # Methodmint def pubmed(keywords, latest_query=None): # Get matching publications f...
<commit_before>import os.path import string import urllib, re from datetime import datetime from xml.dom.minidom import parse, parseString # Django from django.core import serializers from django.conf import settings from django.db import models # Methodmint def pubmed(keywords, latest_query=None): # Get matching...
import os.path import string import urllib, re from datetime import datetime from xml.dom.minidom import parse, parseString # Django from django.core import serializers from django.conf import settings from django.db import models # Methodmint def pubmed(keywords, latest_query=None): # Get matching publications f...
import os.path import string import urllib, re from datetime import datetime from xml.dom.minidom import parse, parseString # Django from django.core import serializers from django.conf import settings from django.db import models # Methodmint def pubmed(keywords, latest_query=None): # Get matching publications f...
<commit_before>import os.path import string import urllib, re from datetime import datetime from xml.dom.minidom import parse, parseString # Django from django.core import serializers from django.conf import settings from django.db import models # Methodmint def pubmed(keywords, latest_query=None): # Get matching...
d410a5295b67b17ca1cdc4d53ed8f776159278bc
json2parquet/__init__.py
json2parquet/__init__.py
# -*- coding: utf-8 -*- from __future__ import unicode_literals from .client import load_json, ingest_data, write_parquet, convert_json __title__ = 'json2parquet' __version__ = '0.0.24' __all__ = ['load_json', 'ingest_data', 'write_parquet', 'convert_json', 'write_parquet_dataset']
# -*- coding: utf-8 -*- from __future__ import unicode_literals from .client import load_json, ingest_data, write_parquet, convert_json, write_parquet_dataset __title__ = 'json2parquet' __version__ = '0.0.24' __all__ = ['load_json', 'ingest_data', 'write_parquet', 'convert_json', 'write_parquet_dataset']
Make client.write_parquet_dataset available for export
Make client.write_parquet_dataset available for export This commit adds write_parquet_dataset to the imports from .client in __init__.py Previously, `from json2parquet import write_parquet_dataset` would result in an error: `ImportError: cannot import name 'write_parquet_dataset' from 'json2parquet' `
Python
mit
andrewgross/json2parquet
# -*- coding: utf-8 -*- from __future__ import unicode_literals from .client import load_json, ingest_data, write_parquet, convert_json __title__ = 'json2parquet' __version__ = '0.0.24' __all__ = ['load_json', 'ingest_data', 'write_parquet', 'convert_json', 'write_parquet_dataset'] Make client.write_parquet_dataset ...
# -*- coding: utf-8 -*- from __future__ import unicode_literals from .client import load_json, ingest_data, write_parquet, convert_json, write_parquet_dataset __title__ = 'json2parquet' __version__ = '0.0.24' __all__ = ['load_json', 'ingest_data', 'write_parquet', 'convert_json', 'write_parquet_dataset']
<commit_before># -*- coding: utf-8 -*- from __future__ import unicode_literals from .client import load_json, ingest_data, write_parquet, convert_json __title__ = 'json2parquet' __version__ = '0.0.24' __all__ = ['load_json', 'ingest_data', 'write_parquet', 'convert_json', 'write_parquet_dataset'] <commit_msg>Make cl...
# -*- coding: utf-8 -*- from __future__ import unicode_literals from .client import load_json, ingest_data, write_parquet, convert_json, write_parquet_dataset __title__ = 'json2parquet' __version__ = '0.0.24' __all__ = ['load_json', 'ingest_data', 'write_parquet', 'convert_json', 'write_parquet_dataset']
# -*- coding: utf-8 -*- from __future__ import unicode_literals from .client import load_json, ingest_data, write_parquet, convert_json __title__ = 'json2parquet' __version__ = '0.0.24' __all__ = ['load_json', 'ingest_data', 'write_parquet', 'convert_json', 'write_parquet_dataset'] Make client.write_parquet_dataset ...
<commit_before># -*- coding: utf-8 -*- from __future__ import unicode_literals from .client import load_json, ingest_data, write_parquet, convert_json __title__ = 'json2parquet' __version__ = '0.0.24' __all__ = ['load_json', 'ingest_data', 'write_parquet', 'convert_json', 'write_parquet_dataset'] <commit_msg>Make cl...
d1a052237dc6fc5a8a198a130c203e823e86ccec
dist/docker/redhat/commandlineparser.py
dist/docker/redhat/commandlineparser.py
import argparse def parse(): parser = argparse.ArgumentParser() parser.add_argument('--developer-mode', default='1', choices=['0', '1'], dest='developerMode') parser.add_argument('--seeds', default=None, help="specify seeds - if left empty will use container's own IP") parser.add_argument('--cpuset', ...
import argparse def parse(): parser = argparse.ArgumentParser() parser.add_argument('--developer-mode', default='1', choices=['0', '1'], dest='developerMode') parser.add_argument('--seeds', default=None, help="specify seeds - if left empty will use container's own IP") parser.add_argument('--cpuset', ...
Fix typo in "--overprovisioned" help text
dist/docker: Fix typo in "--overprovisioned" help text Reported by Mathias Bogaert (@analytically). Message-Id: <13c4d4f57d8c59965d44b353c9e1b869295d4df3@scylladb.com>
Python
agpl-3.0
avikivity/scylla,raphaelsc/scylla,avikivity/scylla,scylladb/scylla,scylladb/scylla,duarten/scylla,duarten/scylla,duarten/scylla,raphaelsc/scylla,avikivity/scylla,scylladb/scylla,scylladb/scylla,raphaelsc/scylla
import argparse def parse(): parser = argparse.ArgumentParser() parser.add_argument('--developer-mode', default='1', choices=['0', '1'], dest='developerMode') parser.add_argument('--seeds', default=None, help="specify seeds - if left empty will use container's own IP") parser.add_argument('--cpuset', ...
import argparse def parse(): parser = argparse.ArgumentParser() parser.add_argument('--developer-mode', default='1', choices=['0', '1'], dest='developerMode') parser.add_argument('--seeds', default=None, help="specify seeds - if left empty will use container's own IP") parser.add_argument('--cpuset', ...
<commit_before>import argparse def parse(): parser = argparse.ArgumentParser() parser.add_argument('--developer-mode', default='1', choices=['0', '1'], dest='developerMode') parser.add_argument('--seeds', default=None, help="specify seeds - if left empty will use container's own IP") parser.add_argume...
import argparse def parse(): parser = argparse.ArgumentParser() parser.add_argument('--developer-mode', default='1', choices=['0', '1'], dest='developerMode') parser.add_argument('--seeds', default=None, help="specify seeds - if left empty will use container's own IP") parser.add_argument('--cpuset', ...
import argparse def parse(): parser = argparse.ArgumentParser() parser.add_argument('--developer-mode', default='1', choices=['0', '1'], dest='developerMode') parser.add_argument('--seeds', default=None, help="specify seeds - if left empty will use container's own IP") parser.add_argument('--cpuset', ...
<commit_before>import argparse def parse(): parser = argparse.ArgumentParser() parser.add_argument('--developer-mode', default='1', choices=['0', '1'], dest='developerMode') parser.add_argument('--seeds', default=None, help="specify seeds - if left empty will use container's own IP") parser.add_argume...
3d570864a39f10d6e502e4005e7931793fca3d01
flask_app/models.py
flask_app/models.py
from flask.ext.sqlalchemy import SQLAlchemy from flask.ext.security import UserMixin, RoleMixin db = SQLAlchemy() ### Add models here roles_users = db.Table('roles_users', db.Column('user_id', db.Integer(), db.ForeignKey('user.id')), db.Column('role_id', db.Integer(), db.ForeignKey('role.id'))) class Role(...
from flask.ext.sqlalchemy import SQLAlchemy from flask.ext.security import UserMixin, RoleMixin db = SQLAlchemy() ### Add models here roles_users = db.Table('roles_users', db.Column('user_id', db.Integer(), db.ForeignKey('user.id', ondelete='CASCADE')), db.Column('role_i...
Add missing cascade deletes on user/roles
Add missing cascade deletes on user/roles
Python
mit
getslash/mailboxer,vmalloc/mailboxer,Infinidat/lanister,vmalloc/mailboxer,getslash/mailboxer,Infinidat/lanister,vmalloc/mailboxer,getslash/mailboxer
from flask.ext.sqlalchemy import SQLAlchemy from flask.ext.security import UserMixin, RoleMixin db = SQLAlchemy() ### Add models here roles_users = db.Table('roles_users', db.Column('user_id', db.Integer(), db.ForeignKey('user.id')), db.Column('role_id', db.Integer(), db.ForeignKey('role.id'))) class Role(...
from flask.ext.sqlalchemy import SQLAlchemy from flask.ext.security import UserMixin, RoleMixin db = SQLAlchemy() ### Add models here roles_users = db.Table('roles_users', db.Column('user_id', db.Integer(), db.ForeignKey('user.id', ondelete='CASCADE')), db.Column('role_i...
<commit_before>from flask.ext.sqlalchemy import SQLAlchemy from flask.ext.security import UserMixin, RoleMixin db = SQLAlchemy() ### Add models here roles_users = db.Table('roles_users', db.Column('user_id', db.Integer(), db.ForeignKey('user.id')), db.Column('role_id', db.Integer(), db.ForeignKey('role.id'))...
from flask.ext.sqlalchemy import SQLAlchemy from flask.ext.security import UserMixin, RoleMixin db = SQLAlchemy() ### Add models here roles_users = db.Table('roles_users', db.Column('user_id', db.Integer(), db.ForeignKey('user.id', ondelete='CASCADE')), db.Column('role_i...
from flask.ext.sqlalchemy import SQLAlchemy from flask.ext.security import UserMixin, RoleMixin db = SQLAlchemy() ### Add models here roles_users = db.Table('roles_users', db.Column('user_id', db.Integer(), db.ForeignKey('user.id')), db.Column('role_id', db.Integer(), db.ForeignKey('role.id'))) class Role(...
<commit_before>from flask.ext.sqlalchemy import SQLAlchemy from flask.ext.security import UserMixin, RoleMixin db = SQLAlchemy() ### Add models here roles_users = db.Table('roles_users', db.Column('user_id', db.Integer(), db.ForeignKey('user.id')), db.Column('role_id', db.Integer(), db.ForeignKey('role.id'))...
5a2d0612f0d3417b07f007a87febdb045bff67e4
astropy/units/format/unicode_format.py
astropy/units/format/unicode_format.py
# -*- coding: utf-8 -*- # Licensed under a 3-clause BSD style license - see LICENSE.rst """ Handles the "Unicode" unit format. """ from __future__ import absolute_import, division, print_function, unicode_literals from . import console class Unicode(console.Console): """ Output-only format for to display pre...
# -*- coding: utf-8 -*- # Licensed under a 3-clause BSD style license - see LICENSE.rst """ Handles the "Unicode" unit format. """ from __future__ import absolute_import, division, print_function, unicode_literals from . import console class Unicode(console.Console): """ Output-only format for to display pre...
Update renamed method (irrep -> decompose)
Update renamed method (irrep -> decompose)
Python
bsd-3-clause
kelle/astropy,lpsinger/astropy,MSeifert04/astropy,pllim/astropy,mhvk/astropy,mhvk/astropy,tbabej/astropy,kelle/astropy,aleksandr-bakanov/astropy,dhomeier/astropy,saimn/astropy,astropy/astropy,DougBurke/astropy,lpsinger/astropy,DougBurke/astropy,pllim/astropy,larrybradley/astropy,larrybradley/astropy,funbaker/astropy,tb...
# -*- coding: utf-8 -*- # Licensed under a 3-clause BSD style license - see LICENSE.rst """ Handles the "Unicode" unit format. """ from __future__ import absolute_import, division, print_function, unicode_literals from . import console class Unicode(console.Console): """ Output-only format for to display pre...
# -*- coding: utf-8 -*- # Licensed under a 3-clause BSD style license - see LICENSE.rst """ Handles the "Unicode" unit format. """ from __future__ import absolute_import, division, print_function, unicode_literals from . import console class Unicode(console.Console): """ Output-only format for to display pre...
<commit_before># -*- coding: utf-8 -*- # Licensed under a 3-clause BSD style license - see LICENSE.rst """ Handles the "Unicode" unit format. """ from __future__ import absolute_import, division, print_function, unicode_literals from . import console class Unicode(console.Console): """ Output-only format for...
# -*- coding: utf-8 -*- # Licensed under a 3-clause BSD style license - see LICENSE.rst """ Handles the "Unicode" unit format. """ from __future__ import absolute_import, division, print_function, unicode_literals from . import console class Unicode(console.Console): """ Output-only format for to display pre...
# -*- coding: utf-8 -*- # Licensed under a 3-clause BSD style license - see LICENSE.rst """ Handles the "Unicode" unit format. """ from __future__ import absolute_import, division, print_function, unicode_literals from . import console class Unicode(console.Console): """ Output-only format for to display pre...
<commit_before># -*- coding: utf-8 -*- # Licensed under a 3-clause BSD style license - see LICENSE.rst """ Handles the "Unicode" unit format. """ from __future__ import absolute_import, division, print_function, unicode_literals from . import console class Unicode(console.Console): """ Output-only format for...
e2bb78a1587b7d5c0416c3632ca9674339826d55
src/yawf/creation.py
src/yawf/creation.py
from django.db import transaction from yawf.config import DEFAULT_START_MESSAGE, WORKFLOW_TYPE_ATTR from yawf import get_workflow, get_workflow_by_instance from yawf import dispatch from yawf.exceptions import WorkflowNotLoadedError, CreateValidationError @transaction.commit_on_success def create(workflow_type, sende...
from django.db import transaction from yawf.config import DEFAULT_START_MESSAGE, WORKFLOW_TYPE_ATTR from yawf import get_workflow, get_workflow_by_instance from yawf import dispatch from yawf.exceptions import WorkflowNotLoadedError, CreateValidationError @transaction.commit_on_success def create(workflow_type, sende...
Make start_message_params optional in start_workflow()
Make start_message_params optional in start_workflow()
Python
mit
freevoid/yawf
from django.db import transaction from yawf.config import DEFAULT_START_MESSAGE, WORKFLOW_TYPE_ATTR from yawf import get_workflow, get_workflow_by_instance from yawf import dispatch from yawf.exceptions import WorkflowNotLoadedError, CreateValidationError @transaction.commit_on_success def create(workflow_type, sende...
from django.db import transaction from yawf.config import DEFAULT_START_MESSAGE, WORKFLOW_TYPE_ATTR from yawf import get_workflow, get_workflow_by_instance from yawf import dispatch from yawf.exceptions import WorkflowNotLoadedError, CreateValidationError @transaction.commit_on_success def create(workflow_type, sende...
<commit_before>from django.db import transaction from yawf.config import DEFAULT_START_MESSAGE, WORKFLOW_TYPE_ATTR from yawf import get_workflow, get_workflow_by_instance from yawf import dispatch from yawf.exceptions import WorkflowNotLoadedError, CreateValidationError @transaction.commit_on_success def create(workf...
from django.db import transaction from yawf.config import DEFAULT_START_MESSAGE, WORKFLOW_TYPE_ATTR from yawf import get_workflow, get_workflow_by_instance from yawf import dispatch from yawf.exceptions import WorkflowNotLoadedError, CreateValidationError @transaction.commit_on_success def create(workflow_type, sende...
from django.db import transaction from yawf.config import DEFAULT_START_MESSAGE, WORKFLOW_TYPE_ATTR from yawf import get_workflow, get_workflow_by_instance from yawf import dispatch from yawf.exceptions import WorkflowNotLoadedError, CreateValidationError @transaction.commit_on_success def create(workflow_type, sende...
<commit_before>from django.db import transaction from yawf.config import DEFAULT_START_MESSAGE, WORKFLOW_TYPE_ATTR from yawf import get_workflow, get_workflow_by_instance from yawf import dispatch from yawf.exceptions import WorkflowNotLoadedError, CreateValidationError @transaction.commit_on_success def create(workf...
f8bdd7c8139cfc6d7af4bb3d89e983073db976bf
mecodesktop.py
mecodesktop.py
""" MacroecoDesktop script for making standalone executable """ from macroeco import desktop desktop()
""" MacroecoDesktop script for making standalone executable """ import sys as _sys from macroeco import desktop if len(_sys.argv) > 1: desktop(_sys.argv[1]) else: desktop()
Allow compiled OS X app to take parameter file as input on command line
Allow compiled OS X app to take parameter file as input on command line
Python
bsd-2-clause
jkitzes/macroeco
""" MacroecoDesktop script for making standalone executable """ from macroeco import desktop desktop() Allow compiled OS X app to take parameter file as input on command line
""" MacroecoDesktop script for making standalone executable """ import sys as _sys from macroeco import desktop if len(_sys.argv) > 1: desktop(_sys.argv[1]) else: desktop()
<commit_before>""" MacroecoDesktop script for making standalone executable """ from macroeco import desktop desktop() <commit_msg>Allow compiled OS X app to take parameter file as input on command line<commit_after>
""" MacroecoDesktop script for making standalone executable """ import sys as _sys from macroeco import desktop if len(_sys.argv) > 1: desktop(_sys.argv[1]) else: desktop()
""" MacroecoDesktop script for making standalone executable """ from macroeco import desktop desktop() Allow compiled OS X app to take parameter file as input on command line""" MacroecoDesktop script for making standalone executable """ import sys as _sys from macroeco import desktop if len(_sys.argv) > 1: desk...
<commit_before>""" MacroecoDesktop script for making standalone executable """ from macroeco import desktop desktop() <commit_msg>Allow compiled OS X app to take parameter file as input on command line<commit_after>""" MacroecoDesktop script for making standalone executable """ import sys as _sys from macroeco import...
71802047e6ee0226f7eaf27f5e3497aea4cd6164
testing/cloudControllerLocustTester.py
testing/cloudControllerLocustTester.py
from locust import HttpLocust, TaskSet, task class WebsiteTasks(TaskSet): @task def index(self): self.client.get("/service") class WebsiteUser(HttpLocust): task_set = WebsiteTasks min_wait = 1000 max_wait = 1000
from locust import HttpLocust, TaskSet, task class WebsiteTasks(TaskSet): @task def index(self): self.client.get("/service") class WebsiteUser(HttpLocust): task_set = WebsiteTasks min_wait = 1000 max_wait = 1500
Update max wait time in locust test script.
Update max wait time in locust test script.
Python
apache-2.0
IrimieBogdan/cloud-controller,IrimieBogdan/cloud-controller
from locust import HttpLocust, TaskSet, task class WebsiteTasks(TaskSet): @task def index(self): self.client.get("/service") class WebsiteUser(HttpLocust): task_set = WebsiteTasks min_wait = 1000 max_wait = 1000 Update max wait time in locust test script.
from locust import HttpLocust, TaskSet, task class WebsiteTasks(TaskSet): @task def index(self): self.client.get("/service") class WebsiteUser(HttpLocust): task_set = WebsiteTasks min_wait = 1000 max_wait = 1500
<commit_before>from locust import HttpLocust, TaskSet, task class WebsiteTasks(TaskSet): @task def index(self): self.client.get("/service") class WebsiteUser(HttpLocust): task_set = WebsiteTasks min_wait = 1000 max_wait = 1000 <commit_msg>Update max wait time in locust test script.<commit_...
from locust import HttpLocust, TaskSet, task class WebsiteTasks(TaskSet): @task def index(self): self.client.get("/service") class WebsiteUser(HttpLocust): task_set = WebsiteTasks min_wait = 1000 max_wait = 1500
from locust import HttpLocust, TaskSet, task class WebsiteTasks(TaskSet): @task def index(self): self.client.get("/service") class WebsiteUser(HttpLocust): task_set = WebsiteTasks min_wait = 1000 max_wait = 1000 Update max wait time in locust test script.from locust import HttpLocust, Task...
<commit_before>from locust import HttpLocust, TaskSet, task class WebsiteTasks(TaskSet): @task def index(self): self.client.get("/service") class WebsiteUser(HttpLocust): task_set = WebsiteTasks min_wait = 1000 max_wait = 1000 <commit_msg>Update max wait time in locust test script.<commit_...
59e4e193ea41d05229f2748743e9783d68d8dabf
apps/__init__.py
apps/__init__.py
## module loader, goes to see which submodules have 'html' directories ## and declares them at the toplevel import os,importlib def find_module_dirs(): curdir = os.path.dirname(os.path.abspath(__file__)) subdirs = [o for o in os.listdir(curdir) if os.path.exists(os.path.sep.join([curdir,o,'__init__.py']))] ...
## module loader, goes to see which submodules have 'html' directories ## and declares them at the toplevel import os,importlib def find_module_dirs(): curdir = os.path.dirname(os.path.abspath(__file__)) subdirs = [o for o in os.listdir(curdir) if os.path.exists(os.path.sep.join([curdir,o,'__init__.py']))] ...
Handle application erroring to not break the server
Handle application erroring to not break the server
Python
agpl-3.0
sociam/indx,sociam/indx,sociam/indx
## module loader, goes to see which submodules have 'html' directories ## and declares them at the toplevel import os,importlib def find_module_dirs(): curdir = os.path.dirname(os.path.abspath(__file__)) subdirs = [o for o in os.listdir(curdir) if os.path.exists(os.path.sep.join([curdir,o,'__init__.py']))] ...
## module loader, goes to see which submodules have 'html' directories ## and declares them at the toplevel import os,importlib def find_module_dirs(): curdir = os.path.dirname(os.path.abspath(__file__)) subdirs = [o for o in os.listdir(curdir) if os.path.exists(os.path.sep.join([curdir,o,'__init__.py']))] ...
<commit_before>## module loader, goes to see which submodules have 'html' directories ## and declares them at the toplevel import os,importlib def find_module_dirs(): curdir = os.path.dirname(os.path.abspath(__file__)) subdirs = [o for o in os.listdir(curdir) if os.path.exists(os.path.sep.join([curdir,o,'__in...
## module loader, goes to see which submodules have 'html' directories ## and declares them at the toplevel import os,importlib def find_module_dirs(): curdir = os.path.dirname(os.path.abspath(__file__)) subdirs = [o for o in os.listdir(curdir) if os.path.exists(os.path.sep.join([curdir,o,'__init__.py']))] ...
## module loader, goes to see which submodules have 'html' directories ## and declares them at the toplevel import os,importlib def find_module_dirs(): curdir = os.path.dirname(os.path.abspath(__file__)) subdirs = [o for o in os.listdir(curdir) if os.path.exists(os.path.sep.join([curdir,o,'__init__.py']))] ...
<commit_before>## module loader, goes to see which submodules have 'html' directories ## and declares them at the toplevel import os,importlib def find_module_dirs(): curdir = os.path.dirname(os.path.abspath(__file__)) subdirs = [o for o in os.listdir(curdir) if os.path.exists(os.path.sep.join([curdir,o,'__in...
5510814b2d186c6bf6d1c8af96eab16302e1675f
test/library/gyptest-shared-obj-install-path.py
test/library/gyptest-shared-obj-install-path.py
#!/usr/bin/env python # Copyright (c) 2010 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Verifies that .so files that are order only dependencies are specified by their install location rather than by their alias. """ import...
#!/usr/bin/env python # Copyright (c) 2010 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Verifies that .so files that are order only dependencies are specified by their install location rather than by their alias. """ # Pyth...
Add with_statement import for python2.5.
Add with_statement import for python2.5. See http://www.python.org/dev/peps/pep-0343/ which describes the with statement. Review URL: http://codereview.chromium.org/5690003 git-svn-id: e7e1075985beda50ea81ac4472467b4f6e91fc78@863 78cadc50-ecff-11dd-a971-7dbc132099af
Python
bsd-3-clause
bnq4ever/gypgoogle,sport-monkey/GYP,chromium/gyp,trafi/gyp,xin3liang/platform_external_chromium_org_tools_gyp,pyokagan/gyp,Danath/gyp,luvit/gyp,tarc/gyp,MIPS/external-chromium_org-tools-gyp,trafi/gyp,mgamer/gyp,springmeyer/gyp,ttyangf/pdfium_gyp,trafi/gyp,duanhjlt/gyp,kevinchen3315/gyp-git,pandaxcl/gyp,turbulenz/gyp,ca...
#!/usr/bin/env python # Copyright (c) 2010 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Verifies that .so files that are order only dependencies are specified by their install location rather than by their alias. """ import...
#!/usr/bin/env python # Copyright (c) 2010 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Verifies that .so files that are order only dependencies are specified by their install location rather than by their alias. """ # Pyth...
<commit_before>#!/usr/bin/env python # Copyright (c) 2010 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Verifies that .so files that are order only dependencies are specified by their install location rather than by their ali...
#!/usr/bin/env python # Copyright (c) 2010 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Verifies that .so files that are order only dependencies are specified by their install location rather than by their alias. """ # Pyth...
#!/usr/bin/env python # Copyright (c) 2010 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Verifies that .so files that are order only dependencies are specified by their install location rather than by their alias. """ import...
<commit_before>#!/usr/bin/env python # Copyright (c) 2010 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Verifies that .so files that are order only dependencies are specified by their install location rather than by their ali...
0404f6ebc33d83fc6dfeceed5d9370e73ef40e64
awx/main/conf.py
awx/main/conf.py
# Copyright (c) 2015 Ansible, Inc.. # All Rights Reserved. import json from django.conf import settings as django_settings from awx.main.models.configuration import TowerSettings class TowerConfiguration(object): def __getattr__(self, key): ts = TowerSettings.objects.filter(key=key) if not ts.exi...
# Copyright (c) 2015 Ansible, Inc.. # All Rights Reserved. import json from django.conf import settings as django_settings from awx.main.models.configuration import TowerSettings class TowerConfiguration(object): # TODO: Caching so we don't have to hit the database every time for settings def __getattr__(sel...
Add a note about caching
Add a note about caching
Python
apache-2.0
snahelou/awx,wwitzel3/awx,wwitzel3/awx,snahelou/awx,wwitzel3/awx,snahelou/awx,wwitzel3/awx,snahelou/awx
# Copyright (c) 2015 Ansible, Inc.. # All Rights Reserved. import json from django.conf import settings as django_settings from awx.main.models.configuration import TowerSettings class TowerConfiguration(object): def __getattr__(self, key): ts = TowerSettings.objects.filter(key=key) if not ts.exi...
# Copyright (c) 2015 Ansible, Inc.. # All Rights Reserved. import json from django.conf import settings as django_settings from awx.main.models.configuration import TowerSettings class TowerConfiguration(object): # TODO: Caching so we don't have to hit the database every time for settings def __getattr__(sel...
<commit_before># Copyright (c) 2015 Ansible, Inc.. # All Rights Reserved. import json from django.conf import settings as django_settings from awx.main.models.configuration import TowerSettings class TowerConfiguration(object): def __getattr__(self, key): ts = TowerSettings.objects.filter(key=key) ...
# Copyright (c) 2015 Ansible, Inc.. # All Rights Reserved. import json from django.conf import settings as django_settings from awx.main.models.configuration import TowerSettings class TowerConfiguration(object): # TODO: Caching so we don't have to hit the database every time for settings def __getattr__(sel...
# Copyright (c) 2015 Ansible, Inc.. # All Rights Reserved. import json from django.conf import settings as django_settings from awx.main.models.configuration import TowerSettings class TowerConfiguration(object): def __getattr__(self, key): ts = TowerSettings.objects.filter(key=key) if not ts.exi...
<commit_before># Copyright (c) 2015 Ansible, Inc.. # All Rights Reserved. import json from django.conf import settings as django_settings from awx.main.models.configuration import TowerSettings class TowerConfiguration(object): def __getattr__(self, key): ts = TowerSettings.objects.filter(key=key) ...
19c4d0035c0e64425adb4aee34a9e364172e529c
gitcommitautosave.py
gitcommitautosave.py
"""Git Commit Auto Save. Sublime Text 3 package to auto save commit messages when the window is closed. This allows the user to close the window without having to save before, or having to deal with the "Save File" popup. """ import sublime_plugin class GitCommitAutoSave(sublime_plugin.EventListener): def on_load(s...
"""Git Commit Auto Save. Sublime Text 3 package to auto save commit messages when the window is closed. This allows the user to close the window without having to save before, or having to deal with the "Save File" popup. """ import sublime_plugin class GitCommitAutoSave(sublime_plugin.EventListener): def on_load(s...
Add support for interactive rebase
Add support for interactive rebase
Python
mit
aristidesfl/sublime-git-commit-message-auto-save
"""Git Commit Auto Save. Sublime Text 3 package to auto save commit messages when the window is closed. This allows the user to close the window without having to save before, or having to deal with the "Save File" popup. """ import sublime_plugin class GitCommitAutoSave(sublime_plugin.EventListener): def on_load(s...
"""Git Commit Auto Save. Sublime Text 3 package to auto save commit messages when the window is closed. This allows the user to close the window without having to save before, or having to deal with the "Save File" popup. """ import sublime_plugin class GitCommitAutoSave(sublime_plugin.EventListener): def on_load(s...
<commit_before>"""Git Commit Auto Save. Sublime Text 3 package to auto save commit messages when the window is closed. This allows the user to close the window without having to save before, or having to deal with the "Save File" popup. """ import sublime_plugin class GitCommitAutoSave(sublime_plugin.EventListener):...
"""Git Commit Auto Save. Sublime Text 3 package to auto save commit messages when the window is closed. This allows the user to close the window without having to save before, or having to deal with the "Save File" popup. """ import sublime_plugin class GitCommitAutoSave(sublime_plugin.EventListener): def on_load(s...
"""Git Commit Auto Save. Sublime Text 3 package to auto save commit messages when the window is closed. This allows the user to close the window without having to save before, or having to deal with the "Save File" popup. """ import sublime_plugin class GitCommitAutoSave(sublime_plugin.EventListener): def on_load(s...
<commit_before>"""Git Commit Auto Save. Sublime Text 3 package to auto save commit messages when the window is closed. This allows the user to close the window without having to save before, or having to deal with the "Save File" popup. """ import sublime_plugin class GitCommitAutoSave(sublime_plugin.EventListener):...
9416261fefeb37ad89509e54975bcba02069183b
pywikibot/__metadata__.py
pywikibot/__metadata__.py
# -*- coding: utf-8 -*- """Pywikibot metadata file.""" # # (C) Pywikibot team, 2020 # # Distributed under the terms of the MIT license. # __name__ = 'pywikibot' __version__ = '4.0.1.dev0' __description__ = 'Python MediaWiki Bot Framework' __maintainer__ = 'The Pywikibot team' __maintainer_email__ = 'pywikibot@lists.wik...
# -*- coding: utf-8 -*- """Pywikibot metadata file.""" # # (C) Pywikibot team, 2020 # # Distributed under the terms of the MIT license. # __name__ = 'pywikibot' __version__ = '4.1.0.dev0' __description__ = 'Python MediaWiki Bot Framework' __maintainer__ = 'The Pywikibot team' __maintainer_email__ = 'pywikibot@lists.wik...
Update pwb version to 4.1
[4.1] Update pwb version to 4.1 The current development is more than just bugfixes and i18n/L10N updates Change-Id: I581bfa1ee49f91161d904227e1be338db8361819
Python
mit
wikimedia/pywikibot-core,wikimedia/pywikibot-core
# -*- coding: utf-8 -*- """Pywikibot metadata file.""" # # (C) Pywikibot team, 2020 # # Distributed under the terms of the MIT license. # __name__ = 'pywikibot' __version__ = '4.0.1.dev0' __description__ = 'Python MediaWiki Bot Framework' __maintainer__ = 'The Pywikibot team' __maintainer_email__ = 'pywikibot@lists.wik...
# -*- coding: utf-8 -*- """Pywikibot metadata file.""" # # (C) Pywikibot team, 2020 # # Distributed under the terms of the MIT license. # __name__ = 'pywikibot' __version__ = '4.1.0.dev0' __description__ = 'Python MediaWiki Bot Framework' __maintainer__ = 'The Pywikibot team' __maintainer_email__ = 'pywikibot@lists.wik...
<commit_before># -*- coding: utf-8 -*- """Pywikibot metadata file.""" # # (C) Pywikibot team, 2020 # # Distributed under the terms of the MIT license. # __name__ = 'pywikibot' __version__ = '4.0.1.dev0' __description__ = 'Python MediaWiki Bot Framework' __maintainer__ = 'The Pywikibot team' __maintainer_email__ = 'pywi...
# -*- coding: utf-8 -*- """Pywikibot metadata file.""" # # (C) Pywikibot team, 2020 # # Distributed under the terms of the MIT license. # __name__ = 'pywikibot' __version__ = '4.1.0.dev0' __description__ = 'Python MediaWiki Bot Framework' __maintainer__ = 'The Pywikibot team' __maintainer_email__ = 'pywikibot@lists.wik...
# -*- coding: utf-8 -*- """Pywikibot metadata file.""" # # (C) Pywikibot team, 2020 # # Distributed under the terms of the MIT license. # __name__ = 'pywikibot' __version__ = '4.0.1.dev0' __description__ = 'Python MediaWiki Bot Framework' __maintainer__ = 'The Pywikibot team' __maintainer_email__ = 'pywikibot@lists.wik...
<commit_before># -*- coding: utf-8 -*- """Pywikibot metadata file.""" # # (C) Pywikibot team, 2020 # # Distributed under the terms of the MIT license. # __name__ = 'pywikibot' __version__ = '4.0.1.dev0' __description__ = 'Python MediaWiki Bot Framework' __maintainer__ = 'The Pywikibot team' __maintainer_email__ = 'pywi...
55c183ad234ec53e2c7ba82e9e19793564373200
comics/comics/dieselsweetiesweb.py
comics/comics/dieselsweetiesweb.py
from comics.aggregator.crawler import CrawlerBase, CrawlerImage from comics.meta.base import MetaBase class Meta(MetaBase): name = 'Diesel Sweeties (web)' language = 'en' url = 'http://www.dieselsweeties.com/' start_date = '2000-01-01' rights = 'Richard Stevens' class Crawler(CrawlerBase): his...
from comics.aggregator.crawler import CrawlerBase, CrawlerImage from comics.meta.base import MetaBase class Meta(MetaBase): name = 'Diesel Sweeties (web)' language = 'en' url = 'http://www.dieselsweeties.com/' start_date = '2000-01-01' rights = 'Richard Stevens' class Crawler(CrawlerBase): his...
Check if field exists, not if it's empty
Check if field exists, not if it's empty
Python
agpl-3.0
jodal/comics,jodal/comics,datagutten/comics,datagutten/comics,datagutten/comics,jodal/comics,jodal/comics,datagutten/comics
from comics.aggregator.crawler import CrawlerBase, CrawlerImage from comics.meta.base import MetaBase class Meta(MetaBase): name = 'Diesel Sweeties (web)' language = 'en' url = 'http://www.dieselsweeties.com/' start_date = '2000-01-01' rights = 'Richard Stevens' class Crawler(CrawlerBase): his...
from comics.aggregator.crawler import CrawlerBase, CrawlerImage from comics.meta.base import MetaBase class Meta(MetaBase): name = 'Diesel Sweeties (web)' language = 'en' url = 'http://www.dieselsweeties.com/' start_date = '2000-01-01' rights = 'Richard Stevens' class Crawler(CrawlerBase): his...
<commit_before>from comics.aggregator.crawler import CrawlerBase, CrawlerImage from comics.meta.base import MetaBase class Meta(MetaBase): name = 'Diesel Sweeties (web)' language = 'en' url = 'http://www.dieselsweeties.com/' start_date = '2000-01-01' rights = 'Richard Stevens' class Crawler(Crawle...
from comics.aggregator.crawler import CrawlerBase, CrawlerImage from comics.meta.base import MetaBase class Meta(MetaBase): name = 'Diesel Sweeties (web)' language = 'en' url = 'http://www.dieselsweeties.com/' start_date = '2000-01-01' rights = 'Richard Stevens' class Crawler(CrawlerBase): his...
from comics.aggregator.crawler import CrawlerBase, CrawlerImage from comics.meta.base import MetaBase class Meta(MetaBase): name = 'Diesel Sweeties (web)' language = 'en' url = 'http://www.dieselsweeties.com/' start_date = '2000-01-01' rights = 'Richard Stevens' class Crawler(CrawlerBase): his...
<commit_before>from comics.aggregator.crawler import CrawlerBase, CrawlerImage from comics.meta.base import MetaBase class Meta(MetaBase): name = 'Diesel Sweeties (web)' language = 'en' url = 'http://www.dieselsweeties.com/' start_date = '2000-01-01' rights = 'Richard Stevens' class Crawler(Crawle...
15838f52f7f0cc40bcec8f64ad59dffe6bd945a5
hatarake/__init__.py
hatarake/__init__.py
import os import platform from hatarake.version import __version__ ISSUES_LINK = 'https://github.com/kfdm/hatarake/issues' ISSUES_API = 'https://api.github.com/repos/kfdm/hatarake/issues?state=open' USER_AGENT = 'Hatarake/%s https://github.com/kfdm/hatarake' % __version__ GROWL_INTERVAL = 30 if 'Darwin' in platform...
import os import platform from hatarake.version import __version__ ISSUES_LINK = 'https://github.com/kfdm/hatarake/issues' ISSUES_API = 'https://api.github.com/repos/kfdm/hatarake/issues?state=open' USER_AGENT = 'Hatarake/%s https://github.com/kfdm/hatarake' % __version__ GROWL_INTERVAL = 30 if 'Darwin' in platform...
Add path for sqlite file
Add path for sqlite file
Python
mit
kfdm/hatarake
import os import platform from hatarake.version import __version__ ISSUES_LINK = 'https://github.com/kfdm/hatarake/issues' ISSUES_API = 'https://api.github.com/repos/kfdm/hatarake/issues?state=open' USER_AGENT = 'Hatarake/%s https://github.com/kfdm/hatarake' % __version__ GROWL_INTERVAL = 30 if 'Darwin' in platform...
import os import platform from hatarake.version import __version__ ISSUES_LINK = 'https://github.com/kfdm/hatarake/issues' ISSUES_API = 'https://api.github.com/repos/kfdm/hatarake/issues?state=open' USER_AGENT = 'Hatarake/%s https://github.com/kfdm/hatarake' % __version__ GROWL_INTERVAL = 30 if 'Darwin' in platform...
<commit_before>import os import platform from hatarake.version import __version__ ISSUES_LINK = 'https://github.com/kfdm/hatarake/issues' ISSUES_API = 'https://api.github.com/repos/kfdm/hatarake/issues?state=open' USER_AGENT = 'Hatarake/%s https://github.com/kfdm/hatarake' % __version__ GROWL_INTERVAL = 30 if 'Darw...
import os import platform from hatarake.version import __version__ ISSUES_LINK = 'https://github.com/kfdm/hatarake/issues' ISSUES_API = 'https://api.github.com/repos/kfdm/hatarake/issues?state=open' USER_AGENT = 'Hatarake/%s https://github.com/kfdm/hatarake' % __version__ GROWL_INTERVAL = 30 if 'Darwin' in platform...
import os import platform from hatarake.version import __version__ ISSUES_LINK = 'https://github.com/kfdm/hatarake/issues' ISSUES_API = 'https://api.github.com/repos/kfdm/hatarake/issues?state=open' USER_AGENT = 'Hatarake/%s https://github.com/kfdm/hatarake' % __version__ GROWL_INTERVAL = 30 if 'Darwin' in platform...
<commit_before>import os import platform from hatarake.version import __version__ ISSUES_LINK = 'https://github.com/kfdm/hatarake/issues' ISSUES_API = 'https://api.github.com/repos/kfdm/hatarake/issues?state=open' USER_AGENT = 'Hatarake/%s https://github.com/kfdm/hatarake' % __version__ GROWL_INTERVAL = 30 if 'Darw...
308390bdd15c9a4abc79b567577b160c8e4adfab
examples/demo/setup.py
examples/demo/setup.py
from setuptools import setup setup(name='demo', install_requires=[ 'wsme', 'PasteScript', 'PasteDeploy', 'WSGIUtils', 'Pygments', ], package=['demo'])
from setuptools import setup setup(name='demo', install_requires=[ 'WSME', 'WSME-Soap', 'PasteScript', 'PasteDeploy', 'WSGIUtils', 'Pygments', ], package=['demo'])
Add a dependency on WSME-Soap
Add a dependency on WSME-Soap
Python
mit
stackforge/wsme
from setuptools import setup setup(name='demo', install_requires=[ 'wsme', 'PasteScript', 'PasteDeploy', 'WSGIUtils', 'Pygments', ], package=['demo']) Add a dependency on WSME-Soap
from setuptools import setup setup(name='demo', install_requires=[ 'WSME', 'WSME-Soap', 'PasteScript', 'PasteDeploy', 'WSGIUtils', 'Pygments', ], package=['demo'])
<commit_before>from setuptools import setup setup(name='demo', install_requires=[ 'wsme', 'PasteScript', 'PasteDeploy', 'WSGIUtils', 'Pygments', ], package=['demo']) <commit_msg>Add a dependency on WSME-Soap<commit_after>
from setuptools import setup setup(name='demo', install_requires=[ 'WSME', 'WSME-Soap', 'PasteScript', 'PasteDeploy', 'WSGIUtils', 'Pygments', ], package=['demo'])
from setuptools import setup setup(name='demo', install_requires=[ 'wsme', 'PasteScript', 'PasteDeploy', 'WSGIUtils', 'Pygments', ], package=['demo']) Add a dependency on WSME-Soapfrom setuptools import setup setup(name='demo', install_requires=[ 'WSME',...
<commit_before>from setuptools import setup setup(name='demo', install_requires=[ 'wsme', 'PasteScript', 'PasteDeploy', 'WSGIUtils', 'Pygments', ], package=['demo']) <commit_msg>Add a dependency on WSME-Soap<commit_after>from setuptools import setup setup(name='demo...
9ca8b4bddabe8bdf91019d0bbc9a792feacbaff9
config.py
config.py
# Log config import logging BASE_PATH = "/home/user/workspace/OSHI-monitoring/" RRD_LOG_PATH = BASE_PATH+"logs/" TRAFFIC_MONITOR_LOG_PATH = BASE_PATH+"logs/" LOG_LEVEL = logging.ERROR # RRD config RRD_STEP = "300" RRD_STORE_PATH = BASE_PATH+"rrd/" RRD_DATA_SOURCE_TYPE = "GAUGE" RRD_DATA_SOURCE_HEARTBEAT = "600" # T...
# Log config import logging BASE_PATH = "/home/user/workspace/OSHI-monitoring/" RRD_LOG_PATH = BASE_PATH + "logs/" TRAFFIC_MONITOR_LOG_PATH = BASE_PATH + "logs/" LOG_LEVEL = logging.ERROR # Traffic monitor config REQUEST_INTERVAL = 30 LLDP_NOISE_BYTE_S = 19 LLDP_NOISE_PACK_S = 0.365 # RRD config RRD_STEP = str(REQU...
Set RRD STEP equal to REQUEST_INTERVAL.
Set RRD STEP equal to REQUEST_INTERVAL.
Python
mit
StefanoSalsano/OSHI-monitoring,StefanoSalsano/OSHI-monitoring,netgroup/OSHI-monitoring,ferrarimarco/OSHI-monitoring,ferrarimarco/OSHI-monitoring,netgroup/OSHI-monitoring
# Log config import logging BASE_PATH = "/home/user/workspace/OSHI-monitoring/" RRD_LOG_PATH = BASE_PATH+"logs/" TRAFFIC_MONITOR_LOG_PATH = BASE_PATH+"logs/" LOG_LEVEL = logging.ERROR # RRD config RRD_STEP = "300" RRD_STORE_PATH = BASE_PATH+"rrd/" RRD_DATA_SOURCE_TYPE = "GAUGE" RRD_DATA_SOURCE_HEARTBEAT = "600" # T...
# Log config import logging BASE_PATH = "/home/user/workspace/OSHI-monitoring/" RRD_LOG_PATH = BASE_PATH + "logs/" TRAFFIC_MONITOR_LOG_PATH = BASE_PATH + "logs/" LOG_LEVEL = logging.ERROR # Traffic monitor config REQUEST_INTERVAL = 30 LLDP_NOISE_BYTE_S = 19 LLDP_NOISE_PACK_S = 0.365 # RRD config RRD_STEP = str(REQU...
<commit_before># Log config import logging BASE_PATH = "/home/user/workspace/OSHI-monitoring/" RRD_LOG_PATH = BASE_PATH+"logs/" TRAFFIC_MONITOR_LOG_PATH = BASE_PATH+"logs/" LOG_LEVEL = logging.ERROR # RRD config RRD_STEP = "300" RRD_STORE_PATH = BASE_PATH+"rrd/" RRD_DATA_SOURCE_TYPE = "GAUGE" RRD_DATA_SOURCE_HEARTBE...
# Log config import logging BASE_PATH = "/home/user/workspace/OSHI-monitoring/" RRD_LOG_PATH = BASE_PATH + "logs/" TRAFFIC_MONITOR_LOG_PATH = BASE_PATH + "logs/" LOG_LEVEL = logging.ERROR # Traffic monitor config REQUEST_INTERVAL = 30 LLDP_NOISE_BYTE_S = 19 LLDP_NOISE_PACK_S = 0.365 # RRD config RRD_STEP = str(REQU...
# Log config import logging BASE_PATH = "/home/user/workspace/OSHI-monitoring/" RRD_LOG_PATH = BASE_PATH+"logs/" TRAFFIC_MONITOR_LOG_PATH = BASE_PATH+"logs/" LOG_LEVEL = logging.ERROR # RRD config RRD_STEP = "300" RRD_STORE_PATH = BASE_PATH+"rrd/" RRD_DATA_SOURCE_TYPE = "GAUGE" RRD_DATA_SOURCE_HEARTBEAT = "600" # T...
<commit_before># Log config import logging BASE_PATH = "/home/user/workspace/OSHI-monitoring/" RRD_LOG_PATH = BASE_PATH+"logs/" TRAFFIC_MONITOR_LOG_PATH = BASE_PATH+"logs/" LOG_LEVEL = logging.ERROR # RRD config RRD_STEP = "300" RRD_STORE_PATH = BASE_PATH+"rrd/" RRD_DATA_SOURCE_TYPE = "GAUGE" RRD_DATA_SOURCE_HEARTBE...
9a7654c727a24eecadc26ac400408cb4837ec0cc
pywayland/protocol/__init__.py
pywayland/protocol/__init__.py
# Copyright 2015 Sean Vig # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, sof...
# Copyright 2015 Sean Vig # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, sof...
Fix intflag on Python 3.5
Fix intflag on Python 3.5 Just define it to IntEnum, which is definitely not going to be correct, but this should fix the tests on Python 3.5
Python
apache-2.0
flacjacket/pywayland
# Copyright 2015 Sean Vig # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, sof...
# Copyright 2015 Sean Vig # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, sof...
<commit_before># Copyright 2015 Sean Vig # # 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 ...
# Copyright 2015 Sean Vig # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, sof...
# Copyright 2015 Sean Vig # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, sof...
<commit_before># Copyright 2015 Sean Vig # # 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 ...
131cb9abd711cc71c558e5a89d5e2b8a28ae8517
tests/integration/test_gists.py
tests/integration/test_gists.py
from .helper import IntegrationHelper import github3 class TestGist(IntegrationHelper): def test_comments(self): """Show that a user can iterate over the comments on a gist.""" cassette_name = self.cassette_name('comments') with self.recorder.use_cassette(cassette_name): gist ...
# -*- coding: utf-8 -*- """Integration tests for methods implemented on Gist.""" from .helper import IntegrationHelper import github3 class TestGist(IntegrationHelper): """Gist integration tests.""" def test_comments(self): """Show that a user can iterate over the comments on a gist.""" cas...
Add docstrings to Gist integration tests
Add docstrings to Gist integration tests @esacteksab would be so proud
Python
bsd-3-clause
krxsky/github3.py,balloob/github3.py,jim-minter/github3.py,ueg1990/github3.py,wbrefvem/github3.py,agamdua/github3.py,christophelec/github3.py,icio/github3.py,sigmavirus24/github3.py,itsmemattchung/github3.py,h4ck3rm1k3/github3.py,degustaf/github3.py
from .helper import IntegrationHelper import github3 class TestGist(IntegrationHelper): def test_comments(self): """Show that a user can iterate over the comments on a gist.""" cassette_name = self.cassette_name('comments') with self.recorder.use_cassette(cassette_name): gist ...
# -*- coding: utf-8 -*- """Integration tests for methods implemented on Gist.""" from .helper import IntegrationHelper import github3 class TestGist(IntegrationHelper): """Gist integration tests.""" def test_comments(self): """Show that a user can iterate over the comments on a gist.""" cas...
<commit_before>from .helper import IntegrationHelper import github3 class TestGist(IntegrationHelper): def test_comments(self): """Show that a user can iterate over the comments on a gist.""" cassette_name = self.cassette_name('comments') with self.recorder.use_cassette(cassette_name): ...
# -*- coding: utf-8 -*- """Integration tests for methods implemented on Gist.""" from .helper import IntegrationHelper import github3 class TestGist(IntegrationHelper): """Gist integration tests.""" def test_comments(self): """Show that a user can iterate over the comments on a gist.""" cas...
from .helper import IntegrationHelper import github3 class TestGist(IntegrationHelper): def test_comments(self): """Show that a user can iterate over the comments on a gist.""" cassette_name = self.cassette_name('comments') with self.recorder.use_cassette(cassette_name): gist ...
<commit_before>from .helper import IntegrationHelper import github3 class TestGist(IntegrationHelper): def test_comments(self): """Show that a user can iterate over the comments on a gist.""" cassette_name = self.cassette_name('comments') with self.recorder.use_cassette(cassette_name): ...
02550f389a6b3208d86e7a92f01c9e1df42561f7
sahara/tests/unit/testutils.py
sahara/tests/unit/testutils.py
# Copyright (c) 2014 Mirantis 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...
# Copyright (c) 2014 Mirantis 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...
Use immutable arg rather mutable arg
Use immutable arg rather mutable arg Passing mutable objects as default args is a known Python pitfall. We'd better avoid this. This commit changes mutable default args with None, then use 'arg = arg or []'. Change-Id: If3a10d58e6cd792a2011c177c49d3b865a7421ff
Python
apache-2.0
henaras/sahara,ekasitk/sahara,esikachev/scenario,redhat-openstack/sahara,ekasitk/sahara,tellesnobrega/sahara,tellesnobrega/sahara,keedio/sahara,citrix-openstack-build/sahara,mapr/sahara,ekasitk/sahara,matips/iosr-2015,bigfootproject/sahara,mapr/sahara,zhujzhuo/Sahara,esikachev/sahara-backup,zhangjunli177/sahara,bigfoot...
# Copyright (c) 2014 Mirantis 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...
# Copyright (c) 2014 Mirantis 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...
<commit_before># Copyright (c) 2014 Mirantis 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 ag...
# Copyright (c) 2014 Mirantis 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...
# Copyright (c) 2014 Mirantis 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...
<commit_before># Copyright (c) 2014 Mirantis 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 ag...
19fb0aa1daceed336c7f452ed361ad79107e75a2
server/src/voodoo/sessions/sqlalchemy_data.py
server/src/voodoo/sessions/sqlalchemy_data.py
#-*-*- encoding: utf-8 -*-*- # # Copyright (C) 2005-2009 University of Deusto # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. # # This software consists of contributions made by many individuals, # listed below: # # A...
#-*-*- encoding: utf-8 -*-*- # # Copyright (C) 2005-2009 University of Deusto # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. # # This software consists of contributions made by many individuals, # listed below: # # A...
Remove sqlalchemy 0.7 warning (Binary => LargeBinary)
Remove sqlalchemy 0.7 warning (Binary => LargeBinary)
Python
bsd-2-clause
morelab/weblabdeusto,weblabdeusto/weblabdeusto,morelab/weblabdeusto,morelab/weblabdeusto,zstars/weblabdeusto,weblabdeusto/weblabdeusto,weblabdeusto/weblabdeusto,weblabdeusto/weblabdeusto,morelab/weblabdeusto,zstars/weblabdeusto,zstars/weblabdeusto,weblabdeusto/weblabdeusto,morelab/weblabdeusto,weblabdeusto/weblabdeusto...
#-*-*- encoding: utf-8 -*-*- # # Copyright (C) 2005-2009 University of Deusto # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. # # This software consists of contributions made by many individuals, # listed below: # # A...
#-*-*- encoding: utf-8 -*-*- # # Copyright (C) 2005-2009 University of Deusto # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. # # This software consists of contributions made by many individuals, # listed below: # # A...
<commit_before>#-*-*- encoding: utf-8 -*-*- # # Copyright (C) 2005-2009 University of Deusto # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. # # This software consists of contributions made by many individuals, # list...
#-*-*- encoding: utf-8 -*-*- # # Copyright (C) 2005-2009 University of Deusto # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. # # This software consists of contributions made by many individuals, # listed below: # # A...
#-*-*- encoding: utf-8 -*-*- # # Copyright (C) 2005-2009 University of Deusto # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. # # This software consists of contributions made by many individuals, # listed below: # # A...
<commit_before>#-*-*- encoding: utf-8 -*-*- # # Copyright (C) 2005-2009 University of Deusto # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. # # This software consists of contributions made by many individuals, # list...
9d184e1d323078d7ce73300ba90f6711c6e8f4c1
oauth_access/models.py
oauth_access/models.py
import datetime from django.db import models from django.contrib.auth.models import User class UserAssociation(models.Model): user = models.ForeignKey(User) service = models.CharField(max_length=75, db_index=True) identifier = models.CharField(max_length=255, db_index=True) token = models.CharF...
import datetime from django.db import models from django.contrib.auth.models import User class UserAssociation(models.Model): user = models.ForeignKey(User) service = models.CharField(max_length=75, db_index=True) identifier = models.CharField(max_length=255, db_index=True) token = models.CharF...
Check if an association has an expiry time before deciding if it's expired
Check if an association has an expiry time before deciding if it's expired
Python
bsd-3-clause
eldarion/django-oauth-access,eldarion/django-oauth-access
import datetime from django.db import models from django.contrib.auth.models import User class UserAssociation(models.Model): user = models.ForeignKey(User) service = models.CharField(max_length=75, db_index=True) identifier = models.CharField(max_length=255, db_index=True) token = models.CharF...
import datetime from django.db import models from django.contrib.auth.models import User class UserAssociation(models.Model): user = models.ForeignKey(User) service = models.CharField(max_length=75, db_index=True) identifier = models.CharField(max_length=255, db_index=True) token = models.CharF...
<commit_before>import datetime from django.db import models from django.contrib.auth.models import User class UserAssociation(models.Model): user = models.ForeignKey(User) service = models.CharField(max_length=75, db_index=True) identifier = models.CharField(max_length=255, db_index=True) token...
import datetime from django.db import models from django.contrib.auth.models import User class UserAssociation(models.Model): user = models.ForeignKey(User) service = models.CharField(max_length=75, db_index=True) identifier = models.CharField(max_length=255, db_index=True) token = models.CharF...
import datetime from django.db import models from django.contrib.auth.models import User class UserAssociation(models.Model): user = models.ForeignKey(User) service = models.CharField(max_length=75, db_index=True) identifier = models.CharField(max_length=255, db_index=True) token = models.CharF...
<commit_before>import datetime from django.db import models from django.contrib.auth.models import User class UserAssociation(models.Model): user = models.ForeignKey(User) service = models.CharField(max_length=75, db_index=True) identifier = models.CharField(max_length=255, db_index=True) token...