Invalid Language values for ListCuratedEnvironmentImages output

0

The CodeBuild ListCuratedEnvironmentImages API method generates an array of EnvironmentPlatform objects. These objects have a language property, with an incorrect list of Valid Values:

  • Expected: JAVA | PYTHON | NODE_JS | RUBY | GOLANG | DOCKER | ANDROID | DOTNET | BASE | PHP
  • Actual: BASE | DOTNET | GOLANG | JAVA | NODE_JS | PYTHON | RUBY | STANDARD
$ aws codebuild list-curated-environment-images | jq '.platforms[].languages | flatten | map(.language)' | jq -s 'reduce .[] as $x ([]; . + $x) | unique | sort | join(" | ")'
"BASE | DOTNET | GOLANG | JAVA | NODE_JS | PYTHON | RUBY | STANDARD"

Of note, the STANDARD value is missing for the documentation.

This incorrect definition also causes invalid enumerations and typings for the AWS JS SDK v3 (see generated type):

Type '"STANDARD"' is not comparable to type 'LanguageType | undefined'.ts(2678)

I have also submitted a feedback form for the corresponding documentation page

nmussy
已提問 2 個月前檢視次數 146 次
1 個回答
-1

The list of valid values for the language property of EnvironmentPlatform objects returned by the CodeBuild ListCuratedEnvironmentImages API has changed. According to the AWS CodeBuild API reference documentation, the valid values are:

  • JAVA
  • PYTHON
  • NODE_JS
  • RUBY
  • GOLANG
  • DOCKER
  • ANDROID
  • DOTNET
  • BASE
  • PHP
profile picture
專家
已回答 2 個月前
  • The STANDARD value is missing from this list of valid values, whilst being a part of the ListCuratedEnvironmentImages output:

    $ aws codebuild list-curated-environment-images | jq '.platforms[] | select(.platform == "AMAZON_LINUX_2") | .languages[] | select (.language == "STANDARD")'

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南