My convention for loglines is to format as: >>> print(f"Static msg: k1={v1} k2={v2}...") Very simple, but putting all dynamic data on the right makes it much easier to skim through logs. Format is also more machine-friendly; many log indexing systems will parse them properly.

Apr 21, 2022 · 6:46 PM UTC

3
1
35
Replying to @gdb
There is a shortcut to print a variable name and it’s value since 3.8: print(f“{v1=}“) 👀
Replying to @gdb
but why not the beautiful people of @OpenAI why?
Such a joy to work with amazingly talented people at SpaceX, Tesla, Neuralink & Boring Co!
1
This tweet is unavailable
Have used it, and am a fan in many contexts!
3