Repository navigation
fix: print results when running ulid as a module - #68
Merged
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #68 +/- ##
=======================================
Coverage 98.65% 98.65%
=======================================
Files 4 4
Lines 372 372
Branches 61 61
=======================================
Hits 367 367
Misses 3 3
Partials 2 2 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
mdomke
requested changes
Oct 26, 2026
|
mdomke
approved these changes
Oct 27, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



python -m ulid build --from-int 0exits successfully without printing its result on the original implementation. The module entry point callsmain()and discards its return value, while the installedulidcommand prints it correctly.Changes
entrypoint()to retainpython -m ulidin module usage text. The installed console entry point keeps its existing default.buildandshow, each with arguments and piped stdin. Cover help/no-argument usage and the existing console entry point as controls.For example, both
python -m ulid build --from-int 0andulid build --from-int 0should print00000000000000000000000000. The subprocess tests exercise the real module boundary rather than callingmain()directly. The four output regressions were confirmed failing before the source fix during the original implementation.Validation
Latest local validation on Linux / Python 3.14.6, after incorporating the maintainer's upstream merges and removing the temporary metadata restrictions:
uv run poe fmtanduv run poe check: passed, including Ruff, Pyrefly and doc8.uv run poe test: 94 passed; CLI module coverage 100%, total reported coverage 99%.uv run prek run --all-files: all configured hooks passed.uv run poe build: wheel and source distribution built successfully. Both declare core metadata 2.5 and retain the upstreamRequires-Python: >=3.11requirement.twine check --strictusing Twine 7.0.0 and packaging 26.3, matching the versions pinned by the upstream package-check action. The wheel also passed check-wheel-contents 0.6.3.build/showcommands produced matching expected output (4 smoke checks passed).git diff --check: passed.Other Python versions and operating systems were not rerun locally for this review revision; the current hosted results are reported in the Checks tab.
Review follow-up
Removed both
core-metadata-version = "2.4"overrides as requested. The maintainer has upgraded the upstream package-check action to v3.0.2, so these compatibility restrictions are no longer necessary.pyproject.tomlnow matches the upstream base; this PR retains only the CLI fix, its regression tests, and the changelog entry.Codex assisted with the implementation, tests, automated validation, and this description.