-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Description
-
Package Name:
azure-eventhub -
Package Version:
5.1.0 -
Operating System:
Linux -
Python Version:
3.8.2
Describe the bug
Existence of emptiness of the file https://github.com/Azure/azure-sdk-for-python/blob/master/sdk/eventhub/azure-eventhub/azure/eventhub/extensions/__init__.py is incompatible with packaging namespaces. It causes problem using this package in Bazel, see dillon-giacoppo/rules_python_external#56
To Reproduce
Steps to reproduce the behavior:
- Go into temporary directory
cd /tmp - Install azure_eventhub under dir1
pip install --target=$(pwd)/dir1 azure_eventhub - Install azure-eventhub-checkpointstoreblob under dir2
pip install --target=$(pwd)/dir2 azure-eventhub-checkpointstoreblob - Create virtual environment
virtualenv venv - Activate virtual environment
source venv/bin/activate - Create main.py
cat > main.py
import sys
sys.path.extend(['/tmp/dir1', '/tmp/dir2'])
from azure.eventhub.extensions.checkpointstoreblob import BlobCheckpointStore
- Execute main.py
python ./main.py - Result is an error:
Traceback (most recent call last):
File "main.py", line 3, in <module>
from azure.eventhub.extensions.checkpointstoreblob import BlobCheckpointStore
ModuleNotFoundError: No module named 'azure.eventhub.extensions.checkpointstoreblob'
Expected behavior
main.py should execute without errors.
Screenshots
N/A
Additional context
The problem emerges because Bazel installs dependencies in separate directories. Current layout, incompatible with packaging namespaces makes it impossible to use in applications build by Bazel, see dillon-giacoppo/rules_python_external#56