diff options
author | Yuqian Yang <crupest@crupest.life> | 2025-02-23 16:40:32 +0800 |
---|---|---|
committer | Yuqian Yang <crupest@crupest.life> | 2025-02-23 16:40:32 +0800 |
commit | 7e54b1ebe280d760347b1b640c9d4d0038ca6c58 (patch) | |
tree | 4d42c7a84066f0c2ae320e32dc7d86072fd0e4ae /services/manager/service/__main__.py | |
parent | 34704b2090c48d9ab9e7458475fd701a38706ae7 (diff) | |
download | crupest-7e54b1ebe280d760347b1b640c9d4d0038ca6c58.tar.gz crupest-7e54b1ebe280d760347b1b640c9d4d0038ca6c58.tar.bz2 crupest-7e54b1ebe280d760347b1b640c9d4d0038ca6c58.zip |
feat(python): move python codes.
Diffstat (limited to 'services/manager/service/__main__.py')
-rw-r--r-- | services/manager/service/__main__.py | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/services/manager/service/__main__.py b/services/manager/service/__main__.py deleted file mode 100644 index 6ea0a8a..0000000 --- a/services/manager/service/__main__.py +++ /dev/null @@ -1,27 +0,0 @@ -import sys - -from manager import CruException - -from ._app import create_app - - -def main(): - app = create_app() - app.run_command() - - -if __name__ == "__main__": - version_info = sys.version_info - if not (version_info.major == 3 and version_info.minor >= 11): - print("This application requires Python 3.11 or later.", file=sys.stderr) - sys.exit(1) - - try: - main() - except CruException as e: - user_message = e.get_user_message() - if user_message is not None: - print(f"Error: {user_message}") - exit(1) - else: - raise |