file descriptors & fdopen

S

Scott Frankel

Why does os.fdopen('foo.txt', 'w') require an integer?
Ultimately, I want to create a new file on disk.

Funny, I can't seem to suss-out how to create a new file without
resorting
to os.system('touch foo.txt'). ... Or maybe not so funny ...
Traceback (most recent call last):
File "<stdin>", line 1, in ?
TypeError: an integer is required


Thanks in advance!
Scott
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,213
Messages
2,571,105
Members
47,698
Latest member
TerraT521

Latest Threads

Top