{"id":21426,"library":"hazelcast-python-client","title":"Hazelcast Python Client","description":"Python client for Hazelcast, an open-source in-memory data grid. Current version 5.6.0 (requires Python 3.11+). Released approximately quarterly.","status":"active","version":"5.6.0","language":"python","source_language":"en","source_url":"https://github.com/hazelcast/hazelcast-python-client","tags":["hazelcast","in-memory-data-grid","distributed-cache","python-client"],"install":[{"cmd":"pip install hazelcast-python-client","lang":"bash","label":"Default install"}],"dependencies":[{"reason":"Kerberos authentication support","package":"hazelcast-kerberos","optional":true}],"imports":[{"note":"hazelcast alone doesn't import client","wrong":"import hazelcast","symbol":"HazelcastClient","correct":"from hazelcast.client import HazelcastClient"},{"note":"ClientConfig is in hazelcast.client","wrong":"from hazelcast.config import ClientConfig","symbol":"ClientConfig","correct":"from hazelcast.client import ClientConfig"}],"quickstart":{"code":"from hazelcast.client import HazelcastClient, ClientConfig\nconfig = ClientConfig()\nconfig.cluster_name = os.environ.get('HZ_CLUSTER_NAME', 'hello-world')\nconfig.cluster_members = [os.environ.get('HZ_MEMBER_ADDRESS', '127.0.0.1:5701')]\nclient = HazelcastClient(config)\nmy_map = client.get_map('my-distributed-map')\nmy_map.set('key', 'value').result()\nprint(my_map.get('key').result())\nclient.shutdown()","lang":"python","description":"Connect to a Hazelcast cluster, use a distributed map."},"warnings":[{"fix":"Use client.get_map('m').get('key').result() for synchronous, or switch to hazelcast.asyncio module.","message":"Async operations now require calling .result() on futures; direct await is only available in asyncio module (Beta).","severity":"breaking","affected_versions":">=5.6.0"},{"fix":"Upgrade Python to 3.11 or higher.","message":"Python 3.11 minimum required starting from v5.6.0.","severity":"breaking","affected_versions":">=5.6.0"},{"fix":"Configure a custom serialization serializer or allow only trusted clusters.","message":"Default serialization uses Python pickle for unrecognized types, which can be a security risk when connecting to untrusted clusters.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-04-27T00:00:00.000Z","next_check":"2026-07-26T00:00:00.000Z","problems":[{"fix":"Use `from hazelcast.client import HazelcastClient`","cause":"Common mistake: `import hazelcast` does not expose HazelcastClient.","error":"ImportError: cannot import name 'HazelcastClient' from 'hazelcast'"},{"fix":"Call `.result()` on the future to wait for the operation to complete.","cause":"Using threading.Thread's join incorrectly; Hazelcast futures use .result() not .join().","error":"AttributeError: 'Future' object has no attribute 'join'"},{"fix":"Ensure client lifecycle management: create client, perform operations, then shutdown.","cause":"Attempting operations after client.shutdown() or before client is fully connected.","error":"hazelcast.errors.HazelcastClientNotActiveError: HazelcastClientNotActiveError()"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}