You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Feb 28, 2024. It is now read-only.
Need to decorate an error message a bit as the below is confusing.
The situation where LDB needs to access s3 but can't due to expired access token is common, so it should give ready instructions, along the lines of "please check S3 credentials"
Here the read-add location is on S3 for which the token is expired:
ldb index --format bare /Users/dkh/Downloads/wine_cancellation.png
Data format: bare-pairs
Indexing paths...
Unable to finish indexing. Partial indexing results:
Found data objects: 0
Found annotations: 0
New data objects: 0
New annotations: 0
New data object paths: 0
ERROR: OSError: [Errno 22] The provided token is malformed or otherwise invalid.
The text was updated successfully, but these errors were encountered:
An s3 credentials error when indexing a local path would typically come from an s3 location configured as the read-add storage location.
Steps to reproduce a similar error:
Create an aws config with a malformed token. For example, if valid credentials exist at ~/.aws/credentials for a profile configured with mfa, copy this file to a temporary location like ~/tmp/aws/credentials and add a few characters to the end of the aws_session_token value.
ldb index s3://ldb-public/remote/data-lakes/dogs-and-cats -vv
s3fs catches botocore's base ClientError (i.e. any botocore error) and uses s3fs.errors.translate_boto_error to translate to a generic python error like OSError. This also typically sets the __cause__ attribute, so a general solution could be to catch exceptions, check for a __cause__ where isinstance on ClientError is true and add a message about it being an aws/s3 error. It could also make sense to link to: https://boto3.amazonaws.com/v1/documentation/api/latest/guide/quickstart.html#configuration
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Need to decorate an error message a bit as the below is confusing.
The situation where LDB needs to access s3 but can't due to expired access token is common, so it should give ready instructions, along the lines of "please check S3 credentials"
Here the read-add location is on S3 for which the token is expired:
The text was updated successfully, but these errors were encountered: