Skip to main content

turbo-xlsx-rs (Python)

Native workbook-model-to-XLSX writer — a PyO3 binding over the turbo-xlsx Rust core. Turn a structured workbook into a formatted .xlsx (OOXML SpreadsheetML, OPC-zipped). Country-agnostic: locale and ISO-4217 currency code are inputs, never hardcoded.

Install

pip install turbo-xlsx-rs          # lean writer
pip install turbo-xlsx-rs-parse    # writer + XLSX reader (adds parse())

The PyPI distribution is turbo-xlsx-rs (PyPI rejects turbo-xlsx as too close to the existing turboxlsx); the import name stays turbo_xlsx either way. The -parse wheel adds an .xlsx reader — pick whichever variant you need.

import turbo_xlsx as x

wb = {
    "sheets": [
        {
            "name": "Pay",
            "rows": [
                {"cells": [
                    {"type": "string", "value": "Alice"},
                    {"type": "currency", "value": 123456,
                     "currency": {"code": "MXN", "locale": "es-MX"}},
                ]}
            ],
        }
    ]
}

data = x.write(wb)            # -> bytes, starts with b"PK" (xlsx is a zip)
assert data.startswith(b"PK")

API

  • write(workbook, opts=None) -> bytes — one-shot from a workbook dict.
  • write_full(workbook, opts=None) -> (bytes, list) — also returns lint diagnostics.
  • write_from_json(input, opts=None) -> bytes — input is a JSON string or value.
  • write_rows(input, opts=None) -> bytes — fast-path: one sheet from typed columns + rows ({sheetName?, locale?, columns?, rows}).
  • create_writer(opts=None) -> WorkbookWriter / WorkbookWriter(locale=None, opts=None) — row-by-row streaming: start_sheet, write_row, end_sheet, finish() -> (bytes, list).
  • parse(data, format=None, sheet=None, typed=False) -> str — turbo-xlsx-rs-parse wheel only. Read an .xlsx (incl. DEFLATE-compressed) into JSON (values grid or typed=True model), format="csv", or format="md". ~10× faster than openpyxl at reading, cell-for-cell verified against it.

opts is an optional dict {meta: {title, author, subject, company}, locale?, password?}. Setting password encrypts the output with ECMA-376 Agile Encryption (AES-256) — x.write(wb, {"password": "s3cret"}) — which Excel/LibreOffice open with that password.

Fatal validate/write faults raise TurboXlsxError (with .code and .message). Non-fatal lints are returned, never raised.

Metadata

Release files for turbo-xlsx-rs-parse 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for turbo-xlsx-rs-parse 0.1.3
File Size Uploaded
turbo_xlsx_rs_parse-0.1.3.tar.gz 84.8 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for turbo-xlsx-rs-parse 0.1.3
File
turbo_xlsx_rs_parse-0.1.3-cp38-abi3-win_amd64.whl CPython 3.8 abi3 Windows x86-64 Details
turbo_xlsx_rs_parse-0.1.3-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.8 abi3 Linux glibc 2.17+ x86-64 Details
turbo_xlsx_rs_parse-0.1.3-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl CPython 3.8 abi3 Linux glibc 2.17+ ARM64 Details
turbo_xlsx_rs_parse-0.1.3-cp38-abi3-macosx_11_0_arm64.whl CPython 3.8 abi3 macOS 11.0+ ARM64 Details

Total release size: 2.9 MB

Release files / turbo_xlsx_rs_parse-0.1.3.tar.gz

Download URL turbo_xlsx_rs_parse-0.1.3.tar.gz
Size 84.8 kB
Tags Source
SHA-256 checksum
How to use checksums
2f6e1553377b5217de39bae2b689164cf5e0df4d6355657a0c73866e6340a769
BLAKE2b-256 checksum
How to use checksums
5998e626eb2a1993e7a86f9df452c15c1fa43a095b0f8e1d39762088507d38f7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.14.1

Release files / turbo_xlsx_rs_parse-0.1.3-cp38-abi3-win_amd64.whl

Download URL turbo_xlsx_rs_parse-0.1.3-cp38-abi3-win_amd64.whl
Size 646.2 kB
Tags CPython 3.8 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
ac9992de33b1054e2fb6bec7c6011598a70f4f6afd59990d932ce0a73c46513d
BLAKE2b-256 checksum
How to use checksums
30f130e7579569789dc8a2d036fffcd397cb7b5a931c0796add602f9c459b38a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.14.1

Release files / turbo_xlsx_rs_parse-0.1.3-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL turbo_xlsx_rs_parse-0.1.3-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 762.9 kB
Tags CPython 3.8 Linux glibc 2.17+ x86-64 abi3
SHA-256 checksum
How to use checksums
580a7ffffeccde24cb3c558cdd315095c934bef088a3e3157aa2f5aeeba58755
BLAKE2b-256 checksum
How to use checksums
3719b871bec79ff3e04a6527c8340f8c829df28edb3e6f20a646e1c786f61d9a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.14.1

Release files / turbo_xlsx_rs_parse-0.1.3-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Download URL turbo_xlsx_rs_parse-0.1.3-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Size 731.1 kB
Tags CPython 3.8 Linux glibc 2.17+ ARM64 abi3
SHA-256 checksum
How to use checksums
32557c4f9a45685a310fcba04582b74b3001db4c1060f626ecb2bb110f86f923
BLAKE2b-256 checksum
How to use checksums
badef94240e5551871c3982797b41936d536480795633ccc142ea6d9b897cfd7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.14.1

Release files / turbo_xlsx_rs_parse-0.1.3-cp38-abi3-macosx_11_0_arm64.whl

Download URL turbo_xlsx_rs_parse-0.1.3-cp38-abi3-macosx_11_0_arm64.whl
Size 684.4 kB
Tags CPython 3.8 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
a0b04e2aaba66c6ea75d87b71320e6f52d9a11be6c5ed7ef73c731d5bbeb3129
BLAKE2b-256 checksum
How to use checksums
dfb7a9efc9aeb942646dd35a0344eef1f8ff82524da36893a35ad2542d297664
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.14.1

Release history Release notifications | RSS feed

This release

0.1.3 This release

5 release files

0.1.2

5 release files

0.1.1

5 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page