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

Proposal: errors: merge github.com/pkg/errors #16968

Closed
fawick opened this issue Sep 2, 2016 · 6 comments
Closed

Proposal: errors: merge github.com/pkg/errors #16968

fawick opened this issue Sep 2, 2016 · 6 comments
Labels
error-handling Language & library change proposals that are about error handling. FrozenDueToAge Proposal v2 A language change or incompatible library change
Milestone

Comments

@fawick
Copy link
Contributor

fawick commented Sep 2, 2016

I think that the API suggested by @davecheney in his GopherContalk and implemented in the repo github.com/pkg/errors should be integrated into the errors package of the standard lib.

I learned that this is already his plan [1], but failed to find an issue or proposal here to track the progress, hence I created this one.

[1] https://twitter.com/davecheney/status/771688315573579778

@bradfitz bradfitz changed the title errors: Merge github.com/pkg/errors Proposal: merge github.com/pkg/errors Sep 2, 2016
@bradfitz bradfitz added this to the Proposal milestone Sep 2, 2016
@ericlagergren
Copy link
Contributor

I very much like @davecheney's const error suggestion (type Error string) he's made before and I wish that could make it into the stdlib. (Obviously for Go 2...)

I'm not sure I would care for Errorf gathering a stack trace. It's handy in some situations, that seems like unnecessary overhead for the general case.

Perhaps I just do not see what benefits this provides. It seems more like a debugging tool, imo.

@SamWhited
Copy link
Member

SamWhited commented Sep 2, 2016

Perhaps I just do not see what benefits this provides. It seems more like a debugging tool, imo.

You seem to have answered your own question. It is a debugging tool, and that is the benefit it provides.

@ericlagergren
Copy link
Contributor

@SamWhited sorry, I wasn't as clear as I should've been.

I do not see what benefits this provides for the errors package the way the it is currently structured. I wouldn't mind something like NewWithStackTrace (obviously with a much better name).

@minux minux changed the title Proposal: merge github.com/pkg/errors Proposal: errors: merge github.com/pkg/errors Sep 11, 2016
@bradfitz
Copy link
Contributor

As @davecheney said (https://twitter.com/davecheney/status/771688315573579778), the bar to entry for the standard library is very high.

I would ask for Dave to write a more formal design document and enter the proposal process, but I can say at this point that the likelihood of this happening is close to zero. I agree we should do something more about errors, but it's more of a Go2 item.

I'm going to close this for now.

@bradfitz bradfitz modified the milestones: Unplanned, Proposal Oct 24, 2016
@bradfitz bradfitz added Proposal-Declined v2 A language change or incompatible library change labels Oct 24, 2016
@adg
Copy link
Contributor

adg commented Oct 24, 2016

Related to #15192

@davecheney
Copy link
Contributor

Agreed.

On Tue, Oct 25, 2016 at 9:16 AM, Brad Fitzpatrick notifications@github.com
wrote:

Closed #16968 #16968.


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#16968 (comment), or mute the
thread
https://github.com/notifications/unsubscribe-auth/AAAcA7Xfvb-5NKKempdFMSz_eFAld7Y1ks5q3S4sgaJpZM4JzrxI
.

@golang golang locked and limited conversation to collaborators Oct 25, 2017
@bradfitz bradfitz added the error-handling Language & library change proposals that are about error handling. label Oct 29, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
error-handling Language & library change proposals that are about error handling. FrozenDueToAge Proposal v2 A language change or incompatible library change
Projects
None yet
Development

No branches or pull requests

7 participants