For others who discover this error, here's what happened as I've traced it:<br>1)
I never before had built a python interpreter on my Windoze box. That
was kind of silly, since I was uploading to my server every time I
wanted to test. So I built on my Windoze box. Thereafter, Windoze
assumed that all *.py files were native to its environment. That's
where the little devil crept in.<br>
2) When I went to edit my files on the server, I never saw any lines
ending in "^M", the dead giveaway that Windoze has mangled the line
endings. So the problem was __invisible__.<br><br>Wow. What a pain in the &(%(<br>
Thanks for everyone's help!<br><font color="#888888">V</font><br><br><div class="gmail_quote">On Mon, Nov 9, 2009 at 9:12 PM, Dave Angel <span dir="ltr"><<a href="mailto:davea@ieee.org">davea@ieee.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Victor Subervi wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="im">
On Mon, Nov 9, 2009 at 2:30 PM, Victor Subervi <<a href="mailto:victorsubervi@gmail.com" target="_blank">victorsubervi@gmail.com</a>>wrote:<br>
<br>
<br>
</div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="im">
On Mon, Nov 9, 2009 at 2:27 PM, Rami Chowdhury <<a href="mailto:rami.chowdhury@gmail.com" target="_blank">rami.chowdhury@gmail.com</a>>wrote:<br>
<br>
<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
</blockquote></div>
<snip><div class="im"><br>
<br>
Hold everything. Apparently line-endings got mangled. What I don't<br>
<br>
</div></blockquote><div class="im">
understand is why I didn't see them when I opened the file to edit, and why<br>
they didn't copy and paste when I did that. But dos2unix cleaned up a couple<br>
of files so I presume it will clean up the rest. However, I tried one file,<br>
that reads exactly the same as index.py, and when I surfed to it got a 500<br>
error. Here's what the log said:<br>
<br></div>
<snip><br>
<br>
</blockquote>
What I've diagnosed as happening when a python script with Windows line-ending was posted on my server's cgi environment:<br>
<br>
The actual error seemed to be a failure to find the python interpreter, since some Unix shells take the shebang line to include the \r character that preceded the newline. Seems to me they could be more tolerant, since I don't think control characters are likely in the interpreter file name.<br>
<br>
DaveA<br>
<br>
</blockquote></div><br>