Skip to content

Commit

Permalink
Drop Python 3.8 support (#245)
Browse files Browse the repository at this point in the history
  • Loading branch information
StevenLooman authored Nov 7, 2024
1 parent c63b2d3 commit daa5e3c
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 14 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
Expand Down
10 changes: 4 additions & 6 deletions async_upnp_client/profiles/profile.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,12 +301,10 @@ async def _update_resubscriber_task(self) -> None:
if self._subscriptions and not self._resubscriber_task:
_LOGGER.debug("Creating resubscribe_task")
# pylint: disable=fixme
# TODO: Use create_task instead of ensure_future with Python 3.8+
# self._resubscriber_task = asyncio.create_task(
# self._resubscribe_loop(),
# name=f"UpnpProfileDevice({self.name})._resubscriber_task",
# )
self._resubscriber_task = asyncio.ensure_future(self._resubscribe_loop())
self._resubscriber_task = asyncio.create_task(
self._resubscribe_loop(),
name=f"UpnpProfileDevice({self.name})._resubscriber_task",
)

if not self._subscriptions and self._resubscriber_task:
_LOGGER.debug("Cancelling resubscribe_task")
Expand Down
1 change: 1 addition & 0 deletions changes/245.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Drop Python 3.8 support.
5 changes: 2 additions & 3 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ classifiers =
Operating System :: POSIX
Operating System :: MacOS :: MacOS X
Operating System :: Microsoft :: Windows
Programming Language :: Python :: 3.8
Programming Language :: Python :: 3.9
Programming Language :: Python :: 3.10
Programming Language :: Python :: 3.11
Expand All @@ -42,9 +41,9 @@ keywords =
Universal Plug and Play

[options]
python_requires = >=3.8
python_requires = >=3.9
install_requires =
voluptuous >= 0.14.2
voluptuous >= 0.15.2
aiohttp >3.9.0, <4.0
async-timeout >=3.0, <5.0
python-didl-lite ~= 1.4.0
Expand Down
2 changes: 0 additions & 2 deletions tests/profiles/test_dlna_dmr.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
"""Unit tests for the DLNA DMR profile."""

import asyncio
import sys
import time
from typing import List, Sequence
from unittest import mock
Expand Down Expand Up @@ -331,7 +330,6 @@ async def test_wait_for_can_play_timeout() -> None:
assert not profile.can_play


@pytest.mark.skipif(sys.version_info < (3, 8), reason="Need Python 3.8 for AsyncMock")
@pytest.mark.asyncio
async def test_fetch_headers() -> None:
"""Test _fetch_headers when the server supports HEAD, GET with range, or just GET."""
Expand Down
3 changes: 1 addition & 2 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
[tox]
envlist = py38, py39, py310, py311, py312, py313, flake8, pylint, codespell, mypy, black, isort
envlist = py39, py310, py311, py312, py313, flake8, pylint, codespell, mypy, black, isort

[gh-actions]
python =
3.8: py38
3.9: py39
3.10: py310
3.11: py311
Expand Down

0 comments on commit daa5e3c

Please sign in to comment.