question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

(aws-cdk-lib): release source maps and files

See original GitHub issue

Describe the feature

See reduce module size RFC and https://github.com/aws/aws-cdk/issues/20320#issuecomment-1140181014.

Submitting a tracking issue for the following feature:

Releasing an additional 2.X.Y-debug package with every release, that will
contain the source maps and source files. In addition to reducing the size of
the aws-cdk-lib package, we want to reduce the volume of artifacts we publish
to npm and other package managers in total. This would be in direct conflict
with that goal by doubling the amount of content that is published on each
release. And, there is currently no demonstrated customer need for a debug
package like this.

Use Case

Today, there’s no way to access the typescript source files from the package downloaded from npm. We haven’t heard from the community that this is a feature that users want to see, but we haven’t been asking either. Please add your +1s and/or comment additional thoughts on this issue.

Proposed Solution

No response

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

CDK version used

2.X

Environment details (OS name and version, etc.)

MacOs

Issue Analytics

  • State:open
  • Created a year ago
  • Reactions:11
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
chris-smith-zocdoccommented, Aug 15, 2022

Agree with Sevi7 that we preferred the previous distribution of aws-cdk-lib (transpiled non-minified source). The module size was not a problem for us. In its current state, debugging is painful which makes finding and fixing bugs in the cdk more difficult.

1reaction
Sevi7commented, Jun 30, 2022

This is a really good idea to have this new package and I really like it. However, having the code minified in the original package (aws-cdk-lib) is in my opinion a bad idea because whenever a developer wants to see an error thrown by aws-cdk-lib and follow the stack trace, the code is unreadable. And consumers using aws-cdk-lib produce many errors (most of the time the code does not deploy at the first time) and the need of being switching packages to use aws-cdk-lib-debug could be quite painful.

Also, consumers who need the package minified will be minifying all their dependencies anyway. I think (and there is a lot of information about this on the internet) it is a best practice to not minify the code of a npm package. The code should be minified by the consumers in a prior step to production.

Read more comments on GitHub >

github_iconTop Results From Across the Web

aws-cdk-lib module - AWS Documentation
AWS Cloud Development Kit Library. The AWS CDK construct library provides APIs to define your CDK application and add CDK constructs to the...
Read more >
Managing dependencies - AWS Documentation
Dependencies for your AWS CDK app or library are managed using package management tools. These tools are commonly used with the programming language...
Read more >
Assets - AWS Cloud Development Kit (AWS CDK) v2
Assets are local files, directories, or Docker images that can be bundled into AWS CDK libraries and apps. For example, an asset might...
Read more >
aws-cdk-lib.pipelines module
CDK Pipelines. A construct library for painless Continuous Delivery of CDK applications. CDK Pipelines is an opinionated construct library.
Read more >
enum SourceMapMode · AWS CDK
map files. INLINE, Inline sourceMap mode - If you want to insert the entire source map into the .js file instead of generating...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found