Message110177
In 2.x, os.getcwd() uses a dynamic allocation scheme to accomodate whatever buffer size the current path needs to be represented.
In 3.x, the max path length is hardcoded to 1026 bytes or characters, and an error is raised if the current path length is larger than that. Even on systems where MAX_PATH is 1024 (a common value), it is still valid to create paths larger than that (using e.g. os.mkdir()).
The attached script shows that os.getcwd() works with a 1032-character path in 2.x, but fails in 3.x. |
|
Date |
User |
Action |
Args |
2010-07-13 12:10:59 | pitrou | set | recipients:
+ pitrou, loewis, vstinner, skrah |
2010-07-13 12:10:59 | pitrou | set | messageid: <1279023059.26.0.245683093399.issue9246@psf.upfronthosting.co.za> |
2010-07-13 12:10:57 | pitrou | link | issue9246 messages |
2010-07-13 12:10:57 | pitrou | create | |
|