python中os模块path.abspath()返回的并不是绝对值,而是个错误的不存在的拼接地址
2015-03-09 23:46
246 查看
附截图:
![](http://images.cnitblog.com/blog2015/653050/201503/092344133557314.jpg)
当前路径:
![](http://images.cnitblog.com/blog2015/653050/201503/092347327149918.png)
a=r'D:\PCsync\python\commands' 为绝对路径
遍历出来的4条应该是D:\PCsync\python\commands\commands.py....
不知道哪里错误了,先记录下来。
![](http://images.cnitblog.com/blog2015/653050/201503/092344133557314.jpg)
当前路径:
![](http://images.cnitblog.com/blog2015/653050/201503/092347327149918.png)
a=r'D:\PCsync\python\commands' 为绝对路径
遍历出来的4条应该是D:\PCsync\python\commands\commands.py....
不知道哪里错误了,先记录下来。
相关文章推荐
- Python模块详解以及import本质,获得文件当前路径os.path.abspath,获得文件的父目录os.path.dirname,放到系统变量的第一位sys.path.insert(0,x)
- python内置模块[sys,os,os.path,stat]
- python os.path模块
- Python的学习(二十五)-- os.path模块
- python os.path模块
- python os.path模块常用方法详解
- 【Python】OS.Path模块函数集合
- Python 中的 os.path 模块说明
- python os.path模块学习
- Python os.path模块
- python os.path模块说明
- Python os.path模块
- Python 中 os.path 模块
- Python 最近因开发项目的需要,有一个需求,就是很多SNS网站都有的通过 Email地址 导入好友列表,不过这次要导入的不是Email 列表,而是QQ的好友列表。 实现方式: 通过goog
- python模块之os和os.path
- python os.path常用模块
- python os.path模块
- Python os.path和shutil模块实现文件复制、删除
- Python os.path模块
- Python os.path模块