Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add minimum compatible version to --version command #8184

Merged
merged 10 commits into from
Mar 12, 2021
1 change: 1 addition & 0 deletions changelog/7477.enhancement.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Add minimum compatible version to --version command
16 changes: 9 additions & 7 deletions rasa/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import sys

from rasa_sdk import __version__ as rasa_sdk_version
from rasa.constants import MINIMUM_COMPATIBLE_VERSION

import rasa.telemetry
import rasa.utils.io
Expand Down Expand Up @@ -82,16 +83,17 @@ def print_version() -> None:
except ModuleNotFoundError:
rasa_x_info = None

print(f"Rasa Version : {version.__version__}")
print(f"Rasa SDK Version : {rasa_sdk_version}")
print(f"Rasa X Version : {rasa_x_info}")
print(f"Python Version : {platform.python_version()}")
print(f"Operating System : {platform.platform()}")
print(f"Python Path : {sys.executable}")
print(f"Rasa Version : {version.__version__}")
print(f"Minimum Compatible Version: {MINIMUM_COMPATIBLE_VERSION}")
print(f"Rasa SDK Version : {rasa_sdk_version}")
print(f"Rasa X Version : {rasa_x_info}")
print(f"Python Version : {platform.python_version()}")
print(f"Operating System : {platform.platform()}")
print(f"Python Path : {sys.executable}")


def main() -> None:
# Running as standalone python application
"""Running as standalone python application"""
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"""Running as standalone python application"""
"""Run as standalone python application"""

By convention we use the imperative


parse_last_positional_argument_as_model_path()
arg_parser = create_argument_parser()
Expand Down