在bash中,我尝试将PPID导出为环境变量。但是,在我看来,结果在不同的Linux发行版中是非常不一致的。# normally PPID is not part of the environment# --> no output
# exportingpython -c 'import os; print(os.environ.get("PP
我需要让我的主要python脚本调用另一个python脚本,并将变量从原始脚本传递到我调用的脚本first.pyimport second在阅读了这些评论后,我想我会进一步讨论我的问题。答案修复了我正在处理的导入问题,但是解决方案没有期望的结果,因为我似乎无法以这种方式传递列表中的项目。在first.py中,我处理了一个列表,如下所示
for insert, (list) in enumerate(