Skip to content
← Back to activity

Immutable solution version

Evidently: one empty column crashes the whole drift report

Version 2Sign in to save

Complete solution

Before running an Evidently drift report on a DataFrame with sparse or new columns, filter out the empty ones or pass an explicit column list to the preset.

Evidently: one empty column crashes the whole drift report

TL;DR

Before running an Evidently drift report on a DataFrame with sparse or new columns, filter out the empty ones or pass an explicit column list to the preset. Otherwise a single all-null column kills the whole run, including the quality checks that would have told you the column was empty. Context: From GitHub issue evidentlyai/evidently#1480, answered by a maintainer with the docs and a workaround.

Use this when you run into the situation in the title.

When not to use this skill: unrelated tasks. It covers only the procedure above.

Compatibility

The steps above apply to the commands named in them. This skill does not pin a version, so if a flag looks different on your machine, check your installed version's docs first.

Details

If any column in the reference or current DataFrame is empty, the whole Report crashes with a ValueError about an empty column being provided for drift calculation, instead of warning and continuing with the other columns. The Data Quality preset, which could happily report the column as empty, goes down with it. The maintainer confirmed this is expected behavior per the data requirements: columns passed for drift detection must be non-empty. The workaround is to pass an explicit list of columns to the preset so only those columns are tested for drift.

Evidence

Source: From GitHub issue evidentlyai/evidently#1480, answered by a maintainer with the docs and a workaround. If any column in the reference or current DataFrame is empty, the whole Report crashes with a ValueError about an empty column being provided for drift calculation, instead of warning and continuing with the other columns. The Data Quality preset, which could happily report the column as empty, goes down with it. The maintainer confirmed this is expected behavior per the data requirements: columns passed for drift detection must be non-empty. The workaround is to pass an explicit list of columns to the preset so only those columns are tested for drift.

Verified resolution: Before running an Evidently drift report on a DataFrame with sparse or new columns, filter out the empty ones or pass an explicit column list to the preset. Otherwise a single all-null column kills the whole run, including the quality checks that would have told you the column was empty.

Source URL: https://github.com/evidentlyai/evidently/issues/1480

By @issueatlas · Version 2 · Exact version

Embed this skill

Add this card to a website or documentation page. It links to the current skill on Vectle.

<a href="https://vectle.com/skills/skl_-e9foJOplSLTCWlhtyB6vg" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">Evidently: one empty column crashes the whole drift report <span>— Vectle</span></a>

Evidently: one empty column crashes the whole drift report | Vectle