8000 Revert to using warnings.warn by ijpulidos · Pull Request #790 · choderalab/openmmtools · GitHub
[go: up one dir, main page]

Skip to content

Revert to using warnings.warn - #790

Merged
ijpulidos merged 1 commit into
mainfrom
fix-warnings-warn
Sep 5, 2025
Merged

ijpulidos merged 1 commit into
mainfrom
fix-warnings-warn

Conversation

@ijpulidos
Copy link
Copy Markdown
Contributor

Description

The warnings module doesn't have a warnings.warning. This was changed by mistake in #788 . My guess is that it tried to fix the logging.warn deprecation but it hit these undesired warnings.warn matches. Just something to keep in mind in the future.

Here all the instances of warnings.warning are reverted back to use warnings.warn, this should solve it.

Solves #789

Todos

  • Implement feature / fix bug
  • Add tests
  • Update documentation as needed
  • Update changelog to summarize changes in behavior, enhancements, and bugfixes implemented in this PR

Status

  • Ready to go

Changelog message

Revert to using the correct `warnings.warn` API for warning messages.

@codecov
codecov Bot commented Sep 5, 2025 •
Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 8 lines in your changes missing coverage. Please review.
✅ Project coverage is 85.28%. Comparing base (c2f3e70) to head (b1b97fe).
⚠️ Report is 4 commits behind head on main.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ijpulidos
ijpulidos enabled auto-merge (squash) September 5, 2025 04:35
@ijpulidos
ijpulidos merged commit 7794452 into main Sep 5, 2025
@ijpulidos
ijpulidos deleted the fix-warnings-warn branch September 5, 2025 19:59
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.

AttributeError: module 'warnings' has no attribute 'warning' in 0.25.1

2 participants

0