Skip to content

Add python 3.14 to supported versions#1599

Open
rytilahti wants to merge 12 commits intopython-kasa:masterfrom
rytilahti:janitor/python314
Open

Add python 3.14 to supported versions#1599
rytilahti wants to merge 12 commits intopython-kasa:masterfrom
rytilahti:janitor/python314

Conversation

@rytilahti
Copy link
Copy Markdown
Member

@rytilahti rytilahti commented Oct 26, 2025

  • Add python 3.14 to our supported versions and to our CI
  • Convert to use pyproject.toml standard dependency groups
  • Fix any issues reported by CI

@rytilahti rytilahti added this to the 0.11 milestone Jan 26, 2026
@ZeliardM
Copy link
Copy Markdown
Contributor

ZeliardM commented Mar 1, 2026

@rytilahti There's a regression problem in asyncclick v8.3.0, it's not in v8.2.0, so I did some testing and modified the following to get it to work:
pyproject.toml:
dependencies = [
"asyncclick>=8.2.0,<8.3.0",
"cryptography>=1.9",
"aiohttp>=3",
"tzdata>=2024.2 ; platform_system == 'Windows'",
"mashumaro>=3.20",
]
cli/common.py:
if child_option is not None:
if child_option is OPTIONAL_VALUE_FLAG:
msg = _list_children()
child_index_option = click.prompt(
f"\n{msg}\nEnter the index number of the child device",
type=click.IntRange(0, len(device.children) - 1),
)
elif child := device.get_child_device(child_option):
echo(f"Targeting child device {child.alias}")
return child
else:
error(
"No child device found with device_id or name: "
f"{child_option} children are:\n{_list_children()}"
)

This updates asyncclick to a version that works for the test but without the regression of the flag issue until it's resolved in v8.3.2, according to their maintainer. Then removes the 'await' from the click.prompt because it's not required in v8.2.0, just v8.3.0. Everything should support Python 3.14 correctly now and it looks good from this end.

@ZeliardM
Copy link
Copy Markdown
Contributor

ZeliardM commented Mar 1, 2026

Also, I believe the latest version of mashumaro fixes the issues and why you had to pin different versions for 3.14 and below 3.14, but I'll need you to confirm it on your end if 3.20 does the trick for mashumaro.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants