Skip to content

Commit

Permalink
codegen fix 3
Browse files Browse the repository at this point in the history
  • Loading branch information
hpohekar committed Apr 3, 2024
1 parent f569ea6 commit 73a49cb
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions src/ansys/fluent/core/launcher/launcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,22 +49,19 @@

def _remove_unused_args(fluent_launch_mode: LaunchMode = None, **kwargs):

print(f"\n kwargs - {kwargs} \n")

def _remove_key(unused_args, **kargs):
for arg in unused_args:
if arg in kwargs:
if arg in kargs:
kargs.pop(arg)
print(f"\n kargs - {kargs} \n")
return kargs

if fluent_launch_mode == LaunchMode.STANDALONE or LaunchMode.PIM:
_remove_key(
return _remove_key(
["start_container", "container_dict", "dry_run", "scheduler_options"],
**kwargs,
)
elif fluent_launch_mode == LaunchMode.CONTAINER:
_remove_key(["start_container", "scheduler_options"], **kwargs)
return _remove_key(["start_container", "scheduler_options"], **kwargs)


def create_launcher(fluent_launch_mode: LaunchMode = None, **kwargs):
Expand Down

0 comments on commit 73a49cb

Please sign in to comment.