aws-samples / aws-samples/amazon-textract-textractor

I am missing something... ~/.aws/config and ~/.aws/credentials

Open
#237 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
Jupyter Notebook
Stars
493
Forks
163
PR merge metrics
No merged PRs in 30d

Description

Hello,
I was trying to run examples from this repo. I do not have prior experience with AWS. I am using conda env on Ubuntu 22.04. As per instructions I have installed the package using `pip install "amazon-textract-textractor[dev]"`. Everything got installed without any hitch. Now I wanted to try out the table extractor example.
When I try to run:
`extractor = Textractor(profile_name="default")`

I get the error: **ProfileNotFound: The config profile (default) could not be found**

I found a workaround in one of the issue post: changing the profile_name to region_name
```
extractor = Textractor(region_name='us-west-2')

document = extractor.analyze_document(
file_source=image,
features=[TextractFeatures.TABLES],
save_image=True
)
```
Now when I proceed I get the error: **NoCredentialsError: Unable to locate credentials**

It seems I am missing the ~/.aws/config and ~/.aws/credentials files. Not sure how I was supposed to get them? Do I need to install the aws sdk first?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.