fmtr.tools 1.3.5__py3-none-any.whl → 1.3.7__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.

Potentially problematic release.


This version of fmtr.tools might be problematic. Click here for more details.

@@ -5,4 +5,4 @@ def main():
5
5
 
6
6
  """
7
7
  from fmtr.tools import yaml
8
- return yaml.install()
8
+ yaml.install()
@@ -30,14 +30,18 @@ def get_logger(name, version=None, host=Constants.FMTR_OBS_HOST, key=None, org=C
30
30
 
31
31
  return logger
32
32
 
33
+ logger = logfire
34
+
33
35
  if key is None:
34
- key = environment_tools.get(Constants.FMTR_OBS_API_KEY_KEY)
35
- url = f"https://{host}/api/{org}/v1/traces"
36
- headers = f"Authorization=Basic {key},stream-name={stream}"
36
+ key = environment_tools.get(Constants.FMTR_OBS_API_KEY_KEY, default=None)
37
+
38
+ if key:
39
+ url = f"https://{host}/api/{org}/v1/traces"
40
+ headers = f"Authorization=Basic {key},stream-name={stream}"
37
41
 
38
- os.environ["OTEL_EXPORTER_OTLP_TRACES_ENDPOINT"] = url
39
- os.environ["OTEL_EXPORTER_OTLP_HEADERS"] = headers
40
- os.environ["OTEL_EXPORTER_OTLP_INSECURE"] = str(False).lower()
42
+ os.environ["OTEL_EXPORTER_OTLP_TRACES_ENDPOINT"] = url
43
+ os.environ["OTEL_EXPORTER_OTLP_HEADERS"] = headers
44
+ os.environ["OTEL_EXPORTER_OTLP_INSECURE"] = str(False).lower()
41
45
 
42
46
  if not version:
43
47
  from fmtr.tools import version_tools
@@ -60,7 +64,9 @@ def get_logger(name, version=None, host=Constants.FMTR_OBS_HOST, key=None, org=C
60
64
  console=console_opts
61
65
  )
62
66
 
63
- logger = logfire
67
+ if key is None:
68
+ logger.warning(f'Observability dependencies installed, but "{Constants.FMTR_OBS_API_KEY_KEY}" not set. Cloud observability will be disabled.')
69
+
64
70
  return logger
65
71
 
66
72
 
fmtr/tools/version CHANGED
@@ -1 +1 @@
1
- 1.3.5
1
+ 1.3.7
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: fmtr.tools
3
- Version: 1.3.5
3
+ Version: 1.3.7
4
4
  Summary: Collection of high-level tools to simplify everyday development tasks, with a focus on AI/ML
5
5
  Home-page: https://github.com/fmtr/fmtr.tools
6
6
  Author: Frontmatter
@@ -130,60 +130,60 @@ Requires-Dist: logfire[httpx]; extra == "http"
130
130
  Provides-Extra: setup
131
131
  Requires-Dist: setuptools; extra == "setup"
132
132
  Provides-Extra: all
133
- Requires-Dist: openpyxl; extra == "all"
134
- Requires-Dist: sentence_transformers; extra == "all"
135
- Requires-Dist: logfire[fastapi]; extra == "all"
136
- Requires-Dist: setuptools; extra == "all"
137
- Requires-Dist: tinynetrc; extra == "all"
138
- Requires-Dist: flet[all]; extra == "all"
139
- Requires-Dist: contexttimer; extra == "all"
133
+ Requires-Dist: fastapi; extra == "all"
134
+ Requires-Dist: flet-video; extra == "all"
135
+ Requires-Dist: bokeh; extra == "all"
136
+ Requires-Dist: google-auth-oauthlib; extra == "all"
137
+ Requires-Dist: pydantic-settings; extra == "all"
140
138
  Requires-Dist: json_repair; extra == "all"
139
+ Requires-Dist: html2text; extra == "all"
140
+ Requires-Dist: filetype; extra == "all"
141
+ Requires-Dist: torchaudio; extra == "all"
142
+ Requires-Dist: dnspython[doh]; extra == "all"
143
+ Requires-Dist: pandas; extra == "all"
141
144
  Requires-Dist: google-api-python-client; extra == "all"
142
- Requires-Dist: bokeh; extra == "all"
143
- Requires-Dist: faker; extra == "all"
145
+ Requires-Dist: diskcache; extra == "all"
146
+ Requires-Dist: peft; extra == "all"
147
+ Requires-Dist: pymupdf4llm; extra == "all"
148
+ Requires-Dist: setuptools; extra == "all"
149
+ Requires-Dist: pymupdf; extra == "all"
150
+ Requires-Dist: flet[all]; extra == "all"
144
151
  Requires-Dist: tabulate; extra == "all"
152
+ Requires-Dist: tokenizers; extra == "all"
153
+ Requires-Dist: huggingface_hub; extra == "all"
154
+ Requires-Dist: sentence_transformers; extra == "all"
155
+ Requires-Dist: flet-webview; extra == "all"
156
+ Requires-Dist: logfire[httpx]; extra == "all"
157
+ Requires-Dist: semver; extra == "all"
145
158
  Requires-Dist: httpx_retries; extra == "all"
146
- Requires-Dist: html2text; extra == "all"
147
- Requires-Dist: google-auth; extra == "all"
148
- Requires-Dist: openai; extra == "all"
159
+ Requires-Dist: ollama; extra == "all"
160
+ Requires-Dist: regex; extra == "all"
161
+ Requires-Dist: pydevd-pycharm~=251.25410.159; extra == "all"
162
+ Requires-Dist: distributed; extra == "all"
149
163
  Requires-Dist: pydantic-ai[logfire,openai]; extra == "all"
150
- Requires-Dist: logfire[httpx]; extra == "all"
151
- Requires-Dist: appdirs; extra == "all"
152
- Requires-Dist: pymupdf; extra == "all"
153
- Requires-Dist: docker; extra == "all"
154
164
  Requires-Dist: dask[bag]; extra == "all"
155
- Requires-Dist: torchvision; extra == "all"
156
- Requires-Dist: distributed; extra == "all"
157
- Requires-Dist: pydantic-settings; extra == "all"
158
- Requires-Dist: logfire; extra == "all"
159
- Requires-Dist: pymupdf4llm; extra == "all"
160
- Requires-Dist: fastapi; extra == "all"
161
- Requires-Dist: huggingface_hub; extra == "all"
162
- Requires-Dist: pytest-cov; extra == "all"
163
- Requires-Dist: sre_yield; extra == "all"
164
- Requires-Dist: flet-webview; extra == "all"
165
- Requires-Dist: pydantic; extra == "all"
166
- Requires-Dist: pandas; extra == "all"
167
- Requires-Dist: flet-video; extra == "all"
168
165
  Requires-Dist: deepmerge; extra == "all"
166
+ Requires-Dist: openai; extra == "all"
167
+ Requires-Dist: pytest-cov; extra == "all"
168
+ Requires-Dist: faker; extra == "all"
169
+ Requires-Dist: Unidecode; extra == "all"
170
+ Requires-Dist: logfire[fastapi]; extra == "all"
171
+ Requires-Dist: appdirs; extra == "all"
169
172
  Requires-Dist: transformers[sentencepiece]; extra == "all"
170
- Requires-Dist: filetype; extra == "all"
171
- Requires-Dist: ollama; extra == "all"
172
- Requires-Dist: uvicorn[standard]; extra == "all"
173
173
  Requires-Dist: google-auth-httplib2; extra == "all"
174
- Requires-Dist: httpx; extra == "all"
175
- Requires-Dist: regex; extra == "all"
176
- Requires-Dist: Unidecode; extra == "all"
177
- Requires-Dist: google-auth-oauthlib; extra == "all"
174
+ Requires-Dist: tinynetrc; extra == "all"
178
175
  Requires-Dist: pyyaml; extra == "all"
176
+ Requires-Dist: pydantic; extra == "all"
177
+ Requires-Dist: openpyxl; extra == "all"
178
+ Requires-Dist: uvicorn[standard]; extra == "all"
179
+ Requires-Dist: torchvision; extra == "all"
179
180
  Requires-Dist: yamlscript; extra == "all"
180
- Requires-Dist: peft; extra == "all"
181
- Requires-Dist: dnspython[doh]; extra == "all"
182
- Requires-Dist: semver; extra == "all"
183
- Requires-Dist: torchaudio; extra == "all"
184
- Requires-Dist: tokenizers; extra == "all"
185
- Requires-Dist: diskcache; extra == "all"
186
- Requires-Dist: pydevd-pycharm~=251.25410.159; extra == "all"
181
+ Requires-Dist: contexttimer; extra == "all"
182
+ Requires-Dist: docker; extra == "all"
183
+ Requires-Dist: logfire; extra == "all"
184
+ Requires-Dist: sre_yield; extra == "all"
185
+ Requires-Dist: httpx; extra == "all"
186
+ Requires-Dist: google-auth; extra == "all"
187
187
  Dynamic: author
188
188
  Dynamic: author-email
189
189
  Dynamic: description
@@ -22,7 +22,7 @@ fmtr/tools/interface_tools.py,sha256=JVYUV7wuMr24BORuUtNaBlTeBFt8VDGJ3HPRajd7Y_4
22
22
  fmtr/tools/iterator_tools.py,sha256=xj5f0c7LgLK53dddRRRJxBoLaBzlZoQS3_GfmpDPMoo,1311
23
23
  fmtr/tools/json_fix_tools.py,sha256=vNSlswVQnujPmKEqDjFJcO901mjMyv59q3awsT7mlhs,477
24
24
  fmtr/tools/json_tools.py,sha256=WkFc5q7oqMtcFejhN1K5zQFULa9TdLOup83Fr0saDRY,348
25
- fmtr/tools/logging_tools.py,sha256=s1c2I1aBMCNqsoGzmizj_ObwTMsH-JKKqDsxbdsntH0,2154
25
+ fmtr/tools/logging_tools.py,sha256=XYAkthur0Nrc9uCuw7QYupfRWt-MSdcb9Y1YH1GcTKM,2374
26
26
  fmtr/tools/merging_tools.py,sha256=KDxCEFJEQJEwGw1qGKAgR55uUE2X2S5NWLKcfHRmX_k,227
27
27
  fmtr/tools/metric_tools.py,sha256=Lvia5CGFRIfrDFA8s37btIfTU5zHbo04cPJdAMtbndQ,272
28
28
  fmtr/tools/name_tools.py,sha256=5CB_phqhHjl66iI8oLxOGPF2odC1apdul-M8Fv2xBhs,5514
@@ -44,7 +44,7 @@ fmtr/tools/tabular_tools.py,sha256=tpIpZzYku1HcJrHZJL6BC39LmN3WUWVhFbK2N7nDVmE,1
44
44
  fmtr/tools/tokenization_tools.py,sha256=me-IBzSLyNYejLybwjO9CNB6Mj2NYfKPaOVThXyaGNg,4268
45
45
  fmtr/tools/tools.py,sha256=CAsApa1YwVdNE6H66Vjivs_mXYvOas3rh7fPELAnTpk,795
46
46
  fmtr/tools/unicode_tools.py,sha256=yS_9wpu8ogNoiIL7s1G_8bETFFO_YQlo4LNPv1NLDeY,52
47
- fmtr/tools/version,sha256=A3CRagPGF-vPgHHT1p_3Z_XER8Hoz9D7TibYsZEJVmU,5
47
+ fmtr/tools/version,sha256=D6_5-XKSRJ7uMrgd-I-BK8oDjUQ8WiJUgC32EIRj8P4,5
48
48
  fmtr/tools/version_tools.py,sha256=yNs_CGqWpqE4jbK9wsPIi14peJVXYbhIcMqHAFOw3yE,1480
49
49
  fmtr/tools/yaml_tools.py,sha256=9kuYChqJelWQIjGlSnK4iDdOWWH06P0gp9jIcRrC3UI,1903
50
50
  fmtr/tools/ai_tools/__init__.py,sha256=JZrLuOFNV1A3wvJgonxOgz_4WS-7MfCuowGWA5uYCjs,372
@@ -58,7 +58,7 @@ fmtr/tools/dns_tools/server.py,sha256=t38TmSpra3FRoMk351eHzOOPlSuaCyjxbvPwX9o15a
58
58
  fmtr/tools/entrypoints/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
59
59
  fmtr/tools/entrypoints/cache_hfh.py,sha256=fQNs4J9twQuZH_Yj98-oOvEX7-LrSUP3kO8nzw2HrHs,60
60
60
  fmtr/tools/entrypoints/ep_test.py,sha256=B8HfWISfSgw_xVX475CbJGh_QnpOe9MH65H8qGjTWbY,46
61
- fmtr/tools/entrypoints/install_yamlscript.py,sha256=_q1OSjV2eja0JFlyS6Fyhx0xx4cFU1esX3X6TKZGG04,123
61
+ fmtr/tools/entrypoints/install_yamlscript.py,sha256=D9-QET4uPkwMvOBQJAgzn1fYb7Z7VAgZzFdHSAXc3Qc,116
62
62
  fmtr/tools/entrypoints/remote_debug_test.py,sha256=wmKg9o2pQq7eqeHmaO8oviujNgtnsCVEXOdXLIcQWs4,123
63
63
  fmtr/tools/entrypoints/shell_debug.py,sha256=0No3tAg9Ri4_vvSlQCUtAY-11HR0nE45i0VVtiAViwY,106
64
64
  fmtr/tools/path_tools/__init__.py,sha256=v5CpmzXq5Ii90FtcmxAJKiLxmguZMrPnQ_HdT872Np0,443
@@ -75,9 +75,9 @@ fmtr/tools/tests/test_environment.py,sha256=iHaiMQfECYZPkPKwfuIZV9uHuWe3aE-p_dN_
75
75
  fmtr/tools/tests/test_json.py,sha256=IeSP4ziPvRcmS8kq7k9tHonC9rN5YYq9GSNT2ul6Msk,287
76
76
  fmtr/tools/tests/test_path.py,sha256=AkZQa6_8BQ-VaCyL_J-iKmdf2ZaM-xFYR37Kun3k4_g,2188
77
77
  fmtr/tools/tests/test_yaml.py,sha256=jc0TwwKu9eC0LvFGNMERdgBue591xwLxYXFbtsRwXVM,287
78
- fmtr_tools-1.3.5.dist-info/licenses/LICENSE,sha256=FW9aa6vVN5IjRQWLT43hs4_koYSmpcbIovlKeAJ0_cI,10757
79
- fmtr_tools-1.3.5.dist-info/METADATA,sha256=BZUlxcIQC0rSnj6GtCK86nkFIqmDK7ArsG8sRi1VRrc,16060
80
- fmtr_tools-1.3.5.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
81
- fmtr_tools-1.3.5.dist-info/entry_points.txt,sha256=h-r__Xh5njtFqreMLg6cGuTFS4Qh-QqJPU1HB-_BS-Q,357
82
- fmtr_tools-1.3.5.dist-info/top_level.txt,sha256=LXem9xCgNOD72tE2gRKESdiQTL902mfFkwWb6-dlwEE,5
83
- fmtr_tools-1.3.5.dist-info/RECORD,,
78
+ fmtr_tools-1.3.7.dist-info/licenses/LICENSE,sha256=FW9aa6vVN5IjRQWLT43hs4_koYSmpcbIovlKeAJ0_cI,10757
79
+ fmtr_tools-1.3.7.dist-info/METADATA,sha256=k4qiny1GqJwYqNMhP27A0fmtJMk_z70R8KisCzcms-c,16060
80
+ fmtr_tools-1.3.7.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
81
+ fmtr_tools-1.3.7.dist-info/entry_points.txt,sha256=h-r__Xh5njtFqreMLg6cGuTFS4Qh-QqJPU1HB-_BS-Q,357
82
+ fmtr_tools-1.3.7.dist-info/top_level.txt,sha256=LXem9xCgNOD72tE2gRKESdiQTL902mfFkwWb6-dlwEE,5
83
+ fmtr_tools-1.3.7.dist-info/RECORD,,