Skip to content

Instantly share code, notes, and snippets.


Éric Araujo merwok

  • Caravan Coop
  • Montréal, Québec, Canada
View GitHub Profile
merwok / app.ini
Last active Jan 17, 2020
test app for custom predicate docs —
View app.ini
use = call:helloapp:main
pyramid.debug_notfound = true
pyramid.debug_routematch = true
pyramid.includes =
use = egg:waitress#main
merwok /
Last active Dec 28, 2020
Example code to reconcile django-storages and django-filebrowser-no-grappelli
import posixpath
from import StorageMixin
from storages.backends.s3boto3 import S3Boto3Storage
class S3Storage(StorageMixin, S3Boto3Storage):
"""Integration between filebrowser and S3 storage."""
def isdir(self, name):

Keybase proof

I hereby claim:

  • I am merwok on github.
  • I am merwok ( on keybase.
  • I have a public key whose fingerprint is B3B4 BE9F D83F 8A80 1450 9B13 D8F3 C537 2C03 6A62

To claim this, I am signing this object:

merwok /
Created Apr 12, 2017 — forked from pior/
Keep your deployment secrets out of your PasterDeploy configuration using Environment Variables
import os
from pyramid.config import Configurator
def main(global_config, **settings):
settings = {k: os.path.expandvars(v) for k, v in settings.items()}
config = Configurator(settings=settings)
return config.make_wsgi_app()
import collections
class OrderedDefaultDict(collections.OrderedDict, collections.defaultdict):
odd = OrderedDefaultDict()
odd.default_factory = list
View mtlpy-workshop-debian-dev-env-fr.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
merwok / gist:2636213
Created May 8, 2012
ReplicaSetConnection for mongokit
View gist:2636213
import pymongo
from mongokit.database import Database
# code copied and adapted from mongokit (3-clause BSD license)
class CallableMixin(object):
brings the callable method to a Document. usefull for the connection's
register method