[Python-au] blind spot with os.path
John Machin
sjmachin at lexicon.net
Thu Oct 15 13:49:00 UTC 2009
On 15/10/2009 8:21 PM, Mike Dewhirst wrote:
> The problem I find is that Python seems to be using the wrong default
> path separator here ...
>
> 'C:\\users\\miked\\py\\chemdata\\src\\getmsds\\testlinks\\leave_empty/*.*'
>
[snip]
> filesdir = testdir + os.path.sep + emptydir
This is not the cause of your problem, but IMHO it's better to use
os.path.join(this, that)
always instead of translating that to
this + os.path.sep + that
sometimes.
Cheers,
John
More information about the python-au
mailing list