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

pytorch/torchserve-kfs:0.7.1 No module named 'tornado' #2123

Closed
phlo46 opened this issue Feb 13, 2023 · 1 comment
Closed

pytorch/torchserve-kfs:0.7.1 No module named 'tornado' #2123

phlo46 opened this issue Feb 13, 2023 · 1 comment
Assignees
Labels
bug Something isn't working docker kubernetes triaged Issue has been reviewed and triaged

Comments

@phlo46
Copy link

phlo46 commented Feb 13, 2023

🐛 Describe the bug

No module named 'tornado' on image pytorch/torchserve-kfs:0.7.1

The tornado package is needed for using with KServe.

Error logs

File "/home/model-server/kserve_wrapper/__main__.py", line 7, in <module>
from TorchserveModel import TorchserveModel
File "/home/model-server/kserve_wrapper/TorchserveModel.py", line 9, in <module>
import tornado.web
ModuleNotFoundError: No module named 'tornado'

Installation instructions

Install torchserve from source: No
Using Docker: Yes. Pulling the image from dockerhub.

Model Packaing

.

config.properties

No response

Versions

.

Repro instructions

docker pull pytorch/torchserve-kfs:0.7.1

docker run -it --rm pytorch/torchserve-kfs:0.7.1 bash

pip show tornado

Possible Solution

No response

@msaroufim
Copy link
Member

Ok there are 2 separate problems here

  1. we don't test our kserve code in CI and really should
  2. I'm not convinced we need the tornado dependency if it's only use case is raising HTTP errors

But the workaround should be easy, either build the kserve images from scratch by adding tornado here https://github.com/pytorch/serve/blob/master/kubernetes/kserve/requirements.txt

Or create a new dockerfile with this in it

FROM pytorch/torchserve-kfs:0.7.1
RUN pip install tornado

Build the image and then run it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working docker kubernetes triaged Issue has been reviewed and triaged
Projects
None yet
Development

No branches or pull requests

3 participants