Skip to content

Commit

Permalink
Merge pull request aws#7274 from aws/huijbers/hotfix-1.32.1
Browse files Browse the repository at this point in the history
See CHANGELOG.md
  • Loading branch information
mergify[bot] authored Apr 9, 2020
2 parents 9766ad6 + b10fd92 commit d0dfe79
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 2 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@

All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.

## [1.32.1](https://github.com/aws/aws-cdk/compare/v1.32.0...v1.32.1) (2020-04-09)


### Bug Fixes

* **iam:** new IAM Condition type is unusable in Java ([#7270](https://github.com/aws/aws-cdk/issues/7270)) ([85f606a](https://github.com/aws/aws-cdk/commit/85f606ad13e4e51b9f66330379a55ef76310a8ca))

## [1.32.0](https://github.com/aws/aws-cdk/compare/v1.31.0...v1.32.0) (2020-04-07)


Expand Down
3 changes: 3 additions & 0 deletions allowed-breaking-changes.txt
Original file line number Diff line number Diff line change
Expand Up @@ -46,3 +46,6 @@ incompatible-argument:@aws-cdk/aws-iam.PolicyStatement.addCondition
incompatible-argument:@aws-cdk/aws-iam.PolicyStatement.addConditions
incompatible-argument:@aws-cdk/aws-iam.PolicyStatement.addFederatedPrincipal
incompatible-argument:@aws-cdk/aws-iam.PrincipalPolicyFragment.<initializer>
changed-type:@aws-cdk/aws-iam.FederatedPrincipal.conditions
changed-type:@aws-cdk/aws-iam.PrincipalPolicyFragment.conditions
changed-type:@aws-cdk/aws-iam.PrincipalWithConditions.conditions
2 changes: 1 addition & 1 deletion lerna.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@
"tools/*"
],
"rejectCycles": "true",
"version": "1.32.0"
"version": "1.32.1"
}
14 changes: 13 additions & 1 deletion packages/@aws-cdk/aws-iam/lib/policy-statement.ts
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,19 @@ export enum Effect {
* Condition for when an IAM policy is in effect. Maps from the keys in a request's context to
* a string value or array of string values. See the Conditions interface for more details.
*/
export type Condition = Record<string, any>;
export type Condition = any;

// NOTE! We'd ideally like to type this as `Record<string, any>`, because the
// API expects a map which can take either strings or lists of strings.
//
// However, if we were to change this right now, the Java bindings for CDK would
// emit a type of `Map<String, Object>`, but the most common types people would
// instantiate would be an `ImmutableMap<String, String>` which would not be
// assignable to `Map<String, Object>`. The types don't have a built-in notion
// of co-contravariance, you have to indicate that on the type. So jsii would first
// need to emit the type as `Map<String, ? extends Object>`.
//
// Feature request in https://github.com/aws/jsii/issues/1517

/**
* Conditions for when an IAM Policy is in effect, specified in the following structure:
Expand Down

0 comments on commit d0dfe79

Please sign in to comment.