Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixes #1783 #1810

Merged
merged 13 commits into from
Nov 2, 2023
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5042,3 +5042,9 @@ Installed executor plugins don't have to be referred to by their full module nam
- CHANGELOG.md to track changes (this file).
- Semantic versioning in VERSION.
- CI pipeline job to enforce versioning.


### Fixed

- Fixed the bug that caused ValueError error when using KEYWORD_ONLY parameter in electron func
- changed code at line 218 in covalent/_shared_files/utils.py
AdityaRaj23 marked this conversation as resolved.
Show resolved Hide resolved
5 changes: 4 additions & 1 deletion covalent/_shared_files/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -211,10 +211,13 @@
elif param.kind == param.VAR_POSITIONAL:
for i in range(ind, len(args)):
named_args[f"arg[{i}]"] = args[i]
elif param.kind in [param.KEYWORD_ONLY, param.VAR_KEYWORD]:
elif param.kind == param.VAR_KEYWORD:
for key, value in kwargs.items():
if key != param_name:
named_kwargs[key] = value
elif param.kind == param.KEYWORD_ONLY:
if param_name in kwargs:
named_kwargs[param_name] = kwargs[param_name]

Check warning on line 220 in covalent/_shared_files/utils.py

View check run for this annotation

Codecov / codecov/patch

covalent/_shared_files/utils.py#L218-L220

Added lines #L218 - L220 were not covered by tests

if len(args) > len(named_args):
raise ValueError(
Expand Down
Loading
Loading