This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def catch_exception(func): | |
def inner_function(*args, **kwargs): | |
# return func(*args, **kwargs) | |
try: | |
return func(*args, **kwargs) | |
except grpc._channel._InactiveRpcError as e: | |
# print(e.details()) | |
# print(args, kwargs) | |
args[2].abort(e.code(), details=f"Greeter:{func.__name__} -> {e.details()}") | |
# raise Exception(f"Greeter: {e.code()}-{e.details()}") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from __future__ import annotations | |
import signal | |
import sys | |
from types import FrameType | |
from typing import Optional | |
import loguru | |
from loguru import logger as _logger |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" Vim color file | |
" intellij | |
" Created by chiendo97 with ThemeCreator (https://github.com/mswift42/themecreator) | |
hi clear | |
if exists("syntax on") | |
syntax reset | |
endif |