GoogleChromeLabs / pywebsocket3

BSD 3-Clause "New" or "Revised" License
44 stars 32 forks source link

Stop wrapping os.popen3 #24

Closed ricea closed 3 years ago

ricea commented 3 years ago

CGIHTTPRequestHandler no longer uses os.popen3 in Python 2.7, which is the oldest version we support. Stop attempting to wrap it. This enables pywebsocket to work with the --cgi-paths command-line option on Python 3.

This means that selecting the interpreter via a "#!" line at the start of the file is explicitly no longer supported on win32, whereas previously it was supposed to work but didn't.

However, the "#!" line is still used to identify executable scripts, even on win32.

Also add a unit test for cgi script execution, and an example script which is used by the test.

Fixes #17

yutakahirano commented 3 years ago

CGIHttpServerRequest

Do you mean CGIHTTPRequestHandler (or CGIHttpServer.CGIHTTPRequestHandler)?

ricea commented 3 years ago

Do you mean CGIHTTPRequestHandler (or CGIHttpServer.CGIHTTPRequestHandler)?

Fixed, thanks.