Repository navigation
Conversation
FanWu-ai
marked this pull request as ready for review
October 8, 2026 06:26
This branch has not been deployed
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.
Problem
Keywords whose names coincide with positional-only parameters belong to
**kwargs.curry.__signature__currently treats those keywords as bindings for the positional-only parameters instead. This changes their defaults and kinds, converts later parameters to keyword-only, and can remove*argsentirely.For example:
The advertised signature is
(*, a=10, **kwargs), whilearemains positional-only with its original default and*argsremains available.Change
Exclude positional-only parameters from keyword-binding transformations in
curry.__signature__. Add regression coverage for same-named keyword bindings, multiple positional-only parameters, preservation of variadic arguments, and a simultaneous real positional-or-keyword binding.Validation
Python 3.12.14. Four new regression cases fail before the source fix and pass afterward. Final local checks:
coverage run -m pytest --doctest-modules toolz/: 272 passed, 2 expected skips (a skipped doctest and Python 3.14-only annotation test).pytest bench/: 19 passed.Repository-wide
pycodestyle --ignore="E731,W503,W504,E402" --exclude=conf.py,tests,examples,bench -r --show-source .: passed.git diff --check: passed.pre-commit run --all-files: passed, including PySentry, actionlint, zizmor, and all remaining applicable hooks.Additional validation completed after opening this draft:
python -m buildandpython -m twine check --strict dist/*: passed for baseline and final code, including wheel and sdist.AI assistance disclosure: this fix, regression tests, and description were prepared with an OpenAI coding assistant.