您的位置: 首页 > IT文章 > python获取当前文件的上一级目录 python获取当前文件的上一级目录 分类: IT文章 • 2023-10-30 18:09:30 import osos.path.dirname(os.path.abspath(__file__))