Create and transform ULIDs
Project description
Fast ULID transformations
Create and transform ULIDs
This library will use the CPP implementation from https://github.com/suyash/ulid if cython is available, and will fallback to pure python if it is not.
Example
>>> import ulid_transform
>>> ulid_transform.ulid_hex()
'01869a2ea5fb0b43aa056293e47c0a35'
>>> ulid_transform.ulid_now()
'0001HZX0NW00GW0X476W5TVBFE'
>>> ulid_transform.ulid_at_time(1234)
'000000016JC62D620DGYNG2R8H'
>>> ulid_transform.ulid_to_bytes('0001HZX0NW00GW0X476W5TVBFE')
b'\x00\x00c\xfe\x82\xbc\x00!\xc0t\x877\x0b\xad\xad\xee'
>> ulid_transform.bytes_to_ulid(b"\x01\x86\x99?\xe8\xf3\x11\xbc\xed\xef\x86U.9\x03z")
'01GTCKZT7K26YEVVW6AMQ3J0VT'
Installation
Install this via pip (or your favourite package manager):
pip install ulid-transform
Contributors ✨
Thanks to https://github.com/suyash/ulid which provides the cython implementation guts.
Thanks goes to these wonderful people (emoji key):
This project follows the all-contributors specification. Contributions of any kind welcome!
Credits
This package was created with Copier and the browniebroke/pypackage-template project template.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
ulid_transform-0.4.1.tar.gz
(14.2 kB
view hashes)
Built Distributions
Close
Hashes for ulid_transform-0.4.1-cp311-cp311-musllinux_1_1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bfda7dbb1c9d182e8bedd31f5cb76a44aaaae1e54a22501e8e48b763407ac9f0 |
|
MD5 | ccbb16f8d8791ba0d08d08f921224f81 |
|
BLAKE2b-256 | f020182064f9d23d3c4fca4da11c7c0c15f79b370f52f08661847e8435611835 |
Close
Hashes for ulid_transform-0.4.1-cp311-cp311-musllinux_1_1_i686.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 15aa7f864684a61cfe235c2ca1f136500358b2edd6bc5c19863eac935a66c07c |
|
MD5 | 69bdf4c205eff6ab003dca5265fd66e4 |
|
BLAKE2b-256 | 5e85b0c1bc357659f9d370b8f6784ef8aabfea757e0fcdd42e31e2e98bbee282 |
Close
Hashes for ulid_transform-0.4.1-cp311-cp311-manylinux_2_17_x86_64.manylinux_2_5_x86_64.manylinux1_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6818ab48a4fa6486280a6f343c7ec6da89209f7a2bd3f1540b6f398fc8d4f447 |
|
MD5 | a3b53ca9fe5d84273263e6d8c3afd6de |
|
BLAKE2b-256 | e81575aea282d9ef148f9ead3d3ff95eccec2ca270c67fa381da6ee1cfdcd2ef |
Close
Hashes for ulid_transform-0.4.1-cp311-cp311-manylinux_2_17_i686.manylinux_2_5_i686.manylinux1_i686.manylinux2014_i686.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 451420f99c6f6002624e729f233ced09bdaf08e9d1514767bff5fc2d5d19ed1a |
|
MD5 | e9b2e405b92ad2bef33bebb89e95c690 |
|
BLAKE2b-256 | f0d8932560a320e9ad05a68ef45d297af468bc11b298f996c82a4a5ee5e9cb00 |
Close
Hashes for ulid_transform-0.4.1-cp310-cp310-musllinux_1_1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9d7ce55ade2d601c44d565f1fa8c3a7cab27fe255cf56e277d801ac621b1ea26 |
|
MD5 | a275736d57b00245d5a410422613a71e |
|
BLAKE2b-256 | 54e719ee74160c994d6aff8507668523dcd79f860a59699469e59842a24adcd7 |
Close
Hashes for ulid_transform-0.4.1-cp310-cp310-musllinux_1_1_i686.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bb8cead9de6ce553eefdb672d8190311250b60e66c2cfb85bef4678fd95a43d2 |
|
MD5 | 62f4446ff94f936b95577a8b2d1616dc |
|
BLAKE2b-256 | 82c81c687b32536f66504a55bbe6231fcca907f2aac7c1fd5fc5a8512080759e |
Close
Hashes for ulid_transform-0.4.1-cp310-cp310-manylinux_2_31_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0abbeb39c225ef35f3dda06ff27b891267da75a70e77224b3c01dfc7df43f985 |
|
MD5 | 2f475e20844c04d55673056d84cf9b4c |
|
BLAKE2b-256 | aede093019b7588296cbe5938c7de042fd385e45ea9716ad2cc2ed90d36bdcfe |
Close
Hashes for ulid_transform-0.4.1-cp310-cp310-manylinux_2_17_x86_64.manylinux_2_5_x86_64.manylinux1_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d06a5c751af081396ccaeb765186f9a5d854fcfae8e4590b8af0c31e5392c672 |
|
MD5 | 147557c8bdc7e8ff72873e859dbeb10b |
|
BLAKE2b-256 | 3406e23361c669c7857a57fe697fdf11a7f34e814156496c7525c6fa285431af |
Close
Hashes for ulid_transform-0.4.1-cp310-cp310-manylinux_2_17_i686.manylinux_2_5_i686.manylinux1_i686.manylinux2014_i686.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 054c3b51788fe867b4e5fd649667e5100f25966e86b0e36eb8a7d908df03b135 |
|
MD5 | c00691402dde24004f980dc82e9226b1 |
|
BLAKE2b-256 | d3fded70ed747c68893d070599477d0ae9563be941495c81f225d0a39b253f88 |