Skip to content

[Maintenance] Add filterwarnings("error") to test_func_utils (refs #6408)Add filterwarnings(error) to test_func_utils and fix deprecated warni…#8224

Open
skysabarre wants to merge 1 commit intopymc-devs:v6from
skysabarre:fix/filterwarnings-test-func-utils
Open

Conversation

@skysabarre
Copy link
Copy Markdown

…ng handling

Description

<Adds pytestmark = pytest.mark.filterwarnings("error") to tests/test_func_utils.py as part of the ongoing effort to catch unexpected warnings across the test suite.

This surfaces that tests calling pm.find_constrained_prior were not handling its FutureWarning (the function is deprecated in favor of PreliZ's maxent). Fixed by wrapping calls in pytest.warns(FutureWarning) and using warnings.catch_warnings() to suppress unrelated PyTensor UserWarnings from loop fusion. -->

Related Issue

  • Closes #
  • Related to $6408

Checklist

Type of change

  • New feature / enhancement
  • Bug fix
  • Documentation
  • Maintenance
  • Other (please specify):

@read-the-docs-community
Copy link
Copy Markdown

Documentation build overview

📚 pymc | 🛠️ Build #32013454 | 📁 Comparing 08370bd against latest (0f5c0ca)


🔍 Preview build

Show files changed (24 files in total): 📝 24 modified | ➕ 0 added | ➖ 0 deleted
File Status
glossary.html 📝 modified
contributing/developer_guide.html 📝 modified
_modules/pymc/pytensorf.html 📝 modified
_modules/pymc/testing.html 📝 modified
api/generated/pymc.draw.html 📝 modified
api/generated/pymc.icdf.html 📝 modified
api/generated/pymc.logcdf.html 📝 modified
api/generated/pymc.logp.html 📝 modified
api/generated/pymc.sample_posterior_predictive.html 📝 modified
api/generated/pymc.sample_prior_predictive.html 📝 modified
_modules/pymc/distributions/continuous.html 📝 modified
_modules/pymc/distributions/distribution.html 📝 modified
_modules/pymc/distributions/shape_utils.html 📝 modified
_modules/pymc/logprob/basic.html 📝 modified
_modules/pymc/model/core.html 📝 modified
_modules/pymc/ode/ode.html 📝 modified
_modules/pymc/sampling/forward.html 📝 modified
_modules/pymc/variational/approximations.html 📝 modified
_modules/pymc/variational/operators.html 📝 modified
_modules/pymc/variational/opvi.html 📝 modified
_modules/pytensor/tensor/basic.html 📝 modified
_modules/pytensor/tensor/math.html 📝 modified
api/distributions/generated/classmethods/pymc.SymbolicRandomVariable.update.html 📝 modified
api/model/generated/classmethods/pymc.model.core.Model.compile_fn.html 📝 modified

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant