View gist:216f4e8d990de7e895c1e3f1a8185538
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
https://squoosh.app/editor | |
npx @squoosh/cli --resize '{"enabled":true,"width":1024,"height":737,"method":"triangle","fitMethod":"stretch","premultiply":false,"linearRGB":false}' --quant '{"enabled":true,"zx":0,"maxNumColors":256,"dither":1}' --oxipng '{"level":3}' |
View test_datetime.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import datetime | |
date = datetime.datetime(2013, 7, 2, 0, 0) | |
has_time = date and date.time() | |
print("** has time: %s" % has_time) | |
if has_time: | |
print("** date: %s" % date.strftime('%H-%M-%S')) | |
else: |
View conftest.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pytest | |
@pytest.fixture(name="fish") | |
def fixture_fish(taste): | |
pass | |
def pytest_generate_tests(metafunc): | |
if "taste" in metafunc.fixturenames: |
View example_mro.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Process(object): | |
def __init__(self, group=None, target=None, name=None, *args, **kwargs): | |
print 'Process __init__' | |
print '* args: {}'.format(args) | |
print '* kwargs: {}'.format(kwargs) | |
class BlockingChannel(object): | |
def __init__(self, channel, *args, **kwargs): | |
super(BlockingChannel, self).__init__(*args, **kwargs) |
View gist:79ae3e1b1d7ffd641773
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[testrun] | |
script=update | |
target-revision=fb3494d06dfb | |
target-version=46.0b1#8 | |
channel=beta-localtest | |
[windows xp 32bit] | |
platform=win32 | |
45.0b6=en-US |