Skip to content

ENH: enable strict zip (almost) everywhere#570

Open
neutrinoceros wants to merge 1 commit intoyt-project:mainfrom
neutrinoceros:enh/strict_zip
Open

ENH: enable strict zip (almost) everywhere#570
neutrinoceros wants to merge 1 commit intoyt-project:mainfrom
neutrinoceros:enh/strict_zip

Conversation

@neutrinoceros
Copy link
Copy Markdown
Member

based off #567
Close #568

@neutrinoceros neutrinoceros added this to the 3.1.0 milestone Mar 13, 2025
@neutrinoceros neutrinoceros added the enhancement New feature or request label Mar 13, 2025
@neutrinoceros neutrinoceros changed the title ENH: enable strict zip (almost) everywhere ENH: enable strict zip (almost) everywhere Mar 13, 2025
Comment thread unyt/dimensions.py
"""
for arg_name, arg_value in chain(zip(names_of_args, args), kwargs.items()):
for arg_name, arg_value in chain(
zip(names_of_args, args, strict=False), kwargs.items()
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is the one place where I used strict=False because it makes sense in this context: when all arguments are passed as keywords, args is empty an d names_of_args is effectively the same as list(kwargs.keys())

@neutrinoceros neutrinoceros force-pushed the enh/strict_zip branch 2 times, most recently from f5d0da2 to 1219576 Compare March 13, 2025 17:15
@neutrinoceros neutrinoceros changed the title ENH: enable strict zip (almost) everywhere ENH: enable strict zip (almost) everywhere (⏰ wait for #567) Mar 13, 2025
@neutrinoceros neutrinoceros changed the title ENH: enable strict zip (almost) everywhere (⏰ wait for #567) ENH: enable strict zip (almost) everywhere Apr 2, 2025
@neutrinoceros neutrinoceros marked this pull request as ready for review April 2, 2025 14:37
@neutrinoceros neutrinoceros force-pushed the enh/strict_zip branch 2 times, most recently from 9ff8fb1 to 49424e8 Compare October 18, 2025 17:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ENH: systematically use strict zips

1 participant