dockerpty
Python library to use the pseudo-tty of a docker container
Decision gist · record as of 2026-08-14
No. The package is abandoned (last release 2016-02-04, no commits since 2019-10-16) and does not explicitly declare its runtime dependency, creating installation friction and compatibility risk. Modern Docker tooling has evolved significantly since then. Consider using maintained alternatives or the official Docker SDK for interactive container control.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires an undeclared external dependency (docker-py >=0.3.2); only works when run in an actual terminal; requires Docker daemon running locally.
- High install friction: the package does not explicitly declare its runtime dependency in PyPI, requiring manual installation.
- Maintenance is abandoned—last release was 2016-02-04, with no commits since 2019-10-16.
License · maintenance · safety
Apache 2.0 (permissive) — Licensed under Apache 2.0 (permissive), allowing commercial and private use with minimal restrictions, though you should review the LICENSE.txt file for exact terms.
last release 2016-02-04 (3844 days) · last repo commit 2019-10-16 · 161 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 706,753 downloads/mo, #5,271 on PyPI
Alternatives
Verify before relying
pip install dockerpty
import dockerpty
dockerpty.start(client, container)- Compatibility with modern Docker SDK versions—last release predates major Docker API changes.
- Python version support—requires_python is unspecified; may not work on modern Python versions.
- Whether the undeclared dependency is still the correct package name or has been superseded.
- Current usability with contemporary Docker tooling and container runtimes.
What it is and what it does
dockerpty is a Python library that bridges the gap between a host terminal and a Docker container's pseudo-terminal (PTY), allowing you to run interactive shell sessions inside containers as if you were directly connected to them. It handles the low-level details of terminal control: piping stdin/stdout/stderr between host and container, managing raw terminal mode, handling window resize signals, and restoring terminal state on exit.
The library is designed for scenarios where you need programmatic, interactive access to a container's shell from Python. It also supports non-TTY attachment for streaming container output. However, the project is abandoned (last release 2016-02-04, no commits since 2019-10-16) and does not explicitly declare its runtime dependency, creating friction for new installations and raising questions about compatibility with modern tooling.
Use it for
- Run interactive shell sessions inside Docker containers from Python scripts, giving users direct terminal control.
- Implement programmatic container debugging or administration tools that need real-time terminal interaction.
- Stream container output in non-TTY mode when interactive control is not required.
- Detach from and re-attach to running containers without stopping them.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
No.
The package is abandoned (last release 2016-02-04, no commits since 2019-10-16) and does not explicitly declare its runtime dependency, creating installation friction and compatibility risk. Modern Docker tooling has evolved significantly since then. Consider using maintained alternatives or the official Docker SDK for interactive container control.
Install
dockerpty on PyPI
Before you install
High install friction: the package does not explicitly declare its runtime dependency in PyPI, requiring manual installation. Maintenance is abandoned—last release was 2016-02-04, with no commits since 2019-10-16.
Requires an undeclared external dependency (docker-py >=0.3.2); only works when run in an actual terminal; requires Docker daemon running locally.
License in practice
Licensed under Apache 2.0 (permissive), allowing commercial and private use with minimal restrictions, though you should review the LICENSE.txt file for exact terms.
Quickstart
pip install dockerpty
import dockerpty
dockerpty.start(client, container)
Verify before relying
- Compatibility with modern Docker SDK versions—last release predates major Docker API changes.
- Python version support—requires_python is unspecified; may not work on modern Python versions.
- Whether the undeclared dependency is still the correct package name or has been superseded.
- Current usability with contemporary Docker tooling and container runtimes.
Package facts
| License | Apache 2.0 permissive |
| Python support | Not specified |
| Install friction | High. Source build required |
| Runtime dependencies | None |
| Maintenance | Abandoned 3,844 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 706,753 / month, #5,271 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 4 - BetaEnvironment :: ConsoleIntended Audience :: DevelopersLicense :: OSI Approved :: Apache Software LicenseProgramming Language :: PythonTopic :: Software Development :: LibrariesTopic :: Software Development :: Libraries :: Python ModulesTopic :: TerminalsTopic :: Terminals :: Terminal Emulators/X Terminals |
Evidence: dockerpty-0.4.1.tar.gz
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “docker container terminal control”
- dockerptyOperates the pseudo-terminal (PTY) allocated to a Docker container,…
- GlancesGlances is a cross-platform system monitoring tool that displays…
- tqdm-loggableConverts tqdm progress bars to logging-friendly messages in headless…
Give your agent the search over MCP, or paste the wish link into any chat.
More Libraries packages
urllib3 is an HTTP client library that provides thread-safe connection pooling, SSL/TLS verification, multipart file uploads, request retries, compression support, and proxy handling for Python applications.
Requests is a Python HTTP library that simplifies sending HTTP/1.1 requests with automatic handling of headers, authentication, cookies, and response parsing.
Pluggy provides a plugin system that lets you define hook specifications and register implementations to be called in sequence, enabling extensible Python applications without tight coupling.
Install it if you're building an extensible application or framework.
Provides parsing, arithmetic, and recurrence rule computation for dates and times, with timezone support and iCalendar RFC compliance.
Install it if you need to parse flexible date strings, compute relative dates, handle timezones, or work with recurrence rules—it's the de facto choice for these tasks.
Six provides utility functions to write Python code that runs on both Python 2.7 and Python 3.3+, smoothing over language differences between the two versions.
pytest is a testing framework that lets you write test functions using plain assert statements and automatically discovers and runs them, with detailed failure reporting.
See also ptyprocess · pywinpty · pairmux · jupyter-server-terminals · docker · pexpect · docker-py · subprocess-multitee · bash · spur