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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
462656f9653ae43ea69080414735927b18e0debf | stats/random_walk.py | stats/random_walk.py | import neo4j
import random
from logbook import Logger
log = Logger('trinity.topics')
DEFAULT_DEPTH = 5
NUM_WALKS = 100
# Passed sorted list (desc order), return top nodes
TO_RETURN = lambda x: x[:10]
random.seed()
def random_walk(graph, node, depth=DEFAULT_DEPTH):
# Pick random neighbor
neighbors = {}
i... | import neo4j
import random
DEFAULT_DEPTH = 5
NUM_WALKS = 100
# Passed sorted list (desc order), return top nodes
TO_RETURN = lambda x: x[:10]
random.seed()
def random_walk(graph, node, depth=DEFAULT_DEPTH):
if depth == 0:
return [node]
# Pick random neighbor
neighbors = {}
i = 0
for r in... | Modify random walk so that it works. | Modify random walk so that it works.
| Python | mit | peplin/trinity | import neo4j
import random
from logbook import Logger
log = Logger('trinity.topics')
DEFAULT_DEPTH = 5
NUM_WALKS = 100
# Passed sorted list (desc order), return top nodes
TO_RETURN = lambda x: x[:10]
random.seed()
def random_walk(graph, node, depth=DEFAULT_DEPTH):
# Pick random neighbor
neighbors = {}
i... | import neo4j
import random
DEFAULT_DEPTH = 5
NUM_WALKS = 100
# Passed sorted list (desc order), return top nodes
TO_RETURN = lambda x: x[:10]
random.seed()
def random_walk(graph, node, depth=DEFAULT_DEPTH):
if depth == 0:
return [node]
# Pick random neighbor
neighbors = {}
i = 0
for r in... | <commit_before>import neo4j
import random
from logbook import Logger
log = Logger('trinity.topics')
DEFAULT_DEPTH = 5
NUM_WALKS = 100
# Passed sorted list (desc order), return top nodes
TO_RETURN = lambda x: x[:10]
random.seed()
def random_walk(graph, node, depth=DEFAULT_DEPTH):
# Pick random neighbor
neigh... | import neo4j
import random
DEFAULT_DEPTH = 5
NUM_WALKS = 100
# Passed sorted list (desc order), return top nodes
TO_RETURN = lambda x: x[:10]
random.seed()
def random_walk(graph, node, depth=DEFAULT_DEPTH):
if depth == 0:
return [node]
# Pick random neighbor
neighbors = {}
i = 0
for r in... | import neo4j
import random
from logbook import Logger
log = Logger('trinity.topics')
DEFAULT_DEPTH = 5
NUM_WALKS = 100
# Passed sorted list (desc order), return top nodes
TO_RETURN = lambda x: x[:10]
random.seed()
def random_walk(graph, node, depth=DEFAULT_DEPTH):
# Pick random neighbor
neighbors = {}
i... | <commit_before>import neo4j
import random
from logbook import Logger
log = Logger('trinity.topics')
DEFAULT_DEPTH = 5
NUM_WALKS = 100
# Passed sorted list (desc order), return top nodes
TO_RETURN = lambda x: x[:10]
random.seed()
def random_walk(graph, node, depth=DEFAULT_DEPTH):
# Pick random neighbor
neigh... |
8eed621a15dafc8b0965c59b8da2296f8193d0ca | karabo_data/tests/test_agipd_geometry.py | karabo_data/tests/test_agipd_geometry.py | import numpy as np
from karabo_data.geometry2 import AGIPD_1MGeometry
def test_snap_assemble_data():
geom = AGIPD_1MGeometry.from_quad_positions(quad_pos=[
(-525, 625),
(-550, -10),
(520, -160),
(542.5, 475),
])
snap_geom = geom.snap()
stacked_data = np.zeros((16, 512,... | import numpy as np
from karabo_data.geometry2 import AGIPD_1MGeometry
def test_snap_assemble_data():
geom = AGIPD_1MGeometry.from_quad_positions(quad_pos=[
(-525, 625),
(-550, -10),
(520, -160),
(542.5, 475),
])
snap_geom = geom.snap()
stacked_data = np.zeros((16, 512,... | Add test of reading & writing CrystFEL geometry | Add test of reading & writing CrystFEL geometry
| Python | bsd-3-clause | European-XFEL/h5tools-py | import numpy as np
from karabo_data.geometry2 import AGIPD_1MGeometry
def test_snap_assemble_data():
geom = AGIPD_1MGeometry.from_quad_positions(quad_pos=[
(-525, 625),
(-550, -10),
(520, -160),
(542.5, 475),
])
snap_geom = geom.snap()
stacked_data = np.zeros((16, 512,... | import numpy as np
from karabo_data.geometry2 import AGIPD_1MGeometry
def test_snap_assemble_data():
geom = AGIPD_1MGeometry.from_quad_positions(quad_pos=[
(-525, 625),
(-550, -10),
(520, -160),
(542.5, 475),
])
snap_geom = geom.snap()
stacked_data = np.zeros((16, 512,... | <commit_before>import numpy as np
from karabo_data.geometry2 import AGIPD_1MGeometry
def test_snap_assemble_data():
geom = AGIPD_1MGeometry.from_quad_positions(quad_pos=[
(-525, 625),
(-550, -10),
(520, -160),
(542.5, 475),
])
snap_geom = geom.snap()
stacked_data = np.... | import numpy as np
from karabo_data.geometry2 import AGIPD_1MGeometry
def test_snap_assemble_data():
geom = AGIPD_1MGeometry.from_quad_positions(quad_pos=[
(-525, 625),
(-550, -10),
(520, -160),
(542.5, 475),
])
snap_geom = geom.snap()
stacked_data = np.zeros((16, 512,... | import numpy as np
from karabo_data.geometry2 import AGIPD_1MGeometry
def test_snap_assemble_data():
geom = AGIPD_1MGeometry.from_quad_positions(quad_pos=[
(-525, 625),
(-550, -10),
(520, -160),
(542.5, 475),
])
snap_geom = geom.snap()
stacked_data = np.zeros((16, 512,... | <commit_before>import numpy as np
from karabo_data.geometry2 import AGIPD_1MGeometry
def test_snap_assemble_data():
geom = AGIPD_1MGeometry.from_quad_positions(quad_pos=[
(-525, 625),
(-550, -10),
(520, -160),
(542.5, 475),
])
snap_geom = geom.snap()
stacked_data = np.... |
2e6823676dace8b3219aeeef69ab04a2a0dd533a | rally-scenarios/plugins/sample_plugin.py | rally-scenarios/plugins/sample_plugin.py | # Copyright 2014 Mirantis Inc.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by... | # Copyright 2014 Mirantis Inc.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by... | Fix outdated link in sample plugin | Fix outdated link in sample plugin
Link in sample_plugin.py is outdated
and is changed
Change-Id: I2f3a7b59c6380e4584a8ce2a5313fe766a40a52a
Closes-Bug: #1491975
| Python | apache-2.0 | steveb/heat,pratikmallya/heat,openstack/heat,gonzolino/heat,dragorosson/heat,dims/heat,steveb/heat,cwolferh/heat-scratch,openstack/heat,takeshineshiro/heat,dragorosson/heat,noironetworks/heat,noironetworks/heat,cwolferh/heat-scratch,jasondunsmore/heat,jasondunsmore/heat,maestro-hybrid-cloud/heat,dims/heat,maestro-hybri... | # Copyright 2014 Mirantis Inc.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by... | # Copyright 2014 Mirantis Inc.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by... | <commit_before># Copyright 2014 Mirantis Inc.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unl... | # Copyright 2014 Mirantis Inc.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by... | # Copyright 2014 Mirantis Inc.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by... | <commit_before># Copyright 2014 Mirantis Inc.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unl... |
eb22e8931b9ffe9c82b52451a7c17943ea43625d | python-tool/script/project.py | python-tool/script/project.py | $py_copyright
def _main():
print("Hello from $project_name")
if __name__ == "__main__":
_main()
| #!/usr/bin/env python
$py_copyright
from __future__ import print_function
def _main():
print("Hello from $project_name")
if __name__ == "__main__":
_main()
| Add shebang and future import | Add shebang and future import
| Python | mit | rcook/ptool-templates,rcook/ptool-templates,rcook/ptool-templates,rcook/ptool-templates,rcook/ptool-templates,rcook/ptool-templates,rcook/ptool-templates,rcook/ptool-templates | $py_copyright
def _main():
print("Hello from $project_name")
if __name__ == "__main__":
_main()
Add shebang and future import | #!/usr/bin/env python
$py_copyright
from __future__ import print_function
def _main():
print("Hello from $project_name")
if __name__ == "__main__":
_main()
| <commit_before>$py_copyright
def _main():
print("Hello from $project_name")
if __name__ == "__main__":
_main()
<commit_msg>Add shebang and future import<commit_after> | #!/usr/bin/env python
$py_copyright
from __future__ import print_function
def _main():
print("Hello from $project_name")
if __name__ == "__main__":
_main()
| $py_copyright
def _main():
print("Hello from $project_name")
if __name__ == "__main__":
_main()
Add shebang and future import#!/usr/bin/env python
$py_copyright
from __future__ import print_function
def _main():
print("Hello from $project_name")
if __name__ == "__main__":
_main()
| <commit_before>$py_copyright
def _main():
print("Hello from $project_name")
if __name__ == "__main__":
_main()
<commit_msg>Add shebang and future import<commit_after>#!/usr/bin/env python
$py_copyright
from __future__ import print_function
def _main():
print("Hello from $project_name")
if __name__ == "_... |
879b15779c921445ca4412d5e63319408d8e32bf | python/islp/02statlearn-ex.py | python/islp/02statlearn-ex.py | import pandas as pd
print('\nKNN\n---')
d = {'X1': [ 0, 2, 0, 0, -1, 1 ],
'X2': [ 3, 0, 1, 1, 0, 1 ],
'X3': [ 0, 0, 3, 2, 1, 1 ],
'Y': ['R', 'R', 'R', 'G', 'G', 'R']}
df = pd.DataFrame(data = d)
df = df.assign(dist = (df.X1**2 + df.X2**2 + df.X3**2)**(0.5))
df = df.sort_val... | import matplotlib.pyplot as plt
import pandas as pd
print('\nKNN\n---')
d = {'X1': [ 0, 2, 0, 0, -1, 1 ],
'X2': [ 3, 0, 1, 1, 0, 1 ],
'X3': [ 0, 0, 3, 2, 1, 1 ],
'Y': ['R', 'R', 'R', 'G', 'G', 'R']}
df = pd.DataFrame(data = d)
df = df.assign(dist = (df.X1**2 + df.X2**2 + df... | Add scatterplot matrix for college.csv. | Add scatterplot matrix for college.csv.
| Python | apache-2.0 | pdbartlett/misc-stuff,pdbartlett/misc-stuff,pdbartlett/misc-stuff,pdbartlett/misc-stuff,pdbartlett/misc-stuff,pdbartlett/misc-stuff,pdbartlett/misc-stuff,pdbartlett/misc-stuff,pdbartlett/misc-stuff,pdbartlett/misc-stuff,pdbartlett/misc-stuff,pdbartlett/misc-stuff,pdbartlett/misc-stuff | import pandas as pd
print('\nKNN\n---')
d = {'X1': [ 0, 2, 0, 0, -1, 1 ],
'X2': [ 3, 0, 1, 1, 0, 1 ],
'X3': [ 0, 0, 3, 2, 1, 1 ],
'Y': ['R', 'R', 'R', 'G', 'G', 'R']}
df = pd.DataFrame(data = d)
df = df.assign(dist = (df.X1**2 + df.X2**2 + df.X3**2)**(0.5))
df = df.sort_val... | import matplotlib.pyplot as plt
import pandas as pd
print('\nKNN\n---')
d = {'X1': [ 0, 2, 0, 0, -1, 1 ],
'X2': [ 3, 0, 1, 1, 0, 1 ],
'X3': [ 0, 0, 3, 2, 1, 1 ],
'Y': ['R', 'R', 'R', 'G', 'G', 'R']}
df = pd.DataFrame(data = d)
df = df.assign(dist = (df.X1**2 + df.X2**2 + df... | <commit_before>import pandas as pd
print('\nKNN\n---')
d = {'X1': [ 0, 2, 0, 0, -1, 1 ],
'X2': [ 3, 0, 1, 1, 0, 1 ],
'X3': [ 0, 0, 3, 2, 1, 1 ],
'Y': ['R', 'R', 'R', 'G', 'G', 'R']}
df = pd.DataFrame(data = d)
df = df.assign(dist = (df.X1**2 + df.X2**2 + df.X3**2)**(0.5))
d... | import matplotlib.pyplot as plt
import pandas as pd
print('\nKNN\n---')
d = {'X1': [ 0, 2, 0, 0, -1, 1 ],
'X2': [ 3, 0, 1, 1, 0, 1 ],
'X3': [ 0, 0, 3, 2, 1, 1 ],
'Y': ['R', 'R', 'R', 'G', 'G', 'R']}
df = pd.DataFrame(data = d)
df = df.assign(dist = (df.X1**2 + df.X2**2 + df... | import pandas as pd
print('\nKNN\n---')
d = {'X1': [ 0, 2, 0, 0, -1, 1 ],
'X2': [ 3, 0, 1, 1, 0, 1 ],
'X3': [ 0, 0, 3, 2, 1, 1 ],
'Y': ['R', 'R', 'R', 'G', 'G', 'R']}
df = pd.DataFrame(data = d)
df = df.assign(dist = (df.X1**2 + df.X2**2 + df.X3**2)**(0.5))
df = df.sort_val... | <commit_before>import pandas as pd
print('\nKNN\n---')
d = {'X1': [ 0, 2, 0, 0, -1, 1 ],
'X2': [ 3, 0, 1, 1, 0, 1 ],
'X3': [ 0, 0, 3, 2, 1, 1 ],
'Y': ['R', 'R', 'R', 'G', 'G', 'R']}
df = pd.DataFrame(data = d)
df = df.assign(dist = (df.X1**2 + df.X2**2 + df.X3**2)**(0.5))
d... |
35514dcb70ed5ede39299802e82fa352188f3546 | examples/nested_inline_tasksets.py | examples/nested_inline_tasksets.py | from locust import HttpUser, TaskSet, task, between
class WebsiteUser(HttpUser):
"""
Example of the ability of inline nested TaskSet classes
"""
host = "http://127.0.0.1:8089"
wait_time = between(2, 5)
class TopLevelTaskSet(TaskSet):
@task
class IndexTaskSet(TaskSet):
... | from locust import HttpUser, TaskSet, task, between
class WebsiteUser(HttpUser):
"""
Example of the ability of inline nested TaskSet classes
"""
host = "http://127.0.0.1:8089"
wait_time = between(2, 5)
@task
class TopLevelTaskSet(TaskSet):
@task
class IndexTaskSet(TaskSet)... | Use @task decorator in taskset example | Use @task decorator in taskset example
| Python | mit | mbeacom/locust,locustio/locust,mbeacom/locust,locustio/locust,mbeacom/locust,mbeacom/locust,locustio/locust,locustio/locust | from locust import HttpUser, TaskSet, task, between
class WebsiteUser(HttpUser):
"""
Example of the ability of inline nested TaskSet classes
"""
host = "http://127.0.0.1:8089"
wait_time = between(2, 5)
class TopLevelTaskSet(TaskSet):
@task
class IndexTaskSet(TaskSet):
... | from locust import HttpUser, TaskSet, task, between
class WebsiteUser(HttpUser):
"""
Example of the ability of inline nested TaskSet classes
"""
host = "http://127.0.0.1:8089"
wait_time = between(2, 5)
@task
class TopLevelTaskSet(TaskSet):
@task
class IndexTaskSet(TaskSet)... | <commit_before>from locust import HttpUser, TaskSet, task, between
class WebsiteUser(HttpUser):
"""
Example of the ability of inline nested TaskSet classes
"""
host = "http://127.0.0.1:8089"
wait_time = between(2, 5)
class TopLevelTaskSet(TaskSet):
@task
class IndexTaskSet... | from locust import HttpUser, TaskSet, task, between
class WebsiteUser(HttpUser):
"""
Example of the ability of inline nested TaskSet classes
"""
host = "http://127.0.0.1:8089"
wait_time = between(2, 5)
@task
class TopLevelTaskSet(TaskSet):
@task
class IndexTaskSet(TaskSet)... | from locust import HttpUser, TaskSet, task, between
class WebsiteUser(HttpUser):
"""
Example of the ability of inline nested TaskSet classes
"""
host = "http://127.0.0.1:8089"
wait_time = between(2, 5)
class TopLevelTaskSet(TaskSet):
@task
class IndexTaskSet(TaskSet):
... | <commit_before>from locust import HttpUser, TaskSet, task, between
class WebsiteUser(HttpUser):
"""
Example of the ability of inline nested TaskSet classes
"""
host = "http://127.0.0.1:8089"
wait_time = between(2, 5)
class TopLevelTaskSet(TaskSet):
@task
class IndexTaskSet... |
8af483f6bfd0576f694b6693deacbf25a782fe5a | pyfire/logger.py | pyfire/logger.py | # -*- coding: utf-8 -*-
"""
pyfire.logger
~~~~~~~~~~~~~
Use pocoo's logbook or a simple no-op fallback
:copyright: (c) 2011 by the pyfire Team, see AUTHORS for more details.
:license: BSD, see LICENSE for more details.
"""
try:
from logbook import Logger
except ImportError:
class Logger(o... | # -*- coding: utf-8 -*-
"""
pyfire.logger
~~~~~~~~~~~~~
Use pocoo's logbook or a simple no-op fallback
:copyright: (c) 2011 by the pyfire Team, see AUTHORS for more details.
:license: BSD, see LICENSE for more details.
"""
import warnings
import pyfire.configuration as config
try:
import lo... | Implement configuration support in logging | Implement configuration support in logging
| Python | bsd-3-clause | IgnitedAndExploded/pyfire,IgnitedAndExploded/pyfire | # -*- coding: utf-8 -*-
"""
pyfire.logger
~~~~~~~~~~~~~
Use pocoo's logbook or a simple no-op fallback
:copyright: (c) 2011 by the pyfire Team, see AUTHORS for more details.
:license: BSD, see LICENSE for more details.
"""
try:
from logbook import Logger
except ImportError:
class Logger(o... | # -*- coding: utf-8 -*-
"""
pyfire.logger
~~~~~~~~~~~~~
Use pocoo's logbook or a simple no-op fallback
:copyright: (c) 2011 by the pyfire Team, see AUTHORS for more details.
:license: BSD, see LICENSE for more details.
"""
import warnings
import pyfire.configuration as config
try:
import lo... | <commit_before># -*- coding: utf-8 -*-
"""
pyfire.logger
~~~~~~~~~~~~~
Use pocoo's logbook or a simple no-op fallback
:copyright: (c) 2011 by the pyfire Team, see AUTHORS for more details.
:license: BSD, see LICENSE for more details.
"""
try:
from logbook import Logger
except ImportError:
... | # -*- coding: utf-8 -*-
"""
pyfire.logger
~~~~~~~~~~~~~
Use pocoo's logbook or a simple no-op fallback
:copyright: (c) 2011 by the pyfire Team, see AUTHORS for more details.
:license: BSD, see LICENSE for more details.
"""
import warnings
import pyfire.configuration as config
try:
import lo... | # -*- coding: utf-8 -*-
"""
pyfire.logger
~~~~~~~~~~~~~
Use pocoo's logbook or a simple no-op fallback
:copyright: (c) 2011 by the pyfire Team, see AUTHORS for more details.
:license: BSD, see LICENSE for more details.
"""
try:
from logbook import Logger
except ImportError:
class Logger(o... | <commit_before># -*- coding: utf-8 -*-
"""
pyfire.logger
~~~~~~~~~~~~~
Use pocoo's logbook or a simple no-op fallback
:copyright: (c) 2011 by the pyfire Team, see AUTHORS for more details.
:license: BSD, see LICENSE for more details.
"""
try:
from logbook import Logger
except ImportError:
... |
1a1aab7c0a107b2a02d08f13c40c515ff265b60b | tempwatcher/watch.py | tempwatcher/watch.py | import json
import requests
class TemperatureWatch(object):
thermostat_url = None
alert_high = 80
alert_low = 60
_last_response = None
def get_info(self):
r = requests.get(self.thermostat_url + '/tstat')
self._last_response = json.loads(r.text)
return r.text
def check... | import json
import requests
class TemperatureWatch(object):
thermostat_url = None
alert_high = 80
alert_low = 60
_last_response = None
def get_info(self):
r = requests.get(self.thermostat_url + '/tstat')
self._last_response = json.loads(r.text)
return r.text
def check... | Break the alert into a method so subclasses can choose how the alert is relayed. | Break the alert into a method so subclasses can choose how the alert is relayed. | Python | bsd-3-clause | adamfast/tempwatcher | import json
import requests
class TemperatureWatch(object):
thermostat_url = None
alert_high = 80
alert_low = 60
_last_response = None
def get_info(self):
r = requests.get(self.thermostat_url + '/tstat')
self._last_response = json.loads(r.text)
return r.text
def check... | import json
import requests
class TemperatureWatch(object):
thermostat_url = None
alert_high = 80
alert_low = 60
_last_response = None
def get_info(self):
r = requests.get(self.thermostat_url + '/tstat')
self._last_response = json.loads(r.text)
return r.text
def check... | <commit_before>import json
import requests
class TemperatureWatch(object):
thermostat_url = None
alert_high = 80
alert_low = 60
_last_response = None
def get_info(self):
r = requests.get(self.thermostat_url + '/tstat')
self._last_response = json.loads(r.text)
return r.text... | import json
import requests
class TemperatureWatch(object):
thermostat_url = None
alert_high = 80
alert_low = 60
_last_response = None
def get_info(self):
r = requests.get(self.thermostat_url + '/tstat')
self._last_response = json.loads(r.text)
return r.text
def check... | import json
import requests
class TemperatureWatch(object):
thermostat_url = None
alert_high = 80
alert_low = 60
_last_response = None
def get_info(self):
r = requests.get(self.thermostat_url + '/tstat')
self._last_response = json.loads(r.text)
return r.text
def check... | <commit_before>import json
import requests
class TemperatureWatch(object):
thermostat_url = None
alert_high = 80
alert_low = 60
_last_response = None
def get_info(self):
r = requests.get(self.thermostat_url + '/tstat')
self._last_response = json.loads(r.text)
return r.text... |
616d33e1c69af979163231ef8e9ca9a1f6c7bdf2 | pyts/__init__.py | pyts/__init__.py | """Time series transformation and classification module for Python.
pyts is a Python package for time series transformation and classification.
It aims to make time series classification easily accessible by providing
preprocessing and utility tools, and implementations of state-of-the-art
algorithms. Most of these al... | """Time series transformation and classification module for Python.
pyts is a Python package for time series transformation and classification.
It aims to make time series classification easily accessible by providing
preprocessing and utility tools, and implementations of state-of-the-art
algorithms. Most of these al... | Update the version on master | Update the version on master
| Python | bsd-3-clause | johannfaouzi/pyts | """Time series transformation and classification module for Python.
pyts is a Python package for time series transformation and classification.
It aims to make time series classification easily accessible by providing
preprocessing and utility tools, and implementations of state-of-the-art
algorithms. Most of these al... | """Time series transformation and classification module for Python.
pyts is a Python package for time series transformation and classification.
It aims to make time series classification easily accessible by providing
preprocessing and utility tools, and implementations of state-of-the-art
algorithms. Most of these al... | <commit_before>"""Time series transformation and classification module for Python.
pyts is a Python package for time series transformation and classification.
It aims to make time series classification easily accessible by providing
preprocessing and utility tools, and implementations of state-of-the-art
algorithms. M... | """Time series transformation and classification module for Python.
pyts is a Python package for time series transformation and classification.
It aims to make time series classification easily accessible by providing
preprocessing and utility tools, and implementations of state-of-the-art
algorithms. Most of these al... | """Time series transformation and classification module for Python.
pyts is a Python package for time series transformation and classification.
It aims to make time series classification easily accessible by providing
preprocessing and utility tools, and implementations of state-of-the-art
algorithms. Most of these al... | <commit_before>"""Time series transformation and classification module for Python.
pyts is a Python package for time series transformation and classification.
It aims to make time series classification easily accessible by providing
preprocessing and utility tools, and implementations of state-of-the-art
algorithms. M... |
fff22f9305fd73f464a6ee9a66b676b66ef88cad | test/parseResults.py | test/parseResults.py | #!/usr/bin/env python3
import json
import sys
PREFIXES = [
["FAIL", "PASS"],
["EXPECTED FAIL", "UNEXPECTED PASS"],
]
def parse_expected_failures():
expected_failures = set()
with open("expected-failures.txt", "r") as fp:
for line in fp:
line = line.strip()
if not line... | #!/usr/bin/env python3
import ijson
import sys
PREFIXES = [
["FAIL", "PASS"],
["EXPECTED FAIL", "UNEXPECTED PASS"],
]
def parse_expected_failures():
expected_failures = set()
with open("expected-failures.txt", "r") as fp:
for line in fp:
line = line.strip()
if not lin... | Use ijson to parse the test262 results. | Use ijson to parse the test262 results.
Parsing the output all at once can cause out-of-memory errors in automated
testing.
| Python | isc | js-temporal/temporal-polyfill,js-temporal/temporal-polyfill,js-temporal/temporal-polyfill | #!/usr/bin/env python3
import json
import sys
PREFIXES = [
["FAIL", "PASS"],
["EXPECTED FAIL", "UNEXPECTED PASS"],
]
def parse_expected_failures():
expected_failures = set()
with open("expected-failures.txt", "r") as fp:
for line in fp:
line = line.strip()
if not line... | #!/usr/bin/env python3
import ijson
import sys
PREFIXES = [
["FAIL", "PASS"],
["EXPECTED FAIL", "UNEXPECTED PASS"],
]
def parse_expected_failures():
expected_failures = set()
with open("expected-failures.txt", "r") as fp:
for line in fp:
line = line.strip()
if not lin... | <commit_before>#!/usr/bin/env python3
import json
import sys
PREFIXES = [
["FAIL", "PASS"],
["EXPECTED FAIL", "UNEXPECTED PASS"],
]
def parse_expected_failures():
expected_failures = set()
with open("expected-failures.txt", "r") as fp:
for line in fp:
line = line.strip()
... | #!/usr/bin/env python3
import ijson
import sys
PREFIXES = [
["FAIL", "PASS"],
["EXPECTED FAIL", "UNEXPECTED PASS"],
]
def parse_expected_failures():
expected_failures = set()
with open("expected-failures.txt", "r") as fp:
for line in fp:
line = line.strip()
if not lin... | #!/usr/bin/env python3
import json
import sys
PREFIXES = [
["FAIL", "PASS"],
["EXPECTED FAIL", "UNEXPECTED PASS"],
]
def parse_expected_failures():
expected_failures = set()
with open("expected-failures.txt", "r") as fp:
for line in fp:
line = line.strip()
if not line... | <commit_before>#!/usr/bin/env python3
import json
import sys
PREFIXES = [
["FAIL", "PASS"],
["EXPECTED FAIL", "UNEXPECTED PASS"],
]
def parse_expected_failures():
expected_failures = set()
with open("expected-failures.txt", "r") as fp:
for line in fp:
line = line.strip()
... |
695ee95faf0ae80f0c69bf47e881af22ab0f00cd | l10n_it_esigibilita_iva/models/account.py | l10n_it_esigibilita_iva/models/account.py | # License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
from odoo import models, fields
class AccountTax(models.Model):
_inherit = 'account.tax'
payability = fields.Selection([
('I', 'Immediate payability'),
('D', 'Deferred payability'),
('S', 'Split payment'),
], string="... | # License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
from odoo import models, fields
class AccountTax(models.Model):
_inherit = 'account.tax'
payability = fields.Selection([
('I', 'VAT payable immediately'),
('D', 'unrealized VAT'),
('S', 'split payments'),
], string="V... | Use correct english terms, from APPENDIX A -TECHNICAL SPECIFICATIONS | Use correct english terms, from APPENDIX A -TECHNICAL SPECIFICATIONS
| Python | agpl-3.0 | dcorio/l10n-italy,OCA/l10n-italy,OCA/l10n-italy,dcorio/l10n-italy,dcorio/l10n-italy,OCA/l10n-italy | # License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
from odoo import models, fields
class AccountTax(models.Model):
_inherit = 'account.tax'
payability = fields.Selection([
('I', 'Immediate payability'),
('D', 'Deferred payability'),
('S', 'Split payment'),
], string="... | # License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
from odoo import models, fields
class AccountTax(models.Model):
_inherit = 'account.tax'
payability = fields.Selection([
('I', 'VAT payable immediately'),
('D', 'unrealized VAT'),
('S', 'split payments'),
], string="V... | <commit_before># License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
from odoo import models, fields
class AccountTax(models.Model):
_inherit = 'account.tax'
payability = fields.Selection([
('I', 'Immediate payability'),
('D', 'Deferred payability'),
('S', 'Split payment'),
... | # License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
from odoo import models, fields
class AccountTax(models.Model):
_inherit = 'account.tax'
payability = fields.Selection([
('I', 'VAT payable immediately'),
('D', 'unrealized VAT'),
('S', 'split payments'),
], string="V... | # License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
from odoo import models, fields
class AccountTax(models.Model):
_inherit = 'account.tax'
payability = fields.Selection([
('I', 'Immediate payability'),
('D', 'Deferred payability'),
('S', 'Split payment'),
], string="... | <commit_before># License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
from odoo import models, fields
class AccountTax(models.Model):
_inherit = 'account.tax'
payability = fields.Selection([
('I', 'Immediate payability'),
('D', 'Deferred payability'),
('S', 'Split payment'),
... |
628ab56107783841d1e64b11c4b82eac4806c019 | selenium_testcase/testcases/content.py | selenium_testcase/testcases/content.py | # -*- coding: utf-8 -*-
from __future__ import absolute_import
from .utils import dom_contains, wait_for
class ContentTestMixin:
# Assert that the DOM contains the given text
def should_see_immediately(self, text):
self.assertTrue(dom_contains(self.browser, text))
# Repeatedly look for the giv... | # -*- coding: utf-8 -*-
from __future__ import absolute_import
from .utils import dom_contains, wait_for
class ContentTestMixin:
def should_see_immediately(self, text):
""" Assert that DOM contains the given text. """
self.assertTrue(dom_contains(self.browser, text))
@wait_for
def shou... | Add should_not_see, has_not_title, title_does_not_contain to ContentTestMixin. | Add should_not_see, has_not_title, title_does_not_contain to ContentTestMixin.
These methods cause a wait for the full duration of the @wait_for timeout when
the assertion test is successful (and the given text is missing). It will fail
fast, but success is slow. These negative information tests should be used
sparin... | Python | bsd-3-clause | nimbis/django-selenium-testcase,nimbis/django-selenium-testcase | # -*- coding: utf-8 -*-
from __future__ import absolute_import
from .utils import dom_contains, wait_for
class ContentTestMixin:
# Assert that the DOM contains the given text
def should_see_immediately(self, text):
self.assertTrue(dom_contains(self.browser, text))
# Repeatedly look for the giv... | # -*- coding: utf-8 -*-
from __future__ import absolute_import
from .utils import dom_contains, wait_for
class ContentTestMixin:
def should_see_immediately(self, text):
""" Assert that DOM contains the given text. """
self.assertTrue(dom_contains(self.browser, text))
@wait_for
def shou... | <commit_before># -*- coding: utf-8 -*-
from __future__ import absolute_import
from .utils import dom_contains, wait_for
class ContentTestMixin:
# Assert that the DOM contains the given text
def should_see_immediately(self, text):
self.assertTrue(dom_contains(self.browser, text))
# Repeatedly l... | # -*- coding: utf-8 -*-
from __future__ import absolute_import
from .utils import dom_contains, wait_for
class ContentTestMixin:
def should_see_immediately(self, text):
""" Assert that DOM contains the given text. """
self.assertTrue(dom_contains(self.browser, text))
@wait_for
def shou... | # -*- coding: utf-8 -*-
from __future__ import absolute_import
from .utils import dom_contains, wait_for
class ContentTestMixin:
# Assert that the DOM contains the given text
def should_see_immediately(self, text):
self.assertTrue(dom_contains(self.browser, text))
# Repeatedly look for the giv... | <commit_before># -*- coding: utf-8 -*-
from __future__ import absolute_import
from .utils import dom_contains, wait_for
class ContentTestMixin:
# Assert that the DOM contains the given text
def should_see_immediately(self, text):
self.assertTrue(dom_contains(self.browser, text))
# Repeatedly l... |
e23dd39880dc849a56d5376dca318f8bcb2cd998 | discover/__init__.py | discover/__init__.py | import logging
import socket
import boto
LOG_FORMAT = '%(asctime)s [%(name)s] %(levelname)s %(message)s'
LOG_DATE = '%Y-%m-%d %I:%M:%S %p'
logging.basicConfig(format=LOG_FORMAT, datefmt=LOG_DATE, level=logging.WARN)
logger = logging.getLogger('yoda-discover')
logger.level = logging.INFO
def port_test(port, host, p... | import logging
import socket
from boto.utils import get_instance_metadata
LOG_FORMAT = '%(asctime)s [%(name)s] %(levelname)s %(message)s'
LOG_DATE = '%Y-%m-%d %I:%M:%S %p'
logging.basicConfig(format=LOG_FORMAT, datefmt=LOG_DATE, level=logging.WARN)
logger = logging.getLogger('yoda-discover')
logger.level = logging.... | Fix import error for boto.utils | Fix import error for boto.utils
| Python | mit | totem/yoda-discover | import logging
import socket
import boto
LOG_FORMAT = '%(asctime)s [%(name)s] %(levelname)s %(message)s'
LOG_DATE = '%Y-%m-%d %I:%M:%S %p'
logging.basicConfig(format=LOG_FORMAT, datefmt=LOG_DATE, level=logging.WARN)
logger = logging.getLogger('yoda-discover')
logger.level = logging.INFO
def port_test(port, host, p... | import logging
import socket
from boto.utils import get_instance_metadata
LOG_FORMAT = '%(asctime)s [%(name)s] %(levelname)s %(message)s'
LOG_DATE = '%Y-%m-%d %I:%M:%S %p'
logging.basicConfig(format=LOG_FORMAT, datefmt=LOG_DATE, level=logging.WARN)
logger = logging.getLogger('yoda-discover')
logger.level = logging.... | <commit_before>import logging
import socket
import boto
LOG_FORMAT = '%(asctime)s [%(name)s] %(levelname)s %(message)s'
LOG_DATE = '%Y-%m-%d %I:%M:%S %p'
logging.basicConfig(format=LOG_FORMAT, datefmt=LOG_DATE, level=logging.WARN)
logger = logging.getLogger('yoda-discover')
logger.level = logging.INFO
def port_tes... | import logging
import socket
from boto.utils import get_instance_metadata
LOG_FORMAT = '%(asctime)s [%(name)s] %(levelname)s %(message)s'
LOG_DATE = '%Y-%m-%d %I:%M:%S %p'
logging.basicConfig(format=LOG_FORMAT, datefmt=LOG_DATE, level=logging.WARN)
logger = logging.getLogger('yoda-discover')
logger.level = logging.... | import logging
import socket
import boto
LOG_FORMAT = '%(asctime)s [%(name)s] %(levelname)s %(message)s'
LOG_DATE = '%Y-%m-%d %I:%M:%S %p'
logging.basicConfig(format=LOG_FORMAT, datefmt=LOG_DATE, level=logging.WARN)
logger = logging.getLogger('yoda-discover')
logger.level = logging.INFO
def port_test(port, host, p... | <commit_before>import logging
import socket
import boto
LOG_FORMAT = '%(asctime)s [%(name)s] %(levelname)s %(message)s'
LOG_DATE = '%Y-%m-%d %I:%M:%S %p'
logging.basicConfig(format=LOG_FORMAT, datefmt=LOG_DATE, level=logging.WARN)
logger = logging.getLogger('yoda-discover')
logger.level = logging.INFO
def port_tes... |
12aaf389356966e7f82c4a588e0ae888073da8dd | discussion/models.py | discussion/models.py | from django.contrib.auth.models import User
from django.db import models
class Discussion(models.Model):
user = models.ForeignKey(User)
name = models.CharField(max_length=255)
slug = models.SlugField()
def __unicode__(self):
return self.name
class Post(models.Model):
discussion = models... | from django.contrib.auth.models import User
from django.db import models
class Discussion(models.Model):
user = models.ForeignKey(User)
name = models.CharField(max_length=255)
slug = models.SlugField()
def __unicode__(self):
return self.name
class Post(models.Model):
discussion = models... | Remove "name" from discussion post | Remove "name" from discussion post
| Python | bsd-2-clause | incuna/django-discussion,incuna/django-discussion,lehins/lehins-discussion,lehins/lehins-discussion,lehins/lehins-discussion | from django.contrib.auth.models import User
from django.db import models
class Discussion(models.Model):
user = models.ForeignKey(User)
name = models.CharField(max_length=255)
slug = models.SlugField()
def __unicode__(self):
return self.name
class Post(models.Model):
discussion = models... | from django.contrib.auth.models import User
from django.db import models
class Discussion(models.Model):
user = models.ForeignKey(User)
name = models.CharField(max_length=255)
slug = models.SlugField()
def __unicode__(self):
return self.name
class Post(models.Model):
discussion = models... | <commit_before>from django.contrib.auth.models import User
from django.db import models
class Discussion(models.Model):
user = models.ForeignKey(User)
name = models.CharField(max_length=255)
slug = models.SlugField()
def __unicode__(self):
return self.name
class Post(models.Model):
disc... | from django.contrib.auth.models import User
from django.db import models
class Discussion(models.Model):
user = models.ForeignKey(User)
name = models.CharField(max_length=255)
slug = models.SlugField()
def __unicode__(self):
return self.name
class Post(models.Model):
discussion = models... | from django.contrib.auth.models import User
from django.db import models
class Discussion(models.Model):
user = models.ForeignKey(User)
name = models.CharField(max_length=255)
slug = models.SlugField()
def __unicode__(self):
return self.name
class Post(models.Model):
discussion = models... | <commit_before>from django.contrib.auth.models import User
from django.db import models
class Discussion(models.Model):
user = models.ForeignKey(User)
name = models.CharField(max_length=255)
slug = models.SlugField()
def __unicode__(self):
return self.name
class Post(models.Model):
disc... |
e59f8e72996b036b7c2df8f6b1054f82d730bdf8 | tinycontent/admin.py | tinycontent/admin.py | from django.contrib import admin
from tinycontent.models import TinyContent, TinyContentFileUpload
class TinyContentAdmin(admin.ModelAdmin):
list_display = ('name', )
search_fields = ('name', 'content', )
admin.site.register(TinyContent, TinyContentAdmin)
class TinyContentFileUploadAdmin(admin.ModelAdmin):... | from django.contrib import admin
from tinycontent.models import TinyContent, TinyContentFileUpload
class TinyContentAdmin(admin.ModelAdmin):
list_display = ('name', )
search_fields = ('name', 'content', )
admin.site.register(TinyContent, TinyContentAdmin)
class TinyContentFileUploadAdmin(admin.ModelAdmin):... | Make it easier to figure out a given file's slug | Make it easier to figure out a given file's slug
| Python | bsd-3-clause | ad-m/django-tinycontent,dominicrodger/django-tinycontent,watchdogpolska/django-tinycontent,dominicrodger/django-tinycontent,ad-m/django-tinycontent,watchdogpolska/django-tinycontent | from django.contrib import admin
from tinycontent.models import TinyContent, TinyContentFileUpload
class TinyContentAdmin(admin.ModelAdmin):
list_display = ('name', )
search_fields = ('name', 'content', )
admin.site.register(TinyContent, TinyContentAdmin)
class TinyContentFileUploadAdmin(admin.ModelAdmin):... | from django.contrib import admin
from tinycontent.models import TinyContent, TinyContentFileUpload
class TinyContentAdmin(admin.ModelAdmin):
list_display = ('name', )
search_fields = ('name', 'content', )
admin.site.register(TinyContent, TinyContentAdmin)
class TinyContentFileUploadAdmin(admin.ModelAdmin):... | <commit_before>from django.contrib import admin
from tinycontent.models import TinyContent, TinyContentFileUpload
class TinyContentAdmin(admin.ModelAdmin):
list_display = ('name', )
search_fields = ('name', 'content', )
admin.site.register(TinyContent, TinyContentAdmin)
class TinyContentFileUploadAdmin(adm... | from django.contrib import admin
from tinycontent.models import TinyContent, TinyContentFileUpload
class TinyContentAdmin(admin.ModelAdmin):
list_display = ('name', )
search_fields = ('name', 'content', )
admin.site.register(TinyContent, TinyContentAdmin)
class TinyContentFileUploadAdmin(admin.ModelAdmin):... | from django.contrib import admin
from tinycontent.models import TinyContent, TinyContentFileUpload
class TinyContentAdmin(admin.ModelAdmin):
list_display = ('name', )
search_fields = ('name', 'content', )
admin.site.register(TinyContent, TinyContentAdmin)
class TinyContentFileUploadAdmin(admin.ModelAdmin):... | <commit_before>from django.contrib import admin
from tinycontent.models import TinyContent, TinyContentFileUpload
class TinyContentAdmin(admin.ModelAdmin):
list_display = ('name', )
search_fields = ('name', 'content', )
admin.site.register(TinyContent, TinyContentAdmin)
class TinyContentFileUploadAdmin(adm... |
a5d7306cdda9e109abbb673b8474f8955a371266 | partner_contact_birthdate/__openerp__.py | partner_contact_birthdate/__openerp__.py | # -*- coding: utf-8 -*-
# Odoo, Open Source Management Solution
# Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es>
#
# 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 ... | # -*- coding: utf-8 -*-
# © <YEAR(S)> <AUTHOR(S)>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
{
"name": "Contact's birthdate",
"version": "9.0.1.0.0",
"author": "Odoo Community Association (OCA)",
"category": "Customer Relationship Management",
"website": "https://odoo-comm... | Fix header to short version | Fix header to short version
| Python | agpl-3.0 | sergiocorato/partner-contact | # -*- coding: utf-8 -*-
# Odoo, Open Source Management Solution
# Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es>
#
# 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 ... | # -*- coding: utf-8 -*-
# © <YEAR(S)> <AUTHOR(S)>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
{
"name": "Contact's birthdate",
"version": "9.0.1.0.0",
"author": "Odoo Community Association (OCA)",
"category": "Customer Relationship Management",
"website": "https://odoo-comm... | <commit_before># -*- coding: utf-8 -*-
# Odoo, Open Source Management Solution
# Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es>
#
# 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, ... | # -*- coding: utf-8 -*-
# © <YEAR(S)> <AUTHOR(S)>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
{
"name": "Contact's birthdate",
"version": "9.0.1.0.0",
"author": "Odoo Community Association (OCA)",
"category": "Customer Relationship Management",
"website": "https://odoo-comm... | # -*- coding: utf-8 -*-
# Odoo, Open Source Management Solution
# Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es>
#
# 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 ... | <commit_before># -*- coding: utf-8 -*-
# Odoo, Open Source Management Solution
# Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es>
#
# 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, ... |
a3c68f6f70a2d4d1ecdcdb982eda9ec15fa4c127 | utils.py | utils.py | from google.appengine.api import users
from google.appengine.ext import db
from model import User
@db.transactional
def create_user(google_user):
user = User(
google_user=google_user
)
user.put()
return user
def get_current_user():
google_user = users.get_current_user()
user = get_use... | from google.appengine.api import users
from google.appengine.ext import db
from model import User
latest_signup = None
@db.transactional
def create_user(google_user):
global latest_signup
user = User(
google_user=google_user
)
user.put()
latest_signup = user
return user
def get_curre... | Fix bug where user could not be found | Fix bug where user could not be found
This problem only occured when a request tried to find the user right
after it had been created.
| Python | mit | youtify/newscontrol,studyindenmark/newscontrol,studyindenmark/newscontrol,youtify/newscontrol | from google.appengine.api import users
from google.appengine.ext import db
from model import User
@db.transactional
def create_user(google_user):
user = User(
google_user=google_user
)
user.put()
return user
def get_current_user():
google_user = users.get_current_user()
user = get_use... | from google.appengine.api import users
from google.appengine.ext import db
from model import User
latest_signup = None
@db.transactional
def create_user(google_user):
global latest_signup
user = User(
google_user=google_user
)
user.put()
latest_signup = user
return user
def get_curre... | <commit_before>from google.appengine.api import users
from google.appengine.ext import db
from model import User
@db.transactional
def create_user(google_user):
user = User(
google_user=google_user
)
user.put()
return user
def get_current_user():
google_user = users.get_current_user()
... | from google.appengine.api import users
from google.appengine.ext import db
from model import User
latest_signup = None
@db.transactional
def create_user(google_user):
global latest_signup
user = User(
google_user=google_user
)
user.put()
latest_signup = user
return user
def get_curre... | from google.appengine.api import users
from google.appengine.ext import db
from model import User
@db.transactional
def create_user(google_user):
user = User(
google_user=google_user
)
user.put()
return user
def get_current_user():
google_user = users.get_current_user()
user = get_use... | <commit_before>from google.appengine.api import users
from google.appengine.ext import db
from model import User
@db.transactional
def create_user(google_user):
user = User(
google_user=google_user
)
user.put()
return user
def get_current_user():
google_user = users.get_current_user()
... |
9f8b555698471987a5a635f69fa0ad68a4b28134 | 14/src.py | 14/src.py | import sys
import itertools
import re
from md5 import md5
puzzle_input = 'abc' # 'yjdafjpo'
def key(n):
return md5(puzzle_input + str(n)).hexdigest()
def otp_keys(horizon):
lookahead = {k: -1 for k in '0123456789abcdef'}
def update_lookahead(n):
for quint in re.finditer(r'(.)\1{4}', key(n)):
lookahea... | import sys
import itertools
import re
from md5 import md5
puzzle_input = 'yjdafjpo'
def key(n):
return md5(puzzle_input + str(n)).hexdigest()
def otp_keys(horizon):
lookahead = {k: -1 for k in '0123456789abcdef'}
def update_lookahead(n):
for quint in re.finditer(r'(.)\1{4}', key(n)):
lookahead[quint.... | Fix problem in previous version | Fix problem in previous version
I was accidentally allowing the current hash's quint to match its triple
| Python | mit | amalloy/advent-of-code-2016 | import sys
import itertools
import re
from md5 import md5
puzzle_input = 'abc' # 'yjdafjpo'
def key(n):
return md5(puzzle_input + str(n)).hexdigest()
def otp_keys(horizon):
lookahead = {k: -1 for k in '0123456789abcdef'}
def update_lookahead(n):
for quint in re.finditer(r'(.)\1{4}', key(n)):
lookahea... | import sys
import itertools
import re
from md5 import md5
puzzle_input = 'yjdafjpo'
def key(n):
return md5(puzzle_input + str(n)).hexdigest()
def otp_keys(horizon):
lookahead = {k: -1 for k in '0123456789abcdef'}
def update_lookahead(n):
for quint in re.finditer(r'(.)\1{4}', key(n)):
lookahead[quint.... | <commit_before>import sys
import itertools
import re
from md5 import md5
puzzle_input = 'abc' # 'yjdafjpo'
def key(n):
return md5(puzzle_input + str(n)).hexdigest()
def otp_keys(horizon):
lookahead = {k: -1 for k in '0123456789abcdef'}
def update_lookahead(n):
for quint in re.finditer(r'(.)\1{4}', key(n)):... | import sys
import itertools
import re
from md5 import md5
puzzle_input = 'yjdafjpo'
def key(n):
return md5(puzzle_input + str(n)).hexdigest()
def otp_keys(horizon):
lookahead = {k: -1 for k in '0123456789abcdef'}
def update_lookahead(n):
for quint in re.finditer(r'(.)\1{4}', key(n)):
lookahead[quint.... | import sys
import itertools
import re
from md5 import md5
puzzle_input = 'abc' # 'yjdafjpo'
def key(n):
return md5(puzzle_input + str(n)).hexdigest()
def otp_keys(horizon):
lookahead = {k: -1 for k in '0123456789abcdef'}
def update_lookahead(n):
for quint in re.finditer(r'(.)\1{4}', key(n)):
lookahea... | <commit_before>import sys
import itertools
import re
from md5 import md5
puzzle_input = 'abc' # 'yjdafjpo'
def key(n):
return md5(puzzle_input + str(n)).hexdigest()
def otp_keys(horizon):
lookahead = {k: -1 for k in '0123456789abcdef'}
def update_lookahead(n):
for quint in re.finditer(r'(.)\1{4}', key(n)):... |
2cdb6a5eeb1730627cea2a812d590efed82d03fb | acceptance_tests/test_course_learners.py | acceptance_tests/test_course_learners.py | from unittest import skipUnless
from bok_choy.web_app_test import WebAppTest
from acceptance_tests import ENABLE_LEARNER_ANALYTICS
from acceptance_tests.mixins import CoursePageTestsMixin
from acceptance_tests.pages import CourseLearnersPage
@skipUnless(ENABLE_LEARNER_ANALYTICS, 'Learner Analytics must be enabled t... | from unittest import skipUnless
from bok_choy.web_app_test import WebAppTest
from acceptance_tests import ENABLE_LEARNER_ANALYTICS
from acceptance_tests.mixins import CoursePageTestsMixin
from acceptance_tests.pages import CourseLearnersPage
@skipUnless(ENABLE_LEARNER_ANALYTICS, 'Learner Analytics must be enabled t... | Add test for learners help link | Add test for learners help link
| Python | agpl-3.0 | Stanford-Online/edx-analytics-dashboard,Stanford-Online/edx-analytics-dashboard,edx/edx-analytics-dashboard,Stanford-Online/edx-analytics-dashboard,edx/edx-analytics-dashboard,edx/edx-analytics-dashboard,Stanford-Online/edx-analytics-dashboard,edx/edx-analytics-dashboard | from unittest import skipUnless
from bok_choy.web_app_test import WebAppTest
from acceptance_tests import ENABLE_LEARNER_ANALYTICS
from acceptance_tests.mixins import CoursePageTestsMixin
from acceptance_tests.pages import CourseLearnersPage
@skipUnless(ENABLE_LEARNER_ANALYTICS, 'Learner Analytics must be enabled t... | from unittest import skipUnless
from bok_choy.web_app_test import WebAppTest
from acceptance_tests import ENABLE_LEARNER_ANALYTICS
from acceptance_tests.mixins import CoursePageTestsMixin
from acceptance_tests.pages import CourseLearnersPage
@skipUnless(ENABLE_LEARNER_ANALYTICS, 'Learner Analytics must be enabled t... | <commit_before>from unittest import skipUnless
from bok_choy.web_app_test import WebAppTest
from acceptance_tests import ENABLE_LEARNER_ANALYTICS
from acceptance_tests.mixins import CoursePageTestsMixin
from acceptance_tests.pages import CourseLearnersPage
@skipUnless(ENABLE_LEARNER_ANALYTICS, 'Learner Analytics mu... | from unittest import skipUnless
from bok_choy.web_app_test import WebAppTest
from acceptance_tests import ENABLE_LEARNER_ANALYTICS
from acceptance_tests.mixins import CoursePageTestsMixin
from acceptance_tests.pages import CourseLearnersPage
@skipUnless(ENABLE_LEARNER_ANALYTICS, 'Learner Analytics must be enabled t... | from unittest import skipUnless
from bok_choy.web_app_test import WebAppTest
from acceptance_tests import ENABLE_LEARNER_ANALYTICS
from acceptance_tests.mixins import CoursePageTestsMixin
from acceptance_tests.pages import CourseLearnersPage
@skipUnless(ENABLE_LEARNER_ANALYTICS, 'Learner Analytics must be enabled t... | <commit_before>from unittest import skipUnless
from bok_choy.web_app_test import WebAppTest
from acceptance_tests import ENABLE_LEARNER_ANALYTICS
from acceptance_tests.mixins import CoursePageTestsMixin
from acceptance_tests.pages import CourseLearnersPage
@skipUnless(ENABLE_LEARNER_ANALYTICS, 'Learner Analytics mu... |
743064dbe22e40928c50817417077b8d52de641c | twistedchecker/functionaltests/comments.py | twistedchecker/functionaltests/comments.py | # enable: W9401,W9402
#A comment does not begin with a whitespace.
a = 1 + 2 # A comment begins with two whitespace.
# a comment begins with a lowercase letter.
# Good comment examples.
# A sentence that spans multiple lines
# doesn't need to have capitalization on second line.
# Here's some code samples:
# x ... | # enable: W9401,W9402
#A comment does not begin with a whitespace.
a = 1 + 2 # A comment begins with two whitespace.
# a comment begins with a lowercase letter.
# Good comment examples.
# A sentence that spans multiple lines
# doesn't need to have capitalization on second line.
# Here's some code samples:
# x ... | Add example with back ticks. | Add example with back ticks.
| Python | mit | twisted/twistedchecker | # enable: W9401,W9402
#A comment does not begin with a whitespace.
a = 1 + 2 # A comment begins with two whitespace.
# a comment begins with a lowercase letter.
# Good comment examples.
# A sentence that spans multiple lines
# doesn't need to have capitalization on second line.
# Here's some code samples:
# x ... | # enable: W9401,W9402
#A comment does not begin with a whitespace.
a = 1 + 2 # A comment begins with two whitespace.
# a comment begins with a lowercase letter.
# Good comment examples.
# A sentence that spans multiple lines
# doesn't need to have capitalization on second line.
# Here's some code samples:
# x ... | <commit_before># enable: W9401,W9402
#A comment does not begin with a whitespace.
a = 1 + 2 # A comment begins with two whitespace.
# a comment begins with a lowercase letter.
# Good comment examples.
# A sentence that spans multiple lines
# doesn't need to have capitalization on second line.
# Here's some code... | # enable: W9401,W9402
#A comment does not begin with a whitespace.
a = 1 + 2 # A comment begins with two whitespace.
# a comment begins with a lowercase letter.
# Good comment examples.
# A sentence that spans multiple lines
# doesn't need to have capitalization on second line.
# Here's some code samples:
# x ... | # enable: W9401,W9402
#A comment does not begin with a whitespace.
a = 1 + 2 # A comment begins with two whitespace.
# a comment begins with a lowercase letter.
# Good comment examples.
# A sentence that spans multiple lines
# doesn't need to have capitalization on second line.
# Here's some code samples:
# x ... | <commit_before># enable: W9401,W9402
#A comment does not begin with a whitespace.
a = 1 + 2 # A comment begins with two whitespace.
# a comment begins with a lowercase letter.
# Good comment examples.
# A sentence that spans multiple lines
# doesn't need to have capitalization on second line.
# Here's some code... |
aabf28c02a4dff593e5e4b156052adb9b81a70c7 | skflow/ops/tests/test_dropout_ops.py | skflow/ops/tests/test_dropout_ops.py | # Copyright 2015-present Scikit Flow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by... | # Copyright 2015-present Scikit Flow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by... | Test for dropout probability be a tensor | Test for dropout probability be a tensor
| Python | apache-2.0 | handroissuazo/tensorflow,elingg/tensorflow,awni/tensorflow,aselle/tensorflow,theflofly/tensorflow,ishay2b/tensorflow,XueqingLin/tensorflow,DavidNorman/tensorflow,odejesush/tensorflow,taknevski/tensorflow-xsmm,AndreasMadsen/tensorflow,Kongsea/tensorflow,hfp/tensorflow-xsmm,jhaux/tensorflow,JingJunYin/tensorflow,tensorfl... | # Copyright 2015-present Scikit Flow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by... | # Copyright 2015-present Scikit Flow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by... | <commit_before># Copyright 2015-present Scikit Flow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unl... | # Copyright 2015-present Scikit Flow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by... | # Copyright 2015-present Scikit Flow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by... | <commit_before># Copyright 2015-present Scikit Flow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unl... |
0e83eff1b63eeb5203b4abc55e6278fc411567ae | setup.py | setup.py | from os.path import dirname, join
from setuptools import find_packages, setup
from channels_redis import __version__
# We use the README as the long_description
readme = open(join(dirname(__file__), "README.rst")).read()
crypto_requires = ["cryptography>=1.3.0"]
test_requires = crypto_requires + [
"pytest>=3.0... | from os.path import dirname, join
from setuptools import find_packages, setup
from channels_redis import __version__
# We use the README as the long_description
readme = open(join(dirname(__file__), "README.rst")).read()
crypto_requires = ["cryptography>=1.3.0"]
test_requires = crypto_requires + [
"pytest>=3.0... | Update dependencies to be more loose (and match Channels) | Update dependencies to be more loose (and match Channels)
| Python | bsd-3-clause | django/asgi_redis | from os.path import dirname, join
from setuptools import find_packages, setup
from channels_redis import __version__
# We use the README as the long_description
readme = open(join(dirname(__file__), "README.rst")).read()
crypto_requires = ["cryptography>=1.3.0"]
test_requires = crypto_requires + [
"pytest>=3.0... | from os.path import dirname, join
from setuptools import find_packages, setup
from channels_redis import __version__
# We use the README as the long_description
readme = open(join(dirname(__file__), "README.rst")).read()
crypto_requires = ["cryptography>=1.3.0"]
test_requires = crypto_requires + [
"pytest>=3.0... | <commit_before>from os.path import dirname, join
from setuptools import find_packages, setup
from channels_redis import __version__
# We use the README as the long_description
readme = open(join(dirname(__file__), "README.rst")).read()
crypto_requires = ["cryptography>=1.3.0"]
test_requires = crypto_requires + [
... | from os.path import dirname, join
from setuptools import find_packages, setup
from channels_redis import __version__
# We use the README as the long_description
readme = open(join(dirname(__file__), "README.rst")).read()
crypto_requires = ["cryptography>=1.3.0"]
test_requires = crypto_requires + [
"pytest>=3.0... | from os.path import dirname, join
from setuptools import find_packages, setup
from channels_redis import __version__
# We use the README as the long_description
readme = open(join(dirname(__file__), "README.rst")).read()
crypto_requires = ["cryptography>=1.3.0"]
test_requires = crypto_requires + [
"pytest>=3.0... | <commit_before>from os.path import dirname, join
from setuptools import find_packages, setup
from channels_redis import __version__
# We use the README as the long_description
readme = open(join(dirname(__file__), "README.rst")).read()
crypto_requires = ["cryptography>=1.3.0"]
test_requires = crypto_requires + [
... |
0ba4eb026c34b85e0413bc83015398eeb33e6547 | setup.py | setup.py | from setuptools import setup, find_packages
setup(
name = 'thespian',
version = '2.1.4',
description = 'Python Actor concurrency library',
author = 'Kevin Quick',
author_email = 'kquick@godaddy.com',
url = 'http://thespianpy.com',
license = 'MIT',
scripts = [ 'thespianShell.py' ],
p... | from setuptools import setup, find_packages
setup(
name = 'thespian',
version = '2.1.4',
description = 'Python Actor concurrency library',
author = 'Kevin Quick',
author_email = 'kquick@godaddy.com',
url = 'http://thespianpy.com',
license = 'MIT',
scripts = [ 'thespianShell.py' ],
p... | Add more classifiers, including Python 3.3 and 3.4 declarations. | Add more classifiers, including Python 3.3 and 3.4 declarations.
| Python | mit | kquick/Thespian,godaddy/Thespian,kquick/Thespian,godaddy/Thespian | from setuptools import setup, find_packages
setup(
name = 'thespian',
version = '2.1.4',
description = 'Python Actor concurrency library',
author = 'Kevin Quick',
author_email = 'kquick@godaddy.com',
url = 'http://thespianpy.com',
license = 'MIT',
scripts = [ 'thespianShell.py' ],
p... | from setuptools import setup, find_packages
setup(
name = 'thespian',
version = '2.1.4',
description = 'Python Actor concurrency library',
author = 'Kevin Quick',
author_email = 'kquick@godaddy.com',
url = 'http://thespianpy.com',
license = 'MIT',
scripts = [ 'thespianShell.py' ],
p... | <commit_before>from setuptools import setup, find_packages
setup(
name = 'thespian',
version = '2.1.4',
description = 'Python Actor concurrency library',
author = 'Kevin Quick',
author_email = 'kquick@godaddy.com',
url = 'http://thespianpy.com',
license = 'MIT',
scripts = [ 'thespianShe... | from setuptools import setup, find_packages
setup(
name = 'thespian',
version = '2.1.4',
description = 'Python Actor concurrency library',
author = 'Kevin Quick',
author_email = 'kquick@godaddy.com',
url = 'http://thespianpy.com',
license = 'MIT',
scripts = [ 'thespianShell.py' ],
p... | from setuptools import setup, find_packages
setup(
name = 'thespian',
version = '2.1.4',
description = 'Python Actor concurrency library',
author = 'Kevin Quick',
author_email = 'kquick@godaddy.com',
url = 'http://thespianpy.com',
license = 'MIT',
scripts = [ 'thespianShell.py' ],
p... | <commit_before>from setuptools import setup, find_packages
setup(
name = 'thespian',
version = '2.1.4',
description = 'Python Actor concurrency library',
author = 'Kevin Quick',
author_email = 'kquick@godaddy.com',
url = 'http://thespianpy.com',
license = 'MIT',
scripts = [ 'thespianShe... |
da765334ffbc87c5cc20c8b3cdf7e31768c97bf7 | setup.py | setup.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from setuptools import setup, find_packages
from tornado_redis_sentinel import __version__
tests_require = [
'mock',
'nose',
'coverage',
'yanc',
'preggy',
'tox',
'ipdb',
'coveralls',
]
setup(
name='tornado-redis-sentinel',
version=... | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from setuptools import setup, find_packages
from tornado_redis_sentinel import __version__
tests_require = [
'mock',
'nose',
'coverage',
'yanc',
'preggy',
'tox',
'ipdb',
'coveralls',
]
setup(
name='tornado-redis-sentinel',
version=... | Remove upper limit for tornado's version | Remove upper limit for tornado's version
My use case seems to work with tornado 4.0.2.
| Python | mit | ms7s/tornado-redis-sentinel | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from setuptools import setup, find_packages
from tornado_redis_sentinel import __version__
tests_require = [
'mock',
'nose',
'coverage',
'yanc',
'preggy',
'tox',
'ipdb',
'coveralls',
]
setup(
name='tornado-redis-sentinel',
version=... | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from setuptools import setup, find_packages
from tornado_redis_sentinel import __version__
tests_require = [
'mock',
'nose',
'coverage',
'yanc',
'preggy',
'tox',
'ipdb',
'coveralls',
]
setup(
name='tornado-redis-sentinel',
version=... | <commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-
from setuptools import setup, find_packages
from tornado_redis_sentinel import __version__
tests_require = [
'mock',
'nose',
'coverage',
'yanc',
'preggy',
'tox',
'ipdb',
'coveralls',
]
setup(
name='tornado-redis-sentinel... | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from setuptools import setup, find_packages
from tornado_redis_sentinel import __version__
tests_require = [
'mock',
'nose',
'coverage',
'yanc',
'preggy',
'tox',
'ipdb',
'coveralls',
]
setup(
name='tornado-redis-sentinel',
version=... | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from setuptools import setup, find_packages
from tornado_redis_sentinel import __version__
tests_require = [
'mock',
'nose',
'coverage',
'yanc',
'preggy',
'tox',
'ipdb',
'coveralls',
]
setup(
name='tornado-redis-sentinel',
version=... | <commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-
from setuptools import setup, find_packages
from tornado_redis_sentinel import __version__
tests_require = [
'mock',
'nose',
'coverage',
'yanc',
'preggy',
'tox',
'ipdb',
'coveralls',
]
setup(
name='tornado-redis-sentinel... |
565c66982965c5abbc88083fa505efb4ce8a92c0 | setup.py | setup.py | #
# This file is part of gruvi. Gruvi is free software available under the terms
# of the MIT license. See the file "LICENSE" that was provided together with
# this source file for the licensing terms.
#
# Copyright (c) 2012 the gruvi authors. See the file "AUTHORS" for a complete
# list.
from setuptools import setup
... | #
# This file is part of gruvi. Gruvi is free software available under the terms
# of the MIT license. See the file "LICENSE" that was provided together with
# this source file for the licensing terms.
#
# Copyright (c) 2012 the gruvi authors. See the file "AUTHORS" for a complete
# list.
from setuptools import setup
... | Use nose as the test driver. | Use nose as the test driver.
| Python | mit | swegener/gruvi,geertj/gruvi,geertj/gruvi,swegener/gruvi | #
# This file is part of gruvi. Gruvi is free software available under the terms
# of the MIT license. See the file "LICENSE" that was provided together with
# this source file for the licensing terms.
#
# Copyright (c) 2012 the gruvi authors. See the file "AUTHORS" for a complete
# list.
from setuptools import setup
... | #
# This file is part of gruvi. Gruvi is free software available under the terms
# of the MIT license. See the file "LICENSE" that was provided together with
# this source file for the licensing terms.
#
# Copyright (c) 2012 the gruvi authors. See the file "AUTHORS" for a complete
# list.
from setuptools import setup
... | <commit_before>#
# This file is part of gruvi. Gruvi is free software available under the terms
# of the MIT license. See the file "LICENSE" that was provided together with
# this source file for the licensing terms.
#
# Copyright (c) 2012 the gruvi authors. See the file "AUTHORS" for a complete
# list.
from setuptool... | #
# This file is part of gruvi. Gruvi is free software available under the terms
# of the MIT license. See the file "LICENSE" that was provided together with
# this source file for the licensing terms.
#
# Copyright (c) 2012 the gruvi authors. See the file "AUTHORS" for a complete
# list.
from setuptools import setup
... | #
# This file is part of gruvi. Gruvi is free software available under the terms
# of the MIT license. See the file "LICENSE" that was provided together with
# this source file for the licensing terms.
#
# Copyright (c) 2012 the gruvi authors. See the file "AUTHORS" for a complete
# list.
from setuptools import setup
... | <commit_before>#
# This file is part of gruvi. Gruvi is free software available under the terms
# of the MIT license. See the file "LICENSE" that was provided together with
# this source file for the licensing terms.
#
# Copyright (c) 2012 the gruvi authors. See the file "AUTHORS" for a complete
# list.
from setuptool... |
d4feda3b91585576708f56ebc8f2c8592f877e2c | setup.py | setup.py | #!/usr/bin/env python
from setuptools import setup
with open('README.rst') as file:
long_description = file.read()
setup(name='parmap',
version='1.5.1.9000',
description=('map and starmap implementations passing additional '
'arguments and parallelizing if possible'),
long_de... | #!/usr/bin/env python
from setuptools import setup
with open('README.rst') as file:
long_description = file.read()
setup(name='parmap',
version='1.5.1.9000',
description=('map and starmap implementations passing additional '
'arguments and parallelizing if possible'),
long_de... | Add long description content type | Add long description content type
| Python | apache-2.0 | zeehio/parmap | #!/usr/bin/env python
from setuptools import setup
with open('README.rst') as file:
long_description = file.read()
setup(name='parmap',
version='1.5.1.9000',
description=('map and starmap implementations passing additional '
'arguments and parallelizing if possible'),
long_de... | #!/usr/bin/env python
from setuptools import setup
with open('README.rst') as file:
long_description = file.read()
setup(name='parmap',
version='1.5.1.9000',
description=('map and starmap implementations passing additional '
'arguments and parallelizing if possible'),
long_de... | <commit_before>#!/usr/bin/env python
from setuptools import setup
with open('README.rst') as file:
long_description = file.read()
setup(name='parmap',
version='1.5.1.9000',
description=('map and starmap implementations passing additional '
'arguments and parallelizing if possible')... | #!/usr/bin/env python
from setuptools import setup
with open('README.rst') as file:
long_description = file.read()
setup(name='parmap',
version='1.5.1.9000',
description=('map and starmap implementations passing additional '
'arguments and parallelizing if possible'),
long_de... | #!/usr/bin/env python
from setuptools import setup
with open('README.rst') as file:
long_description = file.read()
setup(name='parmap',
version='1.5.1.9000',
description=('map and starmap implementations passing additional '
'arguments and parallelizing if possible'),
long_de... | <commit_before>#!/usr/bin/env python
from setuptools import setup
with open('README.rst') as file:
long_description = file.read()
setup(name='parmap',
version='1.5.1.9000',
description=('map and starmap implementations passing additional '
'arguments and parallelizing if possible')... |
29600a6a8e8fa17e1c5b9f53dde57167450cbf4d | setup.py | setup.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
from distutils.core import setup
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-zxcvbn-password',
version='1.0.3.0',
packages=['zxcvbn_password'],
packa... | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
from distutils.core import setup
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-zxcvbn-password',
version='1.0.3.0',
packages=['zxcvbn_password'],
packa... | Fix package data (str to []) | Fix package data (str to [])
| Python | isc | Pawamoy/django-zxcvbn-password,Pawamoy/django-zxcvbn-password,Pawamoy/django-zxcvbn-password | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
from distutils.core import setup
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-zxcvbn-password',
version='1.0.3.0',
packages=['zxcvbn_password'],
packa... | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
from distutils.core import setup
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-zxcvbn-password',
version='1.0.3.0',
packages=['zxcvbn_password'],
packa... | <commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
from distutils.core import setup
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-zxcvbn-password',
version='1.0.3.0',
packages=['zxcvbn_passwo... | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
from distutils.core import setup
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-zxcvbn-password',
version='1.0.3.0',
packages=['zxcvbn_password'],
packa... | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
from distutils.core import setup
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-zxcvbn-password',
version='1.0.3.0',
packages=['zxcvbn_password'],
packa... | <commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
from distutils.core import setup
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-zxcvbn-password',
version='1.0.3.0',
packages=['zxcvbn_passwo... |
9260852d12ca686843ba30f3786b542e6418e4ff | setup.py | setup.py | import os
import sys
import imp
from setuptools import find_packages
try:
from restricted_pkg import setup
except:
# allow falling back to setuptools only if
# we are not trying to upload
if 'upload' in sys.argv:
raise ImportError('restricted_pkg is required to upload, first do pip install rest... | ### GAMECHANGER_CI_PREVENT_BUILD
import os
import sys
import imp
from setuptools import find_packages
try:
from restricted_pkg import setup
except:
# allow falling back to setuptools only if
# we are not trying to upload
if 'upload' in sys.argv:
raise ImportError('restricted_pkg is required to ... | Add magic comment to stop our CI from building a package | Add magic comment to stop our CI from building a package
| Python | mit | gamechanger/dusty,gamechanger/dusty,gamechanger/dusty,gamechanger/dusty,gamechanger/dusty | import os
import sys
import imp
from setuptools import find_packages
try:
from restricted_pkg import setup
except:
# allow falling back to setuptools only if
# we are not trying to upload
if 'upload' in sys.argv:
raise ImportError('restricted_pkg is required to upload, first do pip install rest... | ### GAMECHANGER_CI_PREVENT_BUILD
import os
import sys
import imp
from setuptools import find_packages
try:
from restricted_pkg import setup
except:
# allow falling back to setuptools only if
# we are not trying to upload
if 'upload' in sys.argv:
raise ImportError('restricted_pkg is required to ... | <commit_before>import os
import sys
import imp
from setuptools import find_packages
try:
from restricted_pkg import setup
except:
# allow falling back to setuptools only if
# we are not trying to upload
if 'upload' in sys.argv:
raise ImportError('restricted_pkg is required to upload, first do p... | ### GAMECHANGER_CI_PREVENT_BUILD
import os
import sys
import imp
from setuptools import find_packages
try:
from restricted_pkg import setup
except:
# allow falling back to setuptools only if
# we are not trying to upload
if 'upload' in sys.argv:
raise ImportError('restricted_pkg is required to ... | import os
import sys
import imp
from setuptools import find_packages
try:
from restricted_pkg import setup
except:
# allow falling back to setuptools only if
# we are not trying to upload
if 'upload' in sys.argv:
raise ImportError('restricted_pkg is required to upload, first do pip install rest... | <commit_before>import os
import sys
import imp
from setuptools import find_packages
try:
from restricted_pkg import setup
except:
# allow falling back to setuptools only if
# we are not trying to upload
if 'upload' in sys.argv:
raise ImportError('restricted_pkg is required to upload, first do p... |
7db466f94fbca57482947fa982f56ae77b11f9fa | setup.py | setup.py | #!/usr/bin/env python
"""
Setup file for toolaudit.
"""
import codecs
import os
from setuptools import setup
here = os.path.abspath(os.path.dirname(__file__))
def read(filename):
"""
Read the contents of the files listed in filenames and return it as a
string.
"""
return codecs.open(os.path.jo... | #!/usr/bin/env python
"""
Setup file for toolaudit.
"""
import codecs
import os
from setuptools import setup
here = os.path.abspath(os.path.dirname(__file__))
def read(filename):
"""
Read the contents of the files listed in filenames and return it as a
string.
"""
return codecs.open(os.path.jo... | Set zip_safe to False to eliminate a variable getting the tests to run | Set zip_safe to False to eliminate a variable getting the tests to run
| Python | mit | jstutters/toolaudit | #!/usr/bin/env python
"""
Setup file for toolaudit.
"""
import codecs
import os
from setuptools import setup
here = os.path.abspath(os.path.dirname(__file__))
def read(filename):
"""
Read the contents of the files listed in filenames and return it as a
string.
"""
return codecs.open(os.path.jo... | #!/usr/bin/env python
"""
Setup file for toolaudit.
"""
import codecs
import os
from setuptools import setup
here = os.path.abspath(os.path.dirname(__file__))
def read(filename):
"""
Read the contents of the files listed in filenames and return it as a
string.
"""
return codecs.open(os.path.jo... | <commit_before>#!/usr/bin/env python
"""
Setup file for toolaudit.
"""
import codecs
import os
from setuptools import setup
here = os.path.abspath(os.path.dirname(__file__))
def read(filename):
"""
Read the contents of the files listed in filenames and return it as a
string.
"""
return codecs.... | #!/usr/bin/env python
"""
Setup file for toolaudit.
"""
import codecs
import os
from setuptools import setup
here = os.path.abspath(os.path.dirname(__file__))
def read(filename):
"""
Read the contents of the files listed in filenames and return it as a
string.
"""
return codecs.open(os.path.jo... | #!/usr/bin/env python
"""
Setup file for toolaudit.
"""
import codecs
import os
from setuptools import setup
here = os.path.abspath(os.path.dirname(__file__))
def read(filename):
"""
Read the contents of the files listed in filenames and return it as a
string.
"""
return codecs.open(os.path.jo... | <commit_before>#!/usr/bin/env python
"""
Setup file for toolaudit.
"""
import codecs
import os
from setuptools import setup
here = os.path.abspath(os.path.dirname(__file__))
def read(filename):
"""
Read the contents of the files listed in filenames and return it as a
string.
"""
return codecs.... |
ad855c1466cfa374aad397fcc3f0e72551e4133f | setup.py | setup.py |
from setuptools import setup
setup(name = 'OWSLib',
version = '0.1.0',
description = 'OGC Web Service utility library',
license = 'GPL',
keywords = 'gis ogc ows wfs wms capabilities metadata',
author = 'Sean Gillies',
author_email = 'sgillies@fri... |
from setuptools import setup
setup(name = 'OWSLib',
version = '0.2.0',
description = 'OGC Web Service utility library',
license = 'BSD',
keywords = 'gis ogc ows wfs wms capabilities metadata',
author = 'Sean Gillies',
author_email = 'sgillies@fri... | Change version and license for 0.2 | Change version and license for 0.2
| Python | bsd-3-clause | dblodgett-usgs/OWSLib,geographika/OWSLib,bird-house/OWSLib,ocefpaf/OWSLib,daf/OWSLib,kalxas/OWSLib,tomkralidis/OWSLib,jaygoldfinch/OWSLib,mbertrand/OWSLib,KeyproOy/OWSLib,Jenselme/OWSLib,menegon/OWSLib,jachym/OWSLib,kwilcox/OWSLib,jaygoldfinch/OWSLib,JuergenWeichand/OWSLib,b-cube/OWSLib,gfusca/OWSLib,robmcmullen/OWSLib... |
from setuptools import setup
setup(name = 'OWSLib',
version = '0.1.0',
description = 'OGC Web Service utility library',
license = 'GPL',
keywords = 'gis ogc ows wfs wms capabilities metadata',
author = 'Sean Gillies',
author_email = 'sgillies@fri... |
from setuptools import setup
setup(name = 'OWSLib',
version = '0.2.0',
description = 'OGC Web Service utility library',
license = 'BSD',
keywords = 'gis ogc ows wfs wms capabilities metadata',
author = 'Sean Gillies',
author_email = 'sgillies@fri... | <commit_before>
from setuptools import setup
setup(name = 'OWSLib',
version = '0.1.0',
description = 'OGC Web Service utility library',
license = 'GPL',
keywords = 'gis ogc ows wfs wms capabilities metadata',
author = 'Sean Gillies',
author_email ... |
from setuptools import setup
setup(name = 'OWSLib',
version = '0.2.0',
description = 'OGC Web Service utility library',
license = 'BSD',
keywords = 'gis ogc ows wfs wms capabilities metadata',
author = 'Sean Gillies',
author_email = 'sgillies@fri... |
from setuptools import setup
setup(name = 'OWSLib',
version = '0.1.0',
description = 'OGC Web Service utility library',
license = 'GPL',
keywords = 'gis ogc ows wfs wms capabilities metadata',
author = 'Sean Gillies',
author_email = 'sgillies@fri... | <commit_before>
from setuptools import setup
setup(name = 'OWSLib',
version = '0.1.0',
description = 'OGC Web Service utility library',
license = 'GPL',
keywords = 'gis ogc ows wfs wms capabilities metadata',
author = 'Sean Gillies',
author_email ... |
5b2691dcc89fb9d9b7b1db77e9512976950adf45 | setup.py | setup.py | """Package Keysmith."""
import codecs
import os.path
import setuptools # type: ignore
import keysmith # This project only depends on the standard library.
def read(*parts):
"""Read a file in this repository."""
here = os.path.abspath(os.path.dirname(__file__))
with codecs.open(os.path.join(here, *pa... | """Package Keysmith."""
import codecs
import os.path
import setuptools # type: ignore
import keysmith # This project only depends on the standard library.
def read(*parts):
"""Read a file in this repository."""
here = os.path.abspath(os.path.dirname(__file__))
with codecs.open(os.path.join(here, *pa... | Update the project Development Status | Update the project Development Status
| Python | bsd-3-clause | dmtucker/keysmith | """Package Keysmith."""
import codecs
import os.path
import setuptools # type: ignore
import keysmith # This project only depends on the standard library.
def read(*parts):
"""Read a file in this repository."""
here = os.path.abspath(os.path.dirname(__file__))
with codecs.open(os.path.join(here, *pa... | """Package Keysmith."""
import codecs
import os.path
import setuptools # type: ignore
import keysmith # This project only depends on the standard library.
def read(*parts):
"""Read a file in this repository."""
here = os.path.abspath(os.path.dirname(__file__))
with codecs.open(os.path.join(here, *pa... | <commit_before>"""Package Keysmith."""
import codecs
import os.path
import setuptools # type: ignore
import keysmith # This project only depends on the standard library.
def read(*parts):
"""Read a file in this repository."""
here = os.path.abspath(os.path.dirname(__file__))
with codecs.open(os.path... | """Package Keysmith."""
import codecs
import os.path
import setuptools # type: ignore
import keysmith # This project only depends on the standard library.
def read(*parts):
"""Read a file in this repository."""
here = os.path.abspath(os.path.dirname(__file__))
with codecs.open(os.path.join(here, *pa... | """Package Keysmith."""
import codecs
import os.path
import setuptools # type: ignore
import keysmith # This project only depends on the standard library.
def read(*parts):
"""Read a file in this repository."""
here = os.path.abspath(os.path.dirname(__file__))
with codecs.open(os.path.join(here, *pa... | <commit_before>"""Package Keysmith."""
import codecs
import os.path
import setuptools # type: ignore
import keysmith # This project only depends on the standard library.
def read(*parts):
"""Read a file in this repository."""
here = os.path.abspath(os.path.dirname(__file__))
with codecs.open(os.path... |
05ed915cab57ec8014a4d4636687132694171218 | setup.py | setup.py | from setuptools import setup, find_packages
import populous
requirements = [
"click",
]
setup(
name="populous",
version=populous.__version__,
url=populous.__url__,
description=populous.__doc__,
author=populous.__author__,
license=populous.__license__,
long_description="TODO",
pack... | from setuptools import setup, find_packages
import populous
requirements = [
"click",
"cached-property",
]
setup(
name="populous",
version=populous.__version__,
url=populous.__url__,
description=populous.__doc__,
author=populous.__author__,
license=populous.__license__,
long_descr... | Add cached-property to the dependencies | Add cached-property to the dependencies
| Python | mit | novafloss/populous | from setuptools import setup, find_packages
import populous
requirements = [
"click",
]
setup(
name="populous",
version=populous.__version__,
url=populous.__url__,
description=populous.__doc__,
author=populous.__author__,
license=populous.__license__,
long_description="TODO",
pack... | from setuptools import setup, find_packages
import populous
requirements = [
"click",
"cached-property",
]
setup(
name="populous",
version=populous.__version__,
url=populous.__url__,
description=populous.__doc__,
author=populous.__author__,
license=populous.__license__,
long_descr... | <commit_before>from setuptools import setup, find_packages
import populous
requirements = [
"click",
]
setup(
name="populous",
version=populous.__version__,
url=populous.__url__,
description=populous.__doc__,
author=populous.__author__,
license=populous.__license__,
long_description="... | from setuptools import setup, find_packages
import populous
requirements = [
"click",
"cached-property",
]
setup(
name="populous",
version=populous.__version__,
url=populous.__url__,
description=populous.__doc__,
author=populous.__author__,
license=populous.__license__,
long_descr... | from setuptools import setup, find_packages
import populous
requirements = [
"click",
]
setup(
name="populous",
version=populous.__version__,
url=populous.__url__,
description=populous.__doc__,
author=populous.__author__,
license=populous.__license__,
long_description="TODO",
pack... | <commit_before>from setuptools import setup, find_packages
import populous
requirements = [
"click",
]
setup(
name="populous",
version=populous.__version__,
url=populous.__url__,
description=populous.__doc__,
author=populous.__author__,
license=populous.__license__,
long_description="... |
6edb67deeb3f19b3b5d24e262afc266ce2cb7600 | setup.py | setup.py | from setuptools import setup
import io
# Take from Jeff Knupp's excellent article:
# http://www.jeffknupp.com/blog/2013/08/16/open-sourcing-a-python-project-the-right-way/
def read(*filenames, **kwargs):
encoding = kwargs.get('encoding', 'utf-8')
sep = kwargs.get('sep', '\n')
buf = []
for filename in... | from setuptools import setup
import io
# Take from Jeff Knupp's excellent article:
# http://www.jeffknupp.com/blog/2013/08/16/open-sourcing-a-python-project-the-right-way/
def read(*filenames, **kwargs):
encoding = kwargs.get('encoding', 'utf-8')
sep = kwargs.get('sep', '\n')
buf = []
for filename in... | Add pytz to installation requirements, needed for pedometerpp | Add pytz to installation requirements, needed for pedometerpp
| Python | mit | durden/dayonetools | from setuptools import setup
import io
# Take from Jeff Knupp's excellent article:
# http://www.jeffknupp.com/blog/2013/08/16/open-sourcing-a-python-project-the-right-way/
def read(*filenames, **kwargs):
encoding = kwargs.get('encoding', 'utf-8')
sep = kwargs.get('sep', '\n')
buf = []
for filename in... | from setuptools import setup
import io
# Take from Jeff Knupp's excellent article:
# http://www.jeffknupp.com/blog/2013/08/16/open-sourcing-a-python-project-the-right-way/
def read(*filenames, **kwargs):
encoding = kwargs.get('encoding', 'utf-8')
sep = kwargs.get('sep', '\n')
buf = []
for filename in... | <commit_before>from setuptools import setup
import io
# Take from Jeff Knupp's excellent article:
# http://www.jeffknupp.com/blog/2013/08/16/open-sourcing-a-python-project-the-right-way/
def read(*filenames, **kwargs):
encoding = kwargs.get('encoding', 'utf-8')
sep = kwargs.get('sep', '\n')
buf = []
... | from setuptools import setup
import io
# Take from Jeff Knupp's excellent article:
# http://www.jeffknupp.com/blog/2013/08/16/open-sourcing-a-python-project-the-right-way/
def read(*filenames, **kwargs):
encoding = kwargs.get('encoding', 'utf-8')
sep = kwargs.get('sep', '\n')
buf = []
for filename in... | from setuptools import setup
import io
# Take from Jeff Knupp's excellent article:
# http://www.jeffknupp.com/blog/2013/08/16/open-sourcing-a-python-project-the-right-way/
def read(*filenames, **kwargs):
encoding = kwargs.get('encoding', 'utf-8')
sep = kwargs.get('sep', '\n')
buf = []
for filename in... | <commit_before>from setuptools import setup
import io
# Take from Jeff Knupp's excellent article:
# http://www.jeffknupp.com/blog/2013/08/16/open-sourcing-a-python-project-the-right-way/
def read(*filenames, **kwargs):
encoding = kwargs.get('encoding', 'utf-8')
sep = kwargs.get('sep', '\n')
buf = []
... |
edd54a7e34fdce5268ef1d15bd04b09e724a8508 | setup.py | setup.py | #!/usr/bin/env python
# coding=utf-8
from setuptools import setup
# Get long description (used on PyPI project page)
def get_long_description():
try:
# Use pandoc to create reStructuredText README if possible
import pypandoc
return pypandoc.convert('README.md', 'rst')
except:
... | #!/usr/bin/env python
# coding=utf-8
from setuptools import setup
# Get long description (used on PyPI project page)
def get_long_description():
try:
# Use pandoc to create reStructuredText README if possible
import pypandoc
return pypandoc.convert('README.md', 'rst')
except:
... | Remove long utility command names in favor of awp | Remove long utility command names in favor of awp
| Python | mit | caleb531/alfred-workflow-packager | #!/usr/bin/env python
# coding=utf-8
from setuptools import setup
# Get long description (used on PyPI project page)
def get_long_description():
try:
# Use pandoc to create reStructuredText README if possible
import pypandoc
return pypandoc.convert('README.md', 'rst')
except:
... | #!/usr/bin/env python
# coding=utf-8
from setuptools import setup
# Get long description (used on PyPI project page)
def get_long_description():
try:
# Use pandoc to create reStructuredText README if possible
import pypandoc
return pypandoc.convert('README.md', 'rst')
except:
... | <commit_before>#!/usr/bin/env python
# coding=utf-8
from setuptools import setup
# Get long description (used on PyPI project page)
def get_long_description():
try:
# Use pandoc to create reStructuredText README if possible
import pypandoc
return pypandoc.convert('README.md', 'rst')
e... | #!/usr/bin/env python
# coding=utf-8
from setuptools import setup
# Get long description (used on PyPI project page)
def get_long_description():
try:
# Use pandoc to create reStructuredText README if possible
import pypandoc
return pypandoc.convert('README.md', 'rst')
except:
... | #!/usr/bin/env python
# coding=utf-8
from setuptools import setup
# Get long description (used on PyPI project page)
def get_long_description():
try:
# Use pandoc to create reStructuredText README if possible
import pypandoc
return pypandoc.convert('README.md', 'rst')
except:
... | <commit_before>#!/usr/bin/env python
# coding=utf-8
from setuptools import setup
# Get long description (used on PyPI project page)
def get_long_description():
try:
# Use pandoc to create reStructuredText README if possible
import pypandoc
return pypandoc.convert('README.md', 'rst')
e... |
be8ea4018641cf79a347f2da04b078e725b0801e | setup.py | setup.py | #!/usr/bin/env python
from setuptools import setup, find_packages
import sys
with open('README.md') as f:
readme = f.read()
install_requires = [
'seria',
'python-gnupg'
]
setup(
name='figgypy',
version='0.3.dev',
description='Simple configuration tool. Get config from yaml, json, or xml.',
... | #!/usr/bin/env python
from setuptools import setup, find_packages
import sys
with open('README.md') as f:
readme = f.read()
install_requires = [
'gnupg>=2.0.2',
'seria',
'python-gnupg'
]
setup(
name='figgypy',
version='0.3.dev',
description='Simple configuration tool. Get config from ya... | Add requirement for fork version of gnupg | Add requirement for fork version of gnupg
| Python | mit | theherk/figgypy | #!/usr/bin/env python
from setuptools import setup, find_packages
import sys
with open('README.md') as f:
readme = f.read()
install_requires = [
'seria',
'python-gnupg'
]
setup(
name='figgypy',
version='0.3.dev',
description='Simple configuration tool. Get config from yaml, json, or xml.',
... | #!/usr/bin/env python
from setuptools import setup, find_packages
import sys
with open('README.md') as f:
readme = f.read()
install_requires = [
'gnupg>=2.0.2',
'seria',
'python-gnupg'
]
setup(
name='figgypy',
version='0.3.dev',
description='Simple configuration tool. Get config from ya... | <commit_before>#!/usr/bin/env python
from setuptools import setup, find_packages
import sys
with open('README.md') as f:
readme = f.read()
install_requires = [
'seria',
'python-gnupg'
]
setup(
name='figgypy',
version='0.3.dev',
description='Simple configuration tool. Get config from yaml, j... | #!/usr/bin/env python
from setuptools import setup, find_packages
import sys
with open('README.md') as f:
readme = f.read()
install_requires = [
'gnupg>=2.0.2',
'seria',
'python-gnupg'
]
setup(
name='figgypy',
version='0.3.dev',
description='Simple configuration tool. Get config from ya... | #!/usr/bin/env python
from setuptools import setup, find_packages
import sys
with open('README.md') as f:
readme = f.read()
install_requires = [
'seria',
'python-gnupg'
]
setup(
name='figgypy',
version='0.3.dev',
description='Simple configuration tool. Get config from yaml, json, or xml.',
... | <commit_before>#!/usr/bin/env python
from setuptools import setup, find_packages
import sys
with open('README.md') as f:
readme = f.read()
install_requires = [
'seria',
'python-gnupg'
]
setup(
name='figgypy',
version='0.3.dev',
description='Simple configuration tool. Get config from yaml, j... |
d8de5888e4519ba32d63d5f31aa4806d81c37399 | setup.py | setup.py | #!/usr/bin/env python
from setuptools import setup
VERSION = '0.0.1'
test_requirements = [
'nose>=1.3.7',
'responses>=0.5.1'
]
install_requires = test_requirements + [
'requests>=2.4.3',
]
setup(
name="mondo",
version=VERSION,
description="Mondo Banking API Client",
author=', '.join((
... | #!/usr/bin/env python
from setuptools import setup
VERSION = '0.0.1'
test_requirements = [
'nose>=1.3.4',
'responses>=0.5.1'
]
install_requires = test_requirements + [
'requests>=2.4.3',
]
setup(
name="mondo",
version=VERSION,
description="Mondo Banking API Client",
author=', '.join((
... | Update nose version for Python2 | Update nose version for Python2
| Python | mit | gabalese/mondo-python | #!/usr/bin/env python
from setuptools import setup
VERSION = '0.0.1'
test_requirements = [
'nose>=1.3.7',
'responses>=0.5.1'
]
install_requires = test_requirements + [
'requests>=2.4.3',
]
setup(
name="mondo",
version=VERSION,
description="Mondo Banking API Client",
author=', '.join((
... | #!/usr/bin/env python
from setuptools import setup
VERSION = '0.0.1'
test_requirements = [
'nose>=1.3.4',
'responses>=0.5.1'
]
install_requires = test_requirements + [
'requests>=2.4.3',
]
setup(
name="mondo",
version=VERSION,
description="Mondo Banking API Client",
author=', '.join((
... | <commit_before>#!/usr/bin/env python
from setuptools import setup
VERSION = '0.0.1'
test_requirements = [
'nose>=1.3.7',
'responses>=0.5.1'
]
install_requires = test_requirements + [
'requests>=2.4.3',
]
setup(
name="mondo",
version=VERSION,
description="Mondo Banking API Client",
autho... | #!/usr/bin/env python
from setuptools import setup
VERSION = '0.0.1'
test_requirements = [
'nose>=1.3.4',
'responses>=0.5.1'
]
install_requires = test_requirements + [
'requests>=2.4.3',
]
setup(
name="mondo",
version=VERSION,
description="Mondo Banking API Client",
author=', '.join((
... | #!/usr/bin/env python
from setuptools import setup
VERSION = '0.0.1'
test_requirements = [
'nose>=1.3.7',
'responses>=0.5.1'
]
install_requires = test_requirements + [
'requests>=2.4.3',
]
setup(
name="mondo",
version=VERSION,
description="Mondo Banking API Client",
author=', '.join((
... | <commit_before>#!/usr/bin/env python
from setuptools import setup
VERSION = '0.0.1'
test_requirements = [
'nose>=1.3.7',
'responses>=0.5.1'
]
install_requires = test_requirements + [
'requests>=2.4.3',
]
setup(
name="mondo",
version=VERSION,
description="Mondo Banking API Client",
autho... |
bc687afb9421d61afe95f1c3a444e6c91971a113 | setup.py | setup.py | import os.path
# Install setuptools if not installed.
try:
import setuptools
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup, find_packages
# read README as the long description
readme = 'README' if os.path.exists('README') else 'README.md'
with open... | import os.path
# Install setuptools if not installed.
try:
import setuptools
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup, find_packages
# read README as the long description
readme = 'README' if os.path.exists('README') else 'README.md'
with open... | Add comment for updated Pandas requirement | Add comment for updated Pandas requirement
| Python | bsd-3-clause | UDST/spandex,SANDAG/spandex | import os.path
# Install setuptools if not installed.
try:
import setuptools
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup, find_packages
# read README as the long description
readme = 'README' if os.path.exists('README') else 'README.md'
with open... | import os.path
# Install setuptools if not installed.
try:
import setuptools
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup, find_packages
# read README as the long description
readme = 'README' if os.path.exists('README') else 'README.md'
with open... | <commit_before>import os.path
# Install setuptools if not installed.
try:
import setuptools
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup, find_packages
# read README as the long description
readme = 'README' if os.path.exists('README') else 'READM... | import os.path
# Install setuptools if not installed.
try:
import setuptools
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup, find_packages
# read README as the long description
readme = 'README' if os.path.exists('README') else 'README.md'
with open... | import os.path
# Install setuptools if not installed.
try:
import setuptools
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup, find_packages
# read README as the long description
readme = 'README' if os.path.exists('README') else 'README.md'
with open... | <commit_before>import os.path
# Install setuptools if not installed.
try:
import setuptools
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup, find_packages
# read README as the long description
readme = 'README' if os.path.exists('README') else 'READM... |
61f9f96645daaa42369b86f2af9404f3d228b22e | setup.py | setup.py | #!/usr/bin/env python3
from setuptools import setup
from ipyrmd import __version__
setup(name="ipyrmd",
version=__version__,
description="Convert between IPython/Jupyter notebooks and RMarkdown",
author="Gordon Ball",
author_email="gordon@chronitis.net",
url="https://github.com/chronitis... | #!/usr/bin/env python3
from setuptools import setup
from ipyrmd import __version__
setup(name="ipyrmd",
version=__version__,
description="Convert between IPython/Jupyter notebooks and RMarkdown",
author="Gordon Ball",
author_email="gordon@chronitis.net",
url="https://github.com/chronitis... | Add missing comma in classifier list | Add missing comma in classifier list
| Python | mit | chronitis/ipyrmd | #!/usr/bin/env python3
from setuptools import setup
from ipyrmd import __version__
setup(name="ipyrmd",
version=__version__,
description="Convert between IPython/Jupyter notebooks and RMarkdown",
author="Gordon Ball",
author_email="gordon@chronitis.net",
url="https://github.com/chronitis... | #!/usr/bin/env python3
from setuptools import setup
from ipyrmd import __version__
setup(name="ipyrmd",
version=__version__,
description="Convert between IPython/Jupyter notebooks and RMarkdown",
author="Gordon Ball",
author_email="gordon@chronitis.net",
url="https://github.com/chronitis... | <commit_before>#!/usr/bin/env python3
from setuptools import setup
from ipyrmd import __version__
setup(name="ipyrmd",
version=__version__,
description="Convert between IPython/Jupyter notebooks and RMarkdown",
author="Gordon Ball",
author_email="gordon@chronitis.net",
url="https://githu... | #!/usr/bin/env python3
from setuptools import setup
from ipyrmd import __version__
setup(name="ipyrmd",
version=__version__,
description="Convert between IPython/Jupyter notebooks and RMarkdown",
author="Gordon Ball",
author_email="gordon@chronitis.net",
url="https://github.com/chronitis... | #!/usr/bin/env python3
from setuptools import setup
from ipyrmd import __version__
setup(name="ipyrmd",
version=__version__,
description="Convert between IPython/Jupyter notebooks and RMarkdown",
author="Gordon Ball",
author_email="gordon@chronitis.net",
url="https://github.com/chronitis... | <commit_before>#!/usr/bin/env python3
from setuptools import setup
from ipyrmd import __version__
setup(name="ipyrmd",
version=__version__,
description="Convert between IPython/Jupyter notebooks and RMarkdown",
author="Gordon Ball",
author_email="gordon@chronitis.net",
url="https://githu... |
5c0c0a86827ec6d2b8ece7cffddec3afbfcf72b6 | setup.py | setup.py | import os
from setuptools import setup, find_packages
__version__ = '0.1'
HERE = os.path.dirname(__file__)
try:
long_description = open(os.path.join(HERE, 'README.rst')).read()
except:
long_description = None
setup(
name='rubberjack-cli',
version=__version__,
packages=find_packages(exclude=['tes... | import os
from setuptools import setup, find_packages
__version__ = '0.1'
HERE = os.path.dirname(__file__)
def readme():
with open('README.rst') as f:
return f.read()
setup(
name='rubberjack-cli',
version=__version__,
packages=find_packages(exclude=['test*']),
include_package_data=True... | Include README in package cf. PyPA recommendation | Include README in package cf. PyPA recommendation
http://python-packaging.readthedocs.io/en/latest/metadata.html#a-readme-long-description
| Python | mit | laterpay/rubberjack-cli | import os
from setuptools import setup, find_packages
__version__ = '0.1'
HERE = os.path.dirname(__file__)
try:
long_description = open(os.path.join(HERE, 'README.rst')).read()
except:
long_description = None
setup(
name='rubberjack-cli',
version=__version__,
packages=find_packages(exclude=['tes... | import os
from setuptools import setup, find_packages
__version__ = '0.1'
HERE = os.path.dirname(__file__)
def readme():
with open('README.rst') as f:
return f.read()
setup(
name='rubberjack-cli',
version=__version__,
packages=find_packages(exclude=['test*']),
include_package_data=True... | <commit_before>import os
from setuptools import setup, find_packages
__version__ = '0.1'
HERE = os.path.dirname(__file__)
try:
long_description = open(os.path.join(HERE, 'README.rst')).read()
except:
long_description = None
setup(
name='rubberjack-cli',
version=__version__,
packages=find_package... | import os
from setuptools import setup, find_packages
__version__ = '0.1'
HERE = os.path.dirname(__file__)
def readme():
with open('README.rst') as f:
return f.read()
setup(
name='rubberjack-cli',
version=__version__,
packages=find_packages(exclude=['test*']),
include_package_data=True... | import os
from setuptools import setup, find_packages
__version__ = '0.1'
HERE = os.path.dirname(__file__)
try:
long_description = open(os.path.join(HERE, 'README.rst')).read()
except:
long_description = None
setup(
name='rubberjack-cli',
version=__version__,
packages=find_packages(exclude=['tes... | <commit_before>import os
from setuptools import setup, find_packages
__version__ = '0.1'
HERE = os.path.dirname(__file__)
try:
long_description = open(os.path.join(HERE, 'README.rst')).read()
except:
long_description = None
setup(
name='rubberjack-cli',
version=__version__,
packages=find_package... |
bdee28d919458449d882df352ed6e2d675b87901 | setup.py | setup.py | from setuptools import setup, find_packages
version = __import__('eemeter').get_version()
setup(
name='eemeter',
version=version,
description='Open Energy Efficiency Meter',
long_description=(
"Standard methods for calculating energy efficiency savings."
),
url='https://github.com/ope... | from setuptools import setup, find_packages
version = __import__('eemeter').get_version()
setup(
name='eemeter',
version=version,
description='Open Energy Efficiency Meter',
long_description=(
"Standard methods for calculating energy efficiency savings."
),
url='https://github.com/ope... | Use higher pandas version for python 3.6.0 support | Use higher pandas version for python 3.6.0 support
| Python | apache-2.0 | openeemeter/eemeter,openeemeter/eemeter | from setuptools import setup, find_packages
version = __import__('eemeter').get_version()
setup(
name='eemeter',
version=version,
description='Open Energy Efficiency Meter',
long_description=(
"Standard methods for calculating energy efficiency savings."
),
url='https://github.com/ope... | from setuptools import setup, find_packages
version = __import__('eemeter').get_version()
setup(
name='eemeter',
version=version,
description='Open Energy Efficiency Meter',
long_description=(
"Standard methods for calculating energy efficiency savings."
),
url='https://github.com/ope... | <commit_before>from setuptools import setup, find_packages
version = __import__('eemeter').get_version()
setup(
name='eemeter',
version=version,
description='Open Energy Efficiency Meter',
long_description=(
"Standard methods for calculating energy efficiency savings."
),
url='https:/... | from setuptools import setup, find_packages
version = __import__('eemeter').get_version()
setup(
name='eemeter',
version=version,
description='Open Energy Efficiency Meter',
long_description=(
"Standard methods for calculating energy efficiency savings."
),
url='https://github.com/ope... | from setuptools import setup, find_packages
version = __import__('eemeter').get_version()
setup(
name='eemeter',
version=version,
description='Open Energy Efficiency Meter',
long_description=(
"Standard methods for calculating energy efficiency savings."
),
url='https://github.com/ope... | <commit_before>from setuptools import setup, find_packages
version = __import__('eemeter').get_version()
setup(
name='eemeter',
version=version,
description='Open Energy Efficiency Meter',
long_description=(
"Standard methods for calculating energy efficiency savings."
),
url='https:/... |
e91d22d34027429f7d0db86d2800ba9ed73056be | setup.py | setup.py | from setuptools import setup, find_packages
setup(
name = 'django-news-sitemaps',
version = '0.1.7',
description = 'Generates sitemaps compatible with the Google News schema',
author = 'TWT Web Devs',
author_email = 'webdev@washingtontimes.com',
url = 'http://github.com/washingtontimes/django-n... | from setuptools import setup, find_packages
setup(
name = 'django-news-sitemaps',
version = '1.0.0',
description = 'Generates sitemaps compatible with the Google News schema',
author = 'TWT Web Devs',
author_email = 'webdev@washingtontimes.com',
url = 'http://github.com/washingtontimes/django-n... | Increment version number to 1.0.0 | Increment version number to 1.0.0 | Python | apache-2.0 | theatlantic/django-news-sitemaps | from setuptools import setup, find_packages
setup(
name = 'django-news-sitemaps',
version = '0.1.7',
description = 'Generates sitemaps compatible with the Google News schema',
author = 'TWT Web Devs',
author_email = 'webdev@washingtontimes.com',
url = 'http://github.com/washingtontimes/django-n... | from setuptools import setup, find_packages
setup(
name = 'django-news-sitemaps',
version = '1.0.0',
description = 'Generates sitemaps compatible with the Google News schema',
author = 'TWT Web Devs',
author_email = 'webdev@washingtontimes.com',
url = 'http://github.com/washingtontimes/django-n... | <commit_before>from setuptools import setup, find_packages
setup(
name = 'django-news-sitemaps',
version = '0.1.7',
description = 'Generates sitemaps compatible with the Google News schema',
author = 'TWT Web Devs',
author_email = 'webdev@washingtontimes.com',
url = 'http://github.com/washingto... | from setuptools import setup, find_packages
setup(
name = 'django-news-sitemaps',
version = '1.0.0',
description = 'Generates sitemaps compatible with the Google News schema',
author = 'TWT Web Devs',
author_email = 'webdev@washingtontimes.com',
url = 'http://github.com/washingtontimes/django-n... | from setuptools import setup, find_packages
setup(
name = 'django-news-sitemaps',
version = '0.1.7',
description = 'Generates sitemaps compatible with the Google News schema',
author = 'TWT Web Devs',
author_email = 'webdev@washingtontimes.com',
url = 'http://github.com/washingtontimes/django-n... | <commit_before>from setuptools import setup, find_packages
setup(
name = 'django-news-sitemaps',
version = '0.1.7',
description = 'Generates sitemaps compatible with the Google News schema',
author = 'TWT Web Devs',
author_email = 'webdev@washingtontimes.com',
url = 'http://github.com/washingto... |
96499391091a81302ac3947536b573c21f571677 | setup.py | setup.py | from setuptools import setup
from distutils import sysconfig
import re
#from setuptools.dist import Distribution
site_packages_path = sysconfig.get_python_lib()
sprem = re.match(
r'.*(lib[\\/](python\d\.\d[\\/])?site-packages)', site_packages_path, re.I)
rel_site_packages = sprem.group(1)
#class PureDistribution(... | from setuptools import setup
from distutils import sysconfig
import re
#from setuptools.dist import Distribution
site_packages_path = sysconfig.get_python_lib()
try:
sprem = re.match(
r'.*(lib[\\/](python\d(\.\d)*[\\/])?site-packages)', site_packages_path, re.I)
if sprem is None:
sprem = re.mat... | Expand regex for location of site-packages. Provide more info to user about possible failure to find site-packages | Expand regex for location of site-packages. Provide more info to user about possible failure to find site-packages
| Python | bsd-2-clause | dougn/coverage_pth | from setuptools import setup
from distutils import sysconfig
import re
#from setuptools.dist import Distribution
site_packages_path = sysconfig.get_python_lib()
sprem = re.match(
r'.*(lib[\\/](python\d\.\d[\\/])?site-packages)', site_packages_path, re.I)
rel_site_packages = sprem.group(1)
#class PureDistribution(... | from setuptools import setup
from distutils import sysconfig
import re
#from setuptools.dist import Distribution
site_packages_path = sysconfig.get_python_lib()
try:
sprem = re.match(
r'.*(lib[\\/](python\d(\.\d)*[\\/])?site-packages)', site_packages_path, re.I)
if sprem is None:
sprem = re.mat... | <commit_before>from setuptools import setup
from distutils import sysconfig
import re
#from setuptools.dist import Distribution
site_packages_path = sysconfig.get_python_lib()
sprem = re.match(
r'.*(lib[\\/](python\d\.\d[\\/])?site-packages)', site_packages_path, re.I)
rel_site_packages = sprem.group(1)
#class Pu... | from setuptools import setup
from distutils import sysconfig
import re
#from setuptools.dist import Distribution
site_packages_path = sysconfig.get_python_lib()
try:
sprem = re.match(
r'.*(lib[\\/](python\d(\.\d)*[\\/])?site-packages)', site_packages_path, re.I)
if sprem is None:
sprem = re.mat... | from setuptools import setup
from distutils import sysconfig
import re
#from setuptools.dist import Distribution
site_packages_path = sysconfig.get_python_lib()
sprem = re.match(
r'.*(lib[\\/](python\d\.\d[\\/])?site-packages)', site_packages_path, re.I)
rel_site_packages = sprem.group(1)
#class PureDistribution(... | <commit_before>from setuptools import setup
from distutils import sysconfig
import re
#from setuptools.dist import Distribution
site_packages_path = sysconfig.get_python_lib()
sprem = re.match(
r'.*(lib[\\/](python\d\.\d[\\/])?site-packages)', site_packages_path, re.I)
rel_site_packages = sprem.group(1)
#class Pu... |
42043217547f05eb1652d481840d15b581b80434 | setup.py | setup.py | # -*- coding: utf-8 -*-
import os
from setuptools import find_packages
from setuptools import setup
base_dir = os.path.dirname(__file__)
setup(
name='elastalert',
version='0.0.99',
description='Runs custom filters on Elasticsearch and alerts on matches',
author='Quentin Long',
author_email='qlo@y... | # -*- coding: utf-8 -*-
import os
from setuptools import find_packages
from setuptools import setup
base_dir = os.path.dirname(__file__)
setup(
name='elastalert',
version='0.1.0',
description='Runs custom filters on Elasticsearch and alerts on matches',
author='Quentin Long',
author_email='qlo@ye... | Bump elastalert version to 0.1.0 | Bump elastalert version to 0.1.0
| Python | apache-2.0 | Yelp/elastalert,jetyang2005/elastalert,jetyang2005/elastalert,jetyang2005/elastalert,dvopsway/elastalert,rprabhat/elastalert | # -*- coding: utf-8 -*-
import os
from setuptools import find_packages
from setuptools import setup
base_dir = os.path.dirname(__file__)
setup(
name='elastalert',
version='0.0.99',
description='Runs custom filters on Elasticsearch and alerts on matches',
author='Quentin Long',
author_email='qlo@y... | # -*- coding: utf-8 -*-
import os
from setuptools import find_packages
from setuptools import setup
base_dir = os.path.dirname(__file__)
setup(
name='elastalert',
version='0.1.0',
description='Runs custom filters on Elasticsearch and alerts on matches',
author='Quentin Long',
author_email='qlo@ye... | <commit_before># -*- coding: utf-8 -*-
import os
from setuptools import find_packages
from setuptools import setup
base_dir = os.path.dirname(__file__)
setup(
name='elastalert',
version='0.0.99',
description='Runs custom filters on Elasticsearch and alerts on matches',
author='Quentin Long',
auth... | # -*- coding: utf-8 -*-
import os
from setuptools import find_packages
from setuptools import setup
base_dir = os.path.dirname(__file__)
setup(
name='elastalert',
version='0.1.0',
description='Runs custom filters on Elasticsearch and alerts on matches',
author='Quentin Long',
author_email='qlo@ye... | # -*- coding: utf-8 -*-
import os
from setuptools import find_packages
from setuptools import setup
base_dir = os.path.dirname(__file__)
setup(
name='elastalert',
version='0.0.99',
description='Runs custom filters on Elasticsearch and alerts on matches',
author='Quentin Long',
author_email='qlo@y... | <commit_before># -*- coding: utf-8 -*-
import os
from setuptools import find_packages
from setuptools import setup
base_dir = os.path.dirname(__file__)
setup(
name='elastalert',
version='0.0.99',
description='Runs custom filters on Elasticsearch and alerts on matches',
author='Quentin Long',
auth... |
a1a651acf48604ab135961b324d3b9e271a2128b | setup.py | setup.py | from distutils.core import setup
with open('README.md') as readme:
with open('HISTORY.md') as history:
long_description = readme.read() + '\n\n' + history.read()
VERSION = '1.0'
setup(
name='argparse-autogen',
py_modules=['argparse_autogen'],
version=VERSION,
url='https://github.com/sashg... | from distutils.core import setup
with open('README.md') as readme:
with open('HISTORY.md') as history:
long_description = readme.read() + '\n\n' + history.read()
try:
import pypandoc
long_description = pypandoc.convert(long_description, 'rst')
except(IOError, ImportError):
long_description = ... | Convert md to rst readme specially for PyPi | Convert md to rst readme specially for PyPi
| Python | mit | sashgorokhov/argparse-autogen | from distutils.core import setup
with open('README.md') as readme:
with open('HISTORY.md') as history:
long_description = readme.read() + '\n\n' + history.read()
VERSION = '1.0'
setup(
name='argparse-autogen',
py_modules=['argparse_autogen'],
version=VERSION,
url='https://github.com/sashg... | from distutils.core import setup
with open('README.md') as readme:
with open('HISTORY.md') as history:
long_description = readme.read() + '\n\n' + history.read()
try:
import pypandoc
long_description = pypandoc.convert(long_description, 'rst')
except(IOError, ImportError):
long_description = ... | <commit_before>from distutils.core import setup
with open('README.md') as readme:
with open('HISTORY.md') as history:
long_description = readme.read() + '\n\n' + history.read()
VERSION = '1.0'
setup(
name='argparse-autogen',
py_modules=['argparse_autogen'],
version=VERSION,
url='https://g... | from distutils.core import setup
with open('README.md') as readme:
with open('HISTORY.md') as history:
long_description = readme.read() + '\n\n' + history.read()
try:
import pypandoc
long_description = pypandoc.convert(long_description, 'rst')
except(IOError, ImportError):
long_description = ... | from distutils.core import setup
with open('README.md') as readme:
with open('HISTORY.md') as history:
long_description = readme.read() + '\n\n' + history.read()
VERSION = '1.0'
setup(
name='argparse-autogen',
py_modules=['argparse_autogen'],
version=VERSION,
url='https://github.com/sashg... | <commit_before>from distutils.core import setup
with open('README.md') as readme:
with open('HISTORY.md') as history:
long_description = readme.read() + '\n\n' + history.read()
VERSION = '1.0'
setup(
name='argparse-autogen',
py_modules=['argparse_autogen'],
version=VERSION,
url='https://g... |
4a7a7a0b558358840440f937a03dcc88e469ca01 | setup.py | setup.py | #!/usr/bin/env python
from setuptools import setup, find_packages
with open('README.rst') as readme_file:
README = readme_file.read()
install_requires = [
'click==6.2',
'botocore>=1.4.8,<2.0.0',
'virtualenv>=15.0.0,<16.0.0',
'typing==3.5.2.2',
]
setup(
name='chalice',
version='0.5.0',
... | #!/usr/bin/env python
from setuptools import setup, find_packages
with open('README.rst') as readme_file:
README = readme_file.read()
install_requires = [
'click==6.6',
'botocore>=1.4.8,<2.0.0',
'virtualenv>=15.0.0,<16.0.0',
'typing==3.5.3.0',
]
setup(
name='chalice',
version='0.5.0',
... | Upgrade type and click versions | Upgrade type and click versions
| Python | apache-2.0 | freaker2k7/chalice,awslabs/chalice | #!/usr/bin/env python
from setuptools import setup, find_packages
with open('README.rst') as readme_file:
README = readme_file.read()
install_requires = [
'click==6.2',
'botocore>=1.4.8,<2.0.0',
'virtualenv>=15.0.0,<16.0.0',
'typing==3.5.2.2',
]
setup(
name='chalice',
version='0.5.0',
... | #!/usr/bin/env python
from setuptools import setup, find_packages
with open('README.rst') as readme_file:
README = readme_file.read()
install_requires = [
'click==6.6',
'botocore>=1.4.8,<2.0.0',
'virtualenv>=15.0.0,<16.0.0',
'typing==3.5.3.0',
]
setup(
name='chalice',
version='0.5.0',
... | <commit_before>#!/usr/bin/env python
from setuptools import setup, find_packages
with open('README.rst') as readme_file:
README = readme_file.read()
install_requires = [
'click==6.2',
'botocore>=1.4.8,<2.0.0',
'virtualenv>=15.0.0,<16.0.0',
'typing==3.5.2.2',
]
setup(
name='chalice',
ve... | #!/usr/bin/env python
from setuptools import setup, find_packages
with open('README.rst') as readme_file:
README = readme_file.read()
install_requires = [
'click==6.6',
'botocore>=1.4.8,<2.0.0',
'virtualenv>=15.0.0,<16.0.0',
'typing==3.5.3.0',
]
setup(
name='chalice',
version='0.5.0',
... | #!/usr/bin/env python
from setuptools import setup, find_packages
with open('README.rst') as readme_file:
README = readme_file.read()
install_requires = [
'click==6.2',
'botocore>=1.4.8,<2.0.0',
'virtualenv>=15.0.0,<16.0.0',
'typing==3.5.2.2',
]
setup(
name='chalice',
version='0.5.0',
... | <commit_before>#!/usr/bin/env python
from setuptools import setup, find_packages
with open('README.rst') as readme_file:
README = readme_file.read()
install_requires = [
'click==6.2',
'botocore>=1.4.8,<2.0.0',
'virtualenv>=15.0.0,<16.0.0',
'typing==3.5.2.2',
]
setup(
name='chalice',
ve... |
e5e6d4ac9e86aa7e44694cf4746c4c9ec91df107 | setup.py | setup.py | #!/usr/bin/env python
from distutils.core import setup
setup(name = 'skeleton',
version = '0.0',
description = 'A python skeleton project',
long_description = '''
This project represents a basic python skeleton project that can be used as
the basis for other projects. Feel free to fork this project... | #!/usr/bin/env python
from distutils.core import setup
setup(name = 'skeleton',
version = '0.0',
description = 'A python skeleton project',
long_description = '''
This project represents a basic python skeleton project that can be used as
the basis for other projects. Feel free to fork this project... | Move generic lib to botton of config. | Move generic lib to botton of config.
| Python | bsd-2-clause | arlaneenalra/python-skeleton | #!/usr/bin/env python
from distutils.core import setup
setup(name = 'skeleton',
version = '0.0',
description = 'A python skeleton project',
long_description = '''
This project represents a basic python skeleton project that can be used as
the basis for other projects. Feel free to fork this project... | #!/usr/bin/env python
from distutils.core import setup
setup(name = 'skeleton',
version = '0.0',
description = 'A python skeleton project',
long_description = '''
This project represents a basic python skeleton project that can be used as
the basis for other projects. Feel free to fork this project... | <commit_before>#!/usr/bin/env python
from distutils.core import setup
setup(name = 'skeleton',
version = '0.0',
description = 'A python skeleton project',
long_description = '''
This project represents a basic python skeleton project that can be used as
the basis for other projects. Feel free to fo... | #!/usr/bin/env python
from distutils.core import setup
setup(name = 'skeleton',
version = '0.0',
description = 'A python skeleton project',
long_description = '''
This project represents a basic python skeleton project that can be used as
the basis for other projects. Feel free to fork this project... | #!/usr/bin/env python
from distutils.core import setup
setup(name = 'skeleton',
version = '0.0',
description = 'A python skeleton project',
long_description = '''
This project represents a basic python skeleton project that can be used as
the basis for other projects. Feel free to fork this project... | <commit_before>#!/usr/bin/env python
from distutils.core import setup
setup(name = 'skeleton',
version = '0.0',
description = 'A python skeleton project',
long_description = '''
This project represents a basic python skeleton project that can be used as
the basis for other projects. Feel free to fo... |
0ef968528f31da5dd09f016134b4a1ffa6377f84 | scripts/slave/chromium/package_source.py | scripts/slave/chromium/package_source.py | #!/usr/bin/python
# Copyright (c) 2011 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""A tool to package a checkout's source and upload it to Google Storage."""
import sys
if '__main__' == __name__:
sys.exit(0)
| #!/usr/bin/python
# Copyright (c) 2011 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""A tool to package a checkout's source and upload it to Google Storage."""
import os
import sys
from common import chromium_utils
... | Create source snapshot and upload to GS. | Create source snapshot and upload to GS.
BUG=79198
Review URL: http://codereview.chromium.org/7129020
git-svn-id: 239fca9b83025a0b6f823aeeca02ba5be3d9fd76@88372 0039d316-1c4b-4281-b951-d872f2087c98
| Python | bsd-3-clause | eunchong/build,eunchong/build,eunchong/build,eunchong/build | #!/usr/bin/python
# Copyright (c) 2011 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""A tool to package a checkout's source and upload it to Google Storage."""
import sys
if '__main__' == __name__:
sys.exit(0)
Cr... | #!/usr/bin/python
# Copyright (c) 2011 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""A tool to package a checkout's source and upload it to Google Storage."""
import os
import sys
from common import chromium_utils
... | <commit_before>#!/usr/bin/python
# Copyright (c) 2011 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""A tool to package a checkout's source and upload it to Google Storage."""
import sys
if '__main__' == __name__:
... | #!/usr/bin/python
# Copyright (c) 2011 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""A tool to package a checkout's source and upload it to Google Storage."""
import os
import sys
from common import chromium_utils
... | #!/usr/bin/python
# Copyright (c) 2011 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""A tool to package a checkout's source and upload it to Google Storage."""
import sys
if '__main__' == __name__:
sys.exit(0)
Cr... | <commit_before>#!/usr/bin/python
# Copyright (c) 2011 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""A tool to package a checkout's source and upload it to Google Storage."""
import sys
if '__main__' == __name__:
... |
6c8dd596a0f5f84acee54938d2f948f25445327d | src/Scripts/correlation-histogram.py | src/Scripts/correlation-histogram.py | # Take the output of the BitFunnel correlate command and generate histograms.
from collections import defaultdict
import csv
term_term_correlation = defaultdict(int)
term_all_correlation = defaultdict(int)
# TODO: don't hardcode name.
with open("/tmp/Correlate-0.csv") as f:
reader = csv.reader(f)
for row in ... | # Take the output of the BitFunnel correlate command and generate histograms.
from collections import defaultdict
import csv
term_term_correlation = defaultdict(lambda:defaultdict(int))
term_all_correlation = defaultdict(lambda:defaultdict(int))
def bf_correlate_to_dicts(term_term_correlation,
... | Put multple treatments into the same histogram. | Put multple treatments into the same histogram.
| Python | mit | danluu/BitFunnel,BitFunnel/BitFunnel,BitFunnel/BitFunnel,danluu/BitFunnel,danluu/BitFunnel,danluu/BitFunnel,BitFunnel/BitFunnel,BitFunnel/BitFunnel,BitFunnel/BitFunnel,danluu/BitFunnel,BitFunnel/BitFunnel,danluu/BitFunnel | # Take the output of the BitFunnel correlate command and generate histograms.
from collections import defaultdict
import csv
term_term_correlation = defaultdict(int)
term_all_correlation = defaultdict(int)
# TODO: don't hardcode name.
with open("/tmp/Correlate-0.csv") as f:
reader = csv.reader(f)
for row in ... | # Take the output of the BitFunnel correlate command and generate histograms.
from collections import defaultdict
import csv
term_term_correlation = defaultdict(lambda:defaultdict(int))
term_all_correlation = defaultdict(lambda:defaultdict(int))
def bf_correlate_to_dicts(term_term_correlation,
... | <commit_before># Take the output of the BitFunnel correlate command and generate histograms.
from collections import defaultdict
import csv
term_term_correlation = defaultdict(int)
term_all_correlation = defaultdict(int)
# TODO: don't hardcode name.
with open("/tmp/Correlate-0.csv") as f:
reader = csv.reader(f)
... | # Take the output of the BitFunnel correlate command and generate histograms.
from collections import defaultdict
import csv
term_term_correlation = defaultdict(lambda:defaultdict(int))
term_all_correlation = defaultdict(lambda:defaultdict(int))
def bf_correlate_to_dicts(term_term_correlation,
... | # Take the output of the BitFunnel correlate command and generate histograms.
from collections import defaultdict
import csv
term_term_correlation = defaultdict(int)
term_all_correlation = defaultdict(int)
# TODO: don't hardcode name.
with open("/tmp/Correlate-0.csv") as f:
reader = csv.reader(f)
for row in ... | <commit_before># Take the output of the BitFunnel correlate command and generate histograms.
from collections import defaultdict
import csv
term_term_correlation = defaultdict(int)
term_all_correlation = defaultdict(int)
# TODO: don't hardcode name.
with open("/tmp/Correlate-0.csv") as f:
reader = csv.reader(f)
... |
55dc12dcac51109b4974c58252929066ca985569 | sqjobs/contrib/django/djsqjobs/finders.py | sqjobs/contrib/django/djsqjobs/finders.py | from sqjobs.utils import get_jobs_from_module
import logging
logger = logging.getLogger('sqjobs.contrib.django.utils')
def get_apps_names():
"""
copied from django-extensions compatibility sheam
"""
try:
# django >= 1.7, to support AppConfig
from django.apps import apps
return... | from sqjobs.utils import get_jobs_from_module
import logging
logger = logging.getLogger('sqjobs.contrib.django.utils')
def get_apps_names():
"""
copied from django-extensions compatibility sheam
"""
try:
# django >= 1.7, to support AppConfig
from django.apps import apps
return... | Remove 7 characters to get rid of ".models" | Remove 7 characters to get rid of ".models"
| Python | bsd-3-clause | gnufede/sqjobs,gnufede/sqjobs | from sqjobs.utils import get_jobs_from_module
import logging
logger = logging.getLogger('sqjobs.contrib.django.utils')
def get_apps_names():
"""
copied from django-extensions compatibility sheam
"""
try:
# django >= 1.7, to support AppConfig
from django.apps import apps
return... | from sqjobs.utils import get_jobs_from_module
import logging
logger = logging.getLogger('sqjobs.contrib.django.utils')
def get_apps_names():
"""
copied from django-extensions compatibility sheam
"""
try:
# django >= 1.7, to support AppConfig
from django.apps import apps
return... | <commit_before>from sqjobs.utils import get_jobs_from_module
import logging
logger = logging.getLogger('sqjobs.contrib.django.utils')
def get_apps_names():
"""
copied from django-extensions compatibility sheam
"""
try:
# django >= 1.7, to support AppConfig
from django.apps import apps... | from sqjobs.utils import get_jobs_from_module
import logging
logger = logging.getLogger('sqjobs.contrib.django.utils')
def get_apps_names():
"""
copied from django-extensions compatibility sheam
"""
try:
# django >= 1.7, to support AppConfig
from django.apps import apps
return... | from sqjobs.utils import get_jobs_from_module
import logging
logger = logging.getLogger('sqjobs.contrib.django.utils')
def get_apps_names():
"""
copied from django-extensions compatibility sheam
"""
try:
# django >= 1.7, to support AppConfig
from django.apps import apps
return... | <commit_before>from sqjobs.utils import get_jobs_from_module
import logging
logger = logging.getLogger('sqjobs.contrib.django.utils')
def get_apps_names():
"""
copied from django-extensions compatibility sheam
"""
try:
# django >= 1.7, to support AppConfig
from django.apps import apps... |
24f69b587ce38c581f9ee68e22978963b266f010 | html_to_telegraph.py | html_to_telegraph.py | # encoding=utf8
from lxml import html
def _recursive_convert(element):
# All strings outside tags should be ignored
if not isinstance(element, html.HtmlElement):
return
fragment_root_element = {
'_': element.tag
}
content = []
if element.text:
content.append({'t': ele... | # encoding=utf8
from lxml import html
import json
def _recursive_convert(element):
# All strings outside tags should be ignored
fragment_root_element = {
'_': element.tag
}
content = []
if element.text:
content.append({'t': element.text})
if element.attrib:
fragment_... | Return string instead of list | Return string instead of list
| Python | mit | mercuree/html-telegraph-poster | # encoding=utf8
from lxml import html
def _recursive_convert(element):
# All strings outside tags should be ignored
if not isinstance(element, html.HtmlElement):
return
fragment_root_element = {
'_': element.tag
}
content = []
if element.text:
content.append({'t': ele... | # encoding=utf8
from lxml import html
import json
def _recursive_convert(element):
# All strings outside tags should be ignored
fragment_root_element = {
'_': element.tag
}
content = []
if element.text:
content.append({'t': element.text})
if element.attrib:
fragment_... | <commit_before># encoding=utf8
from lxml import html
def _recursive_convert(element):
# All strings outside tags should be ignored
if not isinstance(element, html.HtmlElement):
return
fragment_root_element = {
'_': element.tag
}
content = []
if element.text:
content.a... | # encoding=utf8
from lxml import html
import json
def _recursive_convert(element):
# All strings outside tags should be ignored
fragment_root_element = {
'_': element.tag
}
content = []
if element.text:
content.append({'t': element.text})
if element.attrib:
fragment_... | # encoding=utf8
from lxml import html
def _recursive_convert(element):
# All strings outside tags should be ignored
if not isinstance(element, html.HtmlElement):
return
fragment_root_element = {
'_': element.tag
}
content = []
if element.text:
content.append({'t': ele... | <commit_before># encoding=utf8
from lxml import html
def _recursive_convert(element):
# All strings outside tags should be ignored
if not isinstance(element, html.HtmlElement):
return
fragment_root_element = {
'_': element.tag
}
content = []
if element.text:
content.a... |
962fc49f734b04e717bf936745013ab0c19c4ee1 | utils.py | utils.py | import cv2
import itertools
import numpy as np
def partition(pred, iterable):
"""
Partition the iterable into two disjoint entries based
on the predicate.
@return: Tuple (iterable1, iterable2)
"""
iter1, iter2 = itertools.tee(iterable)
return itertools.filterfalse(pred, iter1), filter(pred, iter2)
def ... | from six.moves import filterfalse
import cv2
import itertools
import numpy as np
def partition(pred, iterable):
"""
Partition the iterable into two disjoint entries based
on the predicate.
@return: Tuple (iterable1, iterable2)
"""
iter1, iter2 = itertools.tee(iterable)
return filterfalse(pred, iter1), ... | Fix python 2.7 compatibility issue | Fix python 2.7 compatibility issue
| Python | mit | viswanathgs/dist-dqn,viswanathgs/dist-dqn | import cv2
import itertools
import numpy as np
def partition(pred, iterable):
"""
Partition the iterable into two disjoint entries based
on the predicate.
@return: Tuple (iterable1, iterable2)
"""
iter1, iter2 = itertools.tee(iterable)
return itertools.filterfalse(pred, iter1), filter(pred, iter2)
def ... | from six.moves import filterfalse
import cv2
import itertools
import numpy as np
def partition(pred, iterable):
"""
Partition the iterable into two disjoint entries based
on the predicate.
@return: Tuple (iterable1, iterable2)
"""
iter1, iter2 = itertools.tee(iterable)
return filterfalse(pred, iter1), ... | <commit_before>import cv2
import itertools
import numpy as np
def partition(pred, iterable):
"""
Partition the iterable into two disjoint entries based
on the predicate.
@return: Tuple (iterable1, iterable2)
"""
iter1, iter2 = itertools.tee(iterable)
return itertools.filterfalse(pred, iter1), filter(pre... | from six.moves import filterfalse
import cv2
import itertools
import numpy as np
def partition(pred, iterable):
"""
Partition the iterable into two disjoint entries based
on the predicate.
@return: Tuple (iterable1, iterable2)
"""
iter1, iter2 = itertools.tee(iterable)
return filterfalse(pred, iter1), ... | import cv2
import itertools
import numpy as np
def partition(pred, iterable):
"""
Partition the iterable into two disjoint entries based
on the predicate.
@return: Tuple (iterable1, iterable2)
"""
iter1, iter2 = itertools.tee(iterable)
return itertools.filterfalse(pred, iter1), filter(pred, iter2)
def ... | <commit_before>import cv2
import itertools
import numpy as np
def partition(pred, iterable):
"""
Partition the iterable into two disjoint entries based
on the predicate.
@return: Tuple (iterable1, iterable2)
"""
iter1, iter2 = itertools.tee(iterable)
return itertools.filterfalse(pred, iter1), filter(pre... |
1016664a5d0285a51455f90d47940b39f77562e4 | src/pretix/base/views/cachedfiles.py | src/pretix/base/views/cachedfiles.py | import os
from django.http import FileResponse, HttpRequest, HttpResponse
from django.shortcuts import get_object_or_404
from django.utils.functional import cached_property
from django.views.generic import TemplateView
from pretix.base.models import CachedFile
class DownloadView(TemplateView):
template_name = "... | import os
from django.http import FileResponse, HttpRequest, HttpResponse
from django.shortcuts import get_object_or_404
from django.utils.functional import cached_property
from django.views.generic import TemplateView
from pretix.base.models import CachedFile
class DownloadView(TemplateView):
template_name = "... | Remove duplicate dot in file downloads | Remove duplicate dot in file downloads
| Python | apache-2.0 | Flamacue/pretix,Flamacue/pretix,Flamacue/pretix,Flamacue/pretix | import os
from django.http import FileResponse, HttpRequest, HttpResponse
from django.shortcuts import get_object_or_404
from django.utils.functional import cached_property
from django.views.generic import TemplateView
from pretix.base.models import CachedFile
class DownloadView(TemplateView):
template_name = "... | import os
from django.http import FileResponse, HttpRequest, HttpResponse
from django.shortcuts import get_object_or_404
from django.utils.functional import cached_property
from django.views.generic import TemplateView
from pretix.base.models import CachedFile
class DownloadView(TemplateView):
template_name = "... | <commit_before>import os
from django.http import FileResponse, HttpRequest, HttpResponse
from django.shortcuts import get_object_or_404
from django.utils.functional import cached_property
from django.views.generic import TemplateView
from pretix.base.models import CachedFile
class DownloadView(TemplateView):
te... | import os
from django.http import FileResponse, HttpRequest, HttpResponse
from django.shortcuts import get_object_or_404
from django.utils.functional import cached_property
from django.views.generic import TemplateView
from pretix.base.models import CachedFile
class DownloadView(TemplateView):
template_name = "... | import os
from django.http import FileResponse, HttpRequest, HttpResponse
from django.shortcuts import get_object_or_404
from django.utils.functional import cached_property
from django.views.generic import TemplateView
from pretix.base.models import CachedFile
class DownloadView(TemplateView):
template_name = "... | <commit_before>import os
from django.http import FileResponse, HttpRequest, HttpResponse
from django.shortcuts import get_object_or_404
from django.utils.functional import cached_property
from django.views.generic import TemplateView
from pretix.base.models import CachedFile
class DownloadView(TemplateView):
te... |
917ba14418f01fa2fc866fc1c18989cc500c2cfd | bin/license_finder_pip.py | bin/license_finder_pip.py | #!/usr/bin/env python
import json
import sys
from pip._internal.req import parse_requirements
from pip._internal.download import PipSession
from pip._vendor import pkg_resources
from pip._vendor.six import print_
requirements = [pkg_resources.Requirement.parse(str(req.req)) for req
in parse_requiremen... | #!/usr/bin/env python
import json
import sys
try:
from pip._internal.req import parse_requirements
except ImportError:
from pip.req import parse_requirements
try:
from pip._internal.download import PipSession
except ImportError:
from pip.download import PipSession
from pip._vendor imp... | Add backwards compatibility with pip v9 | Add backwards compatibility with pip v9 | Python | mit | pivotal/LicenseFinder,pivotal/LicenseFinder,pivotal/LicenseFinder,pivotal/LicenseFinder,pivotal/LicenseFinder,pivotal/LicenseFinder,pivotal/LicenseFinder | #!/usr/bin/env python
import json
import sys
from pip._internal.req import parse_requirements
from pip._internal.download import PipSession
from pip._vendor import pkg_resources
from pip._vendor.six import print_
requirements = [pkg_resources.Requirement.parse(str(req.req)) for req
in parse_requiremen... | #!/usr/bin/env python
import json
import sys
try:
from pip._internal.req import parse_requirements
except ImportError:
from pip.req import parse_requirements
try:
from pip._internal.download import PipSession
except ImportError:
from pip.download import PipSession
from pip._vendor imp... | <commit_before>#!/usr/bin/env python
import json
import sys
from pip._internal.req import parse_requirements
from pip._internal.download import PipSession
from pip._vendor import pkg_resources
from pip._vendor.six import print_
requirements = [pkg_resources.Requirement.parse(str(req.req)) for req
in p... | #!/usr/bin/env python
import json
import sys
try:
from pip._internal.req import parse_requirements
except ImportError:
from pip.req import parse_requirements
try:
from pip._internal.download import PipSession
except ImportError:
from pip.download import PipSession
from pip._vendor imp... | #!/usr/bin/env python
import json
import sys
from pip._internal.req import parse_requirements
from pip._internal.download import PipSession
from pip._vendor import pkg_resources
from pip._vendor.six import print_
requirements = [pkg_resources.Requirement.parse(str(req.req)) for req
in parse_requiremen... | <commit_before>#!/usr/bin/env python
import json
import sys
from pip._internal.req import parse_requirements
from pip._internal.download import PipSession
from pip._vendor import pkg_resources
from pip._vendor.six import print_
requirements = [pkg_resources.Requirement.parse(str(req.req)) for req
in p... |
3ba549b00e4ee8491e9adab7baa36e27edd45fa9 | {{cookiecutter.extension_name}}/setup.py | {{cookiecutter.extension_name}}/setup.py | from setuptools import setup
from setupbase import create_cmdclass, install_npm
cmdclass = create_cmdclass(['js'])
cmdclass['js'] = install_npm()
setup_args = dict(
name = '{{cookiecutter.extension_name}}',
version = '0.18.0',
packages = ['{{cookiecutter.extension_... | from setuptools import setup
from setupbase import create_cmdclass, install_npm
cmdclass = create_cmdclass(['labextension', 'nbextension'])
cmdclass['labextension'] = install_npm('labextension')
cmdclass['nbextension'] = install_npm('nbextension')
setup_args = dict(
name = '{{cookiecutter.extensio... | Create commands for labextension and nbextension | Create commands for labextension and nbextension
| Python | cc0-1.0 | jupyterlab/mimerender-cookiecutter,gnestor/mimerender-cookiecutter,jupyterlab/mimerender-cookiecutter,gnestor/mimerender-cookiecutter | from setuptools import setup
from setupbase import create_cmdclass, install_npm
cmdclass = create_cmdclass(['js'])
cmdclass['js'] = install_npm()
setup_args = dict(
name = '{{cookiecutter.extension_name}}',
version = '0.18.0',
packages = ['{{cookiecutter.extension_... | from setuptools import setup
from setupbase import create_cmdclass, install_npm
cmdclass = create_cmdclass(['labextension', 'nbextension'])
cmdclass['labextension'] = install_npm('labextension')
cmdclass['nbextension'] = install_npm('nbextension')
setup_args = dict(
name = '{{cookiecutter.extensio... | <commit_before>from setuptools import setup
from setupbase import create_cmdclass, install_npm
cmdclass = create_cmdclass(['js'])
cmdclass['js'] = install_npm()
setup_args = dict(
name = '{{cookiecutter.extension_name}}',
version = '0.18.0',
packages = ['{{cookiecu... | from setuptools import setup
from setupbase import create_cmdclass, install_npm
cmdclass = create_cmdclass(['labextension', 'nbextension'])
cmdclass['labextension'] = install_npm('labextension')
cmdclass['nbextension'] = install_npm('nbextension')
setup_args = dict(
name = '{{cookiecutter.extensio... | from setuptools import setup
from setupbase import create_cmdclass, install_npm
cmdclass = create_cmdclass(['js'])
cmdclass['js'] = install_npm()
setup_args = dict(
name = '{{cookiecutter.extension_name}}',
version = '0.18.0',
packages = ['{{cookiecutter.extension_... | <commit_before>from setuptools import setup
from setupbase import create_cmdclass, install_npm
cmdclass = create_cmdclass(['js'])
cmdclass['js'] = install_npm()
setup_args = dict(
name = '{{cookiecutter.extension_name}}',
version = '0.18.0',
packages = ['{{cookiecu... |
9d5300f6688038ca59b07ed4033c8768658377c6 | examples/prompts/multi-column-autocompletion-with-meta.py | examples/prompts/multi-column-autocompletion-with-meta.py | #!/usr/bin/env python
"""
Autocompletion example that shows meta-information alongside the completions.
"""
from __future__ import unicode_literals
from prompt_toolkit.contrib.completers import WordCompleter
from prompt_toolkit import prompt
animal_completer = WordCompleter([
'alligator',
'ant',
'ape',
... | #!/usr/bin/env python
"""
Autocompletion example that shows meta-information alongside the completions.
"""
from __future__ import unicode_literals
from prompt_toolkit.contrib.completers import WordCompleter
from prompt_toolkit import prompt
animal_completer = WordCompleter([
'alligator',
'ant',
'ape',
... | Fix typo: `dolphine` -> `dolphin` | Fix typo: `dolphine` -> `dolphin`
| Python | bsd-3-clause | jonathanslenders/python-prompt-toolkit | #!/usr/bin/env python
"""
Autocompletion example that shows meta-information alongside the completions.
"""
from __future__ import unicode_literals
from prompt_toolkit.contrib.completers import WordCompleter
from prompt_toolkit import prompt
animal_completer = WordCompleter([
'alligator',
'ant',
'ape',
... | #!/usr/bin/env python
"""
Autocompletion example that shows meta-information alongside the completions.
"""
from __future__ import unicode_literals
from prompt_toolkit.contrib.completers import WordCompleter
from prompt_toolkit import prompt
animal_completer = WordCompleter([
'alligator',
'ant',
'ape',
... | <commit_before>#!/usr/bin/env python
"""
Autocompletion example that shows meta-information alongside the completions.
"""
from __future__ import unicode_literals
from prompt_toolkit.contrib.completers import WordCompleter
from prompt_toolkit import prompt
animal_completer = WordCompleter([
'alligator',
'ant... | #!/usr/bin/env python
"""
Autocompletion example that shows meta-information alongside the completions.
"""
from __future__ import unicode_literals
from prompt_toolkit.contrib.completers import WordCompleter
from prompt_toolkit import prompt
animal_completer = WordCompleter([
'alligator',
'ant',
'ape',
... | #!/usr/bin/env python
"""
Autocompletion example that shows meta-information alongside the completions.
"""
from __future__ import unicode_literals
from prompt_toolkit.contrib.completers import WordCompleter
from prompt_toolkit import prompt
animal_completer = WordCompleter([
'alligator',
'ant',
'ape',
... | <commit_before>#!/usr/bin/env python
"""
Autocompletion example that shows meta-information alongside the completions.
"""
from __future__ import unicode_literals
from prompt_toolkit.contrib.completers import WordCompleter
from prompt_toolkit import prompt
animal_completer = WordCompleter([
'alligator',
'ant... |
973c6a541deadb5a4b7c23dae191acf9d4c1be27 | buffer/tests/test_link.py | buffer/tests/test_link.py | from nose.tools import eq_, raises
from mock import MagicMock, patch
from buffer.models.link import Link
def test_links_shares():
'''
Test link's shares retrieving from constructor
'''
mocked_api = MagicMock()
mocked_api.get.return_value = {'shares': 123}
link = Link(api=mocked_api, url='www.google.co... | from nose.tools import eq_, raises
from mock import MagicMock, patch
from buffer.models.link import Link
def test_links_shares():
'''
Test link's shares retrieving from constructor
'''
mocked_api = MagicMock()
mocked_api.get.return_value = {'shares': 123}
link = Link(api=mocked_api, url='www.google.co... | Test link's shares retrieving using get_share method | Test link's shares retrieving using get_share method
| Python | mit | bufferapp/buffer-python,vtemian/buffpy | from nose.tools import eq_, raises
from mock import MagicMock, patch
from buffer.models.link import Link
def test_links_shares():
'''
Test link's shares retrieving from constructor
'''
mocked_api = MagicMock()
mocked_api.get.return_value = {'shares': 123}
link = Link(api=mocked_api, url='www.google.co... | from nose.tools import eq_, raises
from mock import MagicMock, patch
from buffer.models.link import Link
def test_links_shares():
'''
Test link's shares retrieving from constructor
'''
mocked_api = MagicMock()
mocked_api.get.return_value = {'shares': 123}
link = Link(api=mocked_api, url='www.google.co... | <commit_before>from nose.tools import eq_, raises
from mock import MagicMock, patch
from buffer.models.link import Link
def test_links_shares():
'''
Test link's shares retrieving from constructor
'''
mocked_api = MagicMock()
mocked_api.get.return_value = {'shares': 123}
link = Link(api=mocked_api, url... | from nose.tools import eq_, raises
from mock import MagicMock, patch
from buffer.models.link import Link
def test_links_shares():
'''
Test link's shares retrieving from constructor
'''
mocked_api = MagicMock()
mocked_api.get.return_value = {'shares': 123}
link = Link(api=mocked_api, url='www.google.co... | from nose.tools import eq_, raises
from mock import MagicMock, patch
from buffer.models.link import Link
def test_links_shares():
'''
Test link's shares retrieving from constructor
'''
mocked_api = MagicMock()
mocked_api.get.return_value = {'shares': 123}
link = Link(api=mocked_api, url='www.google.co... | <commit_before>from nose.tools import eq_, raises
from mock import MagicMock, patch
from buffer.models.link import Link
def test_links_shares():
'''
Test link's shares retrieving from constructor
'''
mocked_api = MagicMock()
mocked_api.get.return_value = {'shares': 123}
link = Link(api=mocked_api, url... |
fbf42c288a6faa13ac918047eac09985cbd6f6e0 | cal/v1/network/drivers/openstack_network.py | cal/v1/network/drivers/openstack_network.py | """ OpenstackDriver for Network
based on NetworkDriver
"""
from neutronclient.v2_0 import client
from network_driver import NetworkDriver
class OpenstackNetWorkDriver(NetworkDriver):
"""docstring for OpenstackNetWorkDriver"""
def __init__(self, auth_url, project_name,
username, password... | """ OpenstackDriver for Network
based on NetworkDriver
"""
from neutronclient.v2_0 import client
from network_driver import NetworkDriver
class OpenstackNetWorkDriver(NetworkDriver):
"""docstring for OpenstackNetWorkDriver"""
def __init__(self, auth_url, project_name,
username, passwor... | Add neutron client without test | Add neutron client without test
| Python | apache-2.0 | cloudcomputinghust/CAL | """ OpenstackDriver for Network
based on NetworkDriver
"""
from neutronclient.v2_0 import client
from network_driver import NetworkDriver
class OpenstackNetWorkDriver(NetworkDriver):
"""docstring for OpenstackNetWorkDriver"""
def __init__(self, auth_url, project_name,
username, password... | """ OpenstackDriver for Network
based on NetworkDriver
"""
from neutronclient.v2_0 import client
from network_driver import NetworkDriver
class OpenstackNetWorkDriver(NetworkDriver):
"""docstring for OpenstackNetWorkDriver"""
def __init__(self, auth_url, project_name,
username, passwor... | <commit_before>""" OpenstackDriver for Network
based on NetworkDriver
"""
from neutronclient.v2_0 import client
from network_driver import NetworkDriver
class OpenstackNetWorkDriver(NetworkDriver):
"""docstring for OpenstackNetWorkDriver"""
def __init__(self, auth_url, project_name,
use... | """ OpenstackDriver for Network
based on NetworkDriver
"""
from neutronclient.v2_0 import client
from network_driver import NetworkDriver
class OpenstackNetWorkDriver(NetworkDriver):
"""docstring for OpenstackNetWorkDriver"""
def __init__(self, auth_url, project_name,
username, passwor... | """ OpenstackDriver for Network
based on NetworkDriver
"""
from neutronclient.v2_0 import client
from network_driver import NetworkDriver
class OpenstackNetWorkDriver(NetworkDriver):
"""docstring for OpenstackNetWorkDriver"""
def __init__(self, auth_url, project_name,
username, password... | <commit_before>""" OpenstackDriver for Network
based on NetworkDriver
"""
from neutronclient.v2_0 import client
from network_driver import NetworkDriver
class OpenstackNetWorkDriver(NetworkDriver):
"""docstring for OpenstackNetWorkDriver"""
def __init__(self, auth_url, project_name,
use... |
10ae884bd68feca56b3893b84221b867f3b0aec3 | orangecontrib/text/vectorization/base.py | orangecontrib/text/vectorization/base.py | import numpy as np
from gensim import matutils
from gensim.corpora import Dictionary
class BaseVectorizer:
"""Base class for vectorization objects. """
name = NotImplemented
def transform(self, corpus, copy=True):
"""Transforms a corpus to a new one with additional attributes. """
if copy... | import numpy as np
from gensim import matutils
from gensim.corpora import Dictionary
class BaseVectorizer:
"""Base class for vectorization objects. """
name = NotImplemented
def transform(self, corpus, copy=True):
"""Transforms a corpus to a new one with additional attributes. """
if copy... | Mark features to skip normalization | BoW: Mark features to skip normalization
This fixes SVM on sparse data.
| Python | bsd-2-clause | cheral/orange3-text,cheral/orange3-text,cheral/orange3-text | import numpy as np
from gensim import matutils
from gensim.corpora import Dictionary
class BaseVectorizer:
"""Base class for vectorization objects. """
name = NotImplemented
def transform(self, corpus, copy=True):
"""Transforms a corpus to a new one with additional attributes. """
if copy... | import numpy as np
from gensim import matutils
from gensim.corpora import Dictionary
class BaseVectorizer:
"""Base class for vectorization objects. """
name = NotImplemented
def transform(self, corpus, copy=True):
"""Transforms a corpus to a new one with additional attributes. """
if copy... | <commit_before>import numpy as np
from gensim import matutils
from gensim.corpora import Dictionary
class BaseVectorizer:
"""Base class for vectorization objects. """
name = NotImplemented
def transform(self, corpus, copy=True):
"""Transforms a corpus to a new one with additional attributes. """
... | import numpy as np
from gensim import matutils
from gensim.corpora import Dictionary
class BaseVectorizer:
"""Base class for vectorization objects. """
name = NotImplemented
def transform(self, corpus, copy=True):
"""Transforms a corpus to a new one with additional attributes. """
if copy... | import numpy as np
from gensim import matutils
from gensim.corpora import Dictionary
class BaseVectorizer:
"""Base class for vectorization objects. """
name = NotImplemented
def transform(self, corpus, copy=True):
"""Transforms a corpus to a new one with additional attributes. """
if copy... | <commit_before>import numpy as np
from gensim import matutils
from gensim.corpora import Dictionary
class BaseVectorizer:
"""Base class for vectorization objects. """
name = NotImplemented
def transform(self, corpus, copy=True):
"""Transforms a corpus to a new one with additional attributes. """
... |
2d6babf3bf6107b8a5c42fe76a4d17d7fa0b51f6 | catkin/src/statistics/scripts/listener.py | catkin/src/statistics/scripts/listener.py | #!/usr/bin/env python
import rospy
import socket
from statistics.msg import StatsD
class StatsHandler():
def __init__(self, statsd_host, statsd_port):
self.statsd_target = (statsd_host, statsd_port)
self.sock = socket.socket(
socket.AF_INET,
socket.SOCK_DGRAM
)
def _send_msg(self, statsd_... | #!/usr/bin/env python
import rospy
import socket
from statistics.msg import StatsD
class StatsDHandler():
def __init__(self, statsd_host, statsd_port):
self.statsd_target = (statsd_host, statsd_port)
self.sock = socket.socket(
socket.AF_INET,
socket.SOCK_DGRAM
)
def _send_msg(self, statsd... | Rename statistics handler to be more specific | Rename statistics handler to be more specific
| Python | apache-2.0 | EndPointCorp/appctl,EndPointCorp/appctl | #!/usr/bin/env python
import rospy
import socket
from statistics.msg import StatsD
class StatsHandler():
def __init__(self, statsd_host, statsd_port):
self.statsd_target = (statsd_host, statsd_port)
self.sock = socket.socket(
socket.AF_INET,
socket.SOCK_DGRAM
)
def _send_msg(self, statsd_... | #!/usr/bin/env python
import rospy
import socket
from statistics.msg import StatsD
class StatsDHandler():
def __init__(self, statsd_host, statsd_port):
self.statsd_target = (statsd_host, statsd_port)
self.sock = socket.socket(
socket.AF_INET,
socket.SOCK_DGRAM
)
def _send_msg(self, statsd... | <commit_before>#!/usr/bin/env python
import rospy
import socket
from statistics.msg import StatsD
class StatsHandler():
def __init__(self, statsd_host, statsd_port):
self.statsd_target = (statsd_host, statsd_port)
self.sock = socket.socket(
socket.AF_INET,
socket.SOCK_DGRAM
)
def _send_ms... | #!/usr/bin/env python
import rospy
import socket
from statistics.msg import StatsD
class StatsDHandler():
def __init__(self, statsd_host, statsd_port):
self.statsd_target = (statsd_host, statsd_port)
self.sock = socket.socket(
socket.AF_INET,
socket.SOCK_DGRAM
)
def _send_msg(self, statsd... | #!/usr/bin/env python
import rospy
import socket
from statistics.msg import StatsD
class StatsHandler():
def __init__(self, statsd_host, statsd_port):
self.statsd_target = (statsd_host, statsd_port)
self.sock = socket.socket(
socket.AF_INET,
socket.SOCK_DGRAM
)
def _send_msg(self, statsd_... | <commit_before>#!/usr/bin/env python
import rospy
import socket
from statistics.msg import StatsD
class StatsHandler():
def __init__(self, statsd_host, statsd_port):
self.statsd_target = (statsd_host, statsd_port)
self.sock = socket.socket(
socket.AF_INET,
socket.SOCK_DGRAM
)
def _send_ms... |
01059774f04d26b69a1ddc058416f627da396a58 | src/tempel/models.py | src/tempel/models.py | from django.db import models
from django.conf import settings
from tempel import utils
class Entry(models.Model):
content = models.TextField()
language = models.CharField(max_length=20,
choices=utils.get_languages())
created = models.DateTimeField(auto_now_add=True)
act... | from datetime import datetime
from django.db import models
from django.conf import settings
from tempel import utils
class Entry(models.Model):
content = models.TextField()
language = models.CharField(max_length=20,
choices=utils.get_languages())
created = models.DateTimeF... | Replace Entry's created's auto_now_add=True with default=datetime.now | Replace Entry's created's auto_now_add=True with default=datetime.now
| Python | agpl-3.0 | fajran/tempel | from django.db import models
from django.conf import settings
from tempel import utils
class Entry(models.Model):
content = models.TextField()
language = models.CharField(max_length=20,
choices=utils.get_languages())
created = models.DateTimeField(auto_now_add=True)
act... | from datetime import datetime
from django.db import models
from django.conf import settings
from tempel import utils
class Entry(models.Model):
content = models.TextField()
language = models.CharField(max_length=20,
choices=utils.get_languages())
created = models.DateTimeF... | <commit_before>from django.db import models
from django.conf import settings
from tempel import utils
class Entry(models.Model):
content = models.TextField()
language = models.CharField(max_length=20,
choices=utils.get_languages())
created = models.DateTimeField(auto_now_ad... | from datetime import datetime
from django.db import models
from django.conf import settings
from tempel import utils
class Entry(models.Model):
content = models.TextField()
language = models.CharField(max_length=20,
choices=utils.get_languages())
created = models.DateTimeF... | from django.db import models
from django.conf import settings
from tempel import utils
class Entry(models.Model):
content = models.TextField()
language = models.CharField(max_length=20,
choices=utils.get_languages())
created = models.DateTimeField(auto_now_add=True)
act... | <commit_before>from django.db import models
from django.conf import settings
from tempel import utils
class Entry(models.Model):
content = models.TextField()
language = models.CharField(max_length=20,
choices=utils.get_languages())
created = models.DateTimeField(auto_now_ad... |
9a061d7b13482046509c6c231b0018a600cb9155 | tests/__init__.py | tests/__init__.py | import os
NOSQL = any([name in (os.getenv("DB") or "")
for name in ("datastore", "mongodb", "imap")])
if NOSQL:
from test_dal_nosql import *
else:
from sql import *
| import os
NOSQL = any([name in (os.getenv("DB") or "")
for name in ("datastore", "mongodb", "imap")])
if NOSQL:
from nosql import *
else:
from sql import *
| Fix wrong import in tests | Fix wrong import in tests
| Python | bsd-3-clause | niphlod/pydal,willimoa/pydal,kmcheung12/pydal,manuelep/pydal,stephenrauch/pydal,michele-comitini/pydal,web2py/pydal | import os
NOSQL = any([name in (os.getenv("DB") or "")
for name in ("datastore", "mongodb", "imap")])
if NOSQL:
from test_dal_nosql import *
else:
from sql import *
Fix wrong import in tests | import os
NOSQL = any([name in (os.getenv("DB") or "")
for name in ("datastore", "mongodb", "imap")])
if NOSQL:
from nosql import *
else:
from sql import *
| <commit_before>import os
NOSQL = any([name in (os.getenv("DB") or "")
for name in ("datastore", "mongodb", "imap")])
if NOSQL:
from test_dal_nosql import *
else:
from sql import *
<commit_msg>Fix wrong import in tests<commit_after> | import os
NOSQL = any([name in (os.getenv("DB") or "")
for name in ("datastore", "mongodb", "imap")])
if NOSQL:
from nosql import *
else:
from sql import *
| import os
NOSQL = any([name in (os.getenv("DB") or "")
for name in ("datastore", "mongodb", "imap")])
if NOSQL:
from test_dal_nosql import *
else:
from sql import *
Fix wrong import in testsimport os
NOSQL = any([name in (os.getenv("DB") or "")
for name in ("datastore", "mongodb", "im... | <commit_before>import os
NOSQL = any([name in (os.getenv("DB") or "")
for name in ("datastore", "mongodb", "imap")])
if NOSQL:
from test_dal_nosql import *
else:
from sql import *
<commit_msg>Fix wrong import in tests<commit_after>import os
NOSQL = any([name in (os.getenv("DB") or "")
... |
5ebe17f5dc88fef7718d2c3665b905cc8d7fab7c | alembic/versions/147d1de2e5e4_add_periodicity_of_script.py | alembic/versions/147d1de2e5e4_add_periodicity_of_script.py | """Add periodicity of script
Revision ID: 147d1de2e5e4
Revises:
Create Date: 2019-04-19 18:48:33.526449
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '147d1de2e5e4'
down_revision = None
branch_labels = None
depends_on = None
def upgrade():
op.add_colum... | """Add periodicity of script
Revision ID: 147d1de2e5e4
Revises:
Create Date: 2019-04-19 18:48:33.526449
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '147d1de2e5e4'
down_revision = None
branch_labels = None
depends_on = None
def upgrade():
op.add_colum... | Handle downgrade on a sqlite db | Handle downgrade on a sqlite db
| Python | mit | e-henry/scripto,e-henry/scripto,e-henry/scripto,e-henry/scripto | """Add periodicity of script
Revision ID: 147d1de2e5e4
Revises:
Create Date: 2019-04-19 18:48:33.526449
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '147d1de2e5e4'
down_revision = None
branch_labels = None
depends_on = None
def upgrade():
op.add_colum... | """Add periodicity of script
Revision ID: 147d1de2e5e4
Revises:
Create Date: 2019-04-19 18:48:33.526449
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '147d1de2e5e4'
down_revision = None
branch_labels = None
depends_on = None
def upgrade():
op.add_colum... | <commit_before>"""Add periodicity of script
Revision ID: 147d1de2e5e4
Revises:
Create Date: 2019-04-19 18:48:33.526449
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '147d1de2e5e4'
down_revision = None
branch_labels = None
depends_on = None
def upgrade():
... | """Add periodicity of script
Revision ID: 147d1de2e5e4
Revises:
Create Date: 2019-04-19 18:48:33.526449
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '147d1de2e5e4'
down_revision = None
branch_labels = None
depends_on = None
def upgrade():
op.add_colum... | """Add periodicity of script
Revision ID: 147d1de2e5e4
Revises:
Create Date: 2019-04-19 18:48:33.526449
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '147d1de2e5e4'
down_revision = None
branch_labels = None
depends_on = None
def upgrade():
op.add_colum... | <commit_before>"""Add periodicity of script
Revision ID: 147d1de2e5e4
Revises:
Create Date: 2019-04-19 18:48:33.526449
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '147d1de2e5e4'
down_revision = None
branch_labels = None
depends_on = None
def upgrade():
... |
83c64e096ff8b79e2ae22edbcabb483dcf27302f | tests/conftest.py | tests/conftest.py | import pytest
@pytest.fixture(autouse=True)
def platform(request):
marker = request.node.get_marker('platform')
if marker:
expected = marker.args[0]
minion = request.getfuncargvalue('minion')
platform = minion['container'].get_os_release()['ID']
action = marker.kwargs.get('acti... | import pytest
@pytest.fixture(autouse=True)
def platform(request):
marker = request.node.get_marker('platform')
if marker:
expected = marker.args[0]
minion = request.getfuncargvalue('minion')
os_release = minion['container'].get_os_release()
platform = os_release.get('ID', 'sle... | Fix platform detection for sles <12 | Fix platform detection for sles <12
| Python | mit | dincamihai/salt-toaster,dincamihai/salt-toaster | import pytest
@pytest.fixture(autouse=True)
def platform(request):
marker = request.node.get_marker('platform')
if marker:
expected = marker.args[0]
minion = request.getfuncargvalue('minion')
platform = minion['container'].get_os_release()['ID']
action = marker.kwargs.get('acti... | import pytest
@pytest.fixture(autouse=True)
def platform(request):
marker = request.node.get_marker('platform')
if marker:
expected = marker.args[0]
minion = request.getfuncargvalue('minion')
os_release = minion['container'].get_os_release()
platform = os_release.get('ID', 'sle... | <commit_before>import pytest
@pytest.fixture(autouse=True)
def platform(request):
marker = request.node.get_marker('platform')
if marker:
expected = marker.args[0]
minion = request.getfuncargvalue('minion')
platform = minion['container'].get_os_release()['ID']
action = marker.k... | import pytest
@pytest.fixture(autouse=True)
def platform(request):
marker = request.node.get_marker('platform')
if marker:
expected = marker.args[0]
minion = request.getfuncargvalue('minion')
os_release = minion['container'].get_os_release()
platform = os_release.get('ID', 'sle... | import pytest
@pytest.fixture(autouse=True)
def platform(request):
marker = request.node.get_marker('platform')
if marker:
expected = marker.args[0]
minion = request.getfuncargvalue('minion')
platform = minion['container'].get_os_release()['ID']
action = marker.kwargs.get('acti... | <commit_before>import pytest
@pytest.fixture(autouse=True)
def platform(request):
marker = request.node.get_marker('platform')
if marker:
expected = marker.args[0]
minion = request.getfuncargvalue('minion')
platform = minion['container'].get_os_release()['ID']
action = marker.k... |
c5a0f1f26d2527f49ec00d842ffd56be5f0a9965 | detect/findIgnoreLists.py | detect/findIgnoreLists.py | #!/usr/bin/env python
import os
THIS_SCRIPT_DIRECTORY = os.path.dirname(os.path.abspath(__file__))
THIS_REPO_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir))
REPO_PARENT_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir, os.pardir))
# Lets us combine ignore lists:
# from pr... | #!/usr/bin/env python
import os
THIS_SCRIPT_DIRECTORY = os.path.dirname(os.path.abspath(__file__))
THIS_REPO_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir))
REPO_PARENT_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir, os.pardir))
# Lets us combine ignore lists:
# from pr... | Stop looking in the old fuzzing/ directory | Stop looking in the old fuzzing/ directory
| Python | mpl-2.0 | nth10sd/funfuzz,MozillaSecurity/funfuzz,MozillaSecurity/funfuzz,nth10sd/funfuzz,MozillaSecurity/funfuzz,nth10sd/funfuzz | #!/usr/bin/env python
import os
THIS_SCRIPT_DIRECTORY = os.path.dirname(os.path.abspath(__file__))
THIS_REPO_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir))
REPO_PARENT_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir, os.pardir))
# Lets us combine ignore lists:
# from pr... | #!/usr/bin/env python
import os
THIS_SCRIPT_DIRECTORY = os.path.dirname(os.path.abspath(__file__))
THIS_REPO_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir))
REPO_PARENT_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir, os.pardir))
# Lets us combine ignore lists:
# from pr... | <commit_before>#!/usr/bin/env python
import os
THIS_SCRIPT_DIRECTORY = os.path.dirname(os.path.abspath(__file__))
THIS_REPO_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir))
REPO_PARENT_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir, os.pardir))
# Lets us combine ignore lis... | #!/usr/bin/env python
import os
THIS_SCRIPT_DIRECTORY = os.path.dirname(os.path.abspath(__file__))
THIS_REPO_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir))
REPO_PARENT_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir, os.pardir))
# Lets us combine ignore lists:
# from pr... | #!/usr/bin/env python
import os
THIS_SCRIPT_DIRECTORY = os.path.dirname(os.path.abspath(__file__))
THIS_REPO_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir))
REPO_PARENT_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir, os.pardir))
# Lets us combine ignore lists:
# from pr... | <commit_before>#!/usr/bin/env python
import os
THIS_SCRIPT_DIRECTORY = os.path.dirname(os.path.abspath(__file__))
THIS_REPO_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir))
REPO_PARENT_PATH = os.path.abspath(os.path.join(THIS_SCRIPT_DIRECTORY, os.pardir, os.pardir))
# Lets us combine ignore lis... |
f182bb2dd76483891148476b14ccad08a596b080 | tests/test_lesson_4_temperature.py | tests/test_lesson_4_temperature.py | import unittest
from lessons.lesson_4_temperature import temperature
class CtoFTestCase(unittest.TestCase):
def test_handles_freezing_point(self):
freezing = temperature.c_to_f(0)
self.assertEqual(freezing, 32)
def test_handles_boiling_point(self):
boiling = temperature.c_to_f(100)
... | Add tests for temperature conversions in lesson 4. | Add tests for temperature conversions in lesson 4.
| Python | mit | thejessleigh/test_driven_python,thejessleigh/test_driven_python,thejessleigh/test_driven_python | Add tests for temperature conversions in lesson 4. | import unittest
from lessons.lesson_4_temperature import temperature
class CtoFTestCase(unittest.TestCase):
def test_handles_freezing_point(self):
freezing = temperature.c_to_f(0)
self.assertEqual(freezing, 32)
def test_handles_boiling_point(self):
boiling = temperature.c_to_f(100)
... | <commit_before><commit_msg>Add tests for temperature conversions in lesson 4.<commit_after> | import unittest
from lessons.lesson_4_temperature import temperature
class CtoFTestCase(unittest.TestCase):
def test_handles_freezing_point(self):
freezing = temperature.c_to_f(0)
self.assertEqual(freezing, 32)
def test_handles_boiling_point(self):
boiling = temperature.c_to_f(100)
... | Add tests for temperature conversions in lesson 4.import unittest
from lessons.lesson_4_temperature import temperature
class CtoFTestCase(unittest.TestCase):
def test_handles_freezing_point(self):
freezing = temperature.c_to_f(0)
self.assertEqual(freezing, 32)
def test_handles_boiling_point(... | <commit_before><commit_msg>Add tests for temperature conversions in lesson 4.<commit_after>import unittest
from lessons.lesson_4_temperature import temperature
class CtoFTestCase(unittest.TestCase):
def test_handles_freezing_point(self):
freezing = temperature.c_to_f(0)
self.assertEqual(freezing,... | |
72c00dca2c8310744c424296d8f712909bc95b95 | infosystem/subsystem/capability/entity.py | infosystem/subsystem/capability/entity.py | # Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under t... | # Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under t... | Fix unique contraint in capability | Fix unique contraint in capability
| Python | apache-2.0 | samueldmq/infosystem | # Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under t... | # Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under t... | <commit_before># Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# dist... | # Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under t... | # Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under t... | <commit_before># Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# dist... |
93c6a89bd6f0d8ff9a32e37d4f6e9c4ed0aa3f8f | openedx/core/djangoapps/schedules/apps.py | openedx/core/djangoapps/schedules/apps.py | from django.apps import AppConfig
from django.utils.translation import ugettext_lazy as _
class SchedulesConfig(AppConfig):
name = 'openedx.core.djangoapps.schedules'
verbose_name = _('Schedules')
def ready(self):
# noinspection PyUnresolvedReferences
from . import signals, tasks # pylin... | from django.apps import AppConfig
from django.utils.translation import ugettext_lazy as _
class SchedulesConfig(AppConfig):
name = 'openedx.core.djangoapps.schedules'
verbose_name = _('Schedules')
plugin_app = {}
def ready(self):
# noinspection PyUnresolvedReferences
from . import si... | Update schedules app to be a Django App Plugin | Update schedules app to be a Django App Plugin
| Python | agpl-3.0 | EDUlib/edx-platform,ahmedaljazzar/edx-platform,procangroup/edx-platform,gsehub/edx-platform,edx/edx-platform,stvstnfrd/edx-platform,teltek/edx-platform,ahmedaljazzar/edx-platform,angelapper/edx-platform,EDUlib/edx-platform,ahmedaljazzar/edx-platform,kmoocdev2/edx-platform,appsembler/edx-platform,msegado/edx-platform,cp... | from django.apps import AppConfig
from django.utils.translation import ugettext_lazy as _
class SchedulesConfig(AppConfig):
name = 'openedx.core.djangoapps.schedules'
verbose_name = _('Schedules')
def ready(self):
# noinspection PyUnresolvedReferences
from . import signals, tasks # pylin... | from django.apps import AppConfig
from django.utils.translation import ugettext_lazy as _
class SchedulesConfig(AppConfig):
name = 'openedx.core.djangoapps.schedules'
verbose_name = _('Schedules')
plugin_app = {}
def ready(self):
# noinspection PyUnresolvedReferences
from . import si... | <commit_before>from django.apps import AppConfig
from django.utils.translation import ugettext_lazy as _
class SchedulesConfig(AppConfig):
name = 'openedx.core.djangoapps.schedules'
verbose_name = _('Schedules')
def ready(self):
# noinspection PyUnresolvedReferences
from . import signals,... | from django.apps import AppConfig
from django.utils.translation import ugettext_lazy as _
class SchedulesConfig(AppConfig):
name = 'openedx.core.djangoapps.schedules'
verbose_name = _('Schedules')
plugin_app = {}
def ready(self):
# noinspection PyUnresolvedReferences
from . import si... | from django.apps import AppConfig
from django.utils.translation import ugettext_lazy as _
class SchedulesConfig(AppConfig):
name = 'openedx.core.djangoapps.schedules'
verbose_name = _('Schedules')
def ready(self):
# noinspection PyUnresolvedReferences
from . import signals, tasks # pylin... | <commit_before>from django.apps import AppConfig
from django.utils.translation import ugettext_lazy as _
class SchedulesConfig(AppConfig):
name = 'openedx.core.djangoapps.schedules'
verbose_name = _('Schedules')
def ready(self):
# noinspection PyUnresolvedReferences
from . import signals,... |
ca6a758f525c741f277e7e7be115b5b9d20fa5c1 | openxc/tools/dump.py | openxc/tools/dump.py | """
This module contains the methods for the ``openxc-dump`` command line program.
`main` is executed when ``openxc-dump`` is run, and all other callables in this
module are internal only.
"""
from __future__ import absolute_import
import argparse
import time
from openxc.formats.json import JsonFormatter
from .commo... | """
This module contains the methods for the ``openxc-dump`` command line program.
`main` is executed when ``openxc-dump`` is run, and all other callables in this
module are internal only.
"""
from __future__ import absolute_import
import argparse
import time
from openxc.formats.json import JsonFormatter
from .commo... | Remove a resolved TODO - trace file formats now standardized. | Remove a resolved TODO - trace file formats now standardized.
| Python | bsd-3-clause | openxc/openxc-python,openxc/openxc-python,openxc/openxc-python | """
This module contains the methods for the ``openxc-dump`` command line program.
`main` is executed when ``openxc-dump`` is run, and all other callables in this
module are internal only.
"""
from __future__ import absolute_import
import argparse
import time
from openxc.formats.json import JsonFormatter
from .commo... | """
This module contains the methods for the ``openxc-dump`` command line program.
`main` is executed when ``openxc-dump`` is run, and all other callables in this
module are internal only.
"""
from __future__ import absolute_import
import argparse
import time
from openxc.formats.json import JsonFormatter
from .commo... | <commit_before>"""
This module contains the methods for the ``openxc-dump`` command line program.
`main` is executed when ``openxc-dump`` is run, and all other callables in this
module are internal only.
"""
from __future__ import absolute_import
import argparse
import time
from openxc.formats.json import JsonFormat... | """
This module contains the methods for the ``openxc-dump`` command line program.
`main` is executed when ``openxc-dump`` is run, and all other callables in this
module are internal only.
"""
from __future__ import absolute_import
import argparse
import time
from openxc.formats.json import JsonFormatter
from .commo... | """
This module contains the methods for the ``openxc-dump`` command line program.
`main` is executed when ``openxc-dump`` is run, and all other callables in this
module are internal only.
"""
from __future__ import absolute_import
import argparse
import time
from openxc.formats.json import JsonFormatter
from .commo... | <commit_before>"""
This module contains the methods for the ``openxc-dump`` command line program.
`main` is executed when ``openxc-dump`` is run, and all other callables in this
module are internal only.
"""
from __future__ import absolute_import
import argparse
import time
from openxc.formats.json import JsonFormat... |
b07037277b28f80aaa6d6f74d6f79d4146b5ee23 | oshi_rest_server/oshi_rest_server/urls.py | oshi_rest_server/oshi_rest_server/urls.py | from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'oshi_rest_server.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^admin/', include(admin.site.urls)),
)
| from django.conf.urls import patterns, include, url
from django.contrib import admin
from rest_framework import routers
admin.autodiscover()
urlpatterns = patterns('',
url(r'^', include(routers.urls)),
url(r'^admin/', include(admin.site.urls)),
url... | Configure Django REST framework URLs | Configure Django REST framework URLs
| Python | isc | ferrarimarco/OSHI-REST-server,ferrarimarco/OSHI-REST-server | from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'oshi_rest_server.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^admin/', include(admin.site.urls)),
)
Configure Dja... | from django.conf.urls import patterns, include, url
from django.contrib import admin
from rest_framework import routers
admin.autodiscover()
urlpatterns = patterns('',
url(r'^', include(routers.urls)),
url(r'^admin/', include(admin.site.urls)),
url... | <commit_before>from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'oshi_rest_server.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^admin/', include(admin.site.urls)),
... | from django.conf.urls import patterns, include, url
from django.contrib import admin
from rest_framework import routers
admin.autodiscover()
urlpatterns = patterns('',
url(r'^', include(routers.urls)),
url(r'^admin/', include(admin.site.urls)),
url... | from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'oshi_rest_server.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^admin/', include(admin.site.urls)),
)
Configure Dja... | <commit_before>from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'oshi_rest_server.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^admin/', include(admin.site.urls)),
... |
72e509be8415e628613b2341c136018ff5bb0f44 | openpathsampling/engines/openmm/__init__.py | openpathsampling/engines/openmm/__init__.py | def missing_openmm(*args, **kwargs):
raise RuntimeError("Install OpenMM to use this feature")
try:
import simtk.openmm
import simtk.openmm.app
except ImportError:
HAS_OPENMM = False
Engine = missing_openmm
empty_snapshot_from_openmm_topology = missing_openmm
snapshot_from_pdb = missing_open... | def missing_openmm(*args, **kwargs):
raise RuntimeError("Install OpenMM to use this feature")
try:
import simtk.openmm
import simtk.openmm.app
except ImportError:
HAS_OPENMM = False
Engine = missing_openmm
empty_snapshot_from_openmm_topology = missing_openmm
snapshot_from_pdb = missing_open... | Fix backward compatiblity for MDTrajTopology | Fix backward compatiblity for MDTrajTopology
| Python | mit | openpathsampling/openpathsampling,dwhswenson/openpathsampling,openpathsampling/openpathsampling,choderalab/openpathsampling,openpathsampling/openpathsampling,choderalab/openpathsampling,dwhswenson/openpathsampling,dwhswenson/openpathsampling,choderalab/openpathsampling,openpathsampling/openpathsampling,dwhswenson/openp... | def missing_openmm(*args, **kwargs):
raise RuntimeError("Install OpenMM to use this feature")
try:
import simtk.openmm
import simtk.openmm.app
except ImportError:
HAS_OPENMM = False
Engine = missing_openmm
empty_snapshot_from_openmm_topology = missing_openmm
snapshot_from_pdb = missing_open... | def missing_openmm(*args, **kwargs):
raise RuntimeError("Install OpenMM to use this feature")
try:
import simtk.openmm
import simtk.openmm.app
except ImportError:
HAS_OPENMM = False
Engine = missing_openmm
empty_snapshot_from_openmm_topology = missing_openmm
snapshot_from_pdb = missing_open... | <commit_before>def missing_openmm(*args, **kwargs):
raise RuntimeError("Install OpenMM to use this feature")
try:
import simtk.openmm
import simtk.openmm.app
except ImportError:
HAS_OPENMM = False
Engine = missing_openmm
empty_snapshot_from_openmm_topology = missing_openmm
snapshot_from_pdb... | def missing_openmm(*args, **kwargs):
raise RuntimeError("Install OpenMM to use this feature")
try:
import simtk.openmm
import simtk.openmm.app
except ImportError:
HAS_OPENMM = False
Engine = missing_openmm
empty_snapshot_from_openmm_topology = missing_openmm
snapshot_from_pdb = missing_open... | def missing_openmm(*args, **kwargs):
raise RuntimeError("Install OpenMM to use this feature")
try:
import simtk.openmm
import simtk.openmm.app
except ImportError:
HAS_OPENMM = False
Engine = missing_openmm
empty_snapshot_from_openmm_topology = missing_openmm
snapshot_from_pdb = missing_open... | <commit_before>def missing_openmm(*args, **kwargs):
raise RuntimeError("Install OpenMM to use this feature")
try:
import simtk.openmm
import simtk.openmm.app
except ImportError:
HAS_OPENMM = False
Engine = missing_openmm
empty_snapshot_from_openmm_topology = missing_openmm
snapshot_from_pdb... |
f3be5184dfccdcbbf5b95c7fcd75fbbda8d2ce1c | packages/grid/backend/grid/core/security.py | packages/grid/backend/grid/core/security.py | # stdlib
from datetime import datetime
from datetime import timedelta
from typing import Any
from typing import Optional
from typing import Union
# third party
from jose import jwt
from passlib.context import CryptContext
# grid absolute
from grid.core.config import settings
pwd_context = CryptContext(schemes=["bcry... | # stdlib
from datetime import datetime
from datetime import timedelta
from typing import Any
from typing import Optional
from typing import Union
# third party
from jose import jwt
from passlib.context import CryptContext
# grid absolute
from grid.core.config import settings
pwd_context = CryptContext(schemes=["bcry... | UPDATE create_access_token to handle guest sessions | UPDATE create_access_token to handle guest sessions
| Python | apache-2.0 | OpenMined/PySyft,OpenMined/PySyft,OpenMined/PySyft,OpenMined/PySyft | # stdlib
from datetime import datetime
from datetime import timedelta
from typing import Any
from typing import Optional
from typing import Union
# third party
from jose import jwt
from passlib.context import CryptContext
# grid absolute
from grid.core.config import settings
pwd_context = CryptContext(schemes=["bcry... | # stdlib
from datetime import datetime
from datetime import timedelta
from typing import Any
from typing import Optional
from typing import Union
# third party
from jose import jwt
from passlib.context import CryptContext
# grid absolute
from grid.core.config import settings
pwd_context = CryptContext(schemes=["bcry... | <commit_before># stdlib
from datetime import datetime
from datetime import timedelta
from typing import Any
from typing import Optional
from typing import Union
# third party
from jose import jwt
from passlib.context import CryptContext
# grid absolute
from grid.core.config import settings
pwd_context = CryptContext... | # stdlib
from datetime import datetime
from datetime import timedelta
from typing import Any
from typing import Optional
from typing import Union
# third party
from jose import jwt
from passlib.context import CryptContext
# grid absolute
from grid.core.config import settings
pwd_context = CryptContext(schemes=["bcry... | # stdlib
from datetime import datetime
from datetime import timedelta
from typing import Any
from typing import Optional
from typing import Union
# third party
from jose import jwt
from passlib.context import CryptContext
# grid absolute
from grid.core.config import settings
pwd_context = CryptContext(schemes=["bcry... | <commit_before># stdlib
from datetime import datetime
from datetime import timedelta
from typing import Any
from typing import Optional
from typing import Union
# third party
from jose import jwt
from passlib.context import CryptContext
# grid absolute
from grid.core.config import settings
pwd_context = CryptContext... |
ef41e90cf49856a6d0ca1b363440edb542dd2e0d | tests/test_config.py | tests/test_config.py | # Copyright 2015-2016 Masayuki Yamamoto
#
# 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 agree... | # Copyright 2015-2016 Masayuki Yamamoto
#
# 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 agree... | Add test case for user path | Add test case for user path
Expect filepath joinning '.yanico.conf' under $HOME.
| Python | apache-2.0 | ma8ma/yanico | # Copyright 2015-2016 Masayuki Yamamoto
#
# 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 agree... | # Copyright 2015-2016 Masayuki Yamamoto
#
# 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 agree... | <commit_before># Copyright 2015-2016 Masayuki Yamamoto
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicab... | # Copyright 2015-2016 Masayuki Yamamoto
#
# 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 agree... | # Copyright 2015-2016 Masayuki Yamamoto
#
# 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 agree... | <commit_before># Copyright 2015-2016 Masayuki Yamamoto
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicab... |
b910900f72d6b25cb05c56563968aad102429c25 | gmrh/RepositoryHandler.py | gmrh/RepositoryHandler.py | import os.path
import subprocess
class DefaultRepositoryHandler():
def __init__(self, cwd):
self.cwd = cwd
def repository_exists(self, path):
return os.path.exists(path + os.path.sep + '.git')
def update_repository(self, path, remote_url, remote_branch):
print 'Updating repositor... | import os.path
import subprocess
class DefaultRepositoryHandler():
def __init__(self, cwd):
self.cwd = cwd
def repository_exists(self, path):
return os.path.exists(path + os.path.sep + '.git')
def update_repository(self, path, remote_url, remote_branch):
print 'Updating repositor... | Check the url of the remote & ensure the updating commands are executed in the correct directory | Check the url of the remote & ensure the updating commands are executed in the correct directory
| Python | bsd-3-clause | solarnz/polygamy,solarnz/polygamy | import os.path
import subprocess
class DefaultRepositoryHandler():
def __init__(self, cwd):
self.cwd = cwd
def repository_exists(self, path):
return os.path.exists(path + os.path.sep + '.git')
def update_repository(self, path, remote_url, remote_branch):
print 'Updating repositor... | import os.path
import subprocess
class DefaultRepositoryHandler():
def __init__(self, cwd):
self.cwd = cwd
def repository_exists(self, path):
return os.path.exists(path + os.path.sep + '.git')
def update_repository(self, path, remote_url, remote_branch):
print 'Updating repositor... | <commit_before>import os.path
import subprocess
class DefaultRepositoryHandler():
def __init__(self, cwd):
self.cwd = cwd
def repository_exists(self, path):
return os.path.exists(path + os.path.sep + '.git')
def update_repository(self, path, remote_url, remote_branch):
print 'Upd... | import os.path
import subprocess
class DefaultRepositoryHandler():
def __init__(self, cwd):
self.cwd = cwd
def repository_exists(self, path):
return os.path.exists(path + os.path.sep + '.git')
def update_repository(self, path, remote_url, remote_branch):
print 'Updating repositor... | import os.path
import subprocess
class DefaultRepositoryHandler():
def __init__(self, cwd):
self.cwd = cwd
def repository_exists(self, path):
return os.path.exists(path + os.path.sep + '.git')
def update_repository(self, path, remote_url, remote_branch):
print 'Updating repositor... | <commit_before>import os.path
import subprocess
class DefaultRepositoryHandler():
def __init__(self, cwd):
self.cwd = cwd
def repository_exists(self, path):
return os.path.exists(path + os.path.sep + '.git')
def update_repository(self, path, remote_url, remote_branch):
print 'Upd... |
5a1c48403a912eedc4f5d87215fafdb05eb49ed5 | Python/find-all-duplicates-in-an-array.py | Python/find-all-duplicates-in-an-array.py | # Time: O(n)
# Space: O(1)
# Given an array of integers, 1 <= a[i] <= n (n = size of array),
# some elements appear twice and others appear once.
# Find all the elements that appear twice in this array.
# Could you do it without extra space and in O(n) runtime?
#
# Example:
# Input
#
# [4,3,2,7,8,2,3,1]
#
# Output
#
... | # Time: O(n)
# Space: O(1)
# Given an array of integers, 1 <= a[i] <= n (n = size of array),
# some elements appear twice and others appear once.
# Find all the elements that appear twice in this array.
# Could you do it without extra space and in O(n) runtime?
#
# Example:
# Input
#
# [4,3,2,7,8,2,3,1]
#
# Output
#
... | Add alternative solution for 'Find all duplicates in an array' | Add alternative solution for 'Find all duplicates in an array'
| Python | mit | kamyu104/LeetCode,tudennis/LeetCode---kamyu104-11-24-2015,tudennis/LeetCode---kamyu104-11-24-2015,tudennis/LeetCode---kamyu104-11-24-2015,kamyu104/LeetCode,kamyu104/LeetCode,kamyu104/LeetCode,kamyu104/LeetCode,tudennis/LeetCode---kamyu104-11-24-2015,tudennis/LeetCode---kamyu104-11-24-2015 | # Time: O(n)
# Space: O(1)
# Given an array of integers, 1 <= a[i] <= n (n = size of array),
# some elements appear twice and others appear once.
# Find all the elements that appear twice in this array.
# Could you do it without extra space and in O(n) runtime?
#
# Example:
# Input
#
# [4,3,2,7,8,2,3,1]
#
# Output
#
... | # Time: O(n)
# Space: O(1)
# Given an array of integers, 1 <= a[i] <= n (n = size of array),
# some elements appear twice and others appear once.
# Find all the elements that appear twice in this array.
# Could you do it without extra space and in O(n) runtime?
#
# Example:
# Input
#
# [4,3,2,7,8,2,3,1]
#
# Output
#
... | <commit_before># Time: O(n)
# Space: O(1)
# Given an array of integers, 1 <= a[i] <= n (n = size of array),
# some elements appear twice and others appear once.
# Find all the elements that appear twice in this array.
# Could you do it without extra space and in O(n) runtime?
#
# Example:
# Input
#
# [4,3,2,7,8,2,3,1... | # Time: O(n)
# Space: O(1)
# Given an array of integers, 1 <= a[i] <= n (n = size of array),
# some elements appear twice and others appear once.
# Find all the elements that appear twice in this array.
# Could you do it without extra space and in O(n) runtime?
#
# Example:
# Input
#
# [4,3,2,7,8,2,3,1]
#
# Output
#
... | # Time: O(n)
# Space: O(1)
# Given an array of integers, 1 <= a[i] <= n (n = size of array),
# some elements appear twice and others appear once.
# Find all the elements that appear twice in this array.
# Could you do it without extra space and in O(n) runtime?
#
# Example:
# Input
#
# [4,3,2,7,8,2,3,1]
#
# Output
#
... | <commit_before># Time: O(n)
# Space: O(1)
# Given an array of integers, 1 <= a[i] <= n (n = size of array),
# some elements appear twice and others appear once.
# Find all the elements that appear twice in this array.
# Could you do it without extra space and in O(n) runtime?
#
# Example:
# Input
#
# [4,3,2,7,8,2,3,1... |
3f5e90a19881884408003ed01b04b4a29b3bd2fd | test/command_source/TestCommandSource.py | test/command_source/TestCommandSource.py | """
Test that lldb command "command source" works correctly.
See also http://llvm.org/viewvc/llvm-project?view=rev&revision=109673.
"""
import os, time
import unittest2
import lldb
from lldbtest import *
class CommandSourceTestCase(TestBase):
mydir = "command_source"
def test_command_source(self):
... | """
Test that lldb command "command source" works correctly.
See also http://llvm.org/viewvc/llvm-project?view=rev&revision=109673.
"""
import os, sys
import unittest2
import lldb
from lldbtest import *
class CommandSourceTestCase(TestBase):
mydir = "command_source"
def test_command_source(self):
"... | Add "import sys" for sys.stdout. | Add "import sys" for sys.stdout.
git-svn-id: b33bab8abb5b18c12ee100cd7761ab452d00b2b0@124504 91177308-0d34-0410-b5e6-96231b3b80d8
| Python | apache-2.0 | apple/swift-lldb,apple/swift-lldb,llvm-mirror/lldb,apple/swift-lldb,apple/swift-lldb,apple/swift-lldb,llvm-mirror/lldb,llvm-mirror/lldb,llvm-mirror/lldb,llvm-mirror/lldb,apple/swift-lldb | """
Test that lldb command "command source" works correctly.
See also http://llvm.org/viewvc/llvm-project?view=rev&revision=109673.
"""
import os, time
import unittest2
import lldb
from lldbtest import *
class CommandSourceTestCase(TestBase):
mydir = "command_source"
def test_command_source(self):
... | """
Test that lldb command "command source" works correctly.
See also http://llvm.org/viewvc/llvm-project?view=rev&revision=109673.
"""
import os, sys
import unittest2
import lldb
from lldbtest import *
class CommandSourceTestCase(TestBase):
mydir = "command_source"
def test_command_source(self):
"... | <commit_before>"""
Test that lldb command "command source" works correctly.
See also http://llvm.org/viewvc/llvm-project?view=rev&revision=109673.
"""
import os, time
import unittest2
import lldb
from lldbtest import *
class CommandSourceTestCase(TestBase):
mydir = "command_source"
def test_command_source(... | """
Test that lldb command "command source" works correctly.
See also http://llvm.org/viewvc/llvm-project?view=rev&revision=109673.
"""
import os, sys
import unittest2
import lldb
from lldbtest import *
class CommandSourceTestCase(TestBase):
mydir = "command_source"
def test_command_source(self):
"... | """
Test that lldb command "command source" works correctly.
See also http://llvm.org/viewvc/llvm-project?view=rev&revision=109673.
"""
import os, time
import unittest2
import lldb
from lldbtest import *
class CommandSourceTestCase(TestBase):
mydir = "command_source"
def test_command_source(self):
... | <commit_before>"""
Test that lldb command "command source" works correctly.
See also http://llvm.org/viewvc/llvm-project?view=rev&revision=109673.
"""
import os, time
import unittest2
import lldb
from lldbtest import *
class CommandSourceTestCase(TestBase):
mydir = "command_source"
def test_command_source(... |
73243dc74b416fc42ccb8b684924f0b2a09919a3 | SnakesLadders/SnakesLadders.py | SnakesLadders/SnakesLadders.py | class State(object):
def __init__(self, ix):
self.index = ix
self.link = None # placeholder, not None if Snake or Ladder
def process(self):
"""Action when landed upon"""
if self.link:
if self.link > self.index:
# Ladder!
return self.l... | class State(object):
def __init__(self, ix):
self.index = ix
self.link = None # placeholder, not None if Snake or Ladder
def process(self):
"""Action when landed upon"""
if self.link:
if self.link > self.index:
# Ladder!
return self.l... | Update to move and run | Update to move and run
| Python | cc0-1.0 | robclewley/DataScotties | class State(object):
def __init__(self, ix):
self.index = ix
self.link = None # placeholder, not None if Snake or Ladder
def process(self):
"""Action when landed upon"""
if self.link:
if self.link > self.index:
# Ladder!
return self.l... | class State(object):
def __init__(self, ix):
self.index = ix
self.link = None # placeholder, not None if Snake or Ladder
def process(self):
"""Action when landed upon"""
if self.link:
if self.link > self.index:
# Ladder!
return self.l... | <commit_before>class State(object):
def __init__(self, ix):
self.index = ix
self.link = None # placeholder, not None if Snake or Ladder
def process(self):
"""Action when landed upon"""
if self.link:
if self.link > self.index:
# Ladder!
... | class State(object):
def __init__(self, ix):
self.index = ix
self.link = None # placeholder, not None if Snake or Ladder
def process(self):
"""Action when landed upon"""
if self.link:
if self.link > self.index:
# Ladder!
return self.l... | class State(object):
def __init__(self, ix):
self.index = ix
self.link = None # placeholder, not None if Snake or Ladder
def process(self):
"""Action when landed upon"""
if self.link:
if self.link > self.index:
# Ladder!
return self.l... | <commit_before>class State(object):
def __init__(self, ix):
self.index = ix
self.link = None # placeholder, not None if Snake or Ladder
def process(self):
"""Action when landed upon"""
if self.link:
if self.link > self.index:
# Ladder!
... |
a4e959c1aeb705128898f07bdf9c9fb315ba593c | flexget/tests/test_plugin_interfaces.py | flexget/tests/test_plugin_interfaces.py | from __future__ import unicode_literals, division, absolute_import
from builtins import * # noqa pylint: disable=unused-import, redefined-builtin
from flexget import plugin
class TestInterfaces(object):
"""Test that any plugins declaring certain interfaces at least superficially comply with those interfaces."""... | from __future__ import unicode_literals, division, absolute_import
from builtins import * # noqa pylint: disable=unused-import, redefined-builtin
from flexget import plugin
class TestInterfaces(object):
"""Test that any plugins declaring certain interfaces at least superficially comply with those interfaces."""... | Add tests for search interface plugins | Add tests for search interface plugins
| Python | mit | malkavi/Flexget,tobinjt/Flexget,jacobmetrick/Flexget,jawilson/Flexget,tobinjt/Flexget,LynxyssCZ/Flexget,malkavi/Flexget,qk4l/Flexget,OmgOhnoes/Flexget,JorisDeRieck/Flexget,gazpachoking/Flexget,crawln45/Flexget,jacobmetrick/Flexget,jawilson/Flexget,jacobmetrick/Flexget,tobinjt/Flexget,poulpito/Flexget,JorisDeRieck/Flexg... | from __future__ import unicode_literals, division, absolute_import
from builtins import * # noqa pylint: disable=unused-import, redefined-builtin
from flexget import plugin
class TestInterfaces(object):
"""Test that any plugins declaring certain interfaces at least superficially comply with those interfaces."""... | from __future__ import unicode_literals, division, absolute_import
from builtins import * # noqa pylint: disable=unused-import, redefined-builtin
from flexget import plugin
class TestInterfaces(object):
"""Test that any plugins declaring certain interfaces at least superficially comply with those interfaces."""... | <commit_before>from __future__ import unicode_literals, division, absolute_import
from builtins import * # noqa pylint: disable=unused-import, redefined-builtin
from flexget import plugin
class TestInterfaces(object):
"""Test that any plugins declaring certain interfaces at least superficially comply with those... | from __future__ import unicode_literals, division, absolute_import
from builtins import * # noqa pylint: disable=unused-import, redefined-builtin
from flexget import plugin
class TestInterfaces(object):
"""Test that any plugins declaring certain interfaces at least superficially comply with those interfaces."""... | from __future__ import unicode_literals, division, absolute_import
from builtins import * # noqa pylint: disable=unused-import, redefined-builtin
from flexget import plugin
class TestInterfaces(object):
"""Test that any plugins declaring certain interfaces at least superficially comply with those interfaces."""... | <commit_before>from __future__ import unicode_literals, division, absolute_import
from builtins import * # noqa pylint: disable=unused-import, redefined-builtin
from flexget import plugin
class TestInterfaces(object):
"""Test that any plugins declaring certain interfaces at least superficially comply with those... |
11cf55cf2859a23edd2d1dba56e574d01cacce4f | apps/funding/forms.py | apps/funding/forms.py | from django import forms
from django.utils.translation import ugettext_lazy as _, ugettext as __
from .models import Funding
from .widgets import PerksAmountWidget
class FundingForm(forms.Form):
required_css_class = 'required'
amount = forms.DecimalField(label=_("Amount"), decimal_places=2,
widget=Pe... | from django import forms
from django.utils.translation import ugettext_lazy as _, ugettext as __
from .models import Funding
from .widgets import PerksAmountWidget
class FundingForm(forms.Form):
required_css_class = 'required'
amount = forms.DecimalField(label=_("Amount"), decimal_places=2,
widget=Pe... | Set perks on form save. | Set perks on form save.
| Python | agpl-3.0 | fnp/wolnelektury,fnp/wolnelektury,fnp/wolnelektury,fnp/wolnelektury | from django import forms
from django.utils.translation import ugettext_lazy as _, ugettext as __
from .models import Funding
from .widgets import PerksAmountWidget
class FundingForm(forms.Form):
required_css_class = 'required'
amount = forms.DecimalField(label=_("Amount"), decimal_places=2,
widget=Pe... | from django import forms
from django.utils.translation import ugettext_lazy as _, ugettext as __
from .models import Funding
from .widgets import PerksAmountWidget
class FundingForm(forms.Form):
required_css_class = 'required'
amount = forms.DecimalField(label=_("Amount"), decimal_places=2,
widget=Pe... | <commit_before>from django import forms
from django.utils.translation import ugettext_lazy as _, ugettext as __
from .models import Funding
from .widgets import PerksAmountWidget
class FundingForm(forms.Form):
required_css_class = 'required'
amount = forms.DecimalField(label=_("Amount"), decimal_places=2,
... | from django import forms
from django.utils.translation import ugettext_lazy as _, ugettext as __
from .models import Funding
from .widgets import PerksAmountWidget
class FundingForm(forms.Form):
required_css_class = 'required'
amount = forms.DecimalField(label=_("Amount"), decimal_places=2,
widget=Pe... | from django import forms
from django.utils.translation import ugettext_lazy as _, ugettext as __
from .models import Funding
from .widgets import PerksAmountWidget
class FundingForm(forms.Form):
required_css_class = 'required'
amount = forms.DecimalField(label=_("Amount"), decimal_places=2,
widget=Pe... | <commit_before>from django import forms
from django.utils.translation import ugettext_lazy as _, ugettext as __
from .models import Funding
from .widgets import PerksAmountWidget
class FundingForm(forms.Form):
required_css_class = 'required'
amount = forms.DecimalField(label=_("Amount"), decimal_places=2,
... |
145a72dc8439d4479b64a79e7c94cbc12f4afdd7 | test/__init__.py | test/__init__.py | """Package for regression testing of the blender nif scripts."""
import bpy
def setup(self):
"""Enables the nif scripts addon, so all tests can use it."""
bpy.ops.wm.addon_enable(module="io_scene_nif")
def teardown(self):
"""Disables the nif scripts addon."""
bpy.ops.wm.addon_disable(module="io_scene... | """Package for regression testing of the blender nif scripts."""
import bpy
def setup(self):
"""Enables the nif scripts addon, so all tests can use it."""
bpy.ops.wm.addon_enable(module="io_scene_nif")
# remove default objects
for obj in bpy.data.objects[:]:
bpy.context.scene.objects.unlink(ob... | Remove startup objects when setting up the test module. | Remove startup objects when setting up the test module.
| Python | bsd-3-clause | amorilia/blender_nif_plugin,nightstrike/blender_nif_plugin,amorilia/blender_nif_plugin,nightstrike/blender_nif_plugin | """Package for regression testing of the blender nif scripts."""
import bpy
def setup(self):
"""Enables the nif scripts addon, so all tests can use it."""
bpy.ops.wm.addon_enable(module="io_scene_nif")
def teardown(self):
"""Disables the nif scripts addon."""
bpy.ops.wm.addon_disable(module="io_scene... | """Package for regression testing of the blender nif scripts."""
import bpy
def setup(self):
"""Enables the nif scripts addon, so all tests can use it."""
bpy.ops.wm.addon_enable(module="io_scene_nif")
# remove default objects
for obj in bpy.data.objects[:]:
bpy.context.scene.objects.unlink(ob... | <commit_before>"""Package for regression testing of the blender nif scripts."""
import bpy
def setup(self):
"""Enables the nif scripts addon, so all tests can use it."""
bpy.ops.wm.addon_enable(module="io_scene_nif")
def teardown(self):
"""Disables the nif scripts addon."""
bpy.ops.wm.addon_disable(m... | """Package for regression testing of the blender nif scripts."""
import bpy
def setup(self):
"""Enables the nif scripts addon, so all tests can use it."""
bpy.ops.wm.addon_enable(module="io_scene_nif")
# remove default objects
for obj in bpy.data.objects[:]:
bpy.context.scene.objects.unlink(ob... | """Package for regression testing of the blender nif scripts."""
import bpy
def setup(self):
"""Enables the nif scripts addon, so all tests can use it."""
bpy.ops.wm.addon_enable(module="io_scene_nif")
def teardown(self):
"""Disables the nif scripts addon."""
bpy.ops.wm.addon_disable(module="io_scene... | <commit_before>"""Package for regression testing of the blender nif scripts."""
import bpy
def setup(self):
"""Enables the nif scripts addon, so all tests can use it."""
bpy.ops.wm.addon_enable(module="io_scene_nif")
def teardown(self):
"""Disables the nif scripts addon."""
bpy.ops.wm.addon_disable(m... |
5d6b384a2f1b8caa9421b428e5d81aaa1d9a82e1 | tests/correct.py | tests/correct.py | """Check ringtophat results against scipy.ndimage.convolve""" | """Check ringtophat results against scipy.ndimage.convolve"""
import unittest
from numpy.testing import assert_equal, assert_almost_equal
import numpy as np
import ringtophat
class TestKernels(unittest.TestCase):
def test_binary_disk(self):
actual = ringtophat.binary_disk(1)
desired = np.array([[Fa... | Add first tests. disk and ring masks for simple cases. | Add first tests. disk and ring masks for simple cases. | Python | bsd-3-clause | gammapy/ringtophat,gammapy/ringtophat | """Check ringtophat results against scipy.ndimage.convolve"""Add first tests. disk and ring masks for simple cases. | """Check ringtophat results against scipy.ndimage.convolve"""
import unittest
from numpy.testing import assert_equal, assert_almost_equal
import numpy as np
import ringtophat
class TestKernels(unittest.TestCase):
def test_binary_disk(self):
actual = ringtophat.binary_disk(1)
desired = np.array([[Fa... | <commit_before>"""Check ringtophat results against scipy.ndimage.convolve"""<commit_msg>Add first tests. disk and ring masks for simple cases.<commit_after> | """Check ringtophat results against scipy.ndimage.convolve"""
import unittest
from numpy.testing import assert_equal, assert_almost_equal
import numpy as np
import ringtophat
class TestKernels(unittest.TestCase):
def test_binary_disk(self):
actual = ringtophat.binary_disk(1)
desired = np.array([[Fa... | """Check ringtophat results against scipy.ndimage.convolve"""Add first tests. disk and ring masks for simple cases."""Check ringtophat results against scipy.ndimage.convolve"""
import unittest
from numpy.testing import assert_equal, assert_almost_equal
import numpy as np
import ringtophat
class TestKernels(unittest.Te... | <commit_before>"""Check ringtophat results against scipy.ndimage.convolve"""<commit_msg>Add first tests. disk and ring masks for simple cases.<commit_after>"""Check ringtophat results against scipy.ndimage.convolve"""
import unittest
from numpy.testing import assert_equal, assert_almost_equal
import numpy as np
import ... |
2974972ce36f1cd2dec99a18edc49ac374cdf458 | tools/fitsevt.py | tools/fitsevt.py | #! /usr/bin/python3
import sys
import os
import math
from astropy.io import fits
inputFolder = sys.argv[1]
outputFolder = sys.argv[2]
eLo = int(sys.argv[3])
eHi = int(sys.argv[4])
binSize = int(sys.argv[5])
fnames = os.listdir(inputFolder)
for fname in fnames:
print(fname)
hdulist = fits.open(inputFolder+"/"+fna... | #! /usr/bin/python3
import sys
import os
import math
from astropy.io import fits
inputFolder = sys.argv[1]
outputFolder = sys.argv[2]
eLo = int(sys.argv[3])
eHi = int(sys.argv[4])
binSize = int(sys.argv[5])
fnames = os.listdir(inputFolder)
for fname in fnames:
print(fname)
hdulist = fits.open(inputFolder+"/"+fnam... | Change output filenaming to have .txt | Change output filenaming to have .txt
| Python | mit | fauzanzaid/IUCAA-GRB-detection-Feature-extraction | #! /usr/bin/python3
import sys
import os
import math
from astropy.io import fits
inputFolder = sys.argv[1]
outputFolder = sys.argv[2]
eLo = int(sys.argv[3])
eHi = int(sys.argv[4])
binSize = int(sys.argv[5])
fnames = os.listdir(inputFolder)
for fname in fnames:
print(fname)
hdulist = fits.open(inputFolder+"/"+fna... | #! /usr/bin/python3
import sys
import os
import math
from astropy.io import fits
inputFolder = sys.argv[1]
outputFolder = sys.argv[2]
eLo = int(sys.argv[3])
eHi = int(sys.argv[4])
binSize = int(sys.argv[5])
fnames = os.listdir(inputFolder)
for fname in fnames:
print(fname)
hdulist = fits.open(inputFolder+"/"+fnam... | <commit_before>#! /usr/bin/python3
import sys
import os
import math
from astropy.io import fits
inputFolder = sys.argv[1]
outputFolder = sys.argv[2]
eLo = int(sys.argv[3])
eHi = int(sys.argv[4])
binSize = int(sys.argv[5])
fnames = os.listdir(inputFolder)
for fname in fnames:
print(fname)
hdulist = fits.open(inpu... | #! /usr/bin/python3
import sys
import os
import math
from astropy.io import fits
inputFolder = sys.argv[1]
outputFolder = sys.argv[2]
eLo = int(sys.argv[3])
eHi = int(sys.argv[4])
binSize = int(sys.argv[5])
fnames = os.listdir(inputFolder)
for fname in fnames:
print(fname)
hdulist = fits.open(inputFolder+"/"+fnam... | #! /usr/bin/python3
import sys
import os
import math
from astropy.io import fits
inputFolder = sys.argv[1]
outputFolder = sys.argv[2]
eLo = int(sys.argv[3])
eHi = int(sys.argv[4])
binSize = int(sys.argv[5])
fnames = os.listdir(inputFolder)
for fname in fnames:
print(fname)
hdulist = fits.open(inputFolder+"/"+fna... | <commit_before>#! /usr/bin/python3
import sys
import os
import math
from astropy.io import fits
inputFolder = sys.argv[1]
outputFolder = sys.argv[2]
eLo = int(sys.argv[3])
eHi = int(sys.argv[4])
binSize = int(sys.argv[5])
fnames = os.listdir(inputFolder)
for fname in fnames:
print(fname)
hdulist = fits.open(inpu... |
96871ef8de84653406749a2e503ef4b4fb800b2f | src/mist/io/tests/features/steps/shell.py | src/mist/io/tests/features/steps/shell.py | """
@given:
-------
@when:
------
I type the "{command}" shell command --> shell_command
@then:
------
I should see the "{command}" result in shell output --> shell_output
------
"""
@when(u'I type the "{command}" shell command')
def shell_command(context, command):
shell_input = context.browser.fi... | """
@given:
-------
@when:
------
I type the "{command}" shell command --> shell_command
@then:
------
I should see the "{command}" result in shell output --> shell_output
------
"""
@when(u'I type the "{command}" shell command')
def shell_command(context, command):
shell_input = context.browser.fi... | Fix Shell tests according to css changes | Fix Shell tests according to css changes
| Python | agpl-3.0 | kelonye/mist.io,Lao-liu/mist.io,DimensionDataCBUSydney/mist.io,Lao-liu/mist.io,johnnyWalnut/mist.io,DimensionDataCBUSydney/mist.io,zBMNForks/mist.io,munkiat/mist.io,Lao-liu/mist.io,afivos/mist.io,munkiat/mist.io,munkiat/mist.io,afivos/mist.io,johnnyWalnut/mist.io,Lao-liu/mist.io,munkiat/mist.io,DimensionDataCBUSydney/m... | """
@given:
-------
@when:
------
I type the "{command}" shell command --> shell_command
@then:
------
I should see the "{command}" result in shell output --> shell_output
------
"""
@when(u'I type the "{command}" shell command')
def shell_command(context, command):
shell_input = context.browser.fi... | """
@given:
-------
@when:
------
I type the "{command}" shell command --> shell_command
@then:
------
I should see the "{command}" result in shell output --> shell_output
------
"""
@when(u'I type the "{command}" shell command')
def shell_command(context, command):
shell_input = context.browser.fi... | <commit_before>"""
@given:
-------
@when:
------
I type the "{command}" shell command --> shell_command
@then:
------
I should see the "{command}" result in shell output --> shell_output
------
"""
@when(u'I type the "{command}" shell command')
def shell_command(context, command):
shell_input = con... | """
@given:
-------
@when:
------
I type the "{command}" shell command --> shell_command
@then:
------
I should see the "{command}" result in shell output --> shell_output
------
"""
@when(u'I type the "{command}" shell command')
def shell_command(context, command):
shell_input = context.browser.fi... | """
@given:
-------
@when:
------
I type the "{command}" shell command --> shell_command
@then:
------
I should see the "{command}" result in shell output --> shell_output
------
"""
@when(u'I type the "{command}" shell command')
def shell_command(context, command):
shell_input = context.browser.fi... | <commit_before>"""
@given:
-------
@when:
------
I type the "{command}" shell command --> shell_command
@then:
------
I should see the "{command}" result in shell output --> shell_output
------
"""
@when(u'I type the "{command}" shell command')
def shell_command(context, command):
shell_input = con... |
3c8f7752a6b47a8ce5395b9038a9280fe0369aae | risk_engine_tests.py | risk_engine_tests.py | from risk_engine import RiskEngine
import unittest
class RiskEngineTestCase(unittest.TestCase):
def setUp(self):
self.engine = RiskEngine()
def test_roll_is_near_even(self):
n = 1000000
payout_count = 0
for roll in range(n):
if self.engine.run():
payout_count += 1
payout_perc... | from risk_engine import RiskEngine
import unittest
class RiskEngineTestCase(unittest.TestCase):
def setUp(self):
self.engine = RiskEngine()
def test_roll_is_near_even(self):
n = 1000000
payout_count = 0
for roll in range(n):
if self.engine.run():
payout_count += 1
payout_perc... | Improve the users odds a little | Improve the users odds a little
| Python | mit | joelklabo/risk | from risk_engine import RiskEngine
import unittest
class RiskEngineTestCase(unittest.TestCase):
def setUp(self):
self.engine = RiskEngine()
def test_roll_is_near_even(self):
n = 1000000
payout_count = 0
for roll in range(n):
if self.engine.run():
payout_count += 1
payout_perc... | from risk_engine import RiskEngine
import unittest
class RiskEngineTestCase(unittest.TestCase):
def setUp(self):
self.engine = RiskEngine()
def test_roll_is_near_even(self):
n = 1000000
payout_count = 0
for roll in range(n):
if self.engine.run():
payout_count += 1
payout_perc... | <commit_before>from risk_engine import RiskEngine
import unittest
class RiskEngineTestCase(unittest.TestCase):
def setUp(self):
self.engine = RiskEngine()
def test_roll_is_near_even(self):
n = 1000000
payout_count = 0
for roll in range(n):
if self.engine.run():
payout_count += 1
... | from risk_engine import RiskEngine
import unittest
class RiskEngineTestCase(unittest.TestCase):
def setUp(self):
self.engine = RiskEngine()
def test_roll_is_near_even(self):
n = 1000000
payout_count = 0
for roll in range(n):
if self.engine.run():
payout_count += 1
payout_perc... | from risk_engine import RiskEngine
import unittest
class RiskEngineTestCase(unittest.TestCase):
def setUp(self):
self.engine = RiskEngine()
def test_roll_is_near_even(self):
n = 1000000
payout_count = 0
for roll in range(n):
if self.engine.run():
payout_count += 1
payout_perc... | <commit_before>from risk_engine import RiskEngine
import unittest
class RiskEngineTestCase(unittest.TestCase):
def setUp(self):
self.engine = RiskEngine()
def test_roll_is_near_even(self):
n = 1000000
payout_count = 0
for roll in range(n):
if self.engine.run():
payout_count += 1
... |
c3ca44b17b9e14e8570083ab49be4da8e64757bc | scripts/filter_fasta_on_length.py | scripts/filter_fasta_on_length.py | #!/usr/bin/env python
"""filter_fasta_on_length.py
Filter a fasta file so that the resulting sequences are all longer
or equal to the length threshold parameter. Only accepts stdin."""
import argparse
import sys
from Bio import SeqIO
def main(args):
seqs = []
for i, seq in enumerate(SeqIO.parse(sys.stdin, ... | #!/usr/bin/env python
"""filter_fasta_on_length.py
Filter a fasta file so that the resulting sequences are all longer
or equal to the length threshold parameter. Only accepts stdin."""
import argparse
import sys
from Bio import SeqIO
def main(args):
seqs = []
if args.input_fasta is not None:
input_... | Use either file input or stdin for filtering length | Use either file input or stdin for filtering length
| Python | mit | EnvGen/toolbox,EnvGen/toolbox | #!/usr/bin/env python
"""filter_fasta_on_length.py
Filter a fasta file so that the resulting sequences are all longer
or equal to the length threshold parameter. Only accepts stdin."""
import argparse
import sys
from Bio import SeqIO
def main(args):
seqs = []
for i, seq in enumerate(SeqIO.parse(sys.stdin, ... | #!/usr/bin/env python
"""filter_fasta_on_length.py
Filter a fasta file so that the resulting sequences are all longer
or equal to the length threshold parameter. Only accepts stdin."""
import argparse
import sys
from Bio import SeqIO
def main(args):
seqs = []
if args.input_fasta is not None:
input_... | <commit_before>#!/usr/bin/env python
"""filter_fasta_on_length.py
Filter a fasta file so that the resulting sequences are all longer
or equal to the length threshold parameter. Only accepts stdin."""
import argparse
import sys
from Bio import SeqIO
def main(args):
seqs = []
for i, seq in enumerate(SeqIO.pa... | #!/usr/bin/env python
"""filter_fasta_on_length.py
Filter a fasta file so that the resulting sequences are all longer
or equal to the length threshold parameter. Only accepts stdin."""
import argparse
import sys
from Bio import SeqIO
def main(args):
seqs = []
if args.input_fasta is not None:
input_... | #!/usr/bin/env python
"""filter_fasta_on_length.py
Filter a fasta file so that the resulting sequences are all longer
or equal to the length threshold parameter. Only accepts stdin."""
import argparse
import sys
from Bio import SeqIO
def main(args):
seqs = []
for i, seq in enumerate(SeqIO.parse(sys.stdin, ... | <commit_before>#!/usr/bin/env python
"""filter_fasta_on_length.py
Filter a fasta file so that the resulting sequences are all longer
or equal to the length threshold parameter. Only accepts stdin."""
import argparse
import sys
from Bio import SeqIO
def main(args):
seqs = []
for i, seq in enumerate(SeqIO.pa... |
91c502beb68acff1ad5194a572d5b75f607b7d00 | ckanext/qa/helpers.py | ckanext/qa/helpers.py | from ckan.plugins import toolkit as tk
def qa_openness_stars_resource_html(resource):
qa = resource.get('qa')
if not qa:
return '<!-- No qa info for this resource -->'
extra_vars = qa
return tk.literal(
tk.render('qa/openness_stars.html',
extra_vars=extra_vars))
def... | import copy
from ckan.plugins import toolkit as tk
def qa_openness_stars_resource_html(resource):
qa = resource.get('qa')
if not qa:
return '<!-- No qa info for this resource -->'
# Take a copy of the qa dict, because weirdly the renderer appears to add
# keys to it like _ and app_globals. Thi... | Fix bug that meant rendering debug info was v slow. | Fix bug that meant rendering debug info was v slow.
| Python | mit | ckan/ckanext-qa,ckan/ckanext-qa,ckan/ckanext-qa | from ckan.plugins import toolkit as tk
def qa_openness_stars_resource_html(resource):
qa = resource.get('qa')
if not qa:
return '<!-- No qa info for this resource -->'
extra_vars = qa
return tk.literal(
tk.render('qa/openness_stars.html',
extra_vars=extra_vars))
def... | import copy
from ckan.plugins import toolkit as tk
def qa_openness_stars_resource_html(resource):
qa = resource.get('qa')
if not qa:
return '<!-- No qa info for this resource -->'
# Take a copy of the qa dict, because weirdly the renderer appears to add
# keys to it like _ and app_globals. Thi... | <commit_before>from ckan.plugins import toolkit as tk
def qa_openness_stars_resource_html(resource):
qa = resource.get('qa')
if not qa:
return '<!-- No qa info for this resource -->'
extra_vars = qa
return tk.literal(
tk.render('qa/openness_stars.html',
extra_vars=ext... | import copy
from ckan.plugins import toolkit as tk
def qa_openness_stars_resource_html(resource):
qa = resource.get('qa')
if not qa:
return '<!-- No qa info for this resource -->'
# Take a copy of the qa dict, because weirdly the renderer appears to add
# keys to it like _ and app_globals. Thi... | from ckan.plugins import toolkit as tk
def qa_openness_stars_resource_html(resource):
qa = resource.get('qa')
if not qa:
return '<!-- No qa info for this resource -->'
extra_vars = qa
return tk.literal(
tk.render('qa/openness_stars.html',
extra_vars=extra_vars))
def... | <commit_before>from ckan.plugins import toolkit as tk
def qa_openness_stars_resource_html(resource):
qa = resource.get('qa')
if not qa:
return '<!-- No qa info for this resource -->'
extra_vars = qa
return tk.literal(
tk.render('qa/openness_stars.html',
extra_vars=ext... |
e57d8f885c2be591bcfa7b5f337495cdb2e6ce64 | ooni/tests/test_errors.py | ooni/tests/test_errors.py | from twisted.trial import unittest
import ooni.errors
class TestErrors(unittest.TestCase):
def test_catch_child_failures_before_parent_failures(self):
"""
Verify that more specific Failures are caught first by
handleAllFailures() and failureToString().
Fails if a subclass is list... | from twisted.trial import unittest
import ooni.errors
class TestErrors(unittest.TestCase):
def test_catch_child_failures_before_parent_failures(self):
"""
Verify that more specific Failures are caught first by
handleAllFailures() and failureToString().
Fails if a subclass is list... | Fix typo in docstring spotted by @armadev | Fix typo in docstring spotted by @armadev
| Python | bsd-2-clause | 0xPoly/ooni-probe,0xPoly/ooni-probe,0xPoly/ooni-probe,0xPoly/ooni-probe | from twisted.trial import unittest
import ooni.errors
class TestErrors(unittest.TestCase):
def test_catch_child_failures_before_parent_failures(self):
"""
Verify that more specific Failures are caught first by
handleAllFailures() and failureToString().
Fails if a subclass is list... | from twisted.trial import unittest
import ooni.errors
class TestErrors(unittest.TestCase):
def test_catch_child_failures_before_parent_failures(self):
"""
Verify that more specific Failures are caught first by
handleAllFailures() and failureToString().
Fails if a subclass is list... | <commit_before>from twisted.trial import unittest
import ooni.errors
class TestErrors(unittest.TestCase):
def test_catch_child_failures_before_parent_failures(self):
"""
Verify that more specific Failures are caught first by
handleAllFailures() and failureToString().
Fails if a s... | from twisted.trial import unittest
import ooni.errors
class TestErrors(unittest.TestCase):
def test_catch_child_failures_before_parent_failures(self):
"""
Verify that more specific Failures are caught first by
handleAllFailures() and failureToString().
Fails if a subclass is list... | from twisted.trial import unittest
import ooni.errors
class TestErrors(unittest.TestCase):
def test_catch_child_failures_before_parent_failures(self):
"""
Verify that more specific Failures are caught first by
handleAllFailures() and failureToString().
Fails if a subclass is list... | <commit_before>from twisted.trial import unittest
import ooni.errors
class TestErrors(unittest.TestCase):
def test_catch_child_failures_before_parent_failures(self):
"""
Verify that more specific Failures are caught first by
handleAllFailures() and failureToString().
Fails if a s... |
3d97a2ca6c4c285d59e3c823fbee94a494e85ba0 | app/tests/tests.py | app/tests/tests.py | import unittest
from app import serve
class PageCase(unittest.TestCase):
def setUp(self):
serve.app.config['TESTING'] = True
self.app = serve.app.test_client()
def test_index_load(self):
self.page_test('/', b'')
def test_robots_load(self):
self.page_test('/robots.txt', b... | import unittest
from varsnap import TestVarSnap # noqa: F401
from app import serve
class PageCase(unittest.TestCase):
def setUp(self):
serve.app.config['TESTING'] = True
self.app = serve.app.test_client()
def test_index_load(self):
self.page_test('/', b'')
def test_robots_load... | Add TestVarSnap as a TestCase | Add TestVarSnap as a TestCase
| Python | mit | albertyw/base-flask,albertyw/base-flask,albertyw/base-flask,albertyw/base-flask | import unittest
from app import serve
class PageCase(unittest.TestCase):
def setUp(self):
serve.app.config['TESTING'] = True
self.app = serve.app.test_client()
def test_index_load(self):
self.page_test('/', b'')
def test_robots_load(self):
self.page_test('/robots.txt', b... | import unittest
from varsnap import TestVarSnap # noqa: F401
from app import serve
class PageCase(unittest.TestCase):
def setUp(self):
serve.app.config['TESTING'] = True
self.app = serve.app.test_client()
def test_index_load(self):
self.page_test('/', b'')
def test_robots_load... | <commit_before>import unittest
from app import serve
class PageCase(unittest.TestCase):
def setUp(self):
serve.app.config['TESTING'] = True
self.app = serve.app.test_client()
def test_index_load(self):
self.page_test('/', b'')
def test_robots_load(self):
self.page_test('... | import unittest
from varsnap import TestVarSnap # noqa: F401
from app import serve
class PageCase(unittest.TestCase):
def setUp(self):
serve.app.config['TESTING'] = True
self.app = serve.app.test_client()
def test_index_load(self):
self.page_test('/', b'')
def test_robots_load... | import unittest
from app import serve
class PageCase(unittest.TestCase):
def setUp(self):
serve.app.config['TESTING'] = True
self.app = serve.app.test_client()
def test_index_load(self):
self.page_test('/', b'')
def test_robots_load(self):
self.page_test('/robots.txt', b... | <commit_before>import unittest
from app import serve
class PageCase(unittest.TestCase):
def setUp(self):
serve.app.config['TESTING'] = True
self.app = serve.app.test_client()
def test_index_load(self):
self.page_test('/', b'')
def test_robots_load(self):
self.page_test('... |
1975d5391f058f85272def4435b243440b72bff6 | weather/admin.py | weather/admin.py | from django.contrib.admin import ModelAdmin, register
from django.contrib.gis.admin import GeoModelAdmin
from weather.models import WeatherStation, Location
@register(Location)
class LocationAdmin(GeoModelAdmin):
openlayers_url = '//static.dpaw.wa.gov.au/static/libs/openlayers/2.13.1/OpenLayers.js'
list_displ... | from django.contrib.admin import ModelAdmin, register
from django.contrib.gis.admin import GeoModelAdmin
from weather.models import WeatherStation, Location
@register(Location)
class LocationAdmin(GeoModelAdmin):
list_display = ('pk', 'title', 'point', 'height')
@register(WeatherStation)
class WeatherStationAdm... | Remove custom OpenLayers.js from LocationAdmin. | Remove custom OpenLayers.js from LocationAdmin.
| Python | bsd-3-clause | parksandwildlife/resource_tracking,parksandwildlife/resource_tracking,parksandwildlife/resource_tracking,ropable/resource_tracking,ropable/resource_tracking,ropable/resource_tracking | from django.contrib.admin import ModelAdmin, register
from django.contrib.gis.admin import GeoModelAdmin
from weather.models import WeatherStation, Location
@register(Location)
class LocationAdmin(GeoModelAdmin):
openlayers_url = '//static.dpaw.wa.gov.au/static/libs/openlayers/2.13.1/OpenLayers.js'
list_displ... | from django.contrib.admin import ModelAdmin, register
from django.contrib.gis.admin import GeoModelAdmin
from weather.models import WeatherStation, Location
@register(Location)
class LocationAdmin(GeoModelAdmin):
list_display = ('pk', 'title', 'point', 'height')
@register(WeatherStation)
class WeatherStationAdm... | <commit_before>from django.contrib.admin import ModelAdmin, register
from django.contrib.gis.admin import GeoModelAdmin
from weather.models import WeatherStation, Location
@register(Location)
class LocationAdmin(GeoModelAdmin):
openlayers_url = '//static.dpaw.wa.gov.au/static/libs/openlayers/2.13.1/OpenLayers.js'... | from django.contrib.admin import ModelAdmin, register
from django.contrib.gis.admin import GeoModelAdmin
from weather.models import WeatherStation, Location
@register(Location)
class LocationAdmin(GeoModelAdmin):
list_display = ('pk', 'title', 'point', 'height')
@register(WeatherStation)
class WeatherStationAdm... | from django.contrib.admin import ModelAdmin, register
from django.contrib.gis.admin import GeoModelAdmin
from weather.models import WeatherStation, Location
@register(Location)
class LocationAdmin(GeoModelAdmin):
openlayers_url = '//static.dpaw.wa.gov.au/static/libs/openlayers/2.13.1/OpenLayers.js'
list_displ... | <commit_before>from django.contrib.admin import ModelAdmin, register
from django.contrib.gis.admin import GeoModelAdmin
from weather.models import WeatherStation, Location
@register(Location)
class LocationAdmin(GeoModelAdmin):
openlayers_url = '//static.dpaw.wa.gov.au/static/libs/openlayers/2.13.1/OpenLayers.js'... |
b2d654cf2af71b608d81c6501b214a9b330e1ffe | battlenet/utils.py | battlenet/utils.py | import unicodedata
import urllib
def normalize(name):
if not isinstance(name, unicode):
name = name.decode('utf-8')
return unicodedata.normalize('NFKC', name.replace("'", '')).encode('utf-8')
def quote(name):
if isinstance(name, unicode):
name = normalize(name).encode('utf8')
retur... | import unicodedata
import urllib
def normalize(name):
if not isinstance(name, unicode):
name = name.decode('utf-8')
return unicodedata.normalize('NFKC', name.replace("'", '')).encode('utf-8')
def quote(name):
if isinstance(name, unicode):
name = normalize(name)
return urllib.quote(... | Normalize already returns encoded value. | Normalize already returns encoded value.
| Python | mit | PuckCh/battlenet,vishnevskiy/battlenet | import unicodedata
import urllib
def normalize(name):
if not isinstance(name, unicode):
name = name.decode('utf-8')
return unicodedata.normalize('NFKC', name.replace("'", '')).encode('utf-8')
def quote(name):
if isinstance(name, unicode):
name = normalize(name).encode('utf8')
retur... | import unicodedata
import urllib
def normalize(name):
if not isinstance(name, unicode):
name = name.decode('utf-8')
return unicodedata.normalize('NFKC', name.replace("'", '')).encode('utf-8')
def quote(name):
if isinstance(name, unicode):
name = normalize(name)
return urllib.quote(... | <commit_before>import unicodedata
import urllib
def normalize(name):
if not isinstance(name, unicode):
name = name.decode('utf-8')
return unicodedata.normalize('NFKC', name.replace("'", '')).encode('utf-8')
def quote(name):
if isinstance(name, unicode):
name = normalize(name).encode('ut... | import unicodedata
import urllib
def normalize(name):
if not isinstance(name, unicode):
name = name.decode('utf-8')
return unicodedata.normalize('NFKC', name.replace("'", '')).encode('utf-8')
def quote(name):
if isinstance(name, unicode):
name = normalize(name)
return urllib.quote(... | import unicodedata
import urllib
def normalize(name):
if not isinstance(name, unicode):
name = name.decode('utf-8')
return unicodedata.normalize('NFKC', name.replace("'", '')).encode('utf-8')
def quote(name):
if isinstance(name, unicode):
name = normalize(name).encode('utf8')
retur... | <commit_before>import unicodedata
import urllib
def normalize(name):
if not isinstance(name, unicode):
name = name.decode('utf-8')
return unicodedata.normalize('NFKC', name.replace("'", '')).encode('utf-8')
def quote(name):
if isinstance(name, unicode):
name = normalize(name).encode('ut... |
99b1edfcc317dbb71b8dad9ad501aaa21f8044f9 | zorp/__init__.py | zorp/__init__.py | """
Zorp
"""
from zorp.client import Client
from zorp.decorator import remote_method
from zorp.server import Server
| """
Zorp
"""
from zorp.client import Client, TriesExceededException
from zorp.decorator import remote_method
from zorp.server import Server
| Add TriesExceededException to the base package | Add TriesExceededException to the base package
| Python | mit | proxama/zorp | """
Zorp
"""
from zorp.client import Client
from zorp.decorator import remote_method
from zorp.server import Server
Add TriesExceededException to the base package | """
Zorp
"""
from zorp.client import Client, TriesExceededException
from zorp.decorator import remote_method
from zorp.server import Server
| <commit_before>"""
Zorp
"""
from zorp.client import Client
from zorp.decorator import remote_method
from zorp.server import Server
<commit_msg>Add TriesExceededException to the base package<commit_after> | """
Zorp
"""
from zorp.client import Client, TriesExceededException
from zorp.decorator import remote_method
from zorp.server import Server
| """
Zorp
"""
from zorp.client import Client
from zorp.decorator import remote_method
from zorp.server import Server
Add TriesExceededException to the base package"""
Zorp
"""
from zorp.client import Client, TriesExceededException
from zorp.decorator import remote_method
from zorp.server import Server
| <commit_before>"""
Zorp
"""
from zorp.client import Client
from zorp.decorator import remote_method
from zorp.server import Server
<commit_msg>Add TriesExceededException to the base package<commit_after>"""
Zorp
"""
from zorp.client import Client, TriesExceededException
from zorp.decorator import remote_method
from z... |
cec7922ad7636f62be864d115f8e341ac511bbc9 | numba/tests/foreign_call/test_cffi_call.py | numba/tests/foreign_call/test_cffi_call.py | import os
import ctypes
import doctest
from numba import *
import numba
try:
import cffi
ffi = cffi.FFI()
except ImportError:
ffi = None
# ______________________________________________________________________
def test():
if ffi is not None:
test_cffi_calls()
# _____________________________... | import os
import ctypes
import doctest
from numba import *
import numba
try:
import cffi
ffi = cffi.FFI()
except ImportError:
ffi = None
# ______________________________________________________________________
def test():
if ffi is not None:
test_cffi_calls()
# _____________________________... | Fix CFFI test when executed multiple times | Fix CFFI test when executed multiple times
| Python | bsd-2-clause | stefanseefeld/numba,jriehl/numba,IntelLabs/numba,stonebig/numba,gmarkall/numba,numba/numba,GaZ3ll3/numba,stefanseefeld/numba,numba/numba,IntelLabs/numba,cpcloud/numba,sklam/numba,cpcloud/numba,IntelLabs/numba,shiquanwang/numba,stuartarchibald/numba,sklam/numba,pitrou/numba,gdementen/numba,gmarkall/numba,seibert/numba,s... | import os
import ctypes
import doctest
from numba import *
import numba
try:
import cffi
ffi = cffi.FFI()
except ImportError:
ffi = None
# ______________________________________________________________________
def test():
if ffi is not None:
test_cffi_calls()
# _____________________________... | import os
import ctypes
import doctest
from numba import *
import numba
try:
import cffi
ffi = cffi.FFI()
except ImportError:
ffi = None
# ______________________________________________________________________
def test():
if ffi is not None:
test_cffi_calls()
# _____________________________... | <commit_before>import os
import ctypes
import doctest
from numba import *
import numba
try:
import cffi
ffi = cffi.FFI()
except ImportError:
ffi = None
# ______________________________________________________________________
def test():
if ffi is not None:
test_cffi_calls()
# ______________... | import os
import ctypes
import doctest
from numba import *
import numba
try:
import cffi
ffi = cffi.FFI()
except ImportError:
ffi = None
# ______________________________________________________________________
def test():
if ffi is not None:
test_cffi_calls()
# _____________________________... | import os
import ctypes
import doctest
from numba import *
import numba
try:
import cffi
ffi = cffi.FFI()
except ImportError:
ffi = None
# ______________________________________________________________________
def test():
if ffi is not None:
test_cffi_calls()
# _____________________________... | <commit_before>import os
import ctypes
import doctest
from numba import *
import numba
try:
import cffi
ffi = cffi.FFI()
except ImportError:
ffi = None
# ______________________________________________________________________
def test():
if ffi is not None:
test_cffi_calls()
# ______________... |
6e2dae94239252f6b0338e609a838fa31e417842 | checks.d/veneur.py | checks.d/veneur.py | import datetime
from urlparse import urljoin
import requests
# project
from checks import AgentCheck
class Veneur(AgentCheck):
VERSION_METRIC_NAME = 'veneur.deployed_version'
BUILDAGE_METRIC_NAME = 'veneur.build_age'
ERROR_METRIC_NAME = 'veneur.agent_check.errors_total'
def check(self, instance):
... | import datetime
from urlparse import urljoin
import requests
# project
from checks import AgentCheck
class Veneur(AgentCheck):
VERSION_METRIC_NAME = 'veneur.deployed_version'
BUILDAGE_METRIC_NAME = 'veneur.build_age'
ERROR_METRIC_NAME = 'veneur.agent_check.errors_total'
def check(self, instance):
... | Add the sha to the tags in a way that won't cause an error | Add the sha to the tags in a way that won't cause an error
| Python | mit | stripe/stripe-datadog-checks,stripe/datadog-checks | import datetime
from urlparse import urljoin
import requests
# project
from checks import AgentCheck
class Veneur(AgentCheck):
VERSION_METRIC_NAME = 'veneur.deployed_version'
BUILDAGE_METRIC_NAME = 'veneur.build_age'
ERROR_METRIC_NAME = 'veneur.agent_check.errors_total'
def check(self, instance):
... | import datetime
from urlparse import urljoin
import requests
# project
from checks import AgentCheck
class Veneur(AgentCheck):
VERSION_METRIC_NAME = 'veneur.deployed_version'
BUILDAGE_METRIC_NAME = 'veneur.build_age'
ERROR_METRIC_NAME = 'veneur.agent_check.errors_total'
def check(self, instance):
... | <commit_before>import datetime
from urlparse import urljoin
import requests
# project
from checks import AgentCheck
class Veneur(AgentCheck):
VERSION_METRIC_NAME = 'veneur.deployed_version'
BUILDAGE_METRIC_NAME = 'veneur.build_age'
ERROR_METRIC_NAME = 'veneur.agent_check.errors_total'
def check(self... | import datetime
from urlparse import urljoin
import requests
# project
from checks import AgentCheck
class Veneur(AgentCheck):
VERSION_METRIC_NAME = 'veneur.deployed_version'
BUILDAGE_METRIC_NAME = 'veneur.build_age'
ERROR_METRIC_NAME = 'veneur.agent_check.errors_total'
def check(self, instance):
... | import datetime
from urlparse import urljoin
import requests
# project
from checks import AgentCheck
class Veneur(AgentCheck):
VERSION_METRIC_NAME = 'veneur.deployed_version'
BUILDAGE_METRIC_NAME = 'veneur.build_age'
ERROR_METRIC_NAME = 'veneur.agent_check.errors_total'
def check(self, instance):
... | <commit_before>import datetime
from urlparse import urljoin
import requests
# project
from checks import AgentCheck
class Veneur(AgentCheck):
VERSION_METRIC_NAME = 'veneur.deployed_version'
BUILDAGE_METRIC_NAME = 'veneur.build_age'
ERROR_METRIC_NAME = 'veneur.agent_check.errors_total'
def check(self... |
cc00cc1c2539eb7dbeed2656e1929c8c53c4dd98 | pyverdict/pyverdict/datatype_converters/impala_converter.py | pyverdict/pyverdict/datatype_converters/impala_converter.py | from .converter_base import DatatypeConverterBase
import dateutil
def _str_to_datetime(java_obj, idx):
return dateutil.parser.parse(java_obj.getString(idx))
_typename_to_converter_fxn = {'timestamp': _str_to_datetime}
class ImpalaConverter(DatatypeConverterBase):
@staticmethod
def read_value(result_set... | from .converter_base import DatatypeConverterBase
import dateutil
def _str_to_datetime(java_obj, idx):
return dateutil.parser.parse(java_obj.getString(idx))
_typename_to_converter_fxn = {'timestamp': _str_to_datetime}
class ImpalaConverter(DatatypeConverterBase):
'''
Type conversion rule:
BIGI... | Add type conversion rule comment | Add type conversion rule comment
| Python | apache-2.0 | mozafari/verdict,mozafari/verdict,mozafari/verdict,mozafari/verdict,mozafari/verdict | from .converter_base import DatatypeConverterBase
import dateutil
def _str_to_datetime(java_obj, idx):
return dateutil.parser.parse(java_obj.getString(idx))
_typename_to_converter_fxn = {'timestamp': _str_to_datetime}
class ImpalaConverter(DatatypeConverterBase):
@staticmethod
def read_value(result_set... | from .converter_base import DatatypeConverterBase
import dateutil
def _str_to_datetime(java_obj, idx):
return dateutil.parser.parse(java_obj.getString(idx))
_typename_to_converter_fxn = {'timestamp': _str_to_datetime}
class ImpalaConverter(DatatypeConverterBase):
'''
Type conversion rule:
BIGI... | <commit_before>from .converter_base import DatatypeConverterBase
import dateutil
def _str_to_datetime(java_obj, idx):
return dateutil.parser.parse(java_obj.getString(idx))
_typename_to_converter_fxn = {'timestamp': _str_to_datetime}
class ImpalaConverter(DatatypeConverterBase):
@staticmethod
def read_v... | from .converter_base import DatatypeConverterBase
import dateutil
def _str_to_datetime(java_obj, idx):
return dateutil.parser.parse(java_obj.getString(idx))
_typename_to_converter_fxn = {'timestamp': _str_to_datetime}
class ImpalaConverter(DatatypeConverterBase):
'''
Type conversion rule:
BIGI... | from .converter_base import DatatypeConverterBase
import dateutil
def _str_to_datetime(java_obj, idx):
return dateutil.parser.parse(java_obj.getString(idx))
_typename_to_converter_fxn = {'timestamp': _str_to_datetime}
class ImpalaConverter(DatatypeConverterBase):
@staticmethod
def read_value(result_set... | <commit_before>from .converter_base import DatatypeConverterBase
import dateutil
def _str_to_datetime(java_obj, idx):
return dateutil.parser.parse(java_obj.getString(idx))
_typename_to_converter_fxn = {'timestamp': _str_to_datetime}
class ImpalaConverter(DatatypeConverterBase):
@staticmethod
def read_v... |
f5f4397d026678570ad271e84099d2bcec541c72 | whacked4/whacked4/ui/dialogs/startdialog.py | whacked4/whacked4/ui/dialogs/startdialog.py | #!/usr/bin/env python
#coding=utf8
from whacked4 import config
from whacked4.ui import windows
class StartDialog(windows.StartDialogBase):
"""
This dialog is meant to be displayed on startup of the application. It allows the user to quickly
access some common functions without having to dig down into a m... | #!/usr/bin/env python
#coding=utf8
from whacked4 import config
from whacked4.ui import windows
class StartDialog(windows.StartDialogBase):
"""
This dialog is meant to be displayed on startup of the application. It allows the user to quickly
access some common functions without having to dig down into a m... | Clean the recent files list before displaying it in the startup dialog. | Clean the recent files list before displaying it in the startup dialog.
| Python | bsd-2-clause | GitExl/WhackEd4,GitExl/WhackEd4 | #!/usr/bin/env python
#coding=utf8
from whacked4 import config
from whacked4.ui import windows
class StartDialog(windows.StartDialogBase):
"""
This dialog is meant to be displayed on startup of the application. It allows the user to quickly
access some common functions without having to dig down into a m... | #!/usr/bin/env python
#coding=utf8
from whacked4 import config
from whacked4.ui import windows
class StartDialog(windows.StartDialogBase):
"""
This dialog is meant to be displayed on startup of the application. It allows the user to quickly
access some common functions without having to dig down into a m... | <commit_before>#!/usr/bin/env python
#coding=utf8
from whacked4 import config
from whacked4.ui import windows
class StartDialog(windows.StartDialogBase):
"""
This dialog is meant to be displayed on startup of the application. It allows the user to quickly
access some common functions without having to di... | #!/usr/bin/env python
#coding=utf8
from whacked4 import config
from whacked4.ui import windows
class StartDialog(windows.StartDialogBase):
"""
This dialog is meant to be displayed on startup of the application. It allows the user to quickly
access some common functions without having to dig down into a m... | #!/usr/bin/env python
#coding=utf8
from whacked4 import config
from whacked4.ui import windows
class StartDialog(windows.StartDialogBase):
"""
This dialog is meant to be displayed on startup of the application. It allows the user to quickly
access some common functions without having to dig down into a m... | <commit_before>#!/usr/bin/env python
#coding=utf8
from whacked4 import config
from whacked4.ui import windows
class StartDialog(windows.StartDialogBase):
"""
This dialog is meant to be displayed on startup of the application. It allows the user to quickly
access some common functions without having to di... |
84b27afce57232bc0c8170eaad1beb26fd96eef0 | tools/gyp/find_mac_gcc_version.py | tools/gyp/find_mac_gcc_version.py | #!/usr/bin/env python
# Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
import re
import subprocess
import sys
def main():
job = subprocess.Popen(['xcode... | #!/usr/bin/env python
# Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
import re
import subprocess
import sys
def main():
job = subprocess.Popen(['xcode... | Use clang on mac if XCode >= 4.5 | Use clang on mac if XCode >= 4.5
Review URL: https://codereview.chromium.org//14333010
git-svn-id: c93d8a2297af3b929165606efe145742a534bc71@21950 260f80e4-7a28-3924-810f-c04153c831b5
| Python | bsd-3-clause | dart-archive/dart-sdk,dartino/dart-sdk,dartino/dart-sdk,dart-lang/sdk,dart-lang/sdk,dart-archive/dart-sdk,dartino/dart-sdk,dart-lang/sdk,dartino/dart-sdk,dartino/dart-sdk,dart-archive/dart-sdk,dart-archive/dart-sdk,dart-archive/dart-sdk,dart-archive/dart-sdk,dart-lang/sdk,dart-lang/sdk,dartino/dart-sdk,dart-archive/dar... | #!/usr/bin/env python
# Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
import re
import subprocess
import sys
def main():
job = subprocess.Popen(['xcode... | #!/usr/bin/env python
# Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
import re
import subprocess
import sys
def main():
job = subprocess.Popen(['xcode... | <commit_before>#!/usr/bin/env python
# Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
import re
import subprocess
import sys
def main():
job = subproces... | #!/usr/bin/env python
# Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
import re
import subprocess
import sys
def main():
job = subprocess.Popen(['xcode... | #!/usr/bin/env python
# Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
import re
import subprocess
import sys
def main():
job = subprocess.Popen(['xcode... | <commit_before>#!/usr/bin/env python
# Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
import re
import subprocess
import sys
def main():
job = subproces... |
16742262b6a37f34bf83b3b6d6bcfd72e69276b2 | imagersite/imager_profile/models.py | imagersite/imager_profile/models.py | import six
from django.db import models
from django.contrib.auth.models import User
@six.python_2_unicode_compatible
class ImagerProfile(models.Model):
user = models.OneToOneField(User)
fav_camera = models.CharField(max_length=30)
address = models.CharField(max_length=100)
web_url = models.URLField()... | import six
from django.db import models
from django.contrib.auth.models import ActiveProfileManager, User
@six.python_2_unicode_compatible
class ImagerProfile(models.Model):
user = models.OneToOneField(
User,
nullable=False
)
fav_camera = models.CharField(
max_length=30
)
... | Make sure a user has profile | Make sure a user has profile
| Python | mit | jesseklein406/django-imager,jesseklein406/django-imager,jesseklein406/django-imager | import six
from django.db import models
from django.contrib.auth.models import User
@six.python_2_unicode_compatible
class ImagerProfile(models.Model):
user = models.OneToOneField(User)
fav_camera = models.CharField(max_length=30)
address = models.CharField(max_length=100)
web_url = models.URLField()... | import six
from django.db import models
from django.contrib.auth.models import ActiveProfileManager, User
@six.python_2_unicode_compatible
class ImagerProfile(models.Model):
user = models.OneToOneField(
User,
nullable=False
)
fav_camera = models.CharField(
max_length=30
)
... | <commit_before>import six
from django.db import models
from django.contrib.auth.models import User
@six.python_2_unicode_compatible
class ImagerProfile(models.Model):
user = models.OneToOneField(User)
fav_camera = models.CharField(max_length=30)
address = models.CharField(max_length=100)
web_url = mo... | import six
from django.db import models
from django.contrib.auth.models import ActiveProfileManager, User
@six.python_2_unicode_compatible
class ImagerProfile(models.Model):
user = models.OneToOneField(
User,
nullable=False
)
fav_camera = models.CharField(
max_length=30
)
... | import six
from django.db import models
from django.contrib.auth.models import User
@six.python_2_unicode_compatible
class ImagerProfile(models.Model):
user = models.OneToOneField(User)
fav_camera = models.CharField(max_length=30)
address = models.CharField(max_length=100)
web_url = models.URLField()... | <commit_before>import six
from django.db import models
from django.contrib.auth.models import User
@six.python_2_unicode_compatible
class ImagerProfile(models.Model):
user = models.OneToOneField(User)
fav_camera = models.CharField(max_length=30)
address = models.CharField(max_length=100)
web_url = mo... |
1a089ec6f34ebf81b4437b6f541ee2b9f4b85966 | osf/migrations/0145_pagecounter_data.py | osf/migrations/0145_pagecounter_data.py | # -*- coding: utf-8 -*-
# Generated by Django 1.11.15 on 2018-11-12 17:18
from __future__ import unicode_literals
from django.db import migrations, connection
def reverse_func(state, schema):
with connection.cursor() as cursor:
cursor.execute(
"""
UPDATE osf_pagecounter
... | # -*- coding: utf-8 -*-
# Generated by Django 1.11.15 on 2018-11-12 17:18
from __future__ import unicode_literals
from django.db import migrations
reverse_func = [
"""
UPDATE osf_pagecounter
SET (action, guid_id, file_id, version) = ('download', NULL, NULL, NULL);
"""
]
# Splits the data in pagecount... | Call RunSQL instead of RunPython in pagecounter data migration. | Call RunSQL instead of RunPython in pagecounter data migration.
| Python | apache-2.0 | cslzchen/osf.io,cslzchen/osf.io,Johnetordoff/osf.io,saradbowman/osf.io,felliott/osf.io,baylee-d/osf.io,mattclark/osf.io,mfraezz/osf.io,aaxelb/osf.io,felliott/osf.io,mfraezz/osf.io,brianjgeiger/osf.io,cslzchen/osf.io,CenterForOpenScience/osf.io,aaxelb/osf.io,mattclark/osf.io,adlius/osf.io,saradbowman/osf.io,adlius/osf.i... | # -*- coding: utf-8 -*-
# Generated by Django 1.11.15 on 2018-11-12 17:18
from __future__ import unicode_literals
from django.db import migrations, connection
def reverse_func(state, schema):
with connection.cursor() as cursor:
cursor.execute(
"""
UPDATE osf_pagecounter
... | # -*- coding: utf-8 -*-
# Generated by Django 1.11.15 on 2018-11-12 17:18
from __future__ import unicode_literals
from django.db import migrations
reverse_func = [
"""
UPDATE osf_pagecounter
SET (action, guid_id, file_id, version) = ('download', NULL, NULL, NULL);
"""
]
# Splits the data in pagecount... | <commit_before># -*- coding: utf-8 -*-
# Generated by Django 1.11.15 on 2018-11-12 17:18
from __future__ import unicode_literals
from django.db import migrations, connection
def reverse_func(state, schema):
with connection.cursor() as cursor:
cursor.execute(
"""
UPDATE osf_pagecou... | # -*- coding: utf-8 -*-
# Generated by Django 1.11.15 on 2018-11-12 17:18
from __future__ import unicode_literals
from django.db import migrations
reverse_func = [
"""
UPDATE osf_pagecounter
SET (action, guid_id, file_id, version) = ('download', NULL, NULL, NULL);
"""
]
# Splits the data in pagecount... | # -*- coding: utf-8 -*-
# Generated by Django 1.11.15 on 2018-11-12 17:18
from __future__ import unicode_literals
from django.db import migrations, connection
def reverse_func(state, schema):
with connection.cursor() as cursor:
cursor.execute(
"""
UPDATE osf_pagecounter
... | <commit_before># -*- coding: utf-8 -*-
# Generated by Django 1.11.15 on 2018-11-12 17:18
from __future__ import unicode_literals
from django.db import migrations, connection
def reverse_func(state, schema):
with connection.cursor() as cursor:
cursor.execute(
"""
UPDATE osf_pagecou... |
050394cc0c228edf8ac9c3ea6f2001d36d874841 | spdypy/connection.py | spdypy/connection.py | # -*- coding: utf-8 -*-
"""
spdypy.connection
~~~~~~~~~~~~~~~~~
Contains the code necessary for working with SPDY connections.
"""
# Define some states for SPDYConnections.
NEW = 'NEW'
class SPDYConnection(object):
"""
A representation of a single SPDY connection to a remote server. This
object takes resp... | # -*- coding: utf-8 -*-
"""
spdypy.connection
~~~~~~~~~~~~~~~~~
Contains the code necessary for working with SPDY connections.
"""
# Define some states for SPDYConnections.
NEW = 'NEW'
class SPDYConnection(object):
"""
A representation of a single SPDY connection to a remote server. This
object takes res... | Define the shell of the request method. | Define the shell of the request method.
| Python | mit | Lukasa/spdypy | # -*- coding: utf-8 -*-
"""
spdypy.connection
~~~~~~~~~~~~~~~~~
Contains the code necessary for working with SPDY connections.
"""
# Define some states for SPDYConnections.
NEW = 'NEW'
class SPDYConnection(object):
"""
A representation of a single SPDY connection to a remote server. This
object takes resp... | # -*- coding: utf-8 -*-
"""
spdypy.connection
~~~~~~~~~~~~~~~~~
Contains the code necessary for working with SPDY connections.
"""
# Define some states for SPDYConnections.
NEW = 'NEW'
class SPDYConnection(object):
"""
A representation of a single SPDY connection to a remote server. This
object takes res... | <commit_before># -*- coding: utf-8 -*-
"""
spdypy.connection
~~~~~~~~~~~~~~~~~
Contains the code necessary for working with SPDY connections.
"""
# Define some states for SPDYConnections.
NEW = 'NEW'
class SPDYConnection(object):
"""
A representation of a single SPDY connection to a remote server. This
ob... | # -*- coding: utf-8 -*-
"""
spdypy.connection
~~~~~~~~~~~~~~~~~
Contains the code necessary for working with SPDY connections.
"""
# Define some states for SPDYConnections.
NEW = 'NEW'
class SPDYConnection(object):
"""
A representation of a single SPDY connection to a remote server. This
object takes res... | # -*- coding: utf-8 -*-
"""
spdypy.connection
~~~~~~~~~~~~~~~~~
Contains the code necessary for working with SPDY connections.
"""
# Define some states for SPDYConnections.
NEW = 'NEW'
class SPDYConnection(object):
"""
A representation of a single SPDY connection to a remote server. This
object takes resp... | <commit_before># -*- coding: utf-8 -*-
"""
spdypy.connection
~~~~~~~~~~~~~~~~~
Contains the code necessary for working with SPDY connections.
"""
# Define some states for SPDYConnections.
NEW = 'NEW'
class SPDYConnection(object):
"""
A representation of a single SPDY connection to a remote server. This
ob... |
e3a298bcbe0eac1d2a0ade13244b0f3650bd6c49 | pyinfra/pseudo_modules.py | pyinfra/pseudo_modules.py | # pyinfra
# File: pyinfra/pseudo_modules.py
# Desc: essentially a hack that provides dynamic imports for the current deploy (CLI only)
import sys
import pyinfra
class PseudoModule(object):
_module = None
def __getattr__(self, key):
return getattr(self._module, key)
def __setattr__(self, key, va... | # pyinfra
# File: pyinfra/pseudo_modules.py
# Desc: essentially a hack that provides dynamic imports for the current deploy (CLI only)
import sys
import pyinfra
class PseudoModule(object):
_module = None
def __getattr__(self, key):
return getattr(self._module, key)
def __setattr__(self, key, va... | Add getitem and len support for pseudo modules. | Add getitem and len support for pseudo modules.
| Python | mit | Fizzadar/pyinfra,Fizzadar/pyinfra | # pyinfra
# File: pyinfra/pseudo_modules.py
# Desc: essentially a hack that provides dynamic imports for the current deploy (CLI only)
import sys
import pyinfra
class PseudoModule(object):
_module = None
def __getattr__(self, key):
return getattr(self._module, key)
def __setattr__(self, key, va... | # pyinfra
# File: pyinfra/pseudo_modules.py
# Desc: essentially a hack that provides dynamic imports for the current deploy (CLI only)
import sys
import pyinfra
class PseudoModule(object):
_module = None
def __getattr__(self, key):
return getattr(self._module, key)
def __setattr__(self, key, va... | <commit_before># pyinfra
# File: pyinfra/pseudo_modules.py
# Desc: essentially a hack that provides dynamic imports for the current deploy (CLI only)
import sys
import pyinfra
class PseudoModule(object):
_module = None
def __getattr__(self, key):
return getattr(self._module, key)
def __setattr_... | # pyinfra
# File: pyinfra/pseudo_modules.py
# Desc: essentially a hack that provides dynamic imports for the current deploy (CLI only)
import sys
import pyinfra
class PseudoModule(object):
_module = None
def __getattr__(self, key):
return getattr(self._module, key)
def __setattr__(self, key, va... | # pyinfra
# File: pyinfra/pseudo_modules.py
# Desc: essentially a hack that provides dynamic imports for the current deploy (CLI only)
import sys
import pyinfra
class PseudoModule(object):
_module = None
def __getattr__(self, key):
return getattr(self._module, key)
def __setattr__(self, key, va... | <commit_before># pyinfra
# File: pyinfra/pseudo_modules.py
# Desc: essentially a hack that provides dynamic imports for the current deploy (CLI only)
import sys
import pyinfra
class PseudoModule(object):
_module = None
def __getattr__(self, key):
return getattr(self._module, key)
def __setattr_... |
e83019f67a3c93efac27566666bcff5eb0d2a0da | examples/autopost/auto_post.py | examples/autopost/auto_post.py | import time
import sys
import os
import glob
sys.path.append(os.path.join(sys.path[0], '../../'))
from instabot import Bot
posted_pic_list = []
try:
with open('pics.txt', 'r') as f:
posted_pic_list = f.read().splitlines()
except Exception:
posted_pic_list = []
timeout = 24 * 60 * 60 # pics will be p... | import glob
import os
import sys
import time
from io import open
sys.path.append(os.path.join(sys.path[0], '../../'))
from instabot import Bot
posted_pic_list = []
try:
with open('pics.txt', 'r', encoding='utf8') as f:
posted_pic_list = f.read().splitlines()
except Exception:
posted_pic_list = []
ti... | Add utf-8 in autopost example | Add utf-8 in autopost example
| Python | apache-2.0 | instagrambot/instabot,ohld/instabot,instagrambot/instabot | import time
import sys
import os
import glob
sys.path.append(os.path.join(sys.path[0], '../../'))
from instabot import Bot
posted_pic_list = []
try:
with open('pics.txt', 'r') as f:
posted_pic_list = f.read().splitlines()
except Exception:
posted_pic_list = []
timeout = 24 * 60 * 60 # pics will be p... | import glob
import os
import sys
import time
from io import open
sys.path.append(os.path.join(sys.path[0], '../../'))
from instabot import Bot
posted_pic_list = []
try:
with open('pics.txt', 'r', encoding='utf8') as f:
posted_pic_list = f.read().splitlines()
except Exception:
posted_pic_list = []
ti... | <commit_before>import time
import sys
import os
import glob
sys.path.append(os.path.join(sys.path[0], '../../'))
from instabot import Bot
posted_pic_list = []
try:
with open('pics.txt', 'r') as f:
posted_pic_list = f.read().splitlines()
except Exception:
posted_pic_list = []
timeout = 24 * 60 * 60 #... | import glob
import os
import sys
import time
from io import open
sys.path.append(os.path.join(sys.path[0], '../../'))
from instabot import Bot
posted_pic_list = []
try:
with open('pics.txt', 'r', encoding='utf8') as f:
posted_pic_list = f.read().splitlines()
except Exception:
posted_pic_list = []
ti... | import time
import sys
import os
import glob
sys.path.append(os.path.join(sys.path[0], '../../'))
from instabot import Bot
posted_pic_list = []
try:
with open('pics.txt', 'r') as f:
posted_pic_list = f.read().splitlines()
except Exception:
posted_pic_list = []
timeout = 24 * 60 * 60 # pics will be p... | <commit_before>import time
import sys
import os
import glob
sys.path.append(os.path.join(sys.path[0], '../../'))
from instabot import Bot
posted_pic_list = []
try:
with open('pics.txt', 'r') as f:
posted_pic_list = f.read().splitlines()
except Exception:
posted_pic_list = []
timeout = 24 * 60 * 60 #... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.