[select] Fix new_select() not forwarding constructor args while preserving keyword-only options parameter (#10036)

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: clydebarrow <2366188+clydebarrow@users.noreply.github.com>
Co-authored-by: jesserockz <3060199+jesserockz@users.noreply.github.com>
This commit is contained in:
Copilot 2025-08-06 08:09:36 +12:00 committed by GitHub
parent bd2b3b9da5
commit c308e03e92
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -118,8 +118,8 @@ async def register_select(var, config, *, options: list[str]):
await setup_select_core_(var, config, options=options)
async def new_select(config, *, options: list[str]):
var = cg.new_Pvariable(config[CONF_ID])
async def new_select(config, *args, options: list[str]):
var = cg.new_Pvariable(config[CONF_ID], *args)
await register_select(var, config, options=options)
return var