0001.01.01 · 1 分钟阅读Python __file__ not defined problem解决 Python 交互式命令行中 __file__ 未定义的问题,给出借助 inspect 模块获取当前脚本路径的通用变通写法。python