expr_tracker 0.1.0__tar.gz → 0.1.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.
@@ -1,10 +1,10 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: expr_tracker
3
- Version: 0.1.0
3
+ Version: 0.1.1
4
4
  Summary: Add your description here
5
5
  Author-email: HSPK <whxway@whu.edu.cn>
6
6
  Requires-Python: >=3.10
7
7
  Requires-Dist: jsonlines>=4.0.0
8
8
  Requires-Dist: loguru>=0.7.3
9
- Requires-Dist: slark>=0.1.27
9
+ Requires-Dist: slark>=0.1.28
10
10
  Requires-Dist: wandb>=0.21.0
@@ -1,15 +1,15 @@
1
1
  [project]
2
2
  name = "expr_tracker"
3
- version = "0.1.0"
3
+ version = "0.1.1"
4
4
  description = "Add your description here"
5
5
  readme = "README.md"
6
6
  authors = [{ name = "HSPK", email = "whxway@whu.edu.cn" }]
7
7
  requires-python = ">=3.10"
8
8
  dependencies = [
9
9
  "jsonlines>=4.0.0",
10
- "loguru>=0.7.3",
11
- "slark>=0.1.27",
12
- "wandb>=0.21.0",
10
+ "loguru>=0.7.3",
11
+ "slark>=0.1.28",
12
+ "wandb>=0.21.0",
13
13
  ]
14
14
 
15
15
  [build-system]
@@ -17,6 +17,4 @@ requires = ["hatchling"]
17
17
  build-backend = "hatchling.build"
18
18
 
19
19
  [dependency-groups]
20
- dev = [
21
- "ipykernel>=6.30.1",
22
- ]
20
+ dev = ["ipykernel>=6.30.1"]
@@ -1,4 +1,5 @@
1
1
  from typing import Literal
2
+ from loguru import logger
2
3
 
3
4
 
4
5
  class LarkBackend:
@@ -50,6 +51,11 @@ def alert(
50
51
  for backend in backends:
51
52
  if backend == "lark":
52
53
  lark_backend = LarkBackend()
54
+ if lark_backend.lark._webhook_url is None:
55
+ logger.warning(
56
+ "Lark webhook URL is not set. Please set the WEBHOOK_URL environment variable."
57
+ )
58
+ return
53
59
  lark_backend.publish_alert(title, text, subtitle, level, traceback)
54
60
  else:
55
61
  raise NotImplementedError(f"Backend '{backend}' is not implemented.")
@@ -1253,7 +1253,7 @@ wheels = [
1253
1253
 
1254
1254
  [[package]]
1255
1255
  name = "slark"
1256
- version = "0.1.27"
1256
+ version = "0.1.28"
1257
1257
  source = { registry = "https://pypi.org/simple" }
1258
1258
  dependencies = [
1259
1259
  { name = "arrow" },
@@ -1264,9 +1264,9 @@ dependencies = [
1264
1264
  { name = "pydantic" },
1265
1265
  { name = "requests-toolbelt" },
1266
1266
  ]
1267
- sdist = { url = "https://files.pythonhosted.org/packages/6e/78/aa5ef330646ca00132371c4172ac08232a689f4a7aca67f4c7b1a7529a87/slark-0.1.27.tar.gz", hash = "sha256:4a1032f95fe1bce34dc3792e0f172bc2e5473392da354ad8eeaa250ab121df98", size = 103293 }
1267
+ sdist = { url = "https://files.pythonhosted.org/packages/76/6c/1632d06e19f3039c5fe4e8310056cf2cfaf4e2812b6ffe0176acefb8dca1/slark-0.1.28.tar.gz", hash = "sha256:f1f08bf5f82cbfadc0752b2339fb39c0c35faa834da4191e6c8e1ddca8ea49b5", size = 103331 }
1268
1268
  wheels = [
1269
- { url = "https://files.pythonhosted.org/packages/db/04/66d843aefb74e4e38cf8196a264eb76f17818967f723cbe14a884ff7dfcd/slark-0.1.27-py3-none-any.whl", hash = "sha256:7e13e55e49ee8200bb1f05455113367623970b2cc01edea1cbb78f8bbfe35d11", size = 155583 },
1269
+ { url = "https://files.pythonhosted.org/packages/d6/35/3d38da087da91451617012b3303ade17d271f48972f01fae293dd96418b2/slark-0.1.28-py3-none-any.whl", hash = "sha256:5c7ac2bc48192acfbf3dd691c9de48c47032beb4cfa072bad5115e0b37d9a9b7", size = 155638 },
1270
1270
  ]
1271
1271
 
1272
1272
  [[package]]
File without changes
File without changes