Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fish_trace filters to avoid suppressing traces from binds etc #10424

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

krobelus
Copy link
Member

@krobelus krobelus commented Apr 6, 2024

Today fish_trace=1 traces all fish script code except bind/events/prompt/title.
(Also fish_should_add_to_history which is part of bind).

Let's allow enabling these categories. This is mainly to help debugging; I'm
not sure how useful this is to people who are not very familiar with fish. I'd
only list this in the changelog once we have a better design (reject typos
like "fish_trace=binds" and maybe allow turning off the default script trace).

Today fish_trace=1 traces all fish script code except bind/events/prompt/title.
(Also fish_should_add_to_history which is part of bind).

Let's allow enabling these categories.  This is mainly to help debugging; I'm
not sure how useful this is to people who are not very familiar with fish. I'd
only list this in the changelog once we have a better design (reject typos
like "fish_trace=binds" and maybe allow turning off the default script trace).
@faho
Copy link
Member

faho commented Apr 6, 2024

Fixes #7781

@faho faho added this to the fish next-3.x milestone Apr 6, 2024
@krobelus
Copy link
Member Author

krobelus commented Apr 6, 2024

also set -lx fish_trace 1 should override any existing suppression I think, since this is a debuggin-only feature.

@faho
Copy link
Member

faho commented Apr 6, 2024

also set -lx fish_trace 1 should override any existing suppression I think, since this is a debuggin-only feature.

You mean setting it to "1" should show all traces? I would rather have it stay as it is, because otherwise it's overly chatty.

How about an "all" option that turns on all traces instead?

(this is similar to FLOG, where we have a few categories that are just much too chatty)

@krobelus
Copy link
Member Author

krobelus commented Apr 6, 2024

I was just talking about the problem that there is currently no way to "un-suppress" tracing.
I agree "1/on/true/script" should (as it does today) trace only normal commands.
Agreed with the "all" option (or * I guess), this patch already includes it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants