truthound-dashboard 1.5.0__py3-none-any.whl → 1.5.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.
@@ -187,7 +187,7 @@ class FileConnectionBuilder(ConnectionBuilder):
187
187
  """Connection builder for file-based sources."""
188
188
 
189
189
  source_type = SourceType.FILE
190
- SUPPORTED_EXTENSIONS = {".csv", ".parquet", ".json", ".xlsx", ".xls"}
190
+ SUPPORTED_EXTENSIONS = {".csv", ".parquet", ".json", ".ndjson", ".jsonl"}
191
191
 
192
192
  def build(self, config: dict[str, Any]) -> str:
193
193
  """Build file path from config."""
@@ -216,7 +216,7 @@ class FileConnectionBuilder(ConnectionBuilder):
216
216
  return SourceTypeDefinition(
217
217
  type=SourceType.FILE.value,
218
218
  name="File",
219
- description="Local file (CSV, Parquet, JSON, Excel)",
219
+ description="Local file (CSV, Parquet, JSON, NDJSON, JSONL)",
220
220
  icon="file",
221
221
  category="file",
222
222
  fields=[
@@ -237,7 +237,8 @@ class FileConnectionBuilder(ConnectionBuilder):
237
237
  {"value": "csv", "label": "CSV"},
238
238
  {"value": "parquet", "label": "Parquet"},
239
239
  {"value": "json", "label": "JSON"},
240
- {"value": "excel", "label": "Excel"},
240
+ {"value": "ndjson", "label": "NDJSON"},
241
+ {"value": "jsonl", "label": "JSONL"},
241
242
  ],
242
243
  default="auto",
243
244
  description="File format (auto-detected from extension if not specified)",
@@ -271,13 +272,195 @@ class FileConnectionBuilder(ConnectionBuilder):
271
272
  default=True,
272
273
  description="First row contains column names",
273
274
  ),
275
+ ],
276
+ )
277
+
278
+
279
+ class CSVConnectionBuilder(FileConnectionBuilder):
280
+ """Connection builder for CSV files."""
281
+
282
+ source_type = SourceType.CSV
283
+
284
+ @classmethod
285
+ def get_definition(cls) -> SourceTypeDefinition:
286
+ return SourceTypeDefinition(
287
+ type=SourceType.CSV.value,
288
+ name="CSV",
289
+ description="Comma-separated values file",
290
+ icon="file",
291
+ category="file",
292
+ fields=[
274
293
  FieldDefinition(
275
- name="sheet",
276
- label="Sheet Name",
277
- placeholder="Sheet1",
278
- description="Excel sheet name (for Excel files)",
279
- depends_on="format",
280
- depends_value="excel",
294
+ name="path",
295
+ label="File Path",
296
+ type=FieldType.FILE_PATH,
297
+ required=True,
298
+ placeholder="/path/to/data.csv",
299
+ description="Path to the CSV file",
300
+ ),
301
+ FieldDefinition(
302
+ name="delimiter",
303
+ label="Delimiter",
304
+ placeholder=",",
305
+ default=",",
306
+ description="CSV delimiter character",
307
+ ),
308
+ FieldDefinition(
309
+ name="encoding",
310
+ label="Encoding",
311
+ type=FieldType.SELECT,
312
+ options=[
313
+ {"value": "utf-8", "label": "UTF-8"},
314
+ {"value": "utf-16", "label": "UTF-16"},
315
+ {"value": "iso-8859-1", "label": "ISO-8859-1 (Latin-1)"},
316
+ {"value": "cp1252", "label": "Windows-1252"},
317
+ ],
318
+ default="utf-8",
319
+ description="File encoding",
320
+ ),
321
+ FieldDefinition(
322
+ name="has_header",
323
+ label="Has Header Row",
324
+ type=FieldType.BOOLEAN,
325
+ default=True,
326
+ description="First row contains column names",
327
+ ),
328
+ ],
329
+ )
330
+
331
+
332
+ class ParquetConnectionBuilder(FileConnectionBuilder):
333
+ """Connection builder for Parquet files."""
334
+
335
+ source_type = SourceType.PARQUET
336
+
337
+ @classmethod
338
+ def get_definition(cls) -> SourceTypeDefinition:
339
+ return SourceTypeDefinition(
340
+ type=SourceType.PARQUET.value,
341
+ name="Parquet",
342
+ description="Apache Parquet columnar storage file",
343
+ icon="file",
344
+ category="file",
345
+ fields=[
346
+ FieldDefinition(
347
+ name="path",
348
+ label="File Path",
349
+ type=FieldType.FILE_PATH,
350
+ required=True,
351
+ placeholder="/path/to/data.parquet",
352
+ description="Path to the Parquet file",
353
+ ),
354
+ ],
355
+ )
356
+
357
+
358
+ class JSONConnectionBuilder(FileConnectionBuilder):
359
+ """Connection builder for JSON files."""
360
+
361
+ source_type = SourceType.JSON
362
+
363
+ @classmethod
364
+ def get_definition(cls) -> SourceTypeDefinition:
365
+ return SourceTypeDefinition(
366
+ type=SourceType.JSON.value,
367
+ name="JSON",
368
+ description="JSON file (array of objects)",
369
+ icon="file_json",
370
+ category="file",
371
+ fields=[
372
+ FieldDefinition(
373
+ name="path",
374
+ label="File Path",
375
+ type=FieldType.FILE_PATH,
376
+ required=True,
377
+ placeholder="/path/to/data.json",
378
+ description="Path to the JSON file",
379
+ ),
380
+ FieldDefinition(
381
+ name="encoding",
382
+ label="Encoding",
383
+ type=FieldType.SELECT,
384
+ options=[
385
+ {"value": "utf-8", "label": "UTF-8"},
386
+ {"value": "utf-16", "label": "UTF-16"},
387
+ ],
388
+ default="utf-8",
389
+ description="File encoding",
390
+ ),
391
+ ],
392
+ )
393
+
394
+
395
+ class NDJSONConnectionBuilder(FileConnectionBuilder):
396
+ """Connection builder for NDJSON files."""
397
+
398
+ source_type = SourceType.NDJSON
399
+
400
+ @classmethod
401
+ def get_definition(cls) -> SourceTypeDefinition:
402
+ return SourceTypeDefinition(
403
+ type=SourceType.NDJSON.value,
404
+ name="NDJSON",
405
+ description="Newline-delimited JSON file",
406
+ icon="file_json",
407
+ category="file",
408
+ fields=[
409
+ FieldDefinition(
410
+ name="path",
411
+ label="File Path",
412
+ type=FieldType.FILE_PATH,
413
+ required=True,
414
+ placeholder="/path/to/data.ndjson",
415
+ description="Path to the NDJSON file",
416
+ ),
417
+ FieldDefinition(
418
+ name="encoding",
419
+ label="Encoding",
420
+ type=FieldType.SELECT,
421
+ options=[
422
+ {"value": "utf-8", "label": "UTF-8"},
423
+ {"value": "utf-16", "label": "UTF-16"},
424
+ ],
425
+ default="utf-8",
426
+ description="File encoding",
427
+ ),
428
+ ],
429
+ )
430
+
431
+
432
+ class JSONLConnectionBuilder(FileConnectionBuilder):
433
+ """Connection builder for JSONL files."""
434
+
435
+ source_type = SourceType.JSONL
436
+
437
+ @classmethod
438
+ def get_definition(cls) -> SourceTypeDefinition:
439
+ return SourceTypeDefinition(
440
+ type=SourceType.JSONL.value,
441
+ name="JSONL",
442
+ description="JSON Lines file (one JSON object per line)",
443
+ icon="file_json",
444
+ category="file",
445
+ fields=[
446
+ FieldDefinition(
447
+ name="path",
448
+ label="File Path",
449
+ type=FieldType.FILE_PATH,
450
+ required=True,
451
+ placeholder="/path/to/data.jsonl",
452
+ description="Path to the JSONL file",
453
+ ),
454
+ FieldDefinition(
455
+ name="encoding",
456
+ label="Encoding",
457
+ type=FieldType.SELECT,
458
+ options=[
459
+ {"value": "utf-8", "label": "UTF-8"},
460
+ {"value": "utf-16", "label": "UTF-16"},
461
+ ],
462
+ default="utf-8",
463
+ description="File encoding",
281
464
  ),
282
465
  ],
283
466
  )
@@ -1581,11 +1764,11 @@ class KafkaConnectionBuilder(ConnectionBuilder):
1581
1764
  CONNECTION_BUILDERS: dict[str, type[ConnectionBuilder]] = {
1582
1765
  # File-based
1583
1766
  SourceType.FILE.value: FileConnectionBuilder,
1584
- SourceType.CSV.value: FileConnectionBuilder,
1585
- SourceType.PARQUET.value: FileConnectionBuilder,
1586
- SourceType.JSON.value: FileConnectionBuilder,
1587
- SourceType.NDJSON.value: FileConnectionBuilder,
1588
- SourceType.JSONL.value: FileConnectionBuilder,
1767
+ SourceType.CSV.value: CSVConnectionBuilder,
1768
+ SourceType.PARQUET.value: ParquetConnectionBuilder,
1769
+ SourceType.JSON.value: JSONConnectionBuilder,
1770
+ SourceType.NDJSON.value: NDJSONConnectionBuilder,
1771
+ SourceType.JSONL.value: JSONLConnectionBuilder,
1589
1772
  # Core SQL
1590
1773
  SourceType.POSTGRESQL.value: PostgreSQLConnectionBuilder,
1591
1774
  SourceType.MYSQL.value: MySQLConnectionBuilder,
@@ -1735,11 +1918,18 @@ def get_supported_source_types() -> list[dict[str, Any]]:
1735
1918
  List of source type definitions.
1736
1919
  """
1737
1920
  result = []
1921
+ seen_types: set[str] = set()
1738
1922
  for source_type in SourceType:
1923
+ # Skip generic FILE type - specific format types (CSV, Parquet, etc.) cover it
1924
+ if source_type == SourceType.FILE:
1925
+ continue
1739
1926
  builder_class = CONNECTION_BUILDERS.get(source_type.value)
1740
1927
  if builder_class:
1741
1928
  definition = builder_class.get_definition()
1742
- result.append(definition.to_dict())
1929
+ # Deduplicate by type value
1930
+ if definition.type not in seen_types:
1931
+ seen_types.add(definition.type)
1932
+ result.append(definition.to_dict())
1743
1933
  return result
1744
1934
 
1745
1935
 
@@ -1774,12 +1964,17 @@ def get_source_types_by_category() -> dict[str, list[dict[str, Any]]]:
1774
1964
  "streaming": [],
1775
1965
  }
1776
1966
 
1967
+ seen_types: set[str] = set()
1777
1968
  for source_type in SourceType:
1969
+ if source_type == SourceType.FILE:
1970
+ continue
1778
1971
  builder_class = CONNECTION_BUILDERS.get(source_type.value)
1779
1972
  if builder_class:
1780
1973
  definition = builder_class.get_definition()
1781
- category = definition.category
1782
- if category in categories:
1783
- categories[category].append(definition.to_dict())
1974
+ if definition.type not in seen_types:
1975
+ seen_types.add(definition.type)
1976
+ category = definition.category
1977
+ if category in categories:
1978
+ categories[category].append(definition.to_dict())
1784
1979
 
1785
1980
  return categories
@@ -24,6 +24,7 @@ Example:
24
24
  from __future__ import annotations
25
25
 
26
26
  import logging
27
+ import os
27
28
  from collections.abc import AsyncGenerator
28
29
  from contextlib import asynccontextmanager
29
30
  from pathlib import Path
@@ -244,12 +245,15 @@ def configure_cors(app: FastAPI) -> None:
244
245
  """
245
246
  settings = get_settings()
246
247
 
248
+ extra_origins = os.environ.get("TRUTHOUND_CORS_ORIGINS", "")
247
249
  origins = [
248
250
  "http://localhost:5173", # Vite dev server
249
251
  "http://127.0.0.1:5173",
250
252
  f"http://localhost:{settings.port}", # Dashboard server
251
253
  f"http://127.0.0.1:{settings.port}",
252
254
  ]
255
+ if extra_origins:
256
+ origins.extend([o.strip() for o in extra_origins.split(",") if o.strip()])
253
257
 
254
258
  app.add_middleware(
255
259
  CORSMiddleware,
@@ -6,7 +6,7 @@
6
6
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
7
7
  <meta name="description" content="Truthound Dashboard - Open-source data quality monitoring" />
8
8
  <title>Truthound Dashboard</title>
9
- <script type="module" crossorigin src="/assets/index-BnWMZ9K7.js"></script>
9
+ <script type="module" crossorigin src="/assets/index-Ch94w21P.js"></script>
10
10
  <link rel="stylesheet" crossorigin href="/assets/index-DDRuhd95.css">
11
11
  </head>
12
12
  <body>
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: truthound-dashboard
3
- Version: 1.5.0
3
+ Version: 1.5.1
4
4
  Summary: Open-source data quality dashboard - GX Cloud alternative
5
5
  Author-email: Truthound Team <team@truthound.dev>
6
6
  License-Expression: Apache-2.0
@@ -44,8 +44,9 @@ Provides-Extra: translate
44
44
  Description-Content-Type: text/markdown
45
45
 
46
46
  # truthound-dashboard
47
+ <img width="1697" height="847" alt="truthound-dashboard" src="https://github.com/user-attachments/assets/2239ebff-470b-49fe-ab09-81bc3117880d" />
47
48
 
48
- > **UNDER ACTIVE DEVELOPMENT**: This project is currently in active development. APIs and features may change without notice. Not recommended for production use yet.
49
+ > **Alpha Version**: APIs and features may change without notice.
49
50
 
50
51
  ## Overview
51
52
  <img width="300" height="300" alt="Truthound_icon" src="https://github.com/user-attachments/assets/90d9e806-8895-45ec-97dc-f8300da4d997" />
@@ -60,7 +61,9 @@ A web-based data quality monitoring dashboard for [truthound](https://github.com
60
61
 
61
62
  truthound-dashboard provides a graphical interface for managing data sources, executing validations, tracking historical results, scheduling automated checks, and configuring notifications. It serves as an alternative to commercial data quality platforms.
62
63
 
63
- [Documentation](https://truthound.netlify.app) | [PyPI](https://pypi.org/project/truthound-dashboard/)
64
+ [Documentation](https://truthound.netlify.app) | [PyPI](https://pypi.org/project/truthound-dashboard/) | [Live Demo](https://truthound-dashboard.vercel.app)
65
+
66
+ > **Demo Note**: The live demo uses a free-tier backend ([Render](https://render.com)), which enters sleep mode after 15 minutes of inactivity. The first request may take 30–60 seconds to wake up the server.
64
67
 
65
68
  ## Design Principles
66
69
 
@@ -2,7 +2,7 @@ truthound_dashboard/__init__.py,sha256=bzN84Y01SlEh5F8KkV-fGqPR82_tA0leAP6PyCXk8
2
2
  truthound_dashboard/__main__.py,sha256=Zq98OmYZm4NJ7n2yG5Qr07fkSiwMEQQE20gG1fpW7wo,133
3
3
  truthound_dashboard/cli.py,sha256=1x7AN2g9H5pZ4sG2PakCpSdBYnviknJv7LRIauAPzgU,19348
4
4
  truthound_dashboard/config.py,sha256=fBSxoGitTe-9SeKkkQHtqNTcVxws5fvJ0YhF0EMuqG4,4089
5
- truthound_dashboard/main.py,sha256=r4rJj4uco0RRX1j8qZHdpF4RVKdY1CK-uHf-Udigb7k,9236
5
+ truthound_dashboard/main.py,sha256=5N5-SbTAeRQA68KC4KESTAxMyuHaKAQylCyye6Hmi-4,9416
6
6
  truthound_dashboard/api/__init__.py,sha256=rnbuYRDgh0GcqkR-d9Trkc8L0O34K4tMH6flyeQ9U98,361
7
7
  truthound_dashboard/api/alerts.py,sha256=D2TjODST1hzdMQ1Bp5GgVcs5YXhu4ofdaRtHNYorNns,7653
8
8
  truthound_dashboard/api/anomaly.py,sha256=Ch_3EwKLkMRD7r76gErXxUztUcquT36bChC_RcjjhMw,41388
@@ -51,7 +51,7 @@ truthound_dashboard/core/base.py,sha256=Jp2NFNCacIt2DStGOSvyUYnx1wV-FqDkX9gLroCb
51
51
  truthound_dashboard/core/cache.py,sha256=6LBvu-gdDoGylE2H7_-i-JvlXoQuKPwbXmcdGdAGfmk,21007
52
52
  truthound_dashboard/core/cached_services.py,sha256=VwZ9qbg5ljyIbF3Ql7fpV6T3waWzYxATPmtC1dQQ7qk,11729
53
53
  truthound_dashboard/core/charts.py,sha256=JzhVVMowR4znoXLqKglLBYiwEdUbKGDQ8HFV5PKbv-Q,10226
54
- truthound_dashboard/core/connections.py,sha256=k73O2rv5FdBwaR0rqnCNGyg-khVwMA_Lxc2q1K7DDyI,63216
54
+ truthound_dashboard/core/connections.py,sha256=ZZnwllaCLwomT5mjFTmWJJVSOCfFW590HEOra3SDl4Q,69903
55
55
  truthound_dashboard/core/cross_alerts.py,sha256=HM0LS91YVDxBapoPw5E_g8xzduH7YrrZQcb2t2d1Ui0,37502
56
56
  truthound_dashboard/core/datasource_factory.py,sha256=eBqzEqxs46siaP7DpoOEzTe24QY2PQmyWkVXmAAf1f4,57226
57
57
  truthound_dashboard/core/drift_monitor.py,sha256=kBYKOzCHci07HByN6jMY61OjMptOP1MjwbO5pU5-Ies,61695
@@ -267,7 +267,7 @@ truthound_dashboard/schemas/validators/table_validators.py,sha256=hIt5LcGZ05QZMK
267
267
  truthound_dashboard/schemas/validators/timeseries_validators.py,sha256=xgtC4NyVqq6Sa1hA5QWrohTkAtD0koZmLrxNyON2Cag,14629
268
268
  truthound_dashboard/schemas/validators/uniqueness_validators.py,sha256=Y23ts3FAAuhluXqz8bdFW8VMN5HZIOM7Nz9Hub0ehRw,12110
269
269
  truthound_dashboard/static/favicon.ico,sha256=T9BJXnpyq6t6lpFHd6ivEimWF2uGFzwxDeTDyz2UVmQ,15406
270
- truthound_dashboard/static/index.html,sha256=vC1AiVeONKdVXXZmg-7iuEUerM8y0fimcTjUuKBAwgk,568
270
+ truthound_dashboard/static/index.html,sha256=YrxFUXjSiuXmSC3gr324ZNQlopJOp7PMzPkLRxBM05Y,568
271
271
  truthound_dashboard/static/assets/logo--IpBiMPK.png,sha256=c7ne4oaZ1BpQR5yP2TVYoAE1s1vS7lRPxgWP1pzUMYE,213715
272
272
  truthound_dashboard/translate/__init__.py,sha256=Mv_xtMk4SaBGUsMgJqhwARnkJkZdq4OhJi5HdpdsBnw,1458
273
273
  truthound_dashboard/translate/config_updater.py,sha256=AtJ7ero4cHKwUYQRDbGaPAlLmcyBv0IeBewdiTo0X8c,12038
@@ -280,8 +280,8 @@ truthound_dashboard/translate/providers/mistral.py,sha256=j0oh_mGksdMuIfbuZKq0yo
280
280
  truthound_dashboard/translate/providers/ollama.py,sha256=XlAHE14VvdSPKFbrJIbB3KUHzrgQm0Zj08snL71otUQ,7286
281
281
  truthound_dashboard/translate/providers/openai.py,sha256=AeaOfRjNgCIgBdcX1gcYqqf41fXeEIyN3AiLAOy3SZc,6760
282
282
  truthound_dashboard/translate/providers/registry.py,sha256=iwfcWYJ2uKfwWjsalhV4jSoyZC7bSeujK6sTMuylMMY,6474
283
- truthound_dashboard-1.5.0.dist-info/METADATA,sha256=jYiwdqHZ0ps7XlEBO0dLkP40RiD54bSbcKToV_veGA4,14781
284
- truthound_dashboard-1.5.0.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
285
- truthound_dashboard-1.5.0.dist-info/entry_points.txt,sha256=Xq8qadJ-Sqk4_0Ss_rhCqCv7uxPZZdwO3WUnbK0r6Hw,135
286
- truthound_dashboard-1.5.0.dist-info/licenses/LICENSE,sha256=qrBWTDMS8ZvwVJl3Yo2n8_AxOos3s8S9pcOzLW5Nivg,10763
287
- truthound_dashboard-1.5.0.dist-info/RECORD,,
283
+ truthound_dashboard-1.5.1.dist-info/METADATA,sha256=A5eqsf7SDfG7ducOAh-pUypggUH5hL1UqBHBRJLgL1k,15092
284
+ truthound_dashboard-1.5.1.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
285
+ truthound_dashboard-1.5.1.dist-info/entry_points.txt,sha256=Xq8qadJ-Sqk4_0Ss_rhCqCv7uxPZZdwO3WUnbK0r6Hw,135
286
+ truthound_dashboard-1.5.1.dist-info/licenses/LICENSE,sha256=qrBWTDMS8ZvwVJl3Yo2n8_AxOos3s8S9pcOzLW5Nivg,10763
287
+ truthound_dashboard-1.5.1.dist-info/RECORD,,