[project] name = "magika" description = "A tool to determine the content type of a file with deep learning" authors = [ {name = "Magika Developers", email = "magika-dev@google.com"}, ] readme = "README.md" license = {"text" = "Apache-2.0"} requires-python = ">=3.8" keywords = ["content type detection", "machine learning"] classifiers = [ "Development Status :: 5 - Production/Stable", "Environment :: Console", "License :: OSI Approved :: Apache Software License", "Intended Audience :: Developers", "Intended Audience :: Science/Research", "Intended Audience :: System Administrators", "Programming Language :: Python", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.13", "Operating System :: MacOS", "Operating System :: Microsoft :: Windows", "Operating System :: Unix", "Topic :: Scientific/Engineering :: Artificial Intelligence", "Topic :: Security", "Topic :: Software Development", "Typing :: Typed", ] dynamic = ["version"] dependencies = [ "click>=8.1.7", "onnxruntime>=1.17.0 ; python_version > '3.9'", "onnxruntime>=1.17.0, <1.20.0 ; python_version <= '3.9'", "onnxruntime<=1.20.1 ; sys_platform == 'win32'", "numpy>=1.24; python_version < '3.12'", "numpy>=1.26; python_version >= '3.12' and python_version < '3.13'", "numpy>=2.1.0; python_version >= '3.13'", "python-dotenv>=1.0.1", ] [project.urls] Homepage = "https://github.com/google/magika" Documentation = "https://github.com/google/magika/blob/main/python/README.md" Repository = "https://github.com/google/magika/" Issues = "https://github.com/google/magika/issues" Changelog = "https://github.com/google/magika/blob/main/python/CHANGELOG.md" [tool.uv] dev-dependencies = [ "mypy>=1.11.2", "ipython>=8.12.3", "pytest>=8.3.2", "ruff>=0.6.3", "twine==6.1.0", "tomli-w>=1.0.0", "tomli>=2.0.1", "tqdm>=4.67.1", "dacite>=1.9.2", ] [build-system] requires = ["maturin>=1.7,<2.0"] build-backend = "maturin" [tool.hatch.version] path = "src/magika/__init__.py" [tool.maturin] python-source = "src" module-name = "magika" bindings = "bin" manifest-path = "../rust/cli/Cargo.toml" locked = true [tool.ruff.lint] # Enable Pyflakes (`F`) and a subset of the pycodestyle (`E`) codes by default. # Unlike Flake8, Ruff doesn't enable pycodestyle warnings (`W`) or # McCabe complexity (`C901`) by default. select = ["D", "E4", "E7", "E9", "F", "I001"] ignore = ["D105"] [tool.ruff.lint.per-file-ignores] "scripts/*" = ["D"] "tests/*" = ["D"] [tool.ruff.lint.pydocstyle] convention = "google" [tool.ruff.format] docstring-code-format = true