Skip to content

Commit

Permalink
fix: failing piping on the CLI.
Browse files Browse the repository at this point in the history
  • Loading branch information
germa89 committed Jun 26, 2024
1 parent 3abf23c commit 9818a16
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/ansys/mapdl/core/cli/convert.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ def get_input_source(ctx, param, value):
File mapdl.dat successfully converted to mapdl.out.""",
)
@click.argument("filename_in", callback=get_input_source, required=True)
@click.argument("filename_in", callback=get_input_source, required=False)
@click.option("-o", default=None, help="Name of the output Python script.")
@click.option("--filename_out", default=None, help="Name of the output Python script.")
@click.option(
Expand Down Expand Up @@ -212,6 +212,9 @@ def convert(
)

else:
if not filename_in:
raise ValueError("A file path must be provided.")

Check warning on line 216 in src/ansys/mapdl/core/cli/convert.py

View check run for this annotation

Codecov / codecov/patch

src/ansys/mapdl/core/cli/convert.py#L216

Added line #L216 was not covered by tests

convert_script(
filename_in,
filename_out,
Expand Down

0 comments on commit 9818a16

Please sign in to comment.