Skip to content

Commit d59d609

Browse files
fix: set default value for skip option in groupby function
1 parent 888127a commit d59d609

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

openvariant/commands/openvar.py

+9-9
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ def openvar():
2424
help="Annotation path. eg: /path/annotation_vcf.yaml")
2525
@click.option('--header', is_flag=True, help="Show the result header.")
2626
@click.option('--output', '-o', default=None, help="File to write the output.")
27-
@click.option('--skip', is_flag=True, help="Skip files and directories that are unreadable.")
28-
def cat(input_path: str, where: str or None, annotations: str or None, header: bool, output: str or None, skip: bool):
27+
@click.option('--skip', is_flag=True, help="Skip files and directories that are unreadable.", default=False)
28+
def cat(input_path: str, where: str | None, annotations: str | None, header: bool, output: str | None, skip: bool):
2929
"""Print the parsed files on the stdout/"output"."""
3030
cat_task(input_path, annotations, where, header, output, skip)
3131

@@ -39,9 +39,9 @@ def cat(input_path: str, where: str or None, annotations: str or None, header: b
3939
@click.option('--cores', '-c', type=click.INT, default=cpu_count(), help='Maximum processes to run in parallel.')
4040
@click.option('--quite', '-q', is_flag=True, help="Don't show the progress.")
4141
@click.option('--output', '-o', default=None, help="File to write the output.")
42-
@click.option('--skip', is_flag=True, help="Skip files and directories that are unreadable.")
43-
def count(input_path: str, where: str, group_by: str, cores: int, quite: bool, annotations: str or None,
44-
output: str or None, skip: bool) -> None:
42+
@click.option('--skip', is_flag=True, help="Skip files and directories that are unreadable.", default=False)
43+
def count(input_path: str, where: str, group_by: str, cores: int, quite: bool, annotations: str | None,
44+
output: str | None, skip: bool) -> None:
4545
"""Print on the stdout/"output" the number of rows that meets the criteria."""
4646
result = count_task(input_path, annotations, group_by=group_by, where=where, cores=cores, quite=quite, skip_files=skip)
4747
out_file = None
@@ -76,9 +76,9 @@ def count(input_path: str, where: str, group_by: str, cores: int, quite: bool, a
7676
@click.option('--cores', '-c', type=click.INT, default=cpu_count(), help='Maximum processes to run in parallel.')
7777
@click.option('--quite', '-q', is_flag=True, help="Don't show the progress.")
7878
@click.option('--output', '-o', help="File to write the output.", default=None)
79-
@click.option('--skip', is_flag=True, help="Skip files and directories that are unreadable.")
80-
def groupby(input_path: str, script: str, where: str, group_by: str, cores: int, quite: bool, annotations: str or None,
81-
header: bool, show: bool, output: str or None, skip: bool):
79+
@click.option('--skip', is_flag=True, help="Skip files and directories that are unreadable.", default=False)
80+
def groupby(input_path: str, script: str, where: str, group_by: str, cores: int, quite: bool, annotations: str | None,
81+
header: bool, show: bool, output: str | None, skip: bool):
8282
"""Print on the stdout/"output" the parsed files group by a specified field."""
8383
out_file = None
8484
if output:
@@ -110,7 +110,7 @@ def groupby(input_path: str, script: str, where: str, group_by: str, cores: int,
110110
@openvar.command(name="plugin", short_help='Actions to execute for a plugin: create.')
111111
@click.argument('action', type=click.Choice(['create']))
112112
@click.option('--name', '-n', type=click.STRING, help="Name of the plugin.")
113-
def plugin(action, name: str or None):
113+
def plugin(action, name: str | None):
114114
"""Actions to apply on the plugin system."""
115115
class_name = action.upper()
116116
module_name = "openvariant.tasks.plugin"

0 commit comments

Comments
 (0)