Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecations don't seem to be consistently documented well #14401

Closed
jmm opened this issue Apr 27, 2021 · 5 comments
Closed

Deprecations don't seem to be consistently documented well #14401

jmm opened this issue Apr 27, 2021 · 5 comments
Assignees
Labels
documentation This is a problem with documentation. feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged.

Comments

@jmm
Copy link

jmm commented Apr 27, 2021

Hello,

Deprecations don't seem to be consistently documented well.

At least twice today I've come across deprecation icons where there appears to be zero information about why the functionality is deprecated or what should be used instead.

For example, @aws-cdk/aws-lambda :: class Function (construct) :: addVersion().

Furthermore, there's no reference to that method in the changelog, or even an issue or pull request title including the name.

(Please note that despite all of that, I've seen #5334 and #6771)


This is a 📕 documentation issue

@jmm jmm added documentation This is a problem with documentation. feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Apr 27, 2021
@joehillen
Copy link
Contributor

I've noticed the deprecation warning today as well. There is also currentVersionOptions which seems to call lambda.addVersion() but that property doesn't even have a deprecation warning.

The suggested alternative doesn't even work for all cases because you can't use aliases with Lambda@Edge functions.

@jmm
Copy link
Author

jmm commented Apr 29, 2021

@joehillen Thanks for weighing in. I think the idea is that currentVersionOptions will feed into version creation for you when it's automatically detected that a new version is necessary. So that part probably makes sense. But it would be good for the documentation to explain why things are deprecated, in this case why you shouldn't / don't need to call addVersion() manually.

It's tangential, but I was looking at that method when trying to figure out why I was getting an error related to version creation -- which seems to be because the automated detection has a false positive in a certain case and is too eager.

Unfortunately I don't have any context on the issue regarding Lambda@Edge functions, so not sure how that fits in.

@joehillen
Copy link
Contributor

I've also hit the problem in your linked issue with the new EdgeFunction construct which is what lead me to find this issue.

@rix0rrr
Copy link
Contributor

rix0rrr commented May 10, 2021

We used to not properly surface the recommended replacements for deprecated messages in the documentation.

This has been fixed:

image

@rix0rrr rix0rrr closed this as completed May 10, 2021
@github-actions
Copy link

⚠️COMMENT VISIBILITY WARNING⚠️

Comments on closed issues are hard for our team to see.
If you need more assistance, please either tag a team member or open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation This is a problem with documentation. feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged.
Projects
None yet
Development

No branches or pull requests

3 participants