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.

Author larry
Recipients andrewnester, eryksun, larry, sayanchowdhury, serhiy.storchaka, wrohdewald, xiang.zhang
Date 2017-06-18.14:43:25
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1497797005.75.0.314329430866.issue29657@psf.upfronthosting.co.za>
In-reply-to
Content
"Special cases aren't special enough to break the rules."  I want the error message to mirror the API, which it currently does.  If we swapped them, the error message would now contradict the API.  So no, I don't support swapping "src" and "dst" in the error message only when the error pertains to os.symlink.

If literally every time the two-filename version of OSError is used inside Python, the two filenames are "src" and "dst", then we could consider making it slightly more explicit, e.g.

    FileExistsError: [Errno 17] File exists: src='a', dst='a_link'

I think I'd want the source code to reflect this (e.g. thinking about "src" and "dst" rather than "filename" and "filename2").

Would OP et al consider this change to the error message an improvement, or is it not interesting?
History
Date User Action Args
2017-06-18 14:43:25larrysetrecipients: + larry, wrohdewald, serhiy.storchaka, eryksun, sayanchowdhury, xiang.zhang, andrewnester
2017-06-18 14:43:25larrysetmessageid: <1497797005.75.0.314329430866.issue29657@psf.upfronthosting.co.za>
2017-06-18 14:43:25larrylinkissue29657 messages
2017-06-18 14:43:25larrycreate