Steven D'Aprano <steve+pyt...@pearwood.info> added the comment:

On Thu, Aug 05, 2021 at 12:00:31PM +0000, krey wrote:

> @steven.daprano My suggestion was changing the names of the args, not the 
> order
> 
> Current
> def os.symlink(src, dst):
>     ln -s src dst

So far so good.

> Changing the names
> def os.symlink(dst, src):
>     ln -s dst src

That's not changing the names, that's changing the order.

You're putting the destination first, and the source second. That's the 
opposite order to that of `ln` in all the Unixes I can find, but it 
matches the order of Windows, which seems to be the only OS I can see 
that puts the destination (the path to the symlink) first and the source 
(the path to the target/original) second.

In any case, we have no power to change the order of arguments to `ln`.

> Changing the order
> def os.symlink(dst, src):
>     ln -s src dst

And that's just confused, because you have `ln` use the same order it 
has now, and symlink reverse the order.

> I concede that different unixes have different argnames for ln, it's a 
> bit of a mess. From a CS theory perspective, I think the GNU 
> convention makes more sense.

The GNU convention is the same convention as all the other Unixes, and 
os.symlink. Only the documented names are different.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue44837>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to