Skip to content

Maintenance: aws-cdk dependencies in layers-publisher out of sync with main workspace #1227

Closed
@dreamorosi

Description

@dreamorosi

Summary

The layer-publisher folder contains the utilities and tests used to publish AWS Lambda Layers for Powertools. Currently the folder has its own dependency tree and is disconnected from the main one.

We need to realign the versions of the dependencies related to AWS CDK present in the layer-publisher/package-lock.json file with the ones in package-lock.json.

Why is this needed?

Because layer-publisher uses some utilities from packages/commons and they both import modules from aws-cdk-lib. If the two versions don't match (or at least are not close enough), the interfaces/prototypes of the imported classes will be different thus causing errors.

This happened in this e2e test run: https://github.com/awslabs/aws-lambda-powertools-typescript/actions/runs/3893483365

Notice in the errors that the App class from aws-cdk-lib appears to have different implementation/interface between the two imports.

Which area does this relate to?

Automation, Other

Solution

A short term solution that somewhat manually realigns the two dependency trees is proposed in the linked PR. The long term solution would be to make the layers-publisher part of the main npm workspace, an activity that is tracked in #1226.

Acknowledgment

Metadata

Metadata

Assignees

Labels

automationThis item relates to automationcompletedThis item is complete and has been merged/shippedinternalPRs that introduce changes in governance, tech debt and chores (linting setup, baseline, etc.)

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions