https://github.com/likianta/pycallchain
Assign a python project and its launch file path, pycallchain will describe the call chains/graph by analysing static python files.
https://github.com/likianta/pycallchain
Last synced: 6 months ago
JSON representation
Assign a python project and its launch file path, pycallchain will describe the call chains/graph by analysing static python files.
- Host: GitHub
- URL: https://github.com/likianta/pycallchain
- Owner: likianta
- Created: 2019-07-31T00:49:22.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2019-08-11T16:32:20.000Z (about 6 years ago)
- Last Synced: 2025-02-08T05:26:29.295Z (8 months ago)
- Language: Python
- Homepage:
- Size: 273 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# pycallchain | Python 调用链分析工具
[TOC]
# 使用方法
pass
------------------------------------------------
# 注意事项
本程序不支持处理以下特殊情况.
**case 1: global 变量**
```python
def aaa():
print('aaa')
global a
a = bbbdef bbb():
print('bbb')if __name__ == '__main__':
aaa()
a() # <- 这里的 `a()` 将无法被识别到.```
**case 2: eval 函数**
```python
def aaa():
print('aaa')eval('aaa()') # <- 这里的 `aaa()` 将无法被识别到.
```
**case 3: 抽象引用**
```python
from random import randintdef aaa():
passdef bbb():
passadict = {0: aaa, 1: bbb}
rnd = randint(0, 1)
method = adict.get(rnd)() # <- 这里的函数调用事件无法被识别到.```
**case 4: 可变长度参数 (`*args`, `**kwargs`)**
```python
def aaa(*data):
print(data[0]()) # <- data[0] 无法被关联到 bbb 函数.def bbb():
passaaa(bbb)
```