Skip to content

Conversation

@Nikhil-Narayanan
Copy link
Contributor

@Nikhil-Narayanan Nikhil-Narayanan commented Oct 26, 2025

@Nikhil-Narayanan
Copy link
Contributor Author

image failing test when doing mutation in [core/reshape/tile.py:387](https://github.com/pandas-dev/pandas/blob/v2.2.1/pandas/core/reshape/tile.py#L387)

mx += 0.001 * abs(mx) if mx != 0 else 0.001
mx += 0.001 / abs(mx) if mx != 0 else 0.001

And it passes when the mutation doesn't exist as seen in CI

def test_single_bin_edge_adjustment():
# gh-58517 - test edge adjustment when all values are the same
# mutation on _nbins_to_bins
data = [0.1, 0.1, 0.1]
Copy link
Member

Choose a reason for hiding this comment

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

Could you use pytest.mark.parameterize with data, data_neg and data_tiny?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ooh thank you! My bad

@mroeschke mroeschke added the Testing pandas testing functions or related to the test suite label Oct 27, 2025
@mroeschke mroeschke added this to the 3.0 milestone Oct 29, 2025
@mroeschke mroeschke merged commit f8dea12 into pandas-dev:main Oct 29, 2025
42 checks passed
@mroeschke
Copy link
Member

Thanks @Nikhil-Narayanan

@Nikhil-Narayanan Nikhil-Narayanan deleted the tile-muttest branch October 29, 2025 16:52
zhangbowen-coder pushed a commit to zhangbowen-coder/pandas that referenced this pull request Oct 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Testing pandas testing functions or related to the test suite

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants