chiefbiiko / dynamodb

deno <3 dynamodb
MIT License
25 stars 11 forks source link

error deriving credentials #9

Closed mbonig closed 4 years ago

mbonig commented 4 years ago

Right now I have access keys setup in a standard (default) profile in my ~/.aws/config and ~/.aws/credentials files. When I use the get-aws-config dependency directly I can see it properly retrieving all my credential information correctly. However, when trying to .createClient I get this error:

error: Uncaught Error: unable to derive aws config

Here at this line: https://github.com/chiefbiiko/dynamodb/blob/master/client/derive_config.ts#L27

Looking through the current code it looks like the derive_config.ts is expecting access key and secret to sit on a "credentials" field, where 'got' currently returns those directly on the return object.

chiefbiiko commented 4 years ago

thanks, good catch! if u r currently on this make sure to update dynamodb/deps.ts to import get-aws-config@v0.3.2 that version has some related patches but definitely, the got.credentials thing is just wrong

mbonig commented 4 years ago

Submitted a PR:

https://github.com/chiefbiiko/dynamodb/pull/10/files

Please review my comments. I think there are more changes that need to be made first.

chiefbiiko commented 4 years ago

Fixed in v0.3.0