BentoML
BentoML copied to clipboard
fix: Path issues with pip modules
trafficstars
Always prepend current bentofile directory to system path to avoid unwanted behavior when other bentofiles are on the system PATH This is especially evident when trying to use bentoml cli on python folders that are also pip modules see https://github.com/bentoml/BentoML/issues/4217
we probably should note the side effect of doing this here
- If there is a package/folder named grpc, it will override the default
grpcimport, which makesserve-grpcnot working - the same as
schema, or literally any folder that have the same name as package module imports.