text
stringlengths
0
2.35k
[2977.10 --> 2983.86] I feel like none have been as potentially impactful as the TriProposal was.
[2983.98 --> 2994.84] And I was sad to see it pulled back because I think error handling properly is really important to writing good code, good Go code.
[2995.50 --> 3002.50] And I think the language ergonomics should encourage people to handle their errors properly.
[3002.50 --> 3013.04] And so often people will just, if error does not equal nil, return error and just not think about what they're doing with their errors.
[3013.38 --> 3027.90] And I feel like Tri gave an opportunity to think a little bit harder about wrapping errors properly and what to do with errors and kind of nudged people to do the right thing a little bit more.
[3027.90 --> 3035.18] And certainly the proposal, as it was, needed more work before it should go in.
[3035.58 --> 3042.70] But I really do think we should bring back the TriProposal and keep working on it and make it better.
[3043.10 --> 3047.62] I don't know when we'll have the bandwidth for another big language change like that.
[3047.92 --> 3049.64] I have to agree with Michael.
[3049.64 --> 3056.74] I think the reason the TriProposal got so much bad feedback is sort of the, because Go is so opinionated,
[3056.92 --> 3061.40] a lot of its users have gone into this mentality of Go doesn't need features.
[3061.92 --> 3071.56] So sometimes the users can have this knee-jerk reaction of somebody proposes a change to the language and they go, well, but that wouldn't be Go, right?
[3072.02 --> 3074.06] And I think I agree with Michael in the case of Tri.
[3074.14 --> 3076.82] I think it would have been a very interesting change and I hope it comes back.
[3076.82 --> 3078.90] So just refresh our memories.
[3079.00 --> 3079.74] What did Tri do?
[3080.30 --> 3090.92] Yeah, so basically it gave you a mechanism to try with an expression that returned an error as its final function,
[3091.12 --> 3092.82] that returned an error as its final argument, right?
[3093.10 --> 3096.92] And then it would allow you to handle that error elsewhere.
[3097.48 --> 3102.34] So you could add like, I think in one of the variations of the proposal,
[3102.34 --> 3107.24] there was like a handle for handling like a number of tries in a function.
[3107.98 --> 3113.40] I think in another one, if I'm remembering correctly, recover was an option for handling the error,
[3113.84 --> 3119.14] but you could kind of have the errors handled in like a single place.
[3119.72 --> 3126.44] I mean, basically like people realize that error handling is awkward in Go and the awkwardness, I think,
[3126.50 --> 3128.10] causes people to take shortcuts.
[3128.10 --> 3132.98] And so addressing that awkwardness and nudging people towards doing the right thing,
[3133.04 --> 3136.84] especially if, you know, try and handle came with helpers.
[3136.96 --> 3143.88] And now we do have like functions like errors, is, and as that like help people with like wrapping errors.
[3144.12 --> 3151.02] Like those together would like provide a better model for handling errors and for people to think about handling errors.
[3151.54 --> 3153.12] Wow. Fascinating stuff there.
[3153.12 --> 3158.38] Yeah. Yeah. I tell you what, that's, it's interesting because I think, see, when I handle errors,
[3158.74 --> 3164.02] and I don't know if I do this different to other people, I think that there may be, I may be unusual in this,
[3164.10 --> 3169.82] but I will wrap, when I return the error, I added quite a bit of context there.
[3170.26 --> 3171.60] So each one is different.
[3171.72 --> 3175.48] I'll add and I'll include the thing it's trying to do in that wrapped error.
[3175.48 --> 3181.68] So it's not that I'll have a wrap where I just put the method name or whatever into the error.
[3182.00 --> 3183.60] And it's the same every time.
[3184.02 --> 3190.66] So if it was the same every time, like having it pulled out and have it deal with it in one place is kind of quite nice.
[3191.12 --> 3196.36] But yeah, the other thing is, I mean, this doesn't hurt that, but I do like that error handling is at least explicit.
[3196.36 --> 3205.22] Like, and I think the tried proposal didn't really interfere with that, but I like the fact that in Go, we see, we are kind of handling errors.
[3205.42 --> 3214.92] Even if you are just returning it, it's like, as long as you're not forgetting about it, you know, it's kind of, it's nice that they are in the forefront of our minds when we're coding.
[3215.04 --> 3220.66] I literally was writing something today and I literally had to write if error doesn't equal nil.
[3220.66 --> 3224.86] And then I had to stop and think, oh, what do I do if this errors?
[3225.12 --> 3230.18] Like that actually is a bit of a, not a trivial problem in this particular case.
[3230.36 --> 3232.40] I wasn't able to just return an error.
[3232.82 --> 3234.22] You know, I had to handle that.
[3234.46 --> 3239.14] So I quite like that it's in the forefront, at least of the language, but yeah, interesting.
[3239.28 --> 3244.38] We'll, we'll, we'll definitely find out what our other people think on Twitter when we post that one.
[3244.44 --> 3245.30] It's going to be very interesting.
[3245.30 --> 3245.60] Yeah.
[3245.90 --> 3246.32] I think.
[3246.52 --> 3251.14] I'm interested in seeing how unpopular that, that, that is.
[3251.60 --> 3256.12] Could, do you think that could go for the most unpopular opinion expressed in one of these segments?
[3256.40 --> 3260.30] It could do, or you might surprise us and maybe everyone's like, yeah, we loved that.
[3260.86 --> 3267.20] And honestly, I think that, I think that point of like, we're now so familiar with Go, we, we have to be careful.
[3267.34 --> 3274.24] We don't just become curmudgeons about it and resist any change, you know, because, you know, we do, it should change.
[3274.24 --> 3274.82] It should evolve.
[3274.92 --> 3276.58] It should get better, like all software.
[3276.88 --> 3280.40] So I kind of like, yeah, interested to hear what people think of that.
[3280.58 --> 3286.98] I think Michael also needs to think that if this opinion is going to be really unpopular, then Try is not going to come back.
[3287.22 --> 3288.66] So you want it to be very popular.
[3289.12 --> 3291.56] I hope it's, I mean, I would like for it to be popular.
[3292.16 --> 3292.32] Yeah.
[3292.56 --> 3295.80] That's not really in the spirit of the segment, but that's fine.
[3295.98 --> 3297.86] I think it is unpopular, but.
[3298.16 --> 3298.96] Well, we'll find out.
[3298.96 --> 3306.26] If it's an opinion that I hold, I, I, you know, I would like it to be less unpopular, even though it is unpopular.
[3306.80 --> 3311.22] Sometimes, you know, when the case is made, in fact, it's hard to get unpopular opinions.
[3311.36 --> 3315.14] This is what we've found because people make the case so eloquently like you did.
[3315.40 --> 3320.12] And then people on, on Twitter, you know, they're easily swayed.
[3320.36 --> 3321.46] They'll believe that now.
[3321.46 --> 3332.54] I mean, if I can make reference to the G word again, there was a time in the community where you brought up the G word and people are like, no, not in my go.
[3332.88 --> 3337.48] And they, people were right to be worried about, you know, those things.
[3337.54 --> 3340.60] But I, I think like the case was made.
[3340.60 --> 3355.30] People worked really hard to present the case, why it would actually be an improvement and really convince people, like convince people who use Go that it was actually going to be a net positive.
[3355.56 --> 3364.92] And I, I think the sentiment now towards the G word is a lot more positive than, than it was five or six years ago.
[3365.50 --> 3367.20] Yeah, that is definitely true.
[3367.20 --> 3373.68] And then the counter is, you know, we don't want it to be too easy to change things because of the backwards compatibility promise.
[3373.86 --> 3380.98] I do quite like the fact that it's quite a rigorous process before we really get any big changes like this.
[3381.16 --> 3383.20] I think that's, there's value in that too.
[3383.50 --> 3386.12] So that really only the only good stuff is going to get through.
[3386.40 --> 3386.84] Hopefully.
[3387.52 --> 3392.18] Every new thing we add is something we have to maintain forever.
[3392.80 --> 3396.62] We do have to be careful about adding new things for sure.
[3396.62 --> 3396.98] Yeah.
[3396.98 --> 3398.46] Because forever is ages, isn't it?
[3398.52 --> 3399.30] It's a pretty long time.
[3399.80 --> 3400.10] Yeah.
[3400.76 --> 3403.52] I also remember somebody recently criticizing Go.
[3403.70 --> 3412.86] I think it was on Hacker News saying something along the lines of, Go is a popular language that has ignored all the programming language development in the past 15 years.
[3413.44 --> 3415.78] But that's kind of why it works, right?
[3415.82 --> 3420.04] Because it, it, it only builds on top of what has been well tested.
[3420.04 --> 3425.90] And I think the only major exception there is modules, which goes against everything else that has been done in package management.
[3426.40 --> 3426.42] Yeah.
[3426.46 --> 3427.34] That's quite interesting.
[3427.62 --> 3429.22] It is a very stable thing.
[3429.22 --> 3434.26] And yeah, that other thing of having lots of different ways to do the same thing.
[3434.26 --> 3441.28] In JavaScript, like you almost have to learn a particular flavor of JavaScript now in order to contribute to a project.
[3441.72 --> 3448.28] Some are using all the latest language features and like the little arrows for functions and things like this.
[3448.28 --> 3450.34] And you sort of have to learn all that.