Skip to content

Bug: gguf tries to access newbyteorder, which was removed in numpy2.0 #10127

@renxida

Description

@renxida

What happened?

newbyteorder was removed from the ndarray class in NumPy 2.0. Use arr.view(arr.dtype.newbyteorder(order)) instead.

Name and Version

gguf==0.1.0

What operating system are you seeing the problem on?

Linux

Relevant log output

File "/home/sfdemo/.local/lib/python3.12/site-packages/gguf/gguf_reader.py", line 151, in _get                                .newbyteorder(override_order or self.byte_order)
     ^^^^^^^^^^^^                                                                                                           AttributeError: `newbyteorder` was removed from the ndarray class in NumPy 2.0. Use `arr.view(arr.dtype.newbyteorder(order))` instead.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug-unconfirmedmedium severityUsed to report medium severity bugs in llama.cpp (e.g. Malfunctioning Features but still useable)stale

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions