python-varname icon indicating copy to clipboard operation
python-varname copied to clipboard

argname sample code raises VarnameRetrievingError

Open krwhelan opened this issue 11 months ago • 1 comments

I am running python 3.11 with Pythonnet opened IDLE Following the sample code in readme, I entered:

from varname import argname def func(a, b=1): print(argname('a')) x=2

func(x) Traceback (most recent call last): File "<pyshell#4>", line 1, in func(x) File "<pyshell#2>", line 2, in func print(argname('a')) File "C:\Users\502751870\AppData\Local\Programs\Python\Python311\Lib\site-packages\varname\core.py", line 451, in argname raise VarnameRetrievingError( varname.utils.VarnameRetrievingError: Cannot retrieve the node where the function is called.

krwhelan avatar Mar 22 '24 19:03 krwhelan

See

  • #107

pwwang avatar Mar 22 '24 21:03 pwwang