Skip to content

Bug: gguf pypi package corrupts environment #9566

Closed
@vladmandic

Description

@vladmandic

What happened?

installing gguf using pip install gguf will register gguf AND scripts
which means that any app that has scripts in their structure will suddenly start failing just because gguf is installed.

looking at https://github.com/ggerganov/llama.cpp/blob/master/gguf-py/pyproject.toml

packages = [
    {include = "gguf"},
    {include = "gguf/py.typed"},
    {include = "scripts"},
]

culprit is clear - scripts folder should be moved to be under gguf, not as a separate package.
if that is too much, then at least rename scripts package to be gguf_scripts

Name and Version

latest commit as of date of issue: d39e267

What operating system are you seeing the problem on?

Linux, Mac, Windows, BSD

Relevant log output

import gguf
from scripts import test_module

test_module.some_method()


```log
ImportError: cannot import name 'test_module' from 'scripts' (venv/lib/python3.12/site-packages/scripts/__init__.py)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinghelp wantedExtra attention is neededhigh severityUsed to report high severity bugs in llama.cpp (Malfunctioning hinder important workflow)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions