Install & Compatibility
Where this runs
No compatibility data collected yet for this library.
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
SSHClient
✓ from spindlex import SSHClient
✗ from spindlex.client import SSHClient
The public API is at the package root; using submodules may break in future versions.
SFTPClient
✓ from spindlex import SFTPClient
Basic SSH and SFTP operations using environment variables for credentials.
import os
from spindlex import SSHClient, SFTPClient
host = os.environ.get('SSH_HOST', 'localhost')
port = int(os.environ.get('SSH_PORT', 22))
username = os.environ.get('SSH_USER', 'user')
password = os.environ.get('SSH_PASS', '')
client = SSHClient(host, port=port)
client.connect(username, password)
# Execute a command
stdout, stderr, exit_code = client.run('ls -la')
print('STDOUT:', stdout)
# File transfer
sftp = client.sftp()
sftp.put('local.txt', '/remote/path/remote.txt')
sftp.get('/remote/path/remote.txt', 'downloaded.txt')
client.close()
Errors
Common errors & fixes
spindlex.SSHClient` object has no attribute 'sftp'
Using an older version (<0.6.0) where SFTP was not integrated into SSHClient.
fixUpgrade spindlex to >=0.6.0: pip install --upgrade spindlex
ImportError: cannot import name 'SSHClient' from 'spindlex'
Installed version is <0.5.0 where the main classes were in a different location.
fixUpgrade to 0.7.2: pip install --upgrade spindlex
TimeoutError: Connection timed out
SSH server not reachable or firewall blocking port 22. Also, default timeout is None (infinite) leading to indefinite hang.
fixEnsure server is accessible and set timeout: SSHClient(host, timeout=10)
Upgrade
Version history
0.7.2latest on PyPI · released May 30, 2026
Audit
Dependencies
No dependency data recorded yet.