Skip to content

Fix - tablereport plots fail when dataframe contains $$ as values #2154

Merged
rcap107 merged 9 commits into
skrub-data:mainfrom
Michenina-Lab:first_Probabl_hackathon_attempt
Jun 16, 2026
Merged

Fix - tablereport plots fail when dataframe contains $$ as values #2154
rcap107 merged 9 commits into
skrub-data:mainfrom
Michenina-Lab:first_Probabl_hackathon_attempt

Conversation

@Michenina-Lab

@Michenina-Lab Michenina-Lab commented Jun 10, 2026

Copy link
Copy Markdown
Contributor

Bug Fix Pull Request

Description

An error that could arise when generating the frame with reports may fail when text is containing $$ has been fixed.

fixes #2097

Checklist

  • I have read the contributing guidelines
  • I have added tests that verify the bug fix
  • I have added an entry to CHANGES.rst describing the fix
  • My code follows the code style of this project
  • I have checked my code and corrected any misspellings

How Has This Been Tested?

Tested using test_summarize_dataframe.py

@MarieSacksick MarieSacksick added the CFM sprint June 2026 For PRs opened during the CFM sprint in June 2026 label Jun 10, 2026
@rcap107 rcap107 changed the title First probabl hackathon attempt Fix - tablereport plots fail when dataframe contains $$ as values Jun 10, 2026
Comment thread CHANGES.rst Outdated
contains an inner transformer that has a ``score`` method has been fixed.
:pr:`2052` by :user:`Jérôme Dockès <jeromedockes>`.
An error that could arise when generating the frame with reports may fail when text is containing $$ has been fixed.
:pr:`2097` by :user:`Katerina Michenina <Michenina-Lab>`, :user: `<CecilyTS>`, :user: `Eve Rabin <eve2705>`.

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.

2097 is the issue number, not the PR number! This is PR 2154 (cf. URL)

Comment thread CHANGES.rst Outdated
- An error that could arise when calling ``score`` on a ``SkrubLearner`` that
contains an inner transformer that has a ``score`` method has been fixed.
:pr:`2052` by :user:`Jérôme Dockès <jeromedockes>`.
An error that could arise when generating the frame with reports may fail when text is containing $$ has been fixed.

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
An error that could arise when generating the frame with reports may fail when text is containing $$ has been fixed.
An error that could arise when running `TableReport` on dataframes containing
double dollar (`$$`) signs has been fixed.

@rcap107

rcap107 commented Jun 11, 2026

Copy link
Copy Markdown
Member

Hi @Michenina-Lab, as we discussed in the issue this should merge upstream after #2159 is merged and the minimum matplotlib version becomes 3.6. That should let the tests pass.

@rcap107 rcap107 added this to the Release 0.10 milestone Jun 12, 2026
Comment thread skrub/tests/test_summarize_dataframe.py Outdated

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Could you move the test case in in skrub/_reporting/tests/test_summarize.py?

something like this would work:

def test_dollar_sign(df_module):
    df = df_module.make_dataframe(
        {
            "text": [
                "hello world",
                "foo bar",
                "this is not latex $$ just a double dollar sign",
            ]
        }
    )
    summarize_dataframe(df, with_plots=True, title=None, verbose=0)

df_module is needed to make sure that the the tests run with both pandas and polars

then this file can be removed

@jeromedockes jeromedockes left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

thank you @Michenina-Lab !

@Michenina-Lab

Copy link
Copy Markdown
Contributor Author

thank you @Michenina-Lab !

Big thanks for your help and guidance, @jeromedockes, @rcap107, @emassoulie !

@rcap107

rcap107 commented Jun 16, 2026

Copy link
Copy Markdown
Member

Thank you @Michenina-Lab!

@rcap107 rcap107 merged commit c98cc4c into skrub-data:main Jun 16, 2026
29 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CFM sprint June 2026 For PRs opened during the CFM sprint in June 2026

Projects

None yet

Development

Successfully merging this pull request may close these issues.

summarize_dataframe mis-interprets mathematical expression

5 participants