Repository navigation
Add an interactive mode for profiler-cli - #6400
Merged
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #6400 +/- ##
=======================================
Coverage 85.13% 85.13%
=======================================
Files 365 365
Lines 39944 39944
Branches 11398 11383 -15
=======================================
Hits 34006 34006
Misses 5498 5498
Partials 440 440 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
mstange
force-pushed
the
push-lpmmxzrorvms
branch
from
November 18, 2026 14:30
2dd2ad4 to
a2daa15
Compare
mstange
force-pushed
the
push-lpmmxzrorvms
branch
from
November 18, 2026 14:31
a2daa15 to
2c99063
Compare
fatadel
requested changes
Nov 24, 2026
fatadel
left a comment
Contributor
There was a problem hiding this comment.
Thanks for the PR! I left some comments, although I think more enhanced handling of double Ctrl+C is the only important one.
mstange
force-pushed
the
push-lpmmxzrorvms
branch
from
November 25, 2026 16:25
2c99063 to
9726311
Compare
…nds. Argument validation printed an error and called process.exit(1) in about 30 places. These now throw, and the existing handler in main() prints "Error: <message>" and exits with status 1, so the output stays the same. This makes the commands usable from a long-running process, such as an interactive prompt, where a typo must not end the process. An unknown command now prints a one-line error that points to --help, instead of the error followed by the full help text.
…cess.argv. wasExplicit() decides whether to print the "Other subcommands" hint. It searched process.argv for the parent and subcommand names. It now checks the operands that commander recorded on the parent command, which reflect the arguments that were actually parsed, wherever they came from.
This prepares for an interactive prompt, which needs a fresh program for every line it runs. No behavior change.
"profiler-cli -i [<command>]" runs <command>, if given, and then shows a "> " prompt. Each line is a profiler-cli command without the "profiler-cli" prefix, parsed by a fresh commander program. Errors are printed and the prompt continues. "exit", "quit" or Ctrl-D leave it. The prompt pins the session it loaded, so a "load" in another terminal does not redirect it. "load" and "session use" at the prompt change the pinned session. When the prompt exits, it stops the sessions it loaded, because daemons have no idle timeout and would otherwise keep a profile in memory indefinitely. Sessions that were already running are left alone. The separate-commands mode is unchanged and remains the interface for scripts and AI tools.
mstange
force-pushed
the
push-lpmmxzrorvms
branch
from
November 25, 2026 17:18
9726311 to
011edd6
Compare
fatadel
approved these changes
Nov 30, 2026
fatadel
added a commit
that referenced
this pull request
Dec 1, 2026
Changes: [canova] Add localization guidelines to AGENTS.md (#6487) [staktrace] Add markers to represent causal flows (#6488) [zuhairkhalid229] Highlight more languages in the source view (#6475) [kayaal34] Fix typos in developer docs (#6479) [fatadel] Remove the search field hint (#6490) [mstange] Add an interactive mode for profiler-cli (#6400) [mstange] Make keyboard zooming in chart viewports center on the mouse position. (#6471) [fatadel] Bump profiler-cli version to 0.16.0 (#6502) And special thanks to our localizers: de: Michael Köhler el: Jim Spentzos en-GB: Ian Neal ia: Melo46 it: Francesco Lodolo nl: Mark Heijl ru: berry, Valery Ledovskoy sv-SE: Andreas Pettersson tr: Grk, Selim Şumlu zh-TW: Pin-guang Chen
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Main | Deploy preview
This makes it so that
profiler-cli -i load https://share.firefox.dev/4dJfrbAgives you a REPL style interface.