MouseTools 4.4.0__tar.gz → 4.4.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {mousetools-4.4.0 → mousetools-4.4.1}/PKG-INFO +2 -2
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/auth.py +2 -2
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/channels/facilities/__init__.py +3 -3
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/mixins/couchbase.py +7 -6
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/mixins/disney.py +3 -3
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools.egg-info/PKG-INFO +2 -2
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools.egg-info/requires.txt +1 -1
- {mousetools-4.4.0 → mousetools-4.4.1}/pyproject.toml +13 -5
- {mousetools-4.4.0 → mousetools-4.4.1}/LICENSE +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/README.md +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/__init__.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/api/__init__.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/api/menu.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/api/search.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/channels/__init__.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/channels/calendar/__init__.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/channels/characters/__init__.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/channels/enums.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/channels/facilities/enums.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/channels/facilitystatus/__init__.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/channels/forecastedwaittimes/__init__.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/channels/today/__init__.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/decorators.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/enums.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/mixins/__init__.py +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools/resources/environments.bin +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools.egg-info/SOURCES.txt +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools.egg-info/dependency_links.txt +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/mousetools.egg-info/top_level.txt +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/setup.cfg +0 -0
- {mousetools-4.4.0 → mousetools-4.4.1}/tests/test_mixins.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: mousetools
|
|
3
|
-
Version: 4.4.
|
|
3
|
+
Version: 4.4.1
|
|
4
4
|
Summary: An unofficial Python wrapper for Disney's API
|
|
5
5
|
Author: Scott Caratozzolo
|
|
6
6
|
License-Expression: MIT
|
|
@@ -17,9 +17,9 @@ Classifier: Operating System :: OS Independent
|
|
|
17
17
|
Requires-Python: <4.0,>=3.9
|
|
18
18
|
Description-Content-Type: text/markdown
|
|
19
19
|
License-File: LICENSE
|
|
20
|
-
Requires-Dist: httpx>=0.27.2
|
|
21
20
|
Requires-Dist: pycryptodome>=3.22.0
|
|
22
21
|
Requires-Dist: python-dateutil>=2.9.0.post0
|
|
22
|
+
Requires-Dist: requests>=2.32.3
|
|
23
23
|
Requires-Dist: tzdata>=2025.2
|
|
24
24
|
Dynamic: license-file
|
|
25
25
|
|
|
@@ -5,7 +5,7 @@ from datetime import datetime, timedelta
|
|
|
5
5
|
from importlib.resources import as_file, files
|
|
6
6
|
from typing import Optional
|
|
7
7
|
|
|
8
|
-
import
|
|
8
|
+
import requests
|
|
9
9
|
from Crypto.Cipher import AES
|
|
10
10
|
|
|
11
11
|
logger = logging.getLogger(__name__)
|
|
@@ -42,7 +42,7 @@ class Authentication:
|
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
logger.debug("Sending request for authentication token")
|
|
45
|
-
response =
|
|
45
|
+
response = requests.post(
|
|
46
46
|
f"{self._environments['authzServiceUrl']}/token",
|
|
47
47
|
headers=headers,
|
|
48
48
|
params=body,
|
|
@@ -4,7 +4,7 @@ from datetime import datetime, time, timedelta
|
|
|
4
4
|
from typing import Any, Optional
|
|
5
5
|
from zoneinfo import ZoneInfo
|
|
6
6
|
|
|
7
|
-
import
|
|
7
|
+
import requests
|
|
8
8
|
|
|
9
9
|
from mousetools.api.menu import Menus
|
|
10
10
|
from mousetools.channels import CouchbaseChannel, CouchbaseChildChannel
|
|
@@ -503,11 +503,11 @@ class FacilityChildChannel(CouchbaseChildChannel):
|
|
|
503
503
|
"appid": weather_key,
|
|
504
504
|
}
|
|
505
505
|
try:
|
|
506
|
-
response =
|
|
506
|
+
response = requests.get(weather_url, params=params, timeout=10)
|
|
507
507
|
response.raise_for_status()
|
|
508
508
|
data = response.json()
|
|
509
509
|
return data
|
|
510
|
-
except
|
|
510
|
+
except requests.HTTPError as err:
|
|
511
511
|
logger.error("Request failed: %s", err)
|
|
512
512
|
return {}
|
|
513
513
|
|
|
@@ -3,7 +3,7 @@ import logging
|
|
|
3
3
|
import re
|
|
4
4
|
from typing import Union
|
|
5
5
|
|
|
6
|
-
import
|
|
6
|
+
import requests
|
|
7
7
|
|
|
8
8
|
from mousetools.auth import auth_obj
|
|
9
9
|
|
|
@@ -33,7 +33,7 @@ class CouchbaseMixin:
|
|
|
33
33
|
}
|
|
34
34
|
|
|
35
35
|
logger.info("Sending request for channel data: %s", channel_name)
|
|
36
|
-
response =
|
|
36
|
+
response = requests.post(self._couchbase_url + "/_bulk_get", json=payload, headers=self._headers, timeout=10)
|
|
37
37
|
logger.debug("Response status for %s: %s", channel_name, response.status_code)
|
|
38
38
|
data = None
|
|
39
39
|
try:
|
|
@@ -51,7 +51,7 @@ class CouchbaseMixin:
|
|
|
51
51
|
except Exception:
|
|
52
52
|
logger.debug("Failed to parse line: %s", line)
|
|
53
53
|
continue
|
|
54
|
-
except
|
|
54
|
+
except requests.HTTPError as err:
|
|
55
55
|
logger.error("Request failed: %s", err)
|
|
56
56
|
return None
|
|
57
57
|
|
|
@@ -79,10 +79,11 @@ class CouchbaseMixin:
|
|
|
79
79
|
payload["since"] = since
|
|
80
80
|
|
|
81
81
|
logger.info("Sending request for channel changes: %s", channel_name)
|
|
82
|
-
response =
|
|
82
|
+
response = requests.post(self._couchbase_url + "/_changes", json=payload, headers=self._headers, timeout=10)
|
|
83
83
|
logger.debug("Response status for %s: %s", channel_name, response.status_code)
|
|
84
|
-
|
|
85
|
-
|
|
84
|
+
response.raise_for_status()
|
|
85
|
+
data = response.json()
|
|
86
|
+
except requests.HTTPError as err:
|
|
86
87
|
logger.error("Request failed: %s", err)
|
|
87
88
|
return None
|
|
88
89
|
|
|
@@ -2,7 +2,7 @@ import json
|
|
|
2
2
|
import logging
|
|
3
3
|
from typing import Union
|
|
4
4
|
|
|
5
|
-
import
|
|
5
|
+
import requests
|
|
6
6
|
|
|
7
7
|
from mousetools.auth import auth_obj
|
|
8
8
|
|
|
@@ -21,13 +21,13 @@ class DisneyAPIMixin:
|
|
|
21
21
|
(Union[dict, None]): The disney data.
|
|
22
22
|
"""
|
|
23
23
|
logger.info("Sending request to %s", url)
|
|
24
|
-
response =
|
|
24
|
+
response = requests.get(url, headers=auth_obj.get_headers(), timeout=10)
|
|
25
25
|
logger.debug("Response status: %s", response.status_code)
|
|
26
26
|
|
|
27
27
|
try:
|
|
28
28
|
response.raise_for_status()
|
|
29
29
|
data = response.json()
|
|
30
|
-
except (
|
|
30
|
+
except (requests.HTTPError, json.decoder.JSONDecodeError) as err:
|
|
31
31
|
logger.error("Request failed. Error: %s", err)
|
|
32
32
|
return None
|
|
33
33
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: mousetools
|
|
3
|
-
Version: 4.4.
|
|
3
|
+
Version: 4.4.1
|
|
4
4
|
Summary: An unofficial Python wrapper for Disney's API
|
|
5
5
|
Author: Scott Caratozzolo
|
|
6
6
|
License-Expression: MIT
|
|
@@ -17,9 +17,9 @@ Classifier: Operating System :: OS Independent
|
|
|
17
17
|
Requires-Python: <4.0,>=3.9
|
|
18
18
|
Description-Content-Type: text/markdown
|
|
19
19
|
License-File: LICENSE
|
|
20
|
-
Requires-Dist: httpx>=0.27.2
|
|
21
20
|
Requires-Dist: pycryptodome>=3.22.0
|
|
22
21
|
Requires-Dist: python-dateutil>=2.9.0.post0
|
|
22
|
+
Requires-Dist: requests>=2.32.3
|
|
23
23
|
Requires-Dist: tzdata>=2025.2
|
|
24
24
|
Dynamic: license-file
|
|
25
25
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "mousetools"
|
|
3
|
-
version = "4.4.
|
|
3
|
+
version = "4.4.1"
|
|
4
4
|
authors = [{name = "Scott Caratozzolo"}]
|
|
5
5
|
description = "An unofficial Python wrapper for Disney's API"
|
|
6
6
|
readme = "README.md"
|
|
@@ -8,9 +8,9 @@ license = "MIT"
|
|
|
8
8
|
license-files = ["LICENSE"]
|
|
9
9
|
requires-python = ">=3.9, <4.0"
|
|
10
10
|
dependencies = [
|
|
11
|
-
"httpx>=0.27.2",
|
|
12
11
|
"pycryptodome>=3.22.0",
|
|
13
12
|
"python-dateutil>=2.9.0.post0",
|
|
13
|
+
"requests>=2.32.3",
|
|
14
14
|
"tzdata>=2025.2",
|
|
15
15
|
]
|
|
16
16
|
classifiers = [
|
|
@@ -42,7 +42,7 @@ dev-dependencies = [
|
|
|
42
42
|
"go-task-bin>=3.43.3",
|
|
43
43
|
"icecream>=2.1.4",
|
|
44
44
|
"pytest-mock>=3.14.0",
|
|
45
|
-
"
|
|
45
|
+
"responses>=0.25.7",
|
|
46
46
|
]
|
|
47
47
|
|
|
48
48
|
[build-system]
|
|
@@ -105,17 +105,25 @@ select = [
|
|
|
105
105
|
"D102", "D103", "D417",
|
|
106
106
|
# pylint
|
|
107
107
|
"PL",
|
|
108
|
+
# pep8-naming
|
|
109
|
+
"N",
|
|
110
|
+
# flake8-datetimez
|
|
111
|
+
"DTZ002", "DTZ003", "DTZ004", "DTZ011", "DTZ012",
|
|
112
|
+
# flake8-logging-format
|
|
113
|
+
"G",
|
|
114
|
+
# flake8-print
|
|
115
|
+
"T20",
|
|
108
116
|
]
|
|
109
117
|
|
|
110
118
|
ignore = [
|
|
111
119
|
# LineTooLong
|
|
112
120
|
"E501",
|
|
113
|
-
# DoNotAssignLambda
|
|
114
|
-
"E731",
|
|
115
121
|
# builtin-open
|
|
116
122
|
"PTH123",
|
|
117
123
|
# Magic value used in comparison
|
|
118
124
|
"PLR2004",
|
|
125
|
+
# Logging statement uses %
|
|
126
|
+
"G002",
|
|
119
127
|
]
|
|
120
128
|
|
|
121
129
|
[tool.ruff.lint.per-file-ignores]
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|