I hereby claim:
- I am charlax on github.
- I am charlax (https://keybase.io/charlax) on keybase.
- I have a public key ASAnaIUUkAE-_KNoDaPZOMIa49XGlkuYBlKsFqs4gdORAAo
To claim this, I am signing this object:
[tool.poetry] | |
name = "poetrytest" | |
version = "0.1.0" | |
description = "" | |
authors = ["Charlax <redacted>"] | |
[tool.poetry.dependencies] | |
python = "^3.9" | |
[tool.poetry.dev-dependencies] |
I hereby claim:
To claim this, I am signing this object:
tell application "Google Chrome" | |
set myURL to URL of active tab of front window | |
set myTitle to title of active tab of front window | |
set link to "[" & myTitle & "](" & myURL & ")" | |
return link | |
end tell |
SWIG/_m2crypto.i:30: Error: Unable to find 'openssl/opensslv.h' | |
SWIG/_m2crypto.i:33: Error: Unable to find 'openssl/safestack.h' | |
SWIG/_evp.i:12: Error: Unable to find 'openssl/opensslconf.h' | |
SWIG/_ec.i:7: Error: Unable to find 'openssl/opensslconf.h' | |
error: command 'swig' failed with exit status 1 |
In [1]: import ujson | |
In [2]: d = {"e": {"e": {"e": {c: str(c) for c in range(100)}}}} | |
In [3]: %paste | |
import copy | |
def make_hash(o): | |
""" |
Factories are great when your business logic does not really depend on complex objects relationships and setup.
Fixtures are more powerful when you need to setup a complex object architecture with very specific attributes. For instance, if you want to test a tax engine that depends on a set of transactions with very specific attributes (currencies, amounts, etc.), a set of users with very specific attributes (citizenship, business status, etc.), it will be easier to write this setup using fixtures.
client:
fields:
name: Charles
client_french:
from alembic.script import ScriptDirectory | |
from alembic.config import Config | |
from alembic.migration import MigrationContext | |
from sqlalchemy import create_engine | |
# current head | |
config = Config() | |
config.set_main_option("script_location", "myapp:migrations") | |
script = ScriptDirectory.from_config(config) | |
head_revision = script.get_current_head() |
class ProgressChord(chord): | |
""" | |
Chord that returns both the callback's AsyncResult and the group's | |
AsyncResult. | |
""" | |
# See: | |
# http://stackoverflow.com/questions/15441101/how-to-track-the-progress-of-individual-tasks-inside-a-group-which-forms-the-hea | |
# https://groups.google.com/forum/?fromgroups=#!topic/celery-users/xSdxI-Z08Cw |
import time | |
from celery import chord | |
from celery.utils import uuid | |
from my_app.celery import celery | |
class ProgressChord(chord): |
from sqlalchemy import Column, Integer, Unicode | |
from sqlalchemy import create_engine | |
from sqlalchemy.orm import sessionmaker, scoped_session | |
from sqlalchemy.ext.declarative import declarative_base | |
Base = declarative_base() | |
Session = scoped_session(sessionmaker()) | |
class User(Base): |