juham-visualcrossing 0.0.3__py3-none-any.whl → 0.1.1__py3-none-any.whl

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,10 +1,9 @@
1
1
  from datetime import datetime, timedelta, timezone
2
2
  import json
3
- from typing import Any, Dict, Optional, cast
4
- from typing_extensions import override # for python 3.9 compatibility
5
-
6
- from juham.base import Base, MqttMsg, JMqtt
7
- from juham.web import RCloud, RCloudThread
3
+ from typing import Any, Optional, cast
4
+ from typing_extensions import override
5
+ from masterpiece.mqtt import MqttMsg, Mqtt
6
+ from juham.core import RCloud, RCloudThread
8
7
 
9
8
 
10
9
  class VisualCrossingThread(RCloudThread):
@@ -18,7 +17,7 @@ class VisualCrossingThread(RCloudThread):
18
17
  _location: str = ""
19
18
  _interval: float = 12 * 3600
20
19
 
21
- def __init__(self, client: Optional[JMqtt] = None):
20
+ def __init__(self, client: Optional[Mqtt] = None):
22
21
  """Construct with the given mqtt client. Acquires data from the visual
23
22
  crossing web service and publishes the forecast data to
24
23
  forecast_topic.
@@ -27,7 +26,7 @@ class VisualCrossingThread(RCloudThread):
27
26
  client (object, optional): MQTT client. Defaults to None.
28
27
  """
29
28
  super().__init__(client)
30
- self.mqtt_client: Optional[JMqtt] = client
29
+ self.mqtt_client: Optional[Mqtt] = client
31
30
 
32
31
  @override
33
32
  def update_interval(self) -> float:
@@ -162,7 +161,7 @@ class VisualCrossing(RCloud):
162
161
  # create, initialize and start the asynchronous thread for acquiring forecast
163
162
 
164
163
  self.worker = cast(
165
- VisualCrossingThread, Base.instantiate(VisualCrossing.workerThreadId)
164
+ VisualCrossingThread, self.instantiate(VisualCrossing.workerThreadId)
166
165
  )
167
166
  self.worker.init(
168
167
  self.forecast_topic,
@@ -1,7 +1,7 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: juham_visualcrossing
3
- Version: 0.0.3
4
- Summary: A Weather forecast plugin extending `juham` applications
3
+ Version: 0.1.1
4
+ Summary: A Weather forecast plugin extending `Juham` applications
5
5
  Author-email: J Meskanen <juham.api@gmail.com>
6
6
  Maintainer-email: "J. Meskanen" <juham.api@gmail.com>
7
7
  License: MIT License
@@ -33,14 +33,14 @@ Project-URL: Funding, https://meskanen.com
33
33
  Project-URL: Say Thanks!, http://meskanen.com
34
34
  Project-URL: Source, https://meskanen.com
35
35
  Keywords: object-oriented,plugin,framework
36
- Classifier: Development Status :: 1 - Planning
36
+ Classifier: Development Status :: 2 - Pre-Alpha
37
37
  Classifier: Intended Audience :: Developers
38
38
  Classifier: Topic :: Software Development
39
39
  Classifier: License :: OSI Approved :: MIT License
40
40
  Classifier: Programming Language :: Python :: 3.8
41
41
  Requires-Python: >=3.8
42
42
  Description-Content-Type: text/markdown
43
- Requires-Dist: juham>=0.0.12
43
+ Requires-Dist: juham>=0.0.17
44
44
  Requires-Dist: pytz>=2024.1
45
45
  Requires-Dist: importlib-metadata
46
46
  Provides-Extra: dev
@@ -0,0 +1,8 @@
1
+ juham_visualcrossing/__init__.py,sha256=qsVRSTeJW8jgBtLviUjq5JiJ8Z6eYkBQn6zMWgS0okY,161
2
+ juham_visualcrossing/py.typed,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
3
+ juham_visualcrossing/visualcrossing.py,sha256=yv0SlqAliI97Y10J720KAZpGnE6I8vkdGjzna1pgVg4,7190
4
+ juham_visualcrossing-0.1.1.dist-info/METADATA,sha256=d7r85HPtikXDKnixH2PsTJE6kFCv1XLrMdTZ2u8mRDQ,3153
5
+ juham_visualcrossing-0.1.1.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
6
+ juham_visualcrossing-0.1.1.dist-info/entry_points.txt,sha256=A-NSi2RN5KSKwpbKG592v5qnWnGHmIjPktubd5PQ80M,76
7
+ juham_visualcrossing-0.1.1.dist-info/top_level.txt,sha256=7yWaUHZo-Ng96VJBzUFhaFCBamL71PUjIxZISxMBjSM,21
8
+ juham_visualcrossing-0.1.1.dist-info/RECORD,,
@@ -1,8 +0,0 @@
1
- juham_visualcrossing/__init__.py,sha256=qsVRSTeJW8jgBtLviUjq5JiJ8Z6eYkBQn6zMWgS0okY,161
2
- juham_visualcrossing/py.typed,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
3
- juham_visualcrossing/visualcrossing.py,sha256=i-YPltSzG9oTrNSfNXVcQSmw5TGMzeVBy1O8DUwrHSo,7232
4
- juham_visualcrossing-0.0.3.dist-info/METADATA,sha256=PFAu6xjOyDX0fn2ATCRVYYOG91qkjun-fKTkbe72tys,3152
5
- juham_visualcrossing-0.0.3.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
6
- juham_visualcrossing-0.0.3.dist-info/entry_points.txt,sha256=A-NSi2RN5KSKwpbKG592v5qnWnGHmIjPktubd5PQ80M,76
7
- juham_visualcrossing-0.0.3.dist-info/top_level.txt,sha256=7yWaUHZo-Ng96VJBzUFhaFCBamL71PUjIxZISxMBjSM,21
8
- juham_visualcrossing-0.0.3.dist-info/RECORD,,