Skip to content

Commit

Permalink
move prometheus-client import
Browse files Browse the repository at this point in the history
  • Loading branch information
jeevb committed Sep 20, 2023
1 parent 054c099 commit e65f6c2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
4 changes: 2 additions & 2 deletions flytekit/clis/sdk_in_container/serve.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
from flyteidl.service.agent_pb2_grpc import add_AsyncAgentServiceServicer_to_server
from grpc import aio

from flytekit.extend.backend.agent_service import AsyncAgentService

_serve_help = """Start a grpc server for the agent service."""


Expand Down Expand Up @@ -47,6 +45,8 @@ async def _start_grpc_server(port: int, worker: int, timeout: int):
try:
from prometheus_client import start_http_server

from flytekit.extend.backend.agent_service import AsyncAgentService

start_http_server(9090)
except ImportError as e:
click.secho(f"Failed to start the prometheus server with error {e}", fg="red")
Expand Down
1 change: 0 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@
"rich",
"rich_click",
"jsonpickle",
"prometheus-client",
],
extras_require=extras_require,
scripts=[
Expand Down

0 comments on commit e65f6c2

Please sign in to comment.