Skip to content

About

Polars plugin providing uuid functionality

Resources

Stars

2 stars

Watchers

1 watching

Forks

Latest commit

 

History

24 Commits

Folders and files

Repository files navigation

polars-uuid

CI License: Apache 2.0

A Polars plugin that adds UUID generation and introspection expressions, implemented in Rust for speed.

Installation

pip install polars-uuid-plugin

Quick example

import uuid

import polars as pl
import polars_uuid

df = pl.DataFrame({"name": ["example.com", "example.org", "example.com"]})
df.with_columns(
    polars_uuid.uuid4("name").alias("random_id"),
    polars_uuid.uuid5("name", namespace=uuid.NAMESPACE_DNS).alias("deterministic_id"),
    polars_uuid.uuid7("name").alias("time_ordered_id"),
)

Also included: is_valid_uuid, uuid_version, and extract_timestamp for working with UUIDs already in your data. See polars_uuid/README.md for the full function reference, plus instructions for building the plugin from source, running the test suite, and cutting a release.

Learn more

Repository layout

The Rust/Python plugin project lives in the nested polars_uuid/ directory; the Makefile at this repo root wraps its build commands so you don't need to cd into it yourself (make help lists the available commands).

License

Apache License 2.0

About

Polars plugin providing uuid functionality

Resources

Stars

2 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages