Kristján Valur Jónsson added the comment:

Thanks for your example.

> That's AFAICT exacyly the problem reported by the OP on OS-X.
You are right, I mis-read the original problem.

IMHO, the example you quote is "unexpected".  The purpose of symbolic links is 
to create a "virtual" image of a structure.
a structure like you describe:
/scripts/
  foo.py -> /otherplace/foo.py

contains only a foo.py in its apparent location (scripts).  I would not expect 
the file to be able to import stuff from /otherplace unless that stuff were 
also present in /scripts

In other words: symlinking individual files normally works like you are 
"pulling that file in", not "hopping into that file's real location".

This behaviour is unexpected because I know of no other language tools that 
behave in this way:

/code/
  myfile.c -> /sources/myfile.c
  mylib.h  -> /libs/mylib.h
  libmylib.so -> /libs/libmylib.so

an "#include "mylib.h" in myfile.c would look for the file in /code and find it.
a "cc myfile.c -lmylib" would find the libmylib.so in /code

Since this is not the original problem described, I'll open up a separate 
defect report.

----------

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

Reply via email to