ahawker / ulid

Universally Unique Lexicographically Sortable Identifier (ULID) in Python 3
Apache License 2.0
695 stars 42 forks source link

Fixes #484 - correct hex padding Ensures calls to .hex correctly pad to 32 hex characters, including leading zero. #485

Closed xkortex closed 3 years ago

xkortex commented 3 years ago

Addresses #484 by ensuring that .hex outputs correctly-padded 32 hex characters. With the leading '0x', this means calls to .hex always result in a length-34 string.

0x15caf47948d0246deb95cf9a5ec5957 - Odd length hex string πŸ‘Ž

0x015caf47948d0246deb95cf9a5ec5957 - Even length hex string πŸ‘

ahawker commented 3 years ago

@xkortex Thanks for the contribution & PR. I'll try and find time this week to take a look at this, namely, getting CI working again. In order to do so, can you make sure repo maintainers have modification access to your PR/branch - https://docs.github.com/en/github/collaborating-with-pull-requests/working-with-forks/allowing-changes-to-a-pull-request-branch-created-from-a-fork

Thanks!

xkortex commented 3 years ago

Looks like "Allow edits by maintainers" is checked on this PR. Is that sufficient, or do I need to enable anything on my fork? According to the instructions, that should be sufficient.

codecov[bot] commented 3 years ago

Codecov Report

Merging #485 (73fc7bc) into master (96bdb1d) will not change coverage. The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##            master      #485   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           19        19           
  Lines          547       548    +1     
  Branches        80        80           
=========================================
+ Hits           547       548    +1     
Impacted Files Coverage Ξ”
ulid/ulid.py 100.00% <100.00%> (ΓΈ)

Continue to review full report at Codecov.

Legend - Click here to learn more Ξ” = absolute <relative> (impact), ΓΈ = not affected, ? = missing data Powered by Codecov. Last update 96bdb1d...73fc7bc. Read the comment docs.

ahawker commented 3 years ago

Merged but will need to fix CI so I have automated deployments to pypi again.