Zacro
Fast Rust implementation of xacro (XML macro language) with enhanced features for modular robotics.
Overview
Zacro is a high-performance Rust implementation of the xacro XML macro language with enhanced features specifically designed for modular robotics applications. It provides:
- Complete macro expansion: Full support for xacro macro definitions and calls
- Formatted output: Optional XML formatting with proper indentation
- Modular robot support: Remove redundant first joints for modular robot assemblies
- High performance: Rust implementation for fast processing of large xacro files
- Python bindings: Easy-to-use Python API with both functional and class-based interfaces
Features
- ✅ Complete macro expansion
- ✅ Property definitions and substitution
- ✅ Mathematical expressions
- ✅ File inclusion with package resolution
- ✅ Formatted XML output
- ✅ Modular robot first joint removal
- ✅ Python bindings
- ✅ Class-based and functional APIs
Installation
pip install zacro
From Source
git clone https://github.com/iory/zacro
cd zacro
pip install maturin
maturin develop --features python
Quick Start
Basic Usage
import zacro
# Process xacro file to URDF
result = zacro.xacro_to_string("robot.xacro")
# Process with formatting
result = zacro.xacro_to_string("robot.xacro", format_output=True)
# Process from string
xml_string = """<?xml version="1.0"?>
<robot xmlns:xacro="http://ros.org/wiki/xacro">
<xacro:macro name="box" params="name">
<link name="${name}">
<visual><geometry><box size="1 1 1"/></geometry></visual>
</link>
</xacro:macro>
<xacro:box name="my_box"/>
</robot>"""
result = zacro.xacro_from_string(xml_string, format_output=True)
Modular Robot Support
For modular robot xacro files where each module has a connection joint to its parent:
# Remove redundant first joints in modular robot assemblies
result = zacro.xacro_to_string(
"modular_robot.xacro",
format_output=True,
remove_first_joint=True
)
Class-based API
processor = zacro.XacroProcessor()
processor.set_format_output(True)
processor.set_remove_first_joint(True)
result = processor.process_file("robot.xacro")
Building
Prerequisites
- Rust 1.70+
- Python 3.8+ (for Python bindings)
- maturin (for Python bindings)
Build Rust Library
cargo build --release
Build Python Extension
maturin develop --features python
Run Tests
cargo test
Metadata
Release files for zacro 1.0.13
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| zacro-1.0.13.tar.gz | 100.7 kB | Without provenance | Details for zacro-1.0.13.tar.gz |
Built distributions (wheels)
Total release size: 30.5 MB
Release files / zacro-1.0.13.tar.gz
| Download URL | zacro-1.0.13.tar.gz |
|---|---|
| Size | 100.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f8f327e26e6c65ca55762e9604b0907f9beb938c0d7978a7fd2b95e4dff16ca4
|
|
BLAKE2b-256 checksum How to use checksums |
1f8d2ba36b5009ff9f0da166c34e5a7fe15b84c2d16ce9ee47d1a6c814496bf6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp313-cp313-win_amd64.whl
| Download URL | zacro-1.0.13-cp313-cp313-win_amd64.whl |
|---|---|
| Size | 1.8 MB |
| Tags | CPython 3.13 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
8884c7f7d005806d06b60708d5c593ff09ea6ef49efb09bd0dead5b556c7bf3d
|
|
BLAKE2b-256 checksum How to use checksums |
fbfdfc930036f10b45dae10d27f083502e5b845cc3409ef3439e71116273d1a8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | zacro-1.0.13-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 1.2 MB |
| Tags | CPython 3.13 Linux glibc 2.17+ x86-64 |
|
SHA-256 checksum How to use checksums |
9808cbb5f74a1075f7bfb74a8c19150ae2e565eb472f0762cfd144178907fa59
|
|
BLAKE2b-256 checksum How to use checksums |
f199d782fc4fcab1e1ab1e69ac3e78b40d7be639b58ad01199ff2158f520ebb3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp313-cp313-macosx_11_0_arm64.whl
| Download URL | zacro-1.0.13-cp313-cp313-macosx_11_0_arm64.whl |
|---|---|
| Size | 1.0 MB |
| Tags | CPython 3.13 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
e77ab99d6be8abf168b03141247e9dc14c87e63ecdb59f8ed23f60615a13929f
|
|
BLAKE2b-256 checksum How to use checksums |
badce417e4b41b629439bda24eb324b70cbeaad5abc381f4725682a89ae79e5c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp313-cp313-macosx_10_13_x86_64.whl
| Download URL | zacro-1.0.13-cp313-cp313-macosx_10_13_x86_64.whl |
|---|---|
| Size | 1.1 MB |
| Tags | CPython 3.13 macOS 10.13+ x86-64 |
|
SHA-256 checksum How to use checksums |
d4cc453dc861f989795ce5c9c84d350a77e104955a9fd4d13609cfb4f4f01a8c
|
|
BLAKE2b-256 checksum How to use checksums |
084162b7689b637fd3b05051991b5b33bfe1d4ff0ab00db5a27a7dcc72691dca
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp312-cp312-win_amd64.whl
| Download URL | zacro-1.0.13-cp312-cp312-win_amd64.whl |
|---|---|
| Size | 1.8 MB |
| Tags | CPython 3.12 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
c8a30f8c5e08d4ea16febea715e4b3c81303edf530f19a9d5cbd76c5af236a2e
|
|
BLAKE2b-256 checksum How to use checksums |
d896acfe8e749d2584cf995ababd7cf91563f370abdf4b9d69727ffc00202cdd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | zacro-1.0.13-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 1.2 MB |
| Tags | CPython 3.12 Linux glibc 2.17+ x86-64 |
|
SHA-256 checksum How to use checksums |
4e28d1517955e5086fdcfd4ecc631d644006c851a9384e7993cbb5cc9bfc312d
|
|
BLAKE2b-256 checksum How to use checksums |
e086c6ba2d84991c93ae37563c7d64b1c327d0b41412579298a1c6cc31f1ef60
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp312-cp312-macosx_11_0_arm64.whl
| Download URL | zacro-1.0.13-cp312-cp312-macosx_11_0_arm64.whl |
|---|---|
| Size | 1.0 MB |
| Tags | CPython 3.12 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
f11fe4afa0db81474a6e28c6c86a7bb1b434f64bdd34a9b5db99240b7be039df
|
|
BLAKE2b-256 checksum How to use checksums |
c59e21c35824720bfc9aeb2ef2f8720cfff84385e6e104f09bd8058f1e46a93d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp312-cp312-macosx_10_13_x86_64.whl
| Download URL | zacro-1.0.13-cp312-cp312-macosx_10_13_x86_64.whl |
|---|---|
| Size | 1.1 MB |
| Tags | CPython 3.12 macOS 10.13+ x86-64 |
|
SHA-256 checksum How to use checksums |
a2ded6cba1cccc0cf65bf403fbd777c7bc26dd62da553dcd03a612fa659d95ca
|
|
BLAKE2b-256 checksum How to use checksums |
7148244af1766093137aef215a4fcd6476b2c7f397f6af98ab0e09153cff0baf
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp311-cp311-win_amd64.whl
| Download URL | zacro-1.0.13-cp311-cp311-win_amd64.whl |
|---|---|
| Size | 1.8 MB |
| Tags | CPython 3.11 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
577a6f9fa4eabdd85fcebfc184ff699fe0178588ea41944fa9f3e31c07867bab
|
|
BLAKE2b-256 checksum How to use checksums |
ae1b6bb298138646ce680a422b5e6b2f21597d3b7ca470eef3c71f0ed0e08b04
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | zacro-1.0.13-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 1.2 MB |
| Tags | CPython 3.11 Linux glibc 2.17+ x86-64 |
|
SHA-256 checksum How to use checksums |
44bbbd4d12b50d7c383b5525015e44f1ab7c1ceba4cae1d7b010d4f75e1b47f6
|
|
BLAKE2b-256 checksum How to use checksums |
8cf85699a890aeff997b17ce7a76344ba1969dd1aed8c011deb8eafc7bd8827a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp311-cp311-macosx_11_0_arm64.whl
| Download URL | zacro-1.0.13-cp311-cp311-macosx_11_0_arm64.whl |
|---|---|
| Size | 1.0 MB |
| Tags | CPython 3.11 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
24d11cbcfcb5889f7528c49e2cbd4d577eaf0d12e446060a18572a87dd21ff20
|
|
BLAKE2b-256 checksum How to use checksums |
ee75734422d89263a314744e3d5f2106422d01363f52e19c6918bdeabe89a2ce
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp311-cp311-macosx_10_12_x86_64.whl
| Download URL | zacro-1.0.13-cp311-cp311-macosx_10_12_x86_64.whl |
|---|---|
| Size | 1.1 MB |
| Tags | CPython 3.11 macOS 10.12+ x86-64 |
|
SHA-256 checksum How to use checksums |
1efed3adcf711ed2117a8063427289f48051964dc3a2199cbf98bf8301f4fb5f
|
|
BLAKE2b-256 checksum How to use checksums |
6d90082bd42a887c54333b9b7ae611d75b3821298dab1b3af16190939bab7c55
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp310-cp310-win_amd64.whl
| Download URL | zacro-1.0.13-cp310-cp310-win_amd64.whl |
|---|---|
| Size | 1.8 MB |
| Tags | CPython 3.10 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
b4732878716c61ee5159574c4ab4cbaea8c4ed771b19a2fc64272494001a49ba
|
|
BLAKE2b-256 checksum How to use checksums |
40e8fe6fc8842587329f7a3a82239eca683d0c10d16ab66f2d0119a0c38d96da
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | zacro-1.0.13-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 1.2 MB |
| Tags | CPython 3.10 Linux glibc 2.17+ x86-64 |
|
SHA-256 checksum How to use checksums |
a5e01142a3b736c29517e64f0a103d7c1ef680fa90648cf1a6f39c7979500925
|
|
BLAKE2b-256 checksum How to use checksums |
68ea1b62db471fb2a5bf78308774f3bb0cabaa08cdec7e8a7effb89f5cdcc9d0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp310-cp310-macosx_11_0_arm64.whl
| Download URL | zacro-1.0.13-cp310-cp310-macosx_11_0_arm64.whl |
|---|---|
| Size | 1.0 MB |
| Tags | CPython 3.10 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
4c612cf50b8938dd9d5fad9ed7c122a9ab10f90ea751359ebbd1dc08d38c0912
|
|
BLAKE2b-256 checksum How to use checksums |
f1bb2eca37fa99797c98220efaa8223700ee42f40ced9d4b704a9ecbbd83c0dd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp310-cp310-macosx_10_12_x86_64.whl
| Download URL | zacro-1.0.13-cp310-cp310-macosx_10_12_x86_64.whl |
|---|---|
| Size | 1.1 MB |
| Tags | CPython 3.10 macOS 10.12+ x86-64 |
|
SHA-256 checksum How to use checksums |
45446b7af496a9a133d5cfa9d1bf4ff7d7bc71c5fe6079300f8d03dbf74b6194
|
|
BLAKE2b-256 checksum How to use checksums |
f4ecf35f62fb93b4fcfed756a00126bf5c317fe3eb342a573aeafd3b16666458
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp39-cp39-win_amd64.whl
| Download URL | zacro-1.0.13-cp39-cp39-win_amd64.whl |
|---|---|
| Size | 1.8 MB |
| Tags | CPython 3.9 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
90f522de04df235e1ab067d763e90b871bfaf83d06103d7ffbd8f39bcde6e3f0
|
|
BLAKE2b-256 checksum How to use checksums |
b3884abb6c5b61cd370494e37d9406fbe84512035e5ed78076dade468b09225d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | zacro-1.0.13-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 1.2 MB |
| Tags | CPython 3.9 Linux glibc 2.17+ x86-64 |
|
SHA-256 checksum How to use checksums |
62eba1296633f9a13d9cee578f41b76750172d1612b4b3f03afa040f799a177e
|
|
BLAKE2b-256 checksum How to use checksums |
3282c6394d44732a90e3bace0ce18121238b675f4db41862655e1d0d441cefea
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp39-cp39-macosx_11_0_arm64.whl
| Download URL | zacro-1.0.13-cp39-cp39-macosx_11_0_arm64.whl |
|---|---|
| Size | 1.0 MB |
| Tags | CPython 3.9 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
bafa42a35f54fb2fd7d4307bc10099681c5ac73643adf231280febaad4a873f0
|
|
BLAKE2b-256 checksum How to use checksums |
d30fe3e362abc64545d581b4e9b8fe7027477b28e9a91f79b6145b1b50be6e78
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp39-cp39-macosx_10_12_x86_64.whl
| Download URL | zacro-1.0.13-cp39-cp39-macosx_10_12_x86_64.whl |
|---|---|
| Size | 1.1 MB |
| Tags | CPython 3.9 macOS 10.12+ x86-64 |
|
SHA-256 checksum How to use checksums |
fb691a286076be2862464be8fc43883917bdee3a51e394ec98b8464525eba31e
|
|
BLAKE2b-256 checksum How to use checksums |
1ac83a965b17b0bd94565029e89481447f7a977eab0b4385e1c803ef1a1817b3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp38-cp38-win_amd64.whl
| Download URL | zacro-1.0.13-cp38-cp38-win_amd64.whl |
|---|---|
| Size | 1.8 MB |
| Tags | CPython 3.8 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
8b5bbc349a6a02a8ca850e83abbbd3a7b0230192057eab2d65fb0fc2738869ac
|
|
BLAKE2b-256 checksum How to use checksums |
0716a246ccc10aa967fa1a5e63dbdb87a89ca5d044308ad2fbd47c43a6289cad
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | zacro-1.0.13-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 1.2 MB |
| Tags | CPython 3.8 Linux glibc 2.17+ x86-64 |
|
SHA-256 checksum How to use checksums |
ba8df3c449e60622e23c452274f736c12fa0981c15ef4f59f4f8d6b7ce9613bc
|
|
BLAKE2b-256 checksum How to use checksums |
41be412c52298fb9cd92291f0cc935f1432fb8f04ee70ca19f29ad32cdfd861d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp38-cp38-macosx_11_0_arm64.whl
| Download URL | zacro-1.0.13-cp38-cp38-macosx_11_0_arm64.whl |
|---|---|
| Size | 1.0 MB |
| Tags | CPython 3.8 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
e291c358868fbd9ab37a960ff5bd3992b314271021f9b712beacb76090b5f7c3
|
|
BLAKE2b-256 checksum How to use checksums |
b2409134715f751ea41b041299bfb4bd41cb9a7430c2a6044fbd6aee1cb176b7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / zacro-1.0.13-cp38-cp38-macosx_10_12_x86_64.whl
| Download URL | zacro-1.0.13-cp38-cp38-macosx_10_12_x86_64.whl |
|---|---|
| Size | 1.1 MB |
| Tags | CPython 3.8 macOS 10.12+ x86-64 |
|
SHA-256 checksum How to use checksums |
391969444ba7f61abd041f13b91632247df67f26984f6eddfbd1fc9c3163865d
|
|
BLAKE2b-256 checksum How to use checksums |
65be3441a11de004a812a27484407abe837c04964bbc4df9aaf17c4d84806352
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Security for zacro 1.0.13
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.