python-linkplay 0.1.0__py3-none-any.whl → 0.1.1__py3-none-any.whl
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.
- linkplay/__version__.py +1 -1
- linkplay/bridge.py +6 -12
- linkplay/endpoint.py +6 -1
- {python_linkplay-0.1.0.dist-info → python_linkplay-0.1.1.dist-info}/METADATA +1 -1
- {python_linkplay-0.1.0.dist-info → python_linkplay-0.1.1.dist-info}/RECORD +8 -8
- {python_linkplay-0.1.0.dist-info → python_linkplay-0.1.1.dist-info}/LICENSE +0 -0
- {python_linkplay-0.1.0.dist-info → python_linkplay-0.1.1.dist-info}/WHEEL +0 -0
- {python_linkplay-0.1.0.dist-info → python_linkplay-0.1.1.dist-info}/top_level.txt +0 -0
linkplay/__version__.py
CHANGED
@@ -1 +1 @@
|
|
1
|
-
__version__ = '0.1.
|
1
|
+
__version__ = '0.1.1'
|
linkplay/bridge.py
CHANGED
@@ -72,18 +72,12 @@ class LinkPlayDevice:
|
|
72
72
|
@property
|
73
73
|
def eth(self) -> str | None:
|
74
74
|
"""Returns the ethernet address."""
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
return
|
81
|
-
eth2
|
82
|
-
if eth2
|
83
|
-
else eth0
|
84
|
-
if eth0
|
85
|
-
else self.properties.get(DeviceAttribute.APCLI0)
|
86
|
-
)
|
75
|
+
eth = self.properties.get(DeviceAttribute.ETH2)
|
76
|
+
if eth == "0.0.0.0" or eth is None:
|
77
|
+
eth = self.properties.get(DeviceAttribute.ETH0)
|
78
|
+
if eth == "0.0.0.0" or eth is None:
|
79
|
+
eth = self.properties.get(DeviceAttribute.APCLI0)
|
80
|
+
return eth
|
87
81
|
|
88
82
|
async def timesync(self) -> None:
|
89
83
|
"""Sync the time."""
|
linkplay/endpoint.py
CHANGED
@@ -37,7 +37,12 @@ class LinkPlayApiEndpoint(LinkPlayEndpoint):
|
|
37
37
|
"http",
|
38
38
|
"https",
|
39
39
|
], "Protocol must be either 'http' or 'https'"
|
40
|
-
|
40
|
+
include_port = (protocol == "http" and port != 80) or (
|
41
|
+
protocol == "https" and port != 443
|
42
|
+
)
|
43
|
+
port_suffix = f":{port}" if include_port else ""
|
44
|
+
self._endpoint: str = f"{protocol}://{endpoint}{port_suffix}"
|
45
|
+
|
41
46
|
self._session: ClientSession = session
|
42
47
|
|
43
48
|
def to_dict(self):
|
@@ -1,15 +1,15 @@
|
|
1
1
|
linkplay/__init__.py,sha256=y9ZehEq-KhS3cwn-PUpwVSJGfDUx7e5wf_G6guODcTk,56
|
2
2
|
linkplay/__main__.py,sha256=Wcza80QaWfOaHjyJEfQYhB9kiPLE0NOqIj4zVWv2Nqs,577
|
3
|
-
linkplay/__version__.py,sha256=
|
4
|
-
linkplay/bridge.py,sha256=
|
3
|
+
linkplay/__version__.py,sha256=ls1camlIoMxEZz9gSkZ1OJo-MXqHWwKPtdPbZJmwp7E,22
|
4
|
+
linkplay/bridge.py,sha256=YyqucmFzqAtmc3ttrQEM4nvMhs6ijxHrAhcDIzH6EE0,14970
|
5
5
|
linkplay/consts.py,sha256=98VtgV4xOfXWr00yl1DwfmNxDI6Ul5fNPCyLp8ixggE,13535
|
6
6
|
linkplay/controller.py,sha256=IBFhnt-VhdIZnI_3OLU6hA8oQa9IZWY7-8cN0uCh3-w,3277
|
7
7
|
linkplay/discovery.py,sha256=NnkO9gknp3Cyff7830zBu1LwyhkkWCdhDbEDbAwF8D8,4610
|
8
|
-
linkplay/endpoint.py,sha256=
|
8
|
+
linkplay/endpoint.py,sha256=_gelW0cDWt0SC8EApwaKIVh_YJIMNiOkfrLR_RYW7aM,2677
|
9
9
|
linkplay/exceptions.py,sha256=Kow13uJPSL4y6rXMnkcl_Yp9wH1weOyKw_knd0p-Exc,173
|
10
10
|
linkplay/utils.py,sha256=Kmbzw8zC9mV89ZOC5-GNtbiLkgUkuvAEUcsJdRkSY-w,8485
|
11
|
-
python_linkplay-0.1.
|
12
|
-
python_linkplay-0.1.
|
13
|
-
python_linkplay-0.1.
|
14
|
-
python_linkplay-0.1.
|
15
|
-
python_linkplay-0.1.
|
11
|
+
python_linkplay-0.1.1.dist-info/LICENSE,sha256=bgEtxMyjEHX_4uwaAY3GCFTm234D4AOZ5dM15sk26ms,1073
|
12
|
+
python_linkplay-0.1.1.dist-info/METADATA,sha256=IXlP2wGtwhyhIRYpn8i5rvQEVYRHOk-Z0MMA_3mRNYA,2987
|
13
|
+
python_linkplay-0.1.1.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
|
14
|
+
python_linkplay-0.1.1.dist-info/top_level.txt,sha256=CpSaOVPTzJf5TVIL7MrotSCR34gcIOQy-11l4zGmxxM,9
|
15
|
+
python_linkplay-0.1.1.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|