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

Update docs to reflect new error wrap pattern #3189

Merged
merged 4 commits into from Dec 14, 2019

Conversation

gidjin
Copy link
Contributor

@gidjin gidjin commented Dec 12, 2019

Description

As of go 1.13 there is a new suggested pattern for wrapping errors. This PR updates the docs to reflect that.

Code Review Verification Steps

  • Request review from a member of a different team.

References

Copy link
Contributor

@tinyels tinyels left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great! I wonder if we should include guidance about how we used to do things and how to update those usages.

@chrisgilmerproj
Copy link
Contributor

I agree with @tinyels - let's have a before and after section that shows folks how we used to do it. Folks are still going to come across the old pattern and will want to know how to update.

@gidjin gidjin added the A-Team label Dec 12, 2019
@gidjin
Copy link
Contributor Author

gidjin commented Dec 12, 2019

That's a good idea, I'll add some details to clarify how to migrate

As the standard just recently changed adding some details about the old
way and how to change it to the new recommendation so it can be updated
as we go along.
@gidjin
Copy link
Contributor Author

gidjin commented Dec 13, 2019

@chrisgilmerproj @tinyels I pushed a change to add some details around the previous recommendation to hopefully reduce confusion as people try to follow the new standard.

Copy link
Contributor

@chrisgilmerproj chrisgilmerproj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@gidjin gidjin merged commit 700e98f into master Dec 14, 2019
@gidjin gidjin deleted the gdjn_update_docs_to_reflect_new_error_wrap_pattern branch December 14, 2019 00:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants