I hereby claim:
- I am micktwomey on github.
- I am micktwomey (https://keybase.io/micktwomey) on keybase.
- I have a public key whose fingerprint is 1D6D 1310 409E 5801 A5EA DA4B 1714 CC85 82E2 B3E3
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
| --- /dev/fd/63 2012-10-25 16:46:38.000000000 +0100 | |
| +++ /dev/fd/62 2012-10-25 16:46:38.000000000 +0100 | |
| @@ -1,6 +1,6 @@ | |
| # Redis configuration file example | |
| -# Note on units: when memory size is needed, it is possible to specifiy | |
| +# Note on units: when memory size is needed, it is possible to specify | |
| # it in the usual form of 1k 5GB 4M and so forth: | |
| # |
| """WSGI middleware and test code to munge utf-8 | |
| To work around narrow builds you need to do this: | |
| re.sub(r'\\U[0-9a-f]{8}', '\\ufffd', s.encode("unicode_escape")).decode("unicode_escape") | |
| (Use the representation) | |
| """ |
| import contextlib | |
| import functools | |
| @contextlib.contextmanager | |
| def forgiveness(exceptions): | |
| """Seek forgiveness | |
| """ | |
| try: | |
| yield |
| """Class for printing reports on profiled python code.""" | |
| # Modified by mtt to support loading of stats without creating file objects | |
| # Class for printing reports on profiled python code. rev 1.0 4/1/94 | |
| # | |
| # Based on prior profile module by Sjoerd Mullender... | |
| # which was hacked somewhat by: Guido van Rossum | |
| # | |
| # see profile.doc and profile.py for more info. |
| scheme number | |
| scheme1 5.23456 | |
| scheme2 563.7655 | |
| scheme3 34534.734534 | |
| scheme4 34534.76546756 |
| import socket | |
| if __name__ == "__main__": | |
| sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) | |
| sock.connect(("localhost", 9000)) | |
| data = "some data" | |
| sock.sendall(data) | |
| result = sock.recv(1024) | |
| print result | |
| sock.close() |
| """Generic URI parsing | |
| Intended to be more generally applicable than urlparse. | |
| """ | |
| import cgi | |
| import re | |
| import urllib |
| """My old blog -> tumblr importer | |
| """ | |
| import csv | |
| from getpass import getpass | |
| import json | |
| import logging | |
| import sys | |
| import urllib |
| from pkg_resources import resource_filename | |
| (r"^media/(?P<path>.*)$", 'django.views.static.serve', {'document_root': resource_filename('django.contrib.admin', 'media')}), |