USAGE:(1)

✨ USAGE:(1) ✨

ok so bestie, you know how there's a whole lil command-line bestie that lives next door to pytest-benchmark? that's this one. it's USAGE:(1), from the User Commands section, and it's the tool you reach for when you wanna inspect the data your pytest benchmark fixture has been hoarding. lowkey iconic. πŸ’…


πŸ¦‹ NAME πŸ¦‹

pytest-benchmark β€” the tool for inspecting data from the pytest benchmark fixture. that's it, that's the whole vibe check. ✨


🌸 DESCRIPTION 🌸

here's the whole shape of it, no cap:

pytest-benchmark [-h [COMMAND]] [--storage URI] [--netrc [NETRC]]
                 [--verbose] {help, list or compare}

so you've got a command in there β€” help, list, or compare β€” plus some optional lil flags hanging around. let's break it all the way down. 🫢


πŸ‘‘ commands:

  • help β€” shows you the help and then dips. exit stage left. display help and exit, periodt.
  • list β€” lists all your saved runs. like scrolling through your camera roll but for benchmarks. πŸ“Έ
  • compare β€” compares your saved runs. the main character of the three, honestly.

okay so here's the tea: the compare command takes almost all the --benchmark options from the pytest benchmark fixture, just minus the prefix. a complete list of those can be found in the documentation. don't come for me, I'm just the messenger. πŸ’œ


πŸŽ€ optional arguments:

  • -h, --help β€” show the help message and exit. classic. the og escape hatch. πŸ™ˆ
  • --verbose β€” increases verbosity. give me more words, bestie, I want all the details. πŸ”₯
  • --netrc β€” (no extra description given here, she's mysterious like that. πŸŒ™)
  • --storage β€” (also no description. a woman of few words. ✨)
ngl some of these show up in the synopsis with their arguments, so peep the synopsis line above if you need the full shape: [-h [COMMAND]] [--storage URI] [--netrc [NETRC]] [--verbose]. keep it exact, don't go freestyling. πŸ’–

🌈 EXAMPLES 🌈

πŸ“ load everything from one interpreter

pytest-benchmark compare β€˜Linux-CPython-3.5-64bit/*β€˜

this loads all benchmarks ran with that interpreter. and notice the special quoting β€” those curly-ish quotes are doing the lord's work because they disable your shell's glob expansion. yes bestie, the quoting is load-bearing. do not remove it. 😭

🧚 just the first one, thanks

pytest-benchmark compare 0001

this loads the first run from all the interpreters. one number, so much power. πŸ‘‘

⭐ exactly these files, no more no less

pytest-benchmark compare /foo/bar/0001_abc.json
/lorem/ipsum/0001_sir_dolor.json

this loads runs from exactly those files. precise. curated. a mood. πŸ’…


this manual page is Copyright Β© 2018 Hugo Lefeuvre <hle@debian.org>.

permission is granted to copy, distribute and/or modify this document under the terms of the GNU General Public License, Version 3 or any later version published by the Free Software Foundation. slay, legally. 🌈


and that's the whole page, bestie!! πŸŽ€ this was pytest-benchmark, page USAGE:(1), dated March 2018, and you absolutely ate that read. go compare some runs, you icon. βœ¨πŸ’œπŸ¦‹

πŸ“¦ where this page comes from