【发布时间】:2019-08-14 20:09:28
【问题描述】:
我想让 aws glue python-shell 作业连接到 MS SQL Server。我知道我应该使用 pymssql 库。在我的计算机上,我的脚本可以运行,但使用 AWS,我知道我需要将 pymssql 库上传到 S3 并引用它。
如果我想连接到 redshift,我正在关注 their example 如何提供您自己的 egg 文件,但在创建 egg 文件并运行脚本后我收到此错误
Couldn't find index page for 'redshift-module' (maybe misspelled?)
谁能帮助提供我如何完成提供自己的库?在 redshift 或 ms sql 中。只是寻找一个我可以适应和工作的例子。
完整的作业日志
Creating /glue/lib/installation/site.py
Processing redshift_module-0.1-py3.7.egg
Copying redshift_module-0.1-py3.7.egg to /glue/lib/installation
Adding redshift-module 0.1 to easy-install.pth file
Installed /glue/lib/installation/redshift_module-0.1-py3.7.egg
Processing dependencies for redshift-module==0.1
Searching for redshift-module==0.1
Reading https://pypi.org/simple/redshift-module/
Scanning index of all packages (this may take a while)
Reading https://pypi.org/simple/
完整的错误输出
Couldn't find index page for 'redshift-module' (maybe misspelled?)
No local packages or working download links found for redshift-module==0.1
error: Could not find suitable distribution for Requirement.parse('redshift-module==0.1')
【问题讨论】:
-
你能试试这个stackoverflow.com/questions/46329561/aws-glue-python/…,让我知道它是否适合你吗?
-
这就是我正在做的。尽管那篇文章是关于 Glue (Apache Spark),但我正在使用 Python-Shell,它们都要求您在作业配置中拥有 S3 中的第三方库。在日志中,我看到它找到了我的 .egg 文件,但没有找到我的库。