Skip to content

Commit e51de7e

Browse files
authored
Fix oppia#19271: Fix Docker Failures on macOS from Failed Syscalls (oppia#19947)
* Fix Docker Failures on macOS from Failed Syscalls On macOS, failed syscalls under Docker were not handled properly by Python 2, which the Google Appengine development server runs under. Per [PEP-0475](https://peps.python.org/pep-0475/), the correct response to a failed syscall is to re-try the call, but this is not handled correctly until Python 3. Therefore, in this commit we patch the Google Appengine development server code to wrap the failing calls in try-except blocks. This patching is performed each time the Docker containers start up. For more details, see oppia#19271. * Add wsgi_server.py to exclusion lists * Add wsgi_server.py to linter ignore * Fix path to Google CLoud SDK * Tighten try-except conditions * Prefix edited wsgi_server.py filename with patched_
1 parent 13a2f6a commit e51de7e

5 files changed

+616
-1
lines changed

docker/dev-server.entrypoint.sh

+1
Original file line numberDiff line numberDiff line change
@@ -46,4 +46,5 @@ else
4646
fi
4747

4848
$build_cmd
49+
cp /app/oppia/docker/patched_wsgi_server.py /app/vm_deps/google-cloud-sdk/platform/google_appengine/google/appengine/tools/devappserver2/wsgi_server.py
4950
$dev_appserver_cmd

0 commit comments

Comments
 (0)