This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Crbon.File.FSSpec should accept non-existing pathnames
Type: enhancement Stage: test needed
Components: macOS Versions: Python 2.7
process
Status: closed Resolution: wont fix
Dependencies: Superseder:
Assigned To: jackjansen Nosy List: jackjansen, mwh, ronaldoussoren
Priority: normal Keywords:

Created on 2003-03-19 22:55 by jackjansen, last changed 2022-04-10 16:07 by admin. This issue is now closed.

Messages (6)
msg60319 - (view) Author: Jack Jansen (jackjansen) * (Python committer) Date: 2003-03-19 22:55
Carbon.File.FSSpec currently doesn't accept non-existing pathnames.
This can be fixed in a way similar to what EasyDialogs.AskFileForSave uses, I think.
msg60320 - (view) Author: Michael Hudson (mwh) (Python committer) Date: 2003-03-25 14:38
Logged In: YES 
user_id=6656

This would seem to be a dup of 585923 which is closed, fwiw.

I don't understand the comment about EasyDialogs.AskFileForSave.
msg60321 - (view) Author: Jack Jansen (jackjansen) * (Python committer) Date: 2003-03-25 14:43
Logged In: YES 
user_id=45365

I re-submitted this by popular demand. And, indeed, the logic could be similar to what AskFileForSave does (even though that is not 100% correct),
but this code has to be in C:-(
msg60322 - (view) Author: Michael Hudson (mwh) (Python committer) Date: 2003-03-25 14:48
Logged In: YES 
user_id=6656

I know, you posted this after a complaint from me :-)

It seems to me that the hacks AskFileForSave perpetrates are
going the other way, from FSSpec of absent file to pathname.
 Can it be done backwards?  I guess pain comes from not
being able to call os.path.split in C...
msg60323 - (view) Author: Jack Jansen (jackjansen) * (Python committer) Date: 2003-03-25 16:37
Logged In: YES 
user_id=45365

Sort of. If the user wants an fsspec back you need to construct it. The difficult bit is getting the MacRoman (or whatever the local convention is)/utf-8 handling right. And then there's the 31-char limit for FSSpec filenames, which OSX handles with magic under the hood (but for non-existent files we don't have to worry about this).

But: if you're willing to do a 90% fix (say, by requiring ASCII in the last part of the filename): be my guest!
msg82328 - (view) Author: Ronald Oussoren (ronaldoussoren) * (Python committer) Date: 2009-02-17 12:20
Closing as "won't fix" because the Carbon bindings are deprecated, and 
FSSpec's are even more deprecated (they're even deprecated at the C-level)
History
Date User Action Args
2022-04-10 16:07:47adminsetgithub: 38187
2009-02-17 12:20:21ronaldoussorensetstatus: open -> closed
resolution: wont fix
messages: + msg82328
nosy: + ronaldoussoren
2009-02-13 02:37:34ajaksu2setstage: test needed
type: enhancement
versions: + Python 2.7
2003-03-19 22:55:29jackjansencreate