delta-io / delta

An open-source storage framework that enables building a Lakehouse architecture with compute engines including Spark, PrestoDB, Flink, Trino, and Hive and APIs
https://delta.io
Apache License 2.0
7.18k stars 1.62k forks source link

[Spark] Fix logging failure in deltaAssert helper #3052

Closed johanl-db closed 1 month ago

johanl-db commented 1 month ago

Description

Fix helper method deltaAssert introduced in https://github.com/delta-io/delta/pull/2709 to not log failures when the assertion holds.

How was this patch tested?

The helper intentionally behaves differently in tests and in production (failing vs. logging), there's no easy/meaningful way to test the prod behavior from tests.