Hedera-Lang-Learn / hedera

MIT License
10 stars 2 forks source link

(docs) Fix example for running local tests #441

Closed elliottyates closed 2 years ago

elliottyates commented 2 years ago

Adds --service-ports to docker compose run command for django unit tests so that debugger port is exposed for debug client connections.

Context

During the 10/25/2022 #dojo session we ran into a problem with local debug config that prevented connecting the VS Code debugger (client) to the debugpy server running in the app under test.

This appears to have been due to this quirk of the run command:

The second difference is that the docker compose run command does not create any of the ports specified in the service configuration. This prevents port collisions with already-open ports. If you do want the service’s ports to be created and mapped to the host, specify the --service-ports (cf https://docs.docker.com/engine/reference/commandline/compose_run/#description)