Skip to content

Commit

Permalink
[skip ci] Fix docstring for forward() (#2054)
Browse files Browse the repository at this point in the history
The docstring for tunnels / forward() has been broken since 2 months, since the `\n` in the docstring wasn't escaped and that broke inspect.cleandoc(), which trims consistent leading whitespace after the first line

Not going to tag elias because he's on PTO
  • Loading branch information
ekzhang committed Aug 2, 2024
1 parent 6a0265d commit 525b88b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modal/_tunnel.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ def some_function():
with modal.forward(port=22, unencrypted=True) as tunnel:
hostname, port = tunnel.tcp_socket
connection_cmd = f'ssh -p {port} root@{hostname}'
print(f"ssh into container using:\n{connection_cmd}")
print(f"ssh into container using: {connection_cmd}")
time.sleep(3600) # keep alive for 1 hour or until killed
```
Expand Down

0 comments on commit 525b88b

Please sign in to comment.