Skip to content

Commit

Permalink
add control over prerelease
Browse files Browse the repository at this point in the history
  • Loading branch information
jackaraz committed Jun 21, 2024
1 parent d04b8f9 commit dcc29b8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/spey/_version.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
"""Version number (major.minor.patch[-label])"""

__version__ = "0.1.10"
__version__ = "0.1.10-beta"
7 changes: 6 additions & 1 deletion src/spey/system/webutils.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,12 @@ def check_updates() -> None:
version = __version__
if pypi_version:
log.debug(f"Curernt version {version}, latest version {pypi_version}.")
if Version(version) < Version(pypi_version):
if "beta" in Version(version).prerelease:
log.warning(
f"A prerelease version of Spey is in use: {version}. "
f"Latest stable version is {pypi_version}."
)
elif Version(version) < Version(pypi_version):
log.warning(
f"A newer version ({pypi_version}) of Spey is available. "
f"Current version is {version}."
Expand Down

0 comments on commit dcc29b8

Please sign in to comment.