Skip to content

Instantly share code, notes, and snippets.

@armooo
armooo / gist:5379401
Created April 13, 2013 17:59
the trace function only starts working once the stack frame changes
import sys
def bar(frame, event, arg):
print('line', frame.f_lineno)
print('file', frame.f_code.co_filename)
print('event', event)
#print('arg', arg)
if event == 'call':
return bar
def fail():
playlist: &playlist
!!python/object/apply:jukebox.song.Playlist
args:
storage: &storage
!!python/object/apply:jukebox.storage.MemoryStorage
args:
scanner:
!!python/object/apply:jukebox.scanner.DirScanner

Keybase proof

I hereby claim:

  • I am armooo on github.
  • I am armooo (https://keybase.io/armooo) on keybase.
  • I have a public key ASDdJ6uYsYtt8OXCKR7mcUukUx53uhFdGF92-ZyJgs8zMQo

To claim this, I am signing this object: