On 26Sep2009 10:24, Peng Yu <pengyu...@gmail.com> wrote:
| > [st...@sylar test]$ ls -l
| > total 16
| > -rw-rw-r-- 1 steve steve  6 2009-09-26 23:06 test.py
| > -rw-rw-r-- 1 steve steve 94 2009-09-26 23:08 test.pyc
| >
| > Have you checked the umask of your system?
| 
| Here are my test case. If the .py file has the 'x' mode, the
| corresponding .pyc file also has the 'x' mode after the .py file is
| imported.

Yes, I see this too.

| pe...@selenium:~/test/python/pyc_mode$ umask
| 0077
| pe...@selenium:~/test/python/pyc_mode$ ll
| total 8
| -rw------- 1 pengy lilab  29 2009-09-26 10:10:45 main.py
| -rwx------ 1 pengy lilab 106 2009-09-26 10:19:17 test.py
[...]
| pe...@selenium:~/test/python/pyc_mode$ python main.py
| in_test_func
| pe...@selenium:~/test/python/pyc_mode$ ll
| total 12
| -rw------- 1 pengy lilab  29 2009-09-26 10:10:45 main.py
| -rwx------ 1 pengy lilab 106 2009-09-26 10:19:17 test.py
| -rwx------ 1 pengy lilab 339 2009-09-26 10:20:39 test.pyc

This happens for me with python 2.6 x86_64 on gentoo.

You're not alone.
-- 
Cameron Simpson <c...@zip.com.au> DoD#743
http://www.cskk.ezoshosting.com/cs/

Reaching consensus in a group often is confused with finding the right
answer. - Norman Maier
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to