Closed joguSD closed 7 years ago
Approach looks fine. I just had a few questions. Parameter translation based off model traversal has a fair amount of edge cases and there is a bunch of places in botocore where we do it so I would make sure you take a look at those. The places we do it notably is: serializers, response parsers, and documentation.
It really is a shame that we can't use the CLI, but this is a fairly well known problem as Kyle mentioned. Looks good for the most part, just a few small comments.
_____|\
_.--| SSt |:
<____|.----||
.---''---,
;..__..' _...
,'/ ;|/..--'' \
,'_/.-/': :
_..-'''/ / | \ \ _|/|
\ /-./_ \; \ \,;' \
,\ / \: `:\ \ // `:`.
,' \ /-._; | : : :: ,. .
,' :: /`-._| | | || ' : `.`.)
_,' |;._:: | | | | `| : `'
,' `. / |`-:_ ; | | | : \
`--. ) /|-._: : | \ \
/ / :_| ;`-._; __..--'; : :
/ ( ;|;-./_ _/.-:'o | / ' |
/ , \._/_/_./--''/_|:|___|_,' |
: / `'-'--'----'---------' |
| : O ._O O_. O ._O O_. ; ;
: `. // // // // ,' /
~~~`.______//____//____//____//_______,'~
// //~ // //
~~ _// _// _// ~ _// ~
~ / / / / / / / / ~ ~~
~~~ ~~~ ~~~ ~~~
Looks good. I am not sure about a better name than coerce but :ship: if you can't think of a better name either.
This pull requests adds a basic framework for coercing parameters into the correct type. Input taken from prompts will always be strings and for some basic types it is easy enough to cast them implicitly rather than having to define explicitly what type it is in the wizard specification or have a custom interaction.