Running this example leads to the following stack trace:
Traceback (most recent call last):
File "D:\GitHub\test\test_scalpel.py", line 118, in <module>
main()
File "D:\GitHub\test\test_scalpel.py", line 92, in main
_, const_dict = SSA().compute_SSA(cfg)
File "..\AppData\Local\Programs\Python\Python39\lib\site-packages\scalpel\SSA\const.py", line 107, in compute_SSA
stored_idents, loaded_idents, func_names = self.get_stmt_idents_ctx(stmt, const_dict=tmp_const_dict)
File "C:\Users\ssimon\AppData\Local\Programs\Python\Python39\lib\site-packages\scalpel\SSA\const.py", line 309, in get_stmt_idents_ctx
ident_info = get_vars(visit_node)
File "...\AppData\Local\Programs\Python\Python39\lib\site-packages\scalpel\core\vars_visitor.py", line 188, in get_vars
visitor.visit(node)
File "...\AppData\Local\Programs\Python\Python39\lib\ast.py", line 407, in visit
return visitor(node)
File "...\AppData\Local\Programs\Python\Python39\lib\site-packages\scalpel\core\vars_visitor.py", line 176, in visit_Assign
self.visit(node.value)
File "...\AppData\Local\Programs\Python\Python39\lib\ast.py", line 407, in visit
return visitor(node)
File "...\AppData\Local\Programs\Python\Python39\lib\site-packages\scalpel\core\vars_visitor.py", line 113, in visit_Attribute
self.visit(node.value)
File "...\AppData\Local\Programs\Python\Python39\lib\ast.py", line 407, in visit
return visitor(node)
File "...\AppData\Local\Programs\Python\Python39\lib\site-packages\scalpel\core\vars_visitor.py", line 151, in visit_Subscript
self.slicev(node.slice)
File "...\AppData\Local\Programs\Python\Python39\lib\site-packages\scalpel\core\vars_visitor.py", line 145, in slicev
self.visit(node.value)
AttributeError: 'Tuple' object has no attribute 'value'
I think it is probably a special case, which is currently not covered by the vars visitor module?
PS: Here is the original file from which I extracted the the code line.
I found another problem when I used scalpel for analyzing ML projects. To reproduce the problem, just run the example below.
Running this example leads to the following stack trace:
I think it is probably a special case, which is currently not covered by the vars visitor module?
PS: Here is the original file from which I extracted the the code line.