aws / aws/amazon-redshift-python-driver

PackageNotFoundError: scramp when using redshift_connector library in glue

Đang mở
#219 1 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
Python
Star
220
Fork
86
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

In aws glue shell job , i am using a wheel file which has all the libraries needed for aws wrangler, redshift-connector and i do see scramp library part of the wheel file. However when i install this wheel during glue python shell job i am getting the following error event though scramp library is installed.

Glue python version 3.9
aws wrangler version = 3.7.3
redshift-connector version = 2.1.1

I am trying to connect to redshift serverless using the above libraries and here

`

from redshift_connector.core import BINARY, Connection, Cursor File "/glue/lib/installation/redshift_connector/core.py", line 18, in | from redshift_connector.core import BINARY, Connection, Cursor File "/glue/lib/installation/redshift_connector/core.py", line 18, in
-- | --

from scramp import ScramClient # type: ignore File "/glue/lib/installation/scramp/__init__.py", line 12, in |

__version__ = version("scramp") File "/.pyenv/versions/3.9.10/lib/python3.9/importlib/metadata.py", line 560, in version |  
 
return Distribution.from_name(distribution_name) File "/.pyenv/versions/3.9.10/lib/python3.9/importlib/metadata.py",

"/.pyenv/versions/3.9.10/lib/python3.9/importlib/metadata.py", line 187, in from_name

raise PackageNotFoundError(name) importlib.metadata.PackageNotFoundError: scramp

`

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Hướng nghiên cứu

Start by reproducing the Glue Python 3.9 installation with aws wrangler 3.7.3, redshift-connector 2.1.1, and the supplied wheel. Inspect redshift_connector/core.py, scramp/__init__.py, and Python's importlib.metadata lookup to compare the installed files with the distribution metadata. Done means the connector imports successfully and can proceed to the reported Redshift Serverless connection.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
aws, python
Lĩnh vực
databases
Loại issue
Lỗi
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Cần làm rõ
Mức phù hợp với người mới
25/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.