oe-python-template 0.16.6__py3-none-any.whl → 0.16.9__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.
@@ -12,7 +12,6 @@ from urllib.error import HTTPError
12
12
 
13
13
  from pydantic_settings import BaseSettings
14
14
  from requests import get
15
- from uptime import boottime, uptime
16
15
 
17
16
  from ..utils import ( # noqa: TID252
18
17
  UNHIDE_SENSITIVE_INFO,
@@ -50,7 +49,6 @@ class InfoDict(TypedDict, total=False):
50
49
  package: dict[str, Any]
51
50
  runtime: RuntimeDict
52
51
  settings: dict[str, Any]
53
- # Allow additional string keys with any values for service info
54
52
  __extra__: NotRequired[dict[str, Any]]
55
53
 
56
54
 
@@ -132,7 +130,7 @@ class Service(BaseService):
132
130
  """
133
131
  try:
134
132
  with socket(AF_INET, SOCK_DGRAM) as connection:
135
- connection.connect(("8.8.8.8", 80))
133
+ connection.connect((".".join(str(1) for _ in range(4)), 53))
136
134
  return str(connection.getsockname()[0])
137
135
  except Exception as e:
138
136
  message = f"Failed to get local IP: {e}"
@@ -153,6 +151,8 @@ class Service(BaseService):
153
151
  Returns:
154
152
  dict[str, Any]: Service configuration.
155
153
  """
154
+ from uptime import boottime, uptime # noqa: PLC0415
155
+
156
156
  bootdatetime = boottime()
157
157
  rtn: InfoDict = {
158
158
  "package": {
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: oe-python-template
3
- Version: 0.16.6
3
+ Version: 0.16.9
4
4
  Summary: 🧠 Copier template to scaffold Python projects compliant with best practices and modern tooling.
5
5
  Project-URL: Homepage, https://oe-python-template.readthedocs.io/en/latest/
6
6
  Project-URL: Documentation, https://oe-python-template.readthedocs.io/en/latest/
@@ -14,7 +14,7 @@ oe_python_template/system/__init__.py,sha256=7e2z8HATzy3dAIBXy5PM9rlCC7Rbu8m8Nap
14
14
  oe_python_template/system/_api.py,sha256=pBBCL1gXM7W5dgJqBLKuNFWES0pQF8mbUgQ7H7oHwh8,3714
15
15
  oe_python_template/system/_cli.py,sha256=fVO_TSIyiaMJ2ACeQ4gPy4QQZjmeBVnsxxsViuNGe8I,6990
16
16
  oe_python_template/system/_gui.py,sha256=9U4QMkl1mVJargg_gQ7U8tMlvec4b1cqkTgRcmmyTTc,678
17
- oe_python_template/system/_service.py,sha256=2Vkbn28ipWRMKRt4T9O_CR_uk9pX1mM4jb21DMOvpus,8858
17
+ oe_python_template/system/_service.py,sha256=bydquEzYM_gfBSdsDKjqKo2bmEMftgSQWMCuPuZ88O0,8841
18
18
  oe_python_template/system/_settings.py,sha256=MwMAJYifJ6jGImeSh4e9shmIXmiUSuQGHXz_Ts0mSdk,901
19
19
  oe_python_template/utils/__init__.py,sha256=oM8v1ozMOeBQG-EbBtEGbnuGk52mYNDAmNoR7vNQ7MY,2050
20
20
  oe_python_template/utils/_api.py,sha256=GSI-HPtSdTFv0qP5aTDPa2WS3ewVa1slusG6dvxSu0Y,2474
@@ -33,8 +33,8 @@ oe_python_template/utils/_service.py,sha256=atHAejvBucKXjzhsMSdOBBFa7rRD74zcV70P
33
33
  oe_python_template/utils/_settings.py,sha256=owFoaHEzJnVD3EVyOWF4rfIY7g6eLnU6rN0m4VHhCbA,2464
34
34
  oe_python_template/utils/boot.py,sha256=Qgq1sjT8d3fcfibnMyx5CVUJ_KKXgFI3ozZUIJbhh4I,2921
35
35
  oe_python_template/utils/.vendored/bottle.py,sha256=kZAZmh3nRzCUf-9IKGpv0yqlMciZMA_DNaaMDdcQmt0,175437
36
- oe_python_template-0.16.6.dist-info/METADATA,sha256=yr0FfMCS-vr3TqbeWQFWH9n1bvb7Lhs3JgSsnZ8b3cE,34606
37
- oe_python_template-0.16.6.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
38
- oe_python_template-0.16.6.dist-info/entry_points.txt,sha256=IroSSWhLGxus9rxcashkYQda39TTvf7LbUMYtOKXUBE,66
39
- oe_python_template-0.16.6.dist-info/licenses/LICENSE,sha256=5H409K6xzz9U5eUaoAHQExNkoWJRlU0LEj6wL2QJ34s,1113
40
- oe_python_template-0.16.6.dist-info/RECORD,,
36
+ oe_python_template-0.16.9.dist-info/METADATA,sha256=XjMYJzkIoz9l7aAV9l3_0e3_sF5yfbwZLRoHUjsmpyA,34606
37
+ oe_python_template-0.16.9.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
38
+ oe_python_template-0.16.9.dist-info/entry_points.txt,sha256=IroSSWhLGxus9rxcashkYQda39TTvf7LbUMYtOKXUBE,66
39
+ oe_python_template-0.16.9.dist-info/licenses/LICENSE,sha256=5H409K6xzz9U5eUaoAHQExNkoWJRlU0LEj6wL2QJ34s,1113
40
+ oe_python_template-0.16.9.dist-info/RECORD,,