databrickslabs / lsql

Lightweight SQL execution wrapper only on top of Databricks SDK
https://pypi.org/project/databricks-labs-lsql/
Other
8 stars 3 forks source link

[BUG] Dataclass CounterFieldEncoding requires additional required attribute for conditional formatting #234

Closed pritishpai closed 1 month ago

pritishpai commented 1 month ago

Dataclass CounterFieldEncoding https://github.com/databrickslabs/lsql/blob/main/src/databricks/labs/lsql/lakeview/model.py#L521 currently supports display_name, field_name, row_number. For taking full advantage of the widget capabilities need additional attribute style that can be used for conditional formatting like setting threshold for values and showing it up as warning if thresholds are crossed.

Currently setting 'style' in overrides does not allow it to take effect.

Related to https://github.com/databrickslabs/ucx/pull/2201