Compile errors of user of @aws-crypto/material-management with TypeScript 3.7.2 · Issue #232 · aws/aws-encryption-sdk-javascript · GitHub
Skip to content

Compile errors of user of @aws-crypto/material-management with TypeScript 3.7.2 #232

Closed

Description

@ankon

With @aws-crypto/client-node 1.0.1, TypeScript 3.7.2, on NodeJS 12.13.0 I'm getting this error when compiling our own sources:

> tsc && tsc -p tsconfig.es6.json

node_modules/@aws-crypto/material-management-node/build/main/node_cryptographic_materials_manager.d.ts:3:21 - error TS2440: Import declaration conflicts with local declaration of 'NodeEncryptionMaterial'.

3 NodeAlgorithmSuite, NodeEncryptionMaterial, NodeDecryptionMaterial, KeyringNode, GetEncryptionMaterials, GetDecryptMaterials } from '@aws-crypto/material-management';
                      ~~~~~~~~~~~~~~~~~~~~~~

node_modules/@aws-crypto/material-management-node/build/main/node_cryptographic_materials_manager.d.ts:3:45 - error TS2440: Import declaration conflicts with local declaration of 'NodeDecryptionMaterial'.

3 NodeAlgorithmSuite, NodeEncryptionMaterial, NodeDecryptionMaterial, KeyringNode, GetEncryptionMaterials, GetDecryptMaterials } from '@aws-crypto/material-management';
                                              ~~~~~~~~~~~~~~~~~~~~~~


Found 2 errors.

tsconfig.json:

{
	"extends": "./tsconfig.base.json",
	"compilerOptions": {
		"outDir": "dist"
	}
}

tsconfig.es6.json:

{
	"extends": "./tsconfig.base.json",
	"compilerOptions": {
		"module": "es2015",
		"outDir": "dist.es6"
	}
}

tsconfig.base.json:

{
	"extends": "tsconfig-collaborne",
	"compilerOptions": {
		"declaration": true
	},
	"include": [
		"src"
	]
}

(https://github.com/Collaborne/tsconfig-collaborne/blob/master/tsconfig.json has "tsconfig-collaborne")

Activity

  1. ankon commented on Nov 6, 2019

    @ankon
    Author

    Changing NodeJS to 10.16 doesn't change things.
    Changing TypeScript to 3.6.4 "fixes" the compile error.

  2. seebees commented on Nov 6, 2019

    @seebees
    Contributor

    Thanks for the report!

  3. added 3 commits that reference this issue on Nov 6, 2019
    0332426
    84c77d2
    6ffab03
  4. added a commit that references this issue on Nov 7, 2019
    4818074
  5. ankon commented on Nov 12, 2019

    @ankon
    Author

    If I may ask, what is the rough timeline for a release of the SDK with the fix for that problem?

  6. seebees commented on Nov 12, 2019

    @seebees
    Contributor

    @ankon Released to npm :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions