Skip to content

Commit fc31a51

Browse files
fix: ignore setuptools warning (#1239)
1 parent 761f67e commit fc31a51

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

deploy/sdk/src/dynamo/sdk/__init__.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,17 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515

16+
import warnings
1617
from typing import Any
1718

19+
# Suppress warning from setuptools caused by bentoml
20+
# TODO: Remove this line after the bentoml import is removed from this file
21+
warnings.filterwarnings("ignore", category=UserWarning, message=".*pkg_resources.*")
22+
23+
# flake8: noqa: E402
1824
from bentoml import on_shutdown as async_on_shutdown
1925

26+
# flake8: noqa: E402
2027
from dynamo.sdk.core.decorators.endpoint import api, endpoint
2128
from dynamo.sdk.core.lib import DYNAMO_IMAGE, depends, liveness, readiness, service
2229
from dynamo.sdk.lib.decorators import async_on_start

0 commit comments

Comments
 (0)