Skip to content

[BUGFIX] Incorrect HTML report description for ExpectTableColumnsToMatchSet#11719

Open
wavebyrd wants to merge 3 commits intogreat-expectations:developfrom
wavebyrd:fix/10978-match-set-description
Open

[BUGFIX] Incorrect HTML report description for ExpectTableColumnsToMatchSet#11719
wavebyrd wants to merge 3 commits intogreat-expectations:developfrom
wavebyrd:fix/10978-match-set-description

Conversation

@wavebyrd
Copy link
Copy Markdown

Summary

  • When exact_match is not explicitly passed to ExpectTableColumnsToMatchSet, it defaults to True, but both prescriptive renderers resolved the description to "at least" instead of "exactly"
  • The atomic renderer checked params.exact_match and params.exact_match.value is True, which short-circuits to False when params.exact_match is None
  • The legacy renderer checked params["exact_match"] is True, which also evaluates False for None
  • Fixed both conditions to treat None (the default) the same as True

Fixes #10978

Test plan

  • Validate that ExpectTableColumnsToMatchSet with no exact_match argument renders "Must have exactly these columns" in the HTML report
  • Validate that explicitly passing exact_match=True still renders "exactly"
  • Validate that explicitly passing exact_match=False still renders "at least"

@netlify
Copy link
Copy Markdown

netlify bot commented Mar 13, 2026

‼️ Deploy request for niobium-lead-7998 rejected.

Name Link
🔨 Latest commit 82296c6

@gx-cla-bot
Copy link
Copy Markdown

gx-cla-bot bot commented Mar 13, 2026

A new contributor, HUZZAH! Welcome and thanks for joining our community. In order to accept a pull request we require that all contributors sign our Contributor License Agreement. We have two different CLAs, depending on whether you are contributing to GX in a personal or professional capacity. Please sign the one that is applicable to your situation so that we may accept your contribution:

Individual Contributor License Agreement v1.0
Software Grant and Corporate Contributor License Agreement v1.0

Once you have signed the CLA, you can add a comment with the text @cla-bot check and the bot will update the PR status!

Please reach out to the #gx-community-support channel, on our Slack if you have any questions or if you have already signed the CLA and are receiving this message in error.

Users missing a CLA: carson@carsons-macbook-pro.local

1 similar comment
@gx-cla-bot
Copy link
Copy Markdown

gx-cla-bot bot commented Mar 13, 2026

A new contributor, HUZZAH! Welcome and thanks for joining our community. In order to accept a pull request we require that all contributors sign our Contributor License Agreement. We have two different CLAs, depending on whether you are contributing to GX in a personal or professional capacity. Please sign the one that is applicable to your situation so that we may accept your contribution:

Individual Contributor License Agreement v1.0
Software Grant and Corporate Contributor License Agreement v1.0

Once you have signed the CLA, you can add a comment with the text @cla-bot check and the bot will update the PR status!

Please reach out to the #gx-community-support channel, on our Slack if you have any questions or if you have already signed the CLA and are receiving this message in error.

Users missing a CLA: carson@carsons-macbook-pro.local

@wavebyrd wavebyrd force-pushed the fix/10978-match-set-description branch from 4c9de3c to 0bb7b84 Compare March 13, 2026 21:33
@billdirks
Copy link
Copy Markdown
Contributor

Hi @wavebyrd,
Thanks for the PR! 2 comments:

  1. Could you sign the waiver (see message above)?
  2. It looks like a recent push has put this PR in a state where it contains a lot of historical commits. We won't be able to review until that is fixed since we can't see your proposed change.

…_match not set

When exact_match is omitted (defaults to True), both prescriptive
renderers incorrectly resolved the description to "at least" instead
of "exactly". The atomic renderer failed because it checked
`params.exact_match and params.exact_match.value is True`, which
short-circuits to False when exact_match is None. The legacy renderer
checked `params["exact_match"] is True`, which also fails for None.

Fixes great-expectations#10978
@wavebyrd wavebyrd force-pushed the fix/10978-match-set-description branch from 0bb7b84 to 392ca1f Compare March 17, 2026 17:06
@gx-cla-bot
Copy link
Copy Markdown

gx-cla-bot bot commented Mar 17, 2026

A new contributor, HUZZAH! Welcome and thanks for joining our community. In order to accept a pull request we require that all contributors sign our Contributor License Agreement. We have two different CLAs, depending on whether you are contributing to GX in a personal or professional capacity. Please sign the one that is applicable to your situation so that we may accept your contribution:

Individual Contributor License Agreement v1.0
Software Grant and Corporate Contributor License Agreement v1.0

Once you have signed the CLA, you can add a comment with the text @cla-bot check and the bot will update the PR status!

Please reach out to the #gx-community-support channel, on our Slack if you have any questions or if you have already signed the CLA and are receiving this message in error.

Users missing a CLA: wavebyrd

@wavebyrd
Copy link
Copy Markdown
Author

Fixed the branch history - it now contains only the single commit for this fix. I'll sign the CLA shortly.

@cla-bot check

@gx-cla-bot
Copy link
Copy Markdown

gx-cla-bot bot commented Mar 17, 2026

A new contributor, HUZZAH! Welcome and thanks for joining our community. In order to accept a pull request we require that all contributors sign our Contributor License Agreement. We have two different CLAs, depending on whether you are contributing to GX in a personal or professional capacity. Please sign the one that is applicable to your situation so that we may accept your contribution:

Individual Contributor License Agreement v1.0
Software Grant and Corporate Contributor License Agreement v1.0

Once you have signed the CLA, you can add a comment with the text @cla-bot check and the bot will update the PR status!

Please reach out to the #gx-community-support channel, on our Slack if you have any questions or if you have already signed the CLA and are receiving this message in error.

Users missing a CLA: wavebyrd

@gx-cla-bot
Copy link
Copy Markdown

gx-cla-bot bot commented Mar 17, 2026

A new contributor, HUZZAH! Welcome and thanks for joining our community. In order to accept a pull request we require that all contributors sign our Contributor License Agreement. We have two different CLAs, depending on whether you are contributing to GX in a personal or professional capacity. Please sign the one that is applicable to your situation so that we may accept your contribution:

Individual Contributor License Agreement v1.0
Software Grant and Corporate Contributor License Agreement v1.0

Once you have signed the CLA, you can add a comment with the text @cla-bot check and the bot will update the PR status!

Please reach out to the #gx-community-support channel, on our Slack if you have any questions or if you have already signed the CLA and are receiving this message in error.

Users missing a CLA: wavebyrd

Copy link
Copy Markdown
Contributor

@billdirks billdirks left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, this looks good. I've requested you add a comment explaining the root cause of the issue and the need for this fix.

@@ -286,7 +286,9 @@ def _prescriptive_template(
)

exact_match_str = (
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change looks good but it wasn't apparent to me at first because the bug is caused by something happening in Expectation.configuration. Fixing that would be a bigger change so could you add this comment explaining why this is necessary?

Suggested change
exact_match_str = (
# params.exact_match may be None because Expectation.configuration serializes kwargs
# with exclude_defaults=True. Since exact_match defaults to True, None should be
# treated as True here.
exact_match_str = (

)

exact_match_str = "exactly" if params["exact_match"] is True else "at least"
exact_match_str = "exactly" if params["exact_match"] is not False else "at least"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
exact_match_str = "exactly" if params["exact_match"] is not False else "at least"
# See comment in _prescriptive_template — exact_match may be None
# when its value matches the class default (True).
exact_match_str = "exactly" if params["exact_match"] is not False else "at least"

@billdirks
Copy link
Copy Markdown
Contributor

@wavebyrd I've left a review. Overall the fix looks good. Could you sign the CLA (see message above)? You will need to use the email associated with your github account for it to be accepted.

@NathanFarmer NathanFarmer changed the title Fix incorrect HTML report description for ExpectTableColumnsToMatchSet [BUGFIX] Incorrect HTML report description for ExpectTableColumnsToMatchSet Mar 24, 2026
@gx-cla-bot
Copy link
Copy Markdown

gx-cla-bot bot commented Mar 24, 2026

A new contributor, HUZZAH! Welcome and thanks for joining our community. In order to accept a pull request we require that all contributors sign our Contributor License Agreement. We have two different CLAs, depending on whether you are contributing to GX in a personal or professional capacity. Please sign the one that is applicable to your situation so that we may accept your contribution:

Individual Contributor License Agreement v1.0
Software Grant and Corporate Contributor License Agreement v1.0

Once you have signed the CLA, you can add a comment with the text @cla-bot check and the bot will update the PR status!

Please reach out to the #gx-community-support channel, on our Slack if you have any questions or if you have already signed the CLA and are receiving this message in error.

Users missing a CLA: wavebyrd

@codecov
Copy link
Copy Markdown

codecov bot commented Mar 24, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 84.19%. Comparing base (30a4a34) to head (82296c6).
⚠️ Report is 1 commits behind head on develop.
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop   #11719      +/-   ##
===========================================
- Coverage    84.59%   84.19%   -0.40%     
===========================================
  Files          473      473              
  Lines        39260    39260              
===========================================
- Hits         33211    33054     -157     
- Misses        6049     6206     +157     
Flag Coverage Δ
3.10 73.51% <0.00%> (ø)
3.10 athena ?
3.10 aws_deps ?
3.10 big ?
3.10 clickhouse ?
3.10 filesystem ?
3.10 mysql ?
3.10 openpyxl or pyarrow or project or sqlite or aws_creds ?
3.10 postgresql ?
3.10 spark ?
3.10 spark_connect ?
3.10 sql_server ?
3.10 trino ?
3.11 73.55% <0.00%> (ø)
3.11 athena ?
3.11 aws_deps ?
3.11 big ?
3.11 clickhouse ?
3.11 filesystem ?
3.11 mysql ?
3.11 openpyxl or pyarrow or project or sqlite or aws_creds ?
3.11 postgresql ?
3.11 spark ?
3.11 spark_connect ?
3.11 sql_server ?
3.11 trino ?
3.12 73.54% <0.00%> (-0.02%) ⬇️
3.12 athena ?
3.12 aws_deps ?
3.12 big ?
3.12 filesystem ?
3.12 mysql ?
3.12 openpyxl or pyarrow or project or sqlite or aws_creds ?
3.12 postgresql ?
3.12 spark ?
3.12 spark_connect ?
3.12 sql_server ?
3.12 trino ?
3.13 73.56% <0.00%> (ø)
3.13 athena 41.95% <0.00%> (ø)
3.13 aws_deps 45.20% <0.00%> (ø)
3.13 big 55.25% <0.00%> (ø)
3.13 bigquery 51.25% <0.00%> (ø)
3.13 clickhouse 41.97% <0.00%> (ø)
3.13 databricks 53.04% <0.00%> (ø)
3.13 filesystem 64.33% <100.00%> (ø)
3.13 gx-redshift 51.40% <0.00%> (ø)
3.13 mysql 51.80% <0.00%> (ø)
3.13 openpyxl or pyarrow or project or sqlite or aws_creds 59.94% <0.00%> (ø)
3.13 postgresql 55.19% <0.00%> (ø)
3.13 snowflake 53.88% <0.00%> (-0.01%) ⬇️
3.13 spark 55.89% <0.00%> (ø)
3.13 spark_connect 46.86% <0.00%> (ø)
3.13 sql_server 53.22% <0.00%> (ø)
3.13 trino 48.74% <0.00%> (ø)
cloud 0.00% <0.00%> (ø)
docs-basic 59.23% <0.00%> (ø)
docs-creds-needed ?
docs-spark 57.28% <0.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Incorrect description in the HTML report for the ExpectTableColumnsToMatchSet rule (GX v1.*)

3 participants