Skip to content

Commit 2e9de2c

Browse files
committed
hooks.py(fix[show_hooks]): Remove invalid ignore_errors parameter
why: tmux show-hooks does not accept -q flag. Verified against ~/study/c/tmux/cmd-show-options.c:67 which shows show-hooks accepts "gpt:w" only. what: - Remove ignore_errors parameter from show_hooks() signature - Remove ignore_errors flag handling code - Remove ignore_errors from docstring parameters
1 parent 561b9a5 commit 2e9de2c

File tree

1 file changed

+0
-7
lines changed

1 file changed

+0
-7
lines changed

src/libtmux/hooks.py

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,6 @@ def show_hooks(
243243
self,
244244
global_: bool | None = False,
245245
scope: OptionScope | _DefaultOptionScope | None = DEFAULT_OPTION_SCOPE,
246-
ignore_errors: bool | None = None,
247246
) -> HookDict:
248247
"""Return a dict of hooks for the target.
249248
@@ -253,8 +252,6 @@ def show_hooks(
253252
Pass ``-g`` flag for global hooks, default False.
254253
scope : OptionScope | _DefaultOptionScope | None, optional
255254
Hook scope (Server/Session/Window/Pane), defaults to object's scope.
256-
ignore_errors : bool, optional
257-
Suppress errors with ``-q`` flag.
258255
259256
Returns
260257
-------
@@ -296,10 +293,6 @@ def show_hooks(
296293
else:
297294
flags += (flag,)
298295

299-
if ignore_errors is not None and ignore_errors:
300-
assert isinstance(ignore_errors, bool)
301-
flags += ("-q",)
302-
303296
cmd = self.cmd("show-hooks", *flags)
304297
output = cmd.stdout
305298
hooks: HookDict = {}

0 commit comments

Comments
 (0)