--cli-input-json error message very misleading
- Dominant language
- Python
- Stars
- 17.3k
- Forks
- 4.6k
- Avg merge
- 1d 2h
- Merged PRs (30d)
- 13
Description
I am new to aws cli, and recently discovered the --cli-input-json parameters. I admit that I jumped in without fully read the document, but then, when I firstly specified a file name of my JSON document to the parameter (I guess lots programmers will do the same in the first attempt without reading the documentation), as follows:
aws dynamodb create-table --cli-input-json awscli-jsons/dynamodb-create-table-contact.json
The error message I received would be like:
Error parsing parameter 'cli-input-json': Invalid JSON: No JSON object could be decoded
JSON received: awscli-jsons/dynamodb-create-table-contact.json
In every way the message seems like indicates the file format was wrong, not a valid JSON file, and cannot be parsed. I studied the documents from "aws dynamodb create-table help" and still was given no clue. Much time was spent until I find that I should issue the command as:
aws dynamodb create-table --cli-input-json file://awscli-jsons/dynamodb-create-table-contact.json
Firstly, such important information (using file://), which is different from the norm (in most cases we expect providing the file name), should be mentioned in the command help. Then, the error message is very misleading, points to a wrong direction.
Please enhance this behavior.
Thanks
Bing
Contributor guide
Assessment
This issue has not been assessed yet.