Skip to main content

Data Quality

Upgrading from Collate 2.0.8 to Collate 2.1 changes how test cases are validated and how data quality dimensions are stored. Dynamic assertions also need an optional package on custom ingestion installs. Most other changes are additive.

Data Quality Dimensions Are Now Managed Entities

Breaking. Affects code generated from the Collate 2.0 schemas, the Python and Java software development kits (SDKs), and scripts that set a test definition’s dimension. Other users see a behavioral change only.
A dimension, such as Completeness or Accuracy, was a fixed list of values in Collate 2.0. Each dimension is now its own record. You can add to, rename, or recolor dimensions under Settings > Preferences > Data Quality. Collate includes seven system dimensions that cannot be edited or deleted. The system dimensions are the following:
  • Accuracy
  • Completeness
  • Consistency
  • Integrity
  • Structured Query Language (SQL)
  • Uniqueness
  • Validity
The schema changes as follows:
The following changes apply to your code and data.
  • dataQualityDimension on a test definition is now a plain name string, not an enum.
  • Test cases now carry their own dataQualityDimension. If you do not set one when you create a test case, it takes the dimension of its test definition. CreateTestCaseRequest accepts the new field.
  • The upgrade first creates the system dimensions. It then gives every existing test case that has no dimension the one its test definition names. Collate marks these test cases as inherited, so reclassifying the definition later moves them too.
  • Test cases that already have a dimension are not changed.
  • Test cases whose definition has no dimension or names an unknown one stay without a dimension. They appear under No Dimension in dashboards.
  • If this step fails, the upgrade still finishes and the failure is only logged.
Regenerate any models or clients built from the Collate 2.0 schemas. Code that compared a definition’s dimension against the old list of values keeps working for the seven system names, but no longer sees an enum.

New Test Cases Are Checked Against Their Definition

Breaking. Affects integrations that create test cases. A request that used to be stored as sent can now be rejected.
When you create a test case, Collate now rejects it in the following cases.
  • A parameter that offers a fixed list of values is given a value that is not in that list. Examples are thresholdUnit and the strategy of a custom SQL test. The comparison ignores letter case, and a blank value counts as not set.
  • The test targets a column whose data type the test definition does not support. A definition with no listed data types still supports every type.
Collate 2.0.8 stored these test cases, and they then failed or measured nothing when the test ran. The UI, API clients, and the Model Context Protocol (MCP) create tool all use POST /v1/dataQuality/testCases. The check runs on that call. Updates are checked only for what they change, so test cases you already have stay editable.
The check is not applied to create-or-update calls (PUT) or to comma-separated values (CSV) import in Collate 2.1. Test cases sent that way are still stored as before and can still fail when the test runs.
If an automation creates test cases and starts receiving 400 Bad Request errors after the upgrade, compare the parameter values and the column type against the test definition. Test cases created from dbt or Great Expectations are not affected because they create their own definitions without these limits.

Dynamic Assertions Need the Anomaly Detection Package

Breaking. Affects self-built ingestion environments that install the base collate-ingestion package and run tests with dynamic assertions.
Dynamic assertions predict a bound from past results by using machine learning models. The libraries for these models no longer install with the base collate-ingestion package. They move to an optional anomaly-detection extra. The libraries are Prophet, scikit-learn, statsmodels, SciPy, and cmdstanpy. A test case with a dynamic assertion now fails with an install hint when the extra is missing. In Collate 2.0.8 the libraries were always present. The Collate ingestion images keep the extra, so this only affects environments that you build yourself. To keep dynamic assertions working in a custom environment, install the extra:
Auto classification and the Automator’s machine learning tagging follow the same pattern. Their libraries, spaCy and Presidio, move to a pii-processor extra. The profiler, the Automator, and the range validators now load without either extra. The setup steps are in the how-to guide. For more information, see Set Up Anomaly Detection.

Failure Threshold Applies to Dynamic Assertion Bounds

Behavioral. Affects test cases that combine a dynamic assertion with a failure threshold.
A failure threshold now widens the bound that the dynamic assertion predicts by the threshold. The model sets the bound. For example, a predicted range of 90 to 110 with a 5% threshold accepts values slightly outside that range. A threshold of 0, or no threshold, leaves the predicted bound unchanged. A stored test result value that is neither a number nor an International Organization for Standardization (ISO) date or datetime is now dropped from the series that the model fits. Collate logs a warning that names the value. The test no longer stops because of it.

Set Parameters on In-Set and Not-In-Set Tests

Behavioral. Affects columnValuesToBeInSet and columnValuesToBeNotInSet.
The following changes apply.
  • Values written as a JavaScript Object Notation (JSON) list, such as [false, true], are now accepted. A JSON list with lowercase true, false, or null aborted the test in Collate 2.0.8.
  • On a column of type BOOLEAN, the text values "true" and "false" in any letter case are compared as real booleans.
Breaking. A value that is not a list, such as a bare string or number, now aborts the test with an error. In Collate 2.0.8, the test accepted it. Wrap single values in a list.

Table Column Set Test Honors ordered: "false"

Behavioral. Affects tableColumnToMatchSet.
Setting ordered to the text "false" was treated as true in Collate 2.0.8, so the test compared column order anyway. Now "false" means order is ignored. Tests that relied on the old behavior and passed only because the order matched keep passing. Tests that were failing because of the order may now pass.

Failed Rows Sample Is Kept When a Test Passes Within Its Threshold

Behavioral. Affects what you see on a passing test case.
Collate 2.0.8 stored and showed the Failed Rows Sample only when a test result was Failed. Collate 2.1 also keeps and shows it when a test passes while still finding failed rows. This happens when a failure threshold tolerates them. Expect Failed Rows Samples on test cases that previously showed none.

Unsafe Pandas Expressions Fail the Test

Breaking. Affects data quality tests that run on data lake and file sources, where pandas evaluates expressions.
Collate now checks the expressions you write in a test before they run. This covers the following expressions:
  • The custom SQL query
  • The partition expression
  • Rule library expressions
  • The column name in the inserted-row-count test
An expression that calls functions or reads attributes is no longer executed. The test fails instead. A custom metric with such an expression is skipped with a warning. Rewrite these expressions as plain comparisons.

Failure Thresholds and Dimension Roll-Up on Test Definitions

Additive. Defaults keep existing tests behaving as before.
The built-in column and table tests gain optional parameters. Examples include the following tests:
  • Not-null
  • Unique
  • In-set
  • Between
  • Regex
  • Row count
  • Column count
The following table lists the parameters. The upgrade adds these parameters to the definitions you already have. It also makes the following test definition updates.
  • tableDiff gains parallelQueries (default 1) to run several comparison queries at once.
  • The numeric column tests now list NUMERIC as a supported data type, so they appear for Snowflake and DB2 numeric columns.
  • The upgrade restores missing columnName, rangeType, and rangeInterval parameters on tableRowInsertedCountToBeBetween for deployments that lost them.
  • The upgrade adds the operator and partitionExpression parameters of the custom SQL test where they were missing.

Test Results, Incidents, and Bulk Actions

Additive. Test results, incidents, and bulk actions gain new fields and endpoints.
Test results, incidents, and bulk actions gain the following.
  • Test case results gain duration, errorDetails, and a richer evaluationScope. The errorDetails field holds the type, message, and stack trace of an aborted run. The evaluationScope field says whether the run used a sample or a partition. Dimension results gain minBound, maxBound, and excludedFromRollUp.
  • Incidents gain a failureSummary and an incident summary table for faster listing. They also gain a grouping endpoint (/testCaseIncidentStatus/incidentGroups) that groups open incidents by table, test definition, or owner. The upgrade backfills the summary table from existing incident history.
  • A new request schema, BundleSuiteBulkRemoveRequest, describes removing several test cases from a logical test suite in one call.
  • Data Insights data-asset charts now exclude test cases from totals, so the data-asset total and its entity type breakdown keep reconciling. The upgrade updates the stored chart definitions.
  • The Collate data quality command accepts an optional status file path. The command writes the workflow status as JSON to that file.

Profiler and Sampling Settings

Breaking. Affects stored or scripted configuration that uses sampleDataStorageConfig.
Collate removes external S3 storage for sample data, and with it the sampleDataStorageConfig property from connection and profiler schemas. Because those schemas reject unknown fields, any configuration that still contains this key fails validation. The upgrade strips the key from the following stored items.
  • Services
  • Database and schema profiler settings
  • Version history
  • Saved test connection requests
If you manage connections or profiler settings as code, remove the key from your files. In Python code, the module metadata.profiler.processor.sample_data_handler is removed. Remove any import of the following names from custom profiler code:
  • upload_sample_data
  • upload_to_storage
  • validate_path_pattern
  • PathPatternException
A profiler workflow must also name its database service. A Collate 2.0.8 profiler configuration without source.serviceName scanned every table available in the data source and looked each one up in Collate. That mode is removed, along with metadata.profiler.source.metadata_ext. Set source.serviceName in your YAML Ain’t Markup Language (YAML) and Python profiler configurations. The auto-classification sampleDataCount now has a maximum of 1000. The upgrade lowers any saved pipeline above that to 1000. Lower the value in your own configuration files so they still validate.