Skip to content

Commit

Permalink
icoscp - convert ImportWarning to UserWarning to avoid extra jupyter …
Browse files Browse the repository at this point in the history
…errors
  • Loading branch information
ZogopZ committed Jun 17, 2024
1 parent 018120e commit cb28ad9
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion icoscp/src/icoscp/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
"""
__credits__ = "ICOS Carbon Portal"
__license__ = ['Software: GPL-3.0', 'ICOS Data accessed with this library CC BY 4.0']
__version__ = "0.2.0a0"
__version__ = "0.2.0a2"
__maintainer__ = "ICOS Carbon Portal, elaborated products team"
__email__ = ['info@icos-cp.eu']
__status__ = "stable"
Expand Down
2 changes: 1 addition & 1 deletion icoscp/src/icoscp/cpb/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@
"Find out more here: "
"https://icos-carbon-portal.github.io/pylib/icoscp/install/#upgrade-guide"
)
warnings.warn(old_dob_warning, UserWarning, stacklevel=2)
warnings.warn(old_dob_warning, UserWarning, stacklevel=2)
4 changes: 2 additions & 2 deletions icoscp/src/icoscp/stilt/__init__.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import warnings

warnings.simplefilter('always', ImportWarning)
warnings.simplefilter('always', UserWarning)
stilt_warning = (
"\nThe icoscp STILT module has been moved to a new dedicated library: "
"https://icos-carbon-portal.github.io/pylib/icoscp_stilt/\n"
'To import it use: "from icoscp_stilt import stilt"'
)
warnings.warn(stilt_warning, ImportWarning, stacklevel=2)
warnings.warn(stilt_warning, UserWarning, stacklevel=2)

0 comments on commit cb28ad9

Please sign in to comment.