Skip to content

Handle deprecation warnings from all sources consistently in Python#796

Merged
bryanwweber merged 2 commits intoCantera:masterfrom
speth:fix-python-warnings
Feb 12, 2020
Merged

Handle deprecation warnings from all sources consistently in Python#796
bryanwweber merged 2 commits intoCantera:masterfrom
speth:fix-python-warnings

Conversation

@speth
Copy link
Copy Markdown
Member

@speth speth commented Jan 17, 2020

Checklist

  • There is a clear use-case for this code change
  • The commit message has a short title & references relevant issues
  • Build passes (scons build & scons test) and unit tests address code coverage
  • The pull request is ready for review

If applicable, fill in the issue number this pull request is fixing

Fixes #791

Changes proposed in this pull request

Since deprecation warnings issued from C++ and from Cython code are shown by default, set deprecation warnings issued from Python code to do the same.

Also, modify handling of Cython- and Python- issued deprecation warnings when calling the make_deprecation_warnings_fatal and suppress_deprecation_warnings functions.

speth added 2 commits February 9, 2020 23:15
Since deprecation warnings issued from C++ and from Cython code are shown by
default, set deprecation warnings issued from Python code to do the same.

Also, modify handling of Cython- and Python- issued deprecation warnings when
calling the make_deprecation_warnings_fatal and suppress_deprecation_warnings
functions.
Since tests like test_composite.TestModels.test_load_thermo_models rely on
deprecation warnings being fatal, we need to make sure that this setting is
always enabled. Previously, running the tests using "python -m unittest" instead
of the runCythonTests.py script did not do this.

Fixes Cantera#802
@speth speth force-pushed the fix-python-warnings branch from 53d5801 to f99ae3c Compare February 10, 2020 04:15
@codecov
Copy link
Copy Markdown

codecov bot commented Feb 10, 2020

Codecov Report

Merging #796 into master will not change coverage by %.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #796   +/-   ##
=======================================
  Coverage   71.54%   71.54%           
=======================================
  Files         372      372           
  Lines       44348    44348           
=======================================
  Hits        31730    31730           
  Misses      12618    12618           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 53eca8e...f99ae3c. Read the comment docs.

@bryanwweber bryanwweber merged commit 4657df5 into Cantera:master Feb 12, 2020
speth added a commit to speth/cantera that referenced this pull request Feb 12, 2020
speth added a commit to speth/cantera that referenced this pull request Feb 12, 2020
ischoegl pushed a commit to ischoegl/cantera that referenced this pull request Feb 12, 2020
speth added a commit that referenced this pull request Feb 13, 2020
srikanthallu pushed a commit to srikanthallu/cantera that referenced this pull request Sep 17, 2020
@speth speth deleted the fix-python-warnings branch March 20, 2023 01:23
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.

Deprecation warnings not raised for SolutionArray methods

2 participants