I have added a python package that relies on platform-specific code (e.g. confluent_kakfa). When I build and run the image, I get the error:
Traceback (most recent call last):
File "/foo/foo.runfiles/_main/foo/main.py", line 2, in <module>
from confluent_kafka import Producer
File "/foo/foo.runfiles/rules_python~0.31.0~pip~pip_311_confluent_kafka/site-packages/confluent_kafka/__init__.py", line 19, in <module>
from .deserializing_consumer import DeserializingConsumer
File "/foo/foo.runfiles/rules_python~0.31.0~pip~pip_311_confluent_kafka/site-packages/confluent_kafka/deserializing_consumer.py", line 19, in <module>
from confluent_kafka.cimpl import Consumer as _ConsumerImpl
ModuleNotFoundError: No module named 'confluent_kafka.cimpl'
Which suggests that this package is set up for the wrong architecture in the image. This happens if I build with the platform set.
I'm assuming this happens because the pip dependencies are generated on the host machine, correct? Or is something else going on here?
Any ideas on how this could be fixed?
I have added a python package that relies on platform-specific code (e.g.
confluent_kakfa). When I build and run the image, I get the error:Which suggests that this package is set up for the wrong architecture in the image. This happens if I build with the platform set.
I'm assuming this happens because the pip dependencies are generated on the host machine, correct? Or is something else going on here?
Any ideas on how this could be fixed?