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 andrewnester
Recipients andrewnester, sayanchowdhury, wrohdewald, xiang.zhang
Date 2017-03-03.17:46:02
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1488563162.4.0.850337815376.issue29657@psf.upfronthosting.co.za>
In-reply-to
Content
I've been investigating this issue and did not come up with some easy solution.

So the problem is:
os_symlink uses `path_error2` to throw exception.
the order of file arguments now is src then dest. For provided example src is `a` and dest is `sym_link`. As a result `src` -> `dest` is generated here https://github.com/python/cpython/blob/master/Objects/exceptions.c#L1059

If we change order of arguments passed to `path_error2`, error message will be generated properly but OSError.filename will be incorrect (a_link instead of a) and following test will fail for `link`/`symlink`

https://github.com/python/cpython/blob/master/Lib/test/test_os.py#L2901

Not sure if it's OK or not, so it definitely needs some input from Python core developers.
History
Date User Action Args
2017-03-03 17:46:02andrewnestersetrecipients: + andrewnester, wrohdewald, sayanchowdhury, xiang.zhang
2017-03-03 17:46:02andrewnestersetmessageid: <1488563162.4.0.850337815376.issue29657@psf.upfronthosting.co.za>
2017-03-03 17:46:02andrewnesterlinkissue29657 messages
2017-03-03 17:46:02andrewnestercreate