Skip to content

Instantly share code, notes, and snippets.

@asnr
asnr / Dockerfile.client
Last active June 26, 2019 18:28
Reproduce Pub/Sub publish even after timeout
FROM python:2.7-jessie
RUN pip install google-cloud-pubsub==0.42.1
@asnr
asnr / Dockerfile.client
Created May 20, 2019 01:53
Reproduce pubsub-ddtrace integration error
FROM python:2.7-jessie
RUN pip install ddtrace==0.25.0 google-cloud-pubsub==0.41.0
@asnr
asnr / lexer.rb
Last active April 11, 2018 11:07
Lisp parser. To run: $ ruby lisp.rb -e '(first (list 1 (+ 2 3) 9))'
# frozen_string_literal: true
require 'strscan'
require './tokens'
require './token_stream'
class Lexer
TOKEN_TYPES = [OpenParens, CloseParens, Name, IntegerToken, Whitespace].freeze
def tokenize(code)

Keybase proof

I hereby claim:

  • I am asnr on github.
  • I am asnr (https://keybase.io/asnr) on keybase.
  • I have a public key ASBPC_UGk4cDw7vbGT8SAmTlxRzSy38CgXpEEuJxcaPjzAo

To claim this, I am signing this object:

@asnr
asnr / django_postgres_heroku.md
Created July 5, 2015 08:00
How to get django running with a Postgres backend on Heroku

Django, Postgres then Heroku

Django is running using sqlite local backend, let's upgrade to Postgres.

Install & configure postgres