--- id: hmsclient version: "0.1.1" license: Apache 2.0 license_treatment: permissive maintenance: active --- # hmsclient — A package interact with the Hive metastore via the Thrift protocol License: permissive · Maintenance: active · Downloads: 5.1M/mo ## What it is and what it does HMSClient is a thin Python wrapper around Thrift-generated code for communicating with the Hive metastore. It provides a simple interface to query Hive metadata—such as checking for named partitions—by wrapping the low-level Thrift protocol details. The package depends on thrift for protocol handling and click for its code generation utility. The client is designed for developers who need programmatic access to Hive metastore information from Python. It uses a context-manager pattern for connections and exposes methods like check_for_named_partition to interact with the metastore. The package also includes a code generation tool (generate.py) that can regenerate the Thrift bindings from updated .thrift schema files. Use it for: - Check whether a specific partition exists in a Hive table before running ETL jobs - Programmatically query Hive metadata from Python applications or data pipelines - Regenerate Thrift client code when upgrading to a newer Hive metastore schema - Integrate Hive metastore queries into data orchestration or validation workflows ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. A Python client for connecting to and querying the Hive metastore via the Thrift protocol, enabling programmatic access to Hive metadata and partition information. Yes, if you need Hive metastore access from Python and are working with a compatible Hive version. The low install friction and permissive license make it straightforward to adopt. However, note that the package has not been updated since 2018—verify that the Thrift protocol implementation works with your target Hive metastore version before relying on it in production. ## Install pip install hmsclient uv add hmsclient poetry add hmsclient ## Installing hmsclient Before you install: Low install friction with only 2 runtime dependencies (thrift and click). The package is actively maintained with recent commits, though the latest release was in 2018. License in practice: Licensed under Apache 2.0 (permissive), allowing use in commercial and proprietary projects with minimal restrictions beyond attribution and liability disclaimers. Quickstart: pip install hmsclient from hmsclient import hmsclient client = hmsclient.HMSClient(host='localhost', port=9083) with client as c: c.check_for_named_partition('db', 'table', 'date=20180101') Requires a running Hive metastore server accessible at the specified host and port; thrift compiler needed only if regenerating bindings via generate.py Verify before relying: - Whether the Thrift protocol implementation remains compatible with current Hive metastore versions - Python version support beyond 3.5 and 3.6 listed in classifiers - Whether the package handles Hive metastore schema changes since 2018 ## Package facts - License: Apache 2.0 (permissive) - Python support: unspecified - Install friction: low - Maintenance: active - Downloads: 5.1M/month (top 5,000 on PyPI) - Known vulnerabilities: none known ## Tags hive metastore client, thrift hive connection, hive metadata python, hive partition queries, metastore thrift protocol, hive database client, hive-integration, thrift-client [View on SkillFed](https://skillfed.io/packages/hmsclient) · [View on PyPI](https://pypi.org/project/hmsclient/)