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

*args and **kwargs are not captured in traces #307

Open
NotWearingPants opened this issue Sep 15, 2023 · 1 comment
Open

*args and **kwargs are not captured in traces #307

NotWearingPants opened this issue Sep 15, 2023 · 1 comment

Comments

@NotWearingPants
Copy link
Contributor

The types of *args and **kwargs arguments are not added to traces:

__main__.py:

import foo
foo.func(1, 2, a=3, b=4)

foo.py:

def func(*args, **kwargs):
    return sum(args) + sum(kwargs.values())
$ rm ./monkeytype.sqlite3; pipenv run monkeytype run . && sqlite3 ./monkeytype.sqlite3 .dump
[...]
INSERT INTO monkeytype_call_traces VALUES('2023-09-15 10:21:16.983236','foo','func','{}','{"module": "builtins", "qualname": "int"}',NULL);
COMMIT;

See #304 (comment).

@carljm
Copy link
Contributor

carljm commented Dec 17, 2023

I think this wouldn't be too difficult to implement. I don't expect to have time to do the implementation, but will review a pull request for the feature.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants