~/talk

plac: more than just another command-line arguments parser

Talkat EuroPython 2011 · 2011-06-20..06-26· [developer-experience, python]
links:none on file
slides:none on file

Creates a command-line interface directly from a Python function signature so a one-line CLI from a function signature generates parsing, help and usage; uses Python 3 annotations and inspect to provide annotation-driven type conversion and choice/flag handling; builds a subcommand shell that records and replays interactions for tests, exposed as a subcommand shell with test recording; runs long tasks in separate processes so jobs are killable and nonblocking, implemented as multiprocess cancellable jobs that are demonstrated working.

AI-written summary · about

  1. 0:00plac introduction
  2. 3:59Basic argument parsing
  3. 5:56Simplify with plac
  4. 11:10Custom messages and styles
  5. 19:14Advanced options
  6. 23:30Numeric values and errors
  7. 29:56Subcommands and factories
  8. 35:32Custom commands
  9. 40:49Testing command interactions
  10. 47:20Long tasks responsiveness
  11. 53:19Multiprocessing tasks
  12. 58:19Why plac was created
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.