Skip to content

noid generation is kinda dumb #17

@squidgetx

Description

@squidgetx

Current implementation is basically this:

BETANUMERIC = "0123456789bcdfghjkmnpqrstvwxz"
def generate_noid(length: int) -> str:
    return "".join(secrets.choice(BETANUMERIC) for _ in range(length))

and when an ARK is minted we call generate_noid(8) and then just try again if there is a collision

There's no way this is actually good lol, i mean it's not actually the worst but performance would definitely be better if we used numbers or uuids.

https://metacpan.org/dist/Noid/view/noid

37B combinations

Metadata

Metadata

Assignees

No one assigned

    Labels

    wontfixThis will not be worked on

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions