Skip to content

fix: ship the CRC libraries in sdists and wheels - #191

Open
negoro26 wants to merge 1 commit into
unitreerobotics:masterfrom
negoro26:fix/package-crc-libraries
Open

negoro26 wants to merge 1 commit into
unitreerobotics:masterfrom
negoro26:fix/package-crc-libraries

Conversation

@negoro26

@negoro26 negoro26 commented Oct 22, 2026 •

Copy link
Copy Markdown

Problem

unitree_sdk2py/utils/crc.py loads utils/lib/crc_amd64.so (or crc_aarch64.so) on Linux, but setup.py declares no package data. An sdist therefore omits both libraries, and so does every wheel built from it: pip, uv and python -m build all build wheels through the sdist. Installing from this repository with any of them gives:

OSError: .../unitree_sdk2py/utils/lib/crc_amd64.so: cannot open shared object file: No such file or directory

as soon as CRC() is constructed, so no LowCmd_ can be sent.

Fix

Declare the two libraries as package data (one line in setup.py).

Verification

uv build (sdist, then wheel from the sdist) on master and on this branch:

sdist .so files wheel .so files
master (814556d) none none
this branch crc_aarch64.so, crc_amd64.so crc_aarch64.so, crc_amd64.so

A Go2 low-level client installed from this branch through uv (no manual copying) computes the LowCmd_ CRC for every command: a 67 s run of a 500 Hz control loop sent 490.9 LowCmd per second on a loaded host.

unitree_sdk2py/utils/crc.py loads utils/lib/crc_amd64.so or crc_aarch64.so on Linux, but setup.py declares no package data, so an sdist and any wheel built from it (pip, uv and build all go through the sdist) omit both libraries and CRC() fails with 'cannot open shared object file'. Declare them as package data.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant