{"id":21370,"library":"gamma-pytools","title":"Gamma Pytools","description":"A collection of Python extensions and tools used in BCG GAMMA's open-source libraries. Current version 3.0.2, with support for Python >=3.10 and <4a. Released under MIT license. Maintenance and feature updates with monthly releases.","status":"active","version":"3.0.2","language":"python","source_language":"en","source_url":"https://github.com/BCG-X-Official/pytools","tags":["utilities","extensions","BCG GAMMA","tooling"],"install":[{"cmd":"pip install gamma-pytools","lang":"bash","label":"pip install (PyPI)"}],"dependencies":[{"reason":"Core dependency for array operations","package":"numpy","optional":false},{"reason":"Used for scientific computing utilities","package":"scipy","optional":false},{"reason":"Required for type hints","package":"typing_extensions","optional":false}],"imports":[{"note":"Pytools is a class, not a module.","wrong":"import Pytools","symbol":"Pytools","correct":"from pytools import Pytools"}],"quickstart":{"code":"from pytools import Pytools, Api\n\n# Initialize with optional API token for advanced features\npt = Pytools(api_token=os.environ.get('PYTOOLS_API_TOKEN', ''))\nprint(pt.__version__)","lang":"python","description":"Basic usage of gamma-pytools. The Pytools class is the entry point."},"warnings":[{"fix":"Update your code to use the new method names. See the release notes for details.","message":"Version 3.0.0 introduced breaking API changes: methods like `to_list()` and `to_se` were renamed.","severity":"breaking","affected_versions":">=3.0.0"},{"fix":"Upgrade to Python 3.10 or higher.","message":"Python 3.10 minimum requirement. Older Python versions (3.9 and below) are no longer supported.","severity":"breaking","affected_versions":">=3.0.0"},{"fix":"Check the documentation for alternatives.","message":"Some functions in `pytools.api` module may be deprecated in future releases.","severity":"deprecated","affected_versions":">=3.0.0"},{"fix":"Always use `import pytools`.","message":"The package is named `gamma-pytools` on PyPI, but imports use `pytools`. Do not use `import gamma-pytools`.","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":"Run `pip install gamma-pytools` and then use `import pytools`.","cause":"The package is installed under the name 'gamma-pytools', but the import is 'pytools'.","error":"ImportError: No module named 'pytools'"},{"fix":"Use `import pytools` instead.","cause":"Trying to import the package using its PyPI name with underscores.","error":"ModuleNotFoundError: No module named 'gamma_pytools'"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}