Skip to content

x/xerrors: clarify documentation around stack frames #34349

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

Closed
samcgardner opened this issue Sep 17, 2019 · 4 comments
Closed

x/xerrors: clarify documentation around stack frames #34349

samcgardner opened this issue Sep 17, 2019 · 4 comments
Labels
Documentation Issues describing a change to documentation. FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone

Comments

@samcgardner
Copy link

The docs for the x/xerrors package currently state

Most of the functions and types in this package will be incorporated into the standard library's errors package in Go 1.13; the behavior of this package's Errorf function will be incorporated into the standard library's fmt.Errorf. 

This is not accurate. fmt.Errorf does not provide the stack-trace functionality of xerrors.Errorf. Accordingly, I would suggest changing this docstring to

Most of the functions and types in this package have been incorporated into the standard library's errors package in Go 1.13. However, if you wish to retain the stack trace functionality of `xerrors.Errorf`, you will need to keep using this package.
@gopherbot gopherbot added this to the Unreleased milestone Sep 17, 2019
@toothrot toothrot changed the title x/xerrors Misleading Docstring x/xerrors: clarify documentation around stack frames Sep 17, 2019
@gopherbot gopherbot added the Documentation Issues describing a change to documentation. label Sep 17, 2019
@toothrot toothrot added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Sep 17, 2019
@toothrot
Copy link
Contributor

/cc @jba @neild @mpvl who may be able to help improve the phrasing.

@flibustenet
Copy link

Is there an issue to follow if stack trace will be part of go1.14 ?

@jba
Copy link
Contributor

jba commented Oct 5, 2019

I wrote https://go-review.googlesource.com/c/xerrors/+/199317 to update the doc.

We have no work on errors planned for 1.14. We're going to wait a cycle.

@ALTree
Copy link
Member

ALTree commented Jul 20, 2020

This was fixed in Cl 199317 but the bot didn't close here (because the commit is in the xerrors repo but it references the issue without a golang/go prefix). Closing.

@ALTree ALTree closed this as completed Jul 20, 2020
@golang golang locked and limited conversation to collaborators Jul 20, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Documentation Issues describing a change to documentation. FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Projects
None yet
Development

No branches or pull requests

6 participants