Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2b3889e
commit 8275a10
Showing
1 changed file
with
35 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,51 +1,51 @@ | ||
__ | ||
/ _|_ __ __ _ _ __ ___ ___ ___ _ __ _ _ | ||
| |_| '__/ _` | '_ ` _ \ / _ \/ __| | '_ \| | | | | ||
| _| | | (_| | | | | | | __/\__ \_| |_) | |_| | | ||
|_| |_| \__,_|_| |_| |_|\___||___(_) .__/ \__, | | ||
|_| |__/ | ||
__ | ||
/ _|_ __ __ _ _ __ ___ ___ ___ _ __ _ _ | ||
| |_| '__/ _` | '_ ` _ \ / _ \/ __| | '_ \| | | | | ||
| _| | | (_| | | | | | | __/\__ \_| |_) | |_| | | ||
|_| |_| \__,_|_| |_| |_|\___||___(_) .__/ \__, | | ||
|_| |__/ | ||
|
||
What to do when nothing else helps? Walk the stack trace, of course. | ||
What to do when nothing else helps? Walk the stack trace, of course. | ||
|
||
Is it a good idea? | It depends. | ||
Is it slow? | Terribly. | ||
Is it cool? | Fuck yeah! | ||
Is it a good idea? | It depends. | ||
Is it slow? | Terribly. | ||
Is it cool? | Fuck yeah! | ||
|
||
--------------- | ||
I want it, now! | ||
--------------- | ||
--------------- | ||
I want it, now! | ||
--------------- | ||
|
||
> pip install frames | ||
> pip install frames | ||
|
||
-------- | ||
But how? | ||
-------- | ||
-------- | ||
But how? | ||
-------- | ||
|
||
>>> import frames | ||
>>> import frames | ||
|
||
Seriously? | Okay, okay. | ||
Seriously? | Okay, okay. | ||
|
||
>>> frames.locate_frame(lambda f: 'BOOM' in f.f_locals) | ||
>>> frames.locate_frame(lambda f: 'BOOM' in f.f_locals) | ||
|
||
Boom what? | Meh... | ||
Boom what? | Meh... | ||
|
||
>>> frames.locate_frame( | ||
... lambda f: f.locals.get('__name__') == '__main__' | ||
... ).locals['BOOM'] = 'Yeah' | ||
>>> frames.locate_frame( | ||
... lambda f: f.locals.get('__name__') == '__main__' | ||
... ).locals['BOOM'] = 'Yeah' | ||
|
||
Heh? | This is getting boring ;( | ||
Heh? | This is getting boring ;( | ||
|
||
>>> BOOM | ||
'Yeah' | ||
>>> BOOM | ||
'Yeah' | ||
|
||
------------------------------------ | ||
But you just wrap the system frames? | ||
------------------------------------ | ||
------------------------------------ | ||
But you just wrap the system frames? | ||
------------------------------------ | ||
|
||
Yep, this is a tiny wrapper. That's all it is. | ||
Yep, this is a tiny wrapper. That's all it is. | ||
|
||
---------- | ||
Thank you! | ||
---------- | ||
---------- | ||
Thank you! | ||
---------- | ||
|
||
Goodbye! | ||
Goodbye! |