Install & Compatibility
Where this runs
tested against v2.7.0 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
muslpy 3.10–3.95 runs
installs and imports cleanly · install 0.0s · import 0.912s · 23.4MB
glibcpy 3.10–3.95 runs
installs and imports cleanly · install 3.0s · import 0.836s · 24MB
25MB installed
● package 25MB
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
Etcd3Client
✓ from etcd3gw.client import Etcd3Client
✗ from etcd3gw import Etcd3Client
Etcd3Client is not exposed at package level in 2.x. Must import from submodule.
Etcd3Client
✓ from etcd3gw import Etcd3Client
In version 1.x, direct import worked. Version 2.x changed location.
Create a client, write a key, read it back.
from etcd3gw.client import Etcd3Client
client = Etcd3Client(host='localhost', port=2379)
client.put('/key', 'value')
value, metadata = client.get('/key')
print(value)
Errors
Common errors & fixes
ModuleNotFoundError: No module named 'etcd3gw'
Library not installed or installed in wrong environment.
fixRun `pip install etcd3gw` in the correct Python environment.
ImportError: cannot import name 'Etcd3Client' from 'etcd3gw'
Using wrong import path for version 2.x.
fixUse `from etcd3gw.client import Etcd3Client`.
TypeError: cannot unpack non-iterable str object
Calling `client.get(key)` and trying to unpack the result, but the library version returns a string (v1) instead of tuple (v2).
fixUpdate to v2 and unpack: `value, metadata = client.get(key)`. If stuck on v1, do not unpack.
ConnectionError: HTTPConnectionPool ... Failed to establish a new connection
etcd gateway not running or unreachable at given host:port.
fixVerify etcd is running and the gateway endpoint (usually port 2379) is accessible. Check host/port arguments.
Upgrade
Version history
2.7.0latest on PyPI · released Jun 9, 2026
Audit
Dependencies
requestsrequiredHTTP client for API calls
urllib3requiredUnderlying HTTP library