Skip to content

Commit

Permalink
Add --pdb support to piker search
Browse files Browse the repository at this point in the history
  • Loading branch information
goodboy committed Sep 13, 2023
1 parent 2c88ebe commit 30d55fd
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion piker/brokers/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -454,8 +454,18 @@ async def main():

@cli.command()
@click.argument('pattern', required=True)
# TODO: move this to top level click/typer context for all subs
@click.option(
'--pdb',
is_flag=True,
help='Enable tractor debug mode',
)
@click.pass_obj
def search(config, pattern):
def search(
config: dict,
pattern: str,
pdb: bool,
):
'''
Search for symbols from broker backend(s).
Expand All @@ -468,6 +478,7 @@ async def main(func):

async with maybe_open_pikerd(
loglevel=config['loglevel'],
debug_mode=pdb,
):
return await func()

Expand Down

0 comments on commit 30d55fd

Please sign in to comment.