Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

replace deprecated appdirs with platfromdirs fork #1970

Merged
merged 2 commits into from
Sep 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion miio/integrations/roborock/vacuum/vacuum.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

import click
import pytz
from appdirs import user_cache_dir
from platformdirs import user_cache_dir

from miio.click_common import (
DeviceGroup,
Expand Down
2 changes: 1 addition & 1 deletion miio/integrations/roborock/vacuum/vacuum_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from typing import Any, List # noqa: F401

import click
from appdirs import user_cache_dir
from platformdirs import user_cache_dir
from tqdm import tqdm

from miio.click_common import (
Expand Down
4 changes: 2 additions & 2 deletions miio/miot_cloud.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
from pathlib import Path
from typing import Dict, List, Optional

import appdirs
import platformdirs
from micloud.miotspec import MiotSpec

try:
Expand Down Expand Up @@ -66,7 +66,7 @@ class MiotCloud:
MODEL_MAPPING_FILE = "model-to-urn.json"

def __init__(self):
self._cache_dir = Path(appdirs.user_cache_dir("python-miio"))
self._cache_dir = Path(platformdirs.user_cache_dir("python-miio"))

def get_release_list(self) -> ReleaseList:
"""Fetch a list of available releases."""
Expand Down
26 changes: 13 additions & 13 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ construct = "^2.10.56"
zeroconf = "^0"
attrs = "*"
pytz = "*"
appdirs = "^1"
platformdirs = "*"
tqdm = "^4"
micloud = { version = ">=0.6" }
croniter = ">=1"
Expand Down Expand Up @@ -84,13 +84,14 @@ use_parentheses = true
line_length = 88
forced_separate = "miio.discover"
known_first_party = "miio"
known_third_party = ["appdirs",
known_third_party = [
"attr",
"click",
"construct",
"croniter",
"cryptography",
"netifaces",
"platformdirs",
"pytest",
"pytz",
"setuptools",
Expand Down
Loading