AWS glue is not importing s3fs module
import s3fs
I expect the library to be imported but AWS glue says
ImportError : No module named s3fs
AWS glue is not importing s3fs module
import s3fs
I expect the library to be imported but AWS glue says
ImportError : No module named s3fs
AWS Glue jobs come with some common libraries pre installed but for anything more than that you need to download the .whl
for the library from pypi, which in the case of s3fs
can be found here.
Once you have that, upload it to an s3 bucket, eg. s3://my-libraries/
and reference it in the Python library path
field in the console.
This will prompt Glue to install the libraries within this bucket prior to running the script. Note that only pure python libraries are support currently.
s3fs is only included in Glue 2.0 and up. If you are trying to use this in a Python shell Glue job which uses Glue 1.0, you'll have to provide the whl file for s3fs as Sherlock mentioned above.
Here is a list of the default packages for Python Shell jobs https://docs.aws.amazon.com/glue/latest/dg/add-job-python.html#python-shell-supported-library
© 2022 - 2024 — McMap. All rights reserved.