1 00:00:01,120 --> 00:00:02,040 Welcome. To. 2 00:00:02,280 --> 00:00:04,640 Happy Path Programming. I'm Bruce Eckel. 3 00:00:04,720 --> 00:00:09,720 I'm James Ward. All right, Welcome to Happy Path 4 00:00:09,720 --> 00:00:12,160 Programming. We have a beautiful snowy day 5 00:00:12,160 --> 00:00:15,480 here in Crested Butte. And oh, we got a good one today. 6 00:00:15,480 --> 00:00:17,920 I've been looking forward to this for a while. 7 00:00:18,240 --> 00:00:20,400 So we have with us Phil Holzen's piece. 8 00:00:20,640 --> 00:00:23,240 Did I get that at all right? Yeah, you got that very close. 9 00:00:24,480 --> 00:00:25,800 Welcome Phil. Good to have you. 10 00:00:26,160 --> 00:00:31,080 Thank you very much. So this one is on pickle, which 11 00:00:31,080 --> 00:00:35,160 is a new configuration language that was announced a couple 12 00:00:35,160 --> 00:00:40,280 months ago now and I as soon as I saw it, I was like, Oh my God, 13 00:00:40,280 --> 00:00:42,960 this could be the solution to all of my problems. 14 00:00:42,960 --> 00:00:45,440 Well, and you said new configuration language like 15 00:00:45,440 --> 00:00:48,320 there are others and I think this is sort. 16 00:00:48,440 --> 00:00:51,360 Of stands alone and and it. Is it's like the first time. 17 00:00:51,640 --> 00:00:56,000 I mean it's such. I mean config well what are you 18 00:00:56,040 --> 00:00:58,680 whatever you call them configure they're not really languages 19 00:00:58,680 --> 00:01:03,480 they're more I don't know declarative. 20 00:01:03,480 --> 00:01:06,960 Yeah they're just descriptive yeah whatever. 21 00:01:06,960 --> 00:01:13,280 And the undertaking a like saying, oh, what we need here is 22 00:01:13,280 --> 00:01:20,200 a language that's a big step. I mean that's like that's very 23 00:01:20,200 --> 00:01:25,360 bold and I wouldn't do it, you know, that's like too much work. 24 00:01:26,080 --> 00:01:29,840 So to create a whole language for just this one domain of 25 00:01:29,840 --> 00:01:32,000 configuration. It's the right answer. 26 00:01:32,800 --> 00:01:36,600 It does feel that way, yes. So Phil, give us the overview of 27 00:01:36,600 --> 00:01:37,680 pickle. What is pickle? 28 00:01:38,160 --> 00:01:41,320 And it's spelled PKLI should point out which should be on the 29 00:01:41,320 --> 00:01:43,840 title, but pronounce pickle but PKL. 30 00:01:43,840 --> 00:01:46,760 So give us, give us the rundown. Indeed yes. 31 00:01:46,880 --> 00:01:50,720 In in speech you just at some point forget even to that the 32 00:01:50,720 --> 00:01:53,840 spelling is weird because pickle in my head is now just PKL. 33 00:01:54,280 --> 00:01:57,400 But it is Google able and I certainly appreciate that. 34 00:01:57,400 --> 00:02:00,880 Yes, that's a smart thing to do. It's much better. 35 00:02:00,920 --> 00:02:03,160 Than go. It does go, yeah. 36 00:02:03,720 --> 00:02:06,440 Depending on your cookies, you do end up in a in a sports 37 00:02:06,440 --> 00:02:10,720 league, but but no. If your if your cookies sort of 38 00:02:10,720 --> 00:02:13,600 hang towards programming languages, then and you're all. 39 00:02:13,600 --> 00:02:15,440 Good pickle will get you to the right pickle. 40 00:02:15,960 --> 00:02:18,200 Indeed, yeah. No. 41 00:02:18,200 --> 00:02:21,280 So pickle is a configuration language, as you said, quite 42 00:02:21,280 --> 00:02:22,320 poetically. Thanks for that. 43 00:02:23,360 --> 00:02:27,080 But it's a configuration language that recognizes that 44 00:02:28,120 --> 00:02:31,400 like an ever increasing number of outages, if you read about 45 00:02:31,400 --> 00:02:37,560 any service outages is due to a configuration mishap and the 46 00:02:37,560 --> 00:02:39,880 number of outages increased. Some of the most prominent 47 00:02:39,880 --> 00:02:42,040 outages. Oh, we screwed up the 48 00:02:42,040 --> 00:02:44,960 configuration. So it seems a a sort of an 49 00:02:44,960 --> 00:02:48,840 obvious place for like why isn't there as much instrumentation 50 00:02:48,840 --> 00:02:52,160 there, where as as we have in our programming languages. 51 00:02:53,200 --> 00:02:57,160 So in my IDE, if I write, whether I write Go or Java or 52 00:02:57,160 --> 00:03:02,520 Swift or doesn't matter, I have. I have tremendous amounts of 53 00:03:02,520 --> 00:03:04,880 tooling. You're not going. 54 00:03:05,360 --> 00:03:08,320 To screw up production. Exactly. 55 00:03:08,640 --> 00:03:11,840 And validation can be as simple as, you know, a typo in a YAML 56 00:03:11,840 --> 00:03:13,680 file. We've all sort of omitted a 57 00:03:13,680 --> 00:03:17,160 space at some point, or or because of some editor setting a 58 00:03:17,160 --> 00:03:21,080 tab, creed in, or, you know, annoying things or a string. 59 00:03:21,120 --> 00:03:23,360 Got converted to a boolean unexpectedly. 60 00:03:23,720 --> 00:03:27,560 The Norway problem? What's the Norway problem? 61 00:03:27,720 --> 00:03:30,880 The Norway problem is that in YAML you can say yes and no for 62 00:03:30,880 --> 00:03:34,200 boolean true and false, but you also have country codes and 63 00:03:34,200 --> 00:03:35,960 strings are not necessarily quoted. 64 00:03:36,160 --> 00:03:40,640 So sometimes it's like, you know, Sweden, Finland and false. 65 00:03:40,880 --> 00:03:43,680 Wait, what? False. 66 00:03:43,720 --> 00:03:46,360 Yeah. Oh, because no, the abbreviation 67 00:03:46,360 --> 00:03:49,800 for Norway Got it. Oh yes, That's why it's the 68 00:03:49,800 --> 00:03:52,240 Norway problem, because no becomes a boolean. 69 00:03:52,440 --> 00:03:54,160 Amazing. Once that bites. 70 00:03:54,240 --> 00:03:56,000 You you brilliant language design. 71 00:03:57,800 --> 00:04:00,040 And it would. And it's and it is it. 72 00:04:00,080 --> 00:04:01,880 It did seem to solve a problem right? 73 00:04:01,880 --> 00:04:04,600 Because it sort of denotationalized a bunch of 74 00:04:04,600 --> 00:04:06,480 stuff it it seemed so much lighter. 75 00:04:07,040 --> 00:04:11,240 But then you get these kinds of things and then yeah, maybe 76 00:04:11,240 --> 00:04:13,440 there was a reason for all the heavy notation and stuff. 77 00:04:15,000 --> 00:04:18,640 And so so it's it's there's obviously a space there to to 78 00:04:18,640 --> 00:04:21,200 solve a problem in. And the problem is, whether it's 79 00:04:21,200 --> 00:04:24,200 a typo or whether it's a conceptual error or an 80 00:04:24,200 --> 00:04:27,720 administrative error, assigning more processors than you have 81 00:04:27,720 --> 00:04:32,360 quota for. Yeah, these sorts of errors you 82 00:04:32,360 --> 00:04:37,280 want to to catch before you deploy because that's how you 83 00:04:37,280 --> 00:04:42,880 save outages. Some validation up front to help 84 00:04:42,880 --> 00:04:45,520 give you some level of confidence that the 85 00:04:45,520 --> 00:04:48,440 configuration that you're pushing is correct. 86 00:04:49,200 --> 00:04:53,320 Yeah, it's interesting how we've been, You know, you kind of see 87 00:04:53,320 --> 00:04:57,120 this movement towards, oh, here's something that can be 88 00:04:57,120 --> 00:05:01,400 automatically checked, that people have been doing by hand, 89 00:05:01,400 --> 00:05:07,680 let's automatically check it all the time without relying on the 90 00:05:07,680 --> 00:05:10,960 programmer to do that. And it's like when you think of 91 00:05:10,960 --> 00:05:14,120 it that way, it's pretty obvious because. 92 00:05:14,120 --> 00:05:16,520 And but this doesn't say language yet, right? 93 00:05:16,520 --> 00:05:19,200 This could say UI. Sure. 94 00:05:19,840 --> 00:05:23,400 And if and and maybe some people who work in UI came to this 95 00:05:23,400 --> 00:05:26,360 problem first, we would now do something with UIS that worked 96 00:05:26,360 --> 00:05:27,160 really well. Who knows? 97 00:05:28,880 --> 00:05:32,960 But if if you think about sort of those kinds of constraints 98 00:05:32,960 --> 00:05:37,560 and then think about who operates the the config, oh, 99 00:05:37,560 --> 00:05:39,080 these are people that are used to code. 100 00:05:39,520 --> 00:05:42,680 But also very importantly, this is what I call the 2:00 AM 101 00:05:42,680 --> 00:05:46,440 problem. It's someone who knows how to 102 00:05:46,440 --> 00:05:50,640 code, but who got paged in the middle of the night, gets woken 103 00:05:50,640 --> 00:05:54,600 up, has the reading level of a 12 year old, and needs to solve 104 00:05:54,600 --> 00:05:56,080 a complicated configuration problem. 105 00:05:56,560 --> 00:05:58,600 Yeah. So like make it light, make it 106 00:05:58,600 --> 00:06:05,600 easy, make it simple as much as possible know your audience and 107 00:06:05,600 --> 00:06:09,680 then you you do get to you have to either be really good at UI 108 00:06:10,520 --> 00:06:14,480 which these are in dimensional problems and I don't know how to 109 00:06:14,480 --> 00:06:19,240 stick that in UI but I'm not AUI person so who knows but in 110 00:06:19,240 --> 00:06:21,440 language. One of the goals is to make it 111 00:06:21,440 --> 00:06:24,480 so that at 3:00 in the morning when your pager has gone off. 112 00:06:25,200 --> 00:06:27,040 Well, hopefully first of all, that hasn't happened. 113 00:06:27,200 --> 00:06:30,640 But if for some reason it has, make it easy to identify where 114 00:06:30,640 --> 00:06:35,760 the problem is coming from, and make it easy to fix when you're 115 00:06:35,760 --> 00:06:38,160 when you're, you know, in the middle of the night and your 116 00:06:38,160 --> 00:06:41,440 brain isn't fully functional. Without introducing new problems 117 00:06:41,440 --> 00:06:43,480 at the same time. Right. 118 00:06:44,440 --> 00:06:46,960 And inherently you do introduce some new problems, right? 119 00:06:46,960 --> 00:06:52,560 Because like 1 great benefit of a static format like Jason is 120 00:06:53,160 --> 00:06:56,800 that all the information about this specific machine or this 121 00:06:56,800 --> 00:06:59,760 specific instance or whatever, all the information is in one 122 00:06:59,760 --> 00:07:01,800 place and is explicit. That's a good thing. 123 00:07:03,520 --> 00:07:06,120 So when you start abstracting you start hiding. 124 00:07:06,920 --> 00:07:10,560 But then OK, if you recognise that that's a problem that 125 00:07:10,560 --> 00:07:12,680 you've introduced, can you now solve this problem? 126 00:07:12,680 --> 00:07:14,840 And then you get good IDE support, so you get go to 127 00:07:14,840 --> 00:07:17,720 definition and like debugging tools, that sort of stuff. 128 00:07:18,040 --> 00:07:22,040 Yeah, so by creating an abstraction we have hid some 129 00:07:22,040 --> 00:07:26,760 things or or made some things not as visible by the nature of 130 00:07:26,760 --> 00:07:31,040 having an abstraction. And that has a trade off where 131 00:07:31,040 --> 00:07:33,800 now you're no longer working with maybe exactly the 132 00:07:33,800 --> 00:07:37,480 representation that the the thing that's using the 133 00:07:37,480 --> 00:07:43,400 configuration is is reading. But the the other on the other 134 00:07:43,400 --> 00:07:48,320 side you get all these great additional features of schemas 135 00:07:48,320 --> 00:07:53,000 and functions and reusability with modules and all this kind 136 00:07:53,000 --> 00:07:55,320 of stuff. So give us the the rundown on on 137 00:07:55,320 --> 00:07:58,360 some of the pickle kind of language features and and things 138 00:07:58,360 --> 00:08:03,000 there. Right, so pickle is is lazy, 139 00:08:04,280 --> 00:08:08,120 which is typically, If you want to do like performance, 140 00:08:08,120 --> 00:08:10,840 programming is not necessarily a good thing. 141 00:08:10,920 --> 00:08:13,120 If you need control, that's not necessarily a good thing. 142 00:08:13,120 --> 00:08:15,200 But if you want to be declarative, if you want the 143 00:08:15,200 --> 00:08:17,880 notation to be simple, that's a wonderful, wonderful thing. 144 00:08:18,280 --> 00:08:23,560 So we have objects, but these are basically they have, they 145 00:08:23,560 --> 00:08:25,320 have members, which are properties. 146 00:08:27,640 --> 00:08:29,400 There's some other kinds of members, but we'll get to that 147 00:08:29,400 --> 00:08:32,760 later. And but with these properties, 148 00:08:32,760 --> 00:08:35,440 they're basically lazy because they're lazy. 149 00:08:35,440 --> 00:08:37,799 They're basically zero argument functions, right? 150 00:08:37,840 --> 00:08:42,799 So when you don't use them, whatever defines them is not 151 00:08:42,799 --> 00:08:45,440 evaluated. So if you write very expensive 152 00:08:45,440 --> 00:08:50,200 things about queries over large numbers of files and such, if 153 00:08:50,200 --> 00:08:55,480 you don't actually consume those properties, you don't evaluate 154 00:08:55,480 --> 00:08:56,920 it. And that's great because then 155 00:08:56,920 --> 00:09:02,040 you can write a a very simple query and let laziness solve it 156 00:09:02,040 --> 00:09:06,200 for you. And so we have objects with 157 00:09:06,200 --> 00:09:12,040 properties and these things basically they're your simple 158 00:09:12,040 --> 00:09:17,960 hierarchy like Jason, except now you can refer to other fields 159 00:09:18,600 --> 00:09:22,680 and define functions, so to say your total number of processors 160 00:09:22,680 --> 00:09:26,280 allocated for this thing is the sum of the processors allocated 161 00:09:26,280 --> 00:09:29,680 for your login facility and the processors for your database and 162 00:09:29,680 --> 00:09:34,760 the process etcetera. And if any of them change for a 163 00:09:34,760 --> 00:09:39,200 specific configuration anywhere, then the sum automatically 164 00:09:39,200 --> 00:09:40,480 changes. Yeah. 165 00:09:41,480 --> 00:09:45,440 So there's I guess the high level of this is that 166 00:09:45,440 --> 00:09:53,640 configuration is maybe very mostly hierarchical data and how 167 00:09:53,640 --> 00:09:58,280 do we define that hierarchical data structure especially when 168 00:09:58,280 --> 00:10:01,120 there is potentially relationships across the 169 00:10:01,120 --> 00:10:03,280 hierarchy. And so that's what you're 170 00:10:03,280 --> 00:10:06,600 talking about with like being able to take some definition of 171 00:10:06,600 --> 00:10:11,880 number of CPUs or something and do some some aggregation or some 172 00:10:11,880 --> 00:10:15,080 of that that number and put it into some other part of the 173 00:10:15,080 --> 00:10:17,120 configuration. So how do you? 174 00:10:17,120 --> 00:10:20,160 How do you define the hierarchy? How do you then do operations 175 00:10:20,160 --> 00:10:24,720 across the hierarchy but do this in a lazy and deterministic way? 176 00:10:25,280 --> 00:10:29,160 Exactly, yes. And so that's the there's 177 00:10:29,160 --> 00:10:31,040 there's an upside and a downside to it, right. 178 00:10:31,040 --> 00:10:35,440 So now we sort of bias towards hierarchies, but it's sort of 179 00:10:35,440 --> 00:10:38,200 works out in practice most of the time because we have config 180 00:10:38,200 --> 00:10:41,600 for the application itself, for the infrastructures running on 181 00:10:41,600 --> 00:10:43,560 for. So you you sort of naturally 182 00:10:43,560 --> 00:10:47,920 divide an organiser configuration hierarchical, I 183 00:10:47,920 --> 00:10:50,400 would say There are cases where that's not the case. 184 00:10:51,080 --> 00:10:56,760 So think of CI pipeline configuration. 185 00:10:57,320 --> 00:11:00,960 Those are directed acyclic graphs, not technically trees. 186 00:11:02,120 --> 00:11:04,920 And you can still sort of spin them together by just name 187 00:11:04,920 --> 00:11:07,800 reference because you can just point to the other one and then 188 00:11:07,800 --> 00:11:11,280 you tie a loop. So you can very easily describe 189 00:11:11,280 --> 00:11:15,920 configuration for stuff like dependencies, build systems. 190 00:11:16,760 --> 00:11:20,040 Yeah, that's a good point that it's not just about hierarchical 191 00:11:20,320 --> 00:11:24,680 configuration, because yeah, the the the Dags, right Dags in the 192 00:11:24,680 --> 00:11:29,840 case of of like CI configuration like you do need the a different 193 00:11:30,000 --> 00:11:32,400 not not a purely hierarchical structure. 194 00:11:32,400 --> 00:11:35,320 You need you need some references and and pickle can 195 00:11:35,320 --> 00:11:39,440 model that as well. Yeah, because it is lazy. 196 00:11:39,440 --> 00:11:43,880 You can just refer in. You can let two separate files 197 00:11:43,880 --> 00:11:49,680 modules import each other explicitly, and you can do that 198 00:11:49,680 --> 00:11:51,280 with objects as well, so you can actually. 199 00:11:51,440 --> 00:11:56,640 Get a cyclic issue. You get a cyclic issue if if 200 00:11:56,640 --> 00:11:59,240 that if that model breaks itself. 201 00:11:59,240 --> 00:12:04,560 So pickle only evaluates stuff when it needs to, so most of the 202 00:12:04,560 --> 00:12:08,720 time right? Pickle is used by people who 203 00:12:08,720 --> 00:12:11,640 need other static outputs. So then it's typically used as 204 00:12:11,640 --> 00:12:15,680 acli, and then you evaluate a pickle program and then you get 205 00:12:15,680 --> 00:12:17,440 a Jason and a YAML out or something. 206 00:12:19,800 --> 00:12:24,360 Or it's used by service authors or program authors, right, that 207 00:12:24,360 --> 00:12:27,920 have a that want to consume pickle as their configuration 208 00:12:28,560 --> 00:12:30,640 but then populate their data structures. 209 00:12:32,960 --> 00:12:37,480 And the second approach is the one when I started You're you're 210 00:12:37,680 --> 00:12:42,000 familiar with Gradle since the pickle project uses Gradle and 211 00:12:42,280 --> 00:12:46,400 we had an episode a while back about my attempts to address 212 00:12:46,400 --> 00:12:51,800 some of the Gradle usability issues, and I've been picking 213 00:12:51,800 --> 00:12:55,680 away at different different attempts at at different aspects 214 00:12:55,680 --> 00:12:57,880 to this. But one of those is on the 215 00:12:57,880 --> 00:13:00,400 configuration language for Gradle. 216 00:13:00,680 --> 00:13:03,680 And so I started playing with using pickle as the 217 00:13:03,680 --> 00:13:07,960 configuration language for gradle and and in that case I 218 00:13:07,960 --> 00:13:12,960 was able to take my pickle, generate the Kotlin files for 219 00:13:12,960 --> 00:13:17,880 those pickle definitions and then read my configuration and 220 00:13:17,880 --> 00:13:22,480 then map that into the gradle APIs which are Java APIs 221 00:13:22,480 --> 00:13:26,000 essentially and and So yeah, it was great that I, you know, I 222 00:13:26,000 --> 00:13:29,160 wasn't like the other approach would be OK take my pickle file 223 00:13:29,360 --> 00:13:33,640 now generate a yaml file or something and then parse the 224 00:13:33,640 --> 00:13:35,920 yaml file. It's like no like like I just 225 00:13:35,920 --> 00:13:39,440 want an API to my configuration. And it's cool that pickle gives 226 00:13:39,440 --> 00:13:43,800 you both kind of directions into to what how you want to deal 227 00:13:43,800 --> 00:13:47,840 with your your configuration, either programmatic or just a a 228 00:13:48,000 --> 00:13:53,240 mapping into to a static file. Yeah, now that's that's entirely 229 00:13:53,240 --> 00:13:55,840 a good point and I think the so it's worth a mention Peter 230 00:13:55,840 --> 00:14:00,040 Niederweiser as a name drop. He's the the person who started 231 00:14:00,040 --> 00:14:04,400 pickle and the insight that he had was besides. 232 00:14:04,400 --> 00:14:07,920 Oh, a language is a good fit here well, and many more 233 00:14:07,920 --> 00:14:11,880 insights leading to Pickle. But the insight that he had was 234 00:14:11,880 --> 00:14:16,680 also. I want to do his words justice 235 00:14:16,680 --> 00:14:18,160 and think of how he said it, because it was quite good. 236 00:14:21,640 --> 00:14:22,920 Did I just lose my train of thought? 237 00:14:22,920 --> 00:14:25,040 I just don't think I did. So configuration. 238 00:14:25,040 --> 00:14:27,520 We've got this configuration format and then we have 239 00:14:27,520 --> 00:14:31,640 different ways to process it. And so it seems like that was 240 00:14:31,640 --> 00:14:37,880 one of the initial goals of pickle was to not just be a a 241 00:14:38,200 --> 00:14:43,440 mapper to a static to a static another static format, but also 242 00:14:43,440 --> 00:14:46,560 provide the programmatic interfaces to it. 243 00:14:48,000 --> 00:14:50,560 Right. I I regained my chain of 244 00:14:50,560 --> 00:14:51,240 thought. Thank you very much. 245 00:14:51,240 --> 00:14:53,360 Perfect. So, so Peter jumped back and 246 00:14:53,360 --> 00:14:57,440 said, look, I can solve these problems that I know that I have 247 00:14:57,560 --> 00:15:00,200 or that I know that people around me have handling 248 00:15:00,200 --> 00:15:03,480 services. Or I can take a slightly more 249 00:15:03,480 --> 00:15:06,240 fundamental step back and say, how do we keep doing this? 250 00:15:06,440 --> 00:15:09,320 Because there's already a bunch of things that say, OK, 251 00:15:10,000 --> 00:15:14,480 basically you want static Jason, but you want templating, right? 252 00:15:14,480 --> 00:15:17,640 So then you get Jason it, which solves that problem. 253 00:15:17,760 --> 00:15:20,800 But now you also have a YAML file because you simply also run 254 00:15:20,800 --> 00:15:23,400 on a infrastructure that needs YAML as config. 255 00:15:23,800 --> 00:15:26,880 Right. So they need to have different 256 00:15:26,880 --> 00:15:30,800 representations. And normally we duct tape that 257 00:15:30,800 --> 00:15:33,800 stuff with with other tools and like, you know, rewrite this 258 00:15:33,800 --> 00:15:37,960 Jason into YAML and yeah, all these kinds of duct AP tools. 259 00:15:37,960 --> 00:15:39,680 But like, what if? What if you see the whole thing 260 00:15:39,680 --> 00:15:44,240 as one problem, And that's what he what he sort of designed 261 00:15:44,520 --> 00:15:50,440 Pickle 4. Yeah, I I think, correct me if 262 00:15:50,440 --> 00:15:55,080 I'm wrong, but I think when we explored this at the Winter Tech 263 00:15:55,080 --> 00:16:01,800 forum, I noticed that you had objects but not inheritance. 264 00:16:01,800 --> 00:16:04,200 Is that right? We do. 265 00:16:04,720 --> 00:16:06,240 You do inheritance. We do. 266 00:16:06,240 --> 00:16:11,280 Yes, we have single inheritance. So normal extents of normal type 267 00:16:11,280 --> 00:16:16,600 system. Yeah, so that allows you to to 268 00:16:17,640 --> 00:16:20,320 have. Let's see a practical example 269 00:16:20,320 --> 00:16:21,960 here. I'm trying to think if I used 270 00:16:21,960 --> 00:16:26,040 inheritance on the pickle GitHub action stuff that I was working 271 00:16:26,040 --> 00:16:28,160 on. It seems like there's places 272 00:16:28,160 --> 00:16:35,600 where in their model you've got a job and then a job has steps 273 00:16:35,840 --> 00:16:39,120 and then steps have other things in them. 274 00:16:39,360 --> 00:16:42,160 And I was trying to think if there is any place where I used 275 00:16:42,160 --> 00:16:46,800 inheritance and I don't know if there was but I'm sure I will at 276 00:16:46,800 --> 00:16:49,200 some point as I go further with that uncover. 277 00:16:49,360 --> 00:16:52,600 Oh, this thing has some of the same shared structure as this 278 00:16:52,600 --> 00:16:56,480 other thing, and so let's create create a a parent class for that 279 00:16:56,480 --> 00:16:58,760 thing and so that so that we don't have to duplicate. 280 00:16:59,040 --> 00:17:00,600 Those pieces, it tends to be that. 281 00:17:00,600 --> 00:17:06,240 So you you can either do something where where you do by 282 00:17:06,240 --> 00:17:11,440 composition just by by holding objects inside objects, or you 283 00:17:11,440 --> 00:17:14,119 can do something like, oh, I'm going to you know, I have 5 284 00:17:14,119 --> 00:17:17,800 variants of something, let's say of a of a of ACI pipeline. 285 00:17:17,960 --> 00:17:20,119 So you've got like testing pipelines, and you've got build 286 00:17:20,119 --> 00:17:23,000 pipelines and you've got. So you've got some sort of basic 287 00:17:23,000 --> 00:17:26,280 profiles and they have a few parameters each that are not 288 00:17:26,280 --> 00:17:28,240 relevant for each other. You can just give all the 289 00:17:28,240 --> 00:17:31,400 parameters in one structure, make them nullable, and add a 290 00:17:31,400 --> 00:17:35,400 condition saying If it's this flavor pipeline, then all of 291 00:17:35,400 --> 00:17:39,240 these things must be there, and those things must not be So you 292 00:17:39,240 --> 00:17:41,720 can do that, but that doesn't scale really well, and at some 293 00:17:41,720 --> 00:17:44,320 point you get stuff that really has nothing to do with each 294 00:17:44,320 --> 00:17:45,960 other and it just gets to be confusing. 295 00:17:45,960 --> 00:17:47,200 Yeah. You're just bloating these 296 00:17:47,200 --> 00:17:52,040 definitions when they're not actually shared Shared 297 00:17:52,040 --> 00:17:53,960 definitions. And yeah, I mean it's cool that 298 00:17:53,960 --> 00:17:59,080 you can make them default as as null and then then you don't 299 00:17:59,080 --> 00:18:00,840 have to even think about their existence. 300 00:18:01,080 --> 00:18:05,000 But sure, is nicer when your when your schema can match the 301 00:18:05,000 --> 00:18:07,200 reality of how you're going to actually use it. 302 00:18:08,640 --> 00:18:12,040 Yes, and so the basically the the design constraint there is 303 00:18:12,040 --> 00:18:16,640 how is it so? Typically when you really like 304 00:18:16,640 --> 00:18:21,080 wiggle down on a problem the the problem itself, the the path to 305 00:18:21,080 --> 00:18:23,600 the solution is often to find the simplest way of expressing 306 00:18:23,600 --> 00:18:27,040 the problem. And so how do you make it 307 00:18:27,160 --> 00:18:30,800 obvious what the simple way of writing down the problem is and 308 00:18:30,920 --> 00:18:34,160 like that problem isn't solved. Like I still struggle with a 309 00:18:34,160 --> 00:18:36,320 whole bunch of problems I know about and I run into. 310 00:18:36,920 --> 00:18:39,920 Yeah. But you sort of go for those 311 00:18:39,920 --> 00:18:42,240 places where OK, here, here, there's a lot of friction. 312 00:18:42,400 --> 00:18:44,920 Can I make this easier? And there should be an intuitive 313 00:18:44,920 --> 00:18:46,800 bridge that that solves that problem. 314 00:18:47,480 --> 00:18:50,600 Well, and here's what I hate about declarative languages 315 00:18:51,160 --> 00:18:54,560 generally, is that there's no reusability. 316 00:18:54,560 --> 00:18:59,400 There's no a way, there's no way to take some some common thing 317 00:18:59,400 --> 00:19:03,240 and turn that into a function or some other higher level thing. 318 00:19:03,520 --> 00:19:06,600 And when we were at the Winter Tech Forum exploring pickle, 319 00:19:07,320 --> 00:19:11,360 we're like, OK, let's start with GitHub Actions. 320 00:19:11,720 --> 00:19:14,800 I hate how much boilerplate there is in GitHub Actions. 321 00:19:15,160 --> 00:19:18,360 So the the first thing that we worked on was, can we start 322 00:19:18,360 --> 00:19:22,160 creating a GitHub Action replacement. 323 00:19:22,160 --> 00:19:25,760 You know, so I can write my GitHub actions in pickle And we 324 00:19:25,760 --> 00:19:28,680 turned our we started. There was two different builds 325 00:19:28,680 --> 00:19:30,880 that we started like, OK, we're going to migrate these two 326 00:19:30,880 --> 00:19:35,800 builds to pickle. And the first one was, I don't 327 00:19:35,800 --> 00:19:38,160 know, 15 lines of YAML, so it wasn't a very long one or 328 00:19:38,160 --> 00:19:41,040 something, you know, it started very simple and we got it down 329 00:19:41,040 --> 00:19:46,000 to like 3 lines of pickle. And that's like to me, it's like 330 00:19:46,480 --> 00:19:50,600 I I just so despised that in declarative languages there's no 331 00:19:50,600 --> 00:19:55,640 ability to do that. Like higher order structure 332 00:19:55,640 --> 00:19:58,920 where I can create a reusable thing and then that reusable 333 00:19:58,920 --> 00:20:02,040 thing can be based on other reusable things and and in 334 00:20:02,040 --> 00:20:05,560 pickle it's like oh. Like at that that point when we 335 00:20:05,560 --> 00:20:09,040 got that working at the Winter Tech Forum, everyone was just 336 00:20:09,040 --> 00:20:14,560 like sold, like like so sold on having a language that allows us 337 00:20:14,560 --> 00:20:19,000 to have actual reusability. And so yeah, that was that was 338 00:20:19,000 --> 00:20:21,400 cool. And we were able to get this all 339 00:20:21,400 --> 00:20:26,400 working with knowing very little about pickle and just kind of 340 00:20:26,400 --> 00:20:29,720 stumbling through. And guessing, that was. 341 00:20:29,720 --> 00:20:33,920 The nice thing is that you could guess, and your answers were 342 00:20:33,920 --> 00:20:37,320 almost always right. I don't know if we yeah, we were 343 00:20:37,320 --> 00:20:39,840 very impressed with the guessability of the language. 344 00:20:40,040 --> 00:20:43,880 We were expecting a lot of toil, yeah, because that's typical in 345 00:20:43,880 --> 00:20:49,920 these domains and within a couple hours we had at least two 346 00:20:49,920 --> 00:20:54,160 builds migrated over to a shared module with the GitHub Action 347 00:20:54,160 --> 00:20:56,400 stuff in it. And a pretty good grasp of the 348 00:20:56,400 --> 00:20:59,520 language, yeah, yeah. Yeah, so I guess the surface 349 00:20:59,520 --> 00:21:01,720 area is small enough that it's learnable. 350 00:21:01,720 --> 00:21:04,320 The Intellij plugin that we were using was awesome. 351 00:21:04,800 --> 00:21:08,960 And so yeah, it was just, it was way more delightful experience 352 00:21:08,960 --> 00:21:12,600 than we expected for how quickly we were able to make progress. 353 00:21:12,600 --> 00:21:16,200 Typically when you embark on some project like that, you're 354 00:21:16,200 --> 00:21:20,680 expecting days of turmoil and we within hours had had stuff 355 00:21:20,680 --> 00:21:24,600 working, had replaced our GitHub action pipeline to use the 356 00:21:24,600 --> 00:21:26,560 pickle file. You know, obviously we have to 357 00:21:26,560 --> 00:21:30,040 still generate the EMO underneath, but but yeah, and 358 00:21:30,080 --> 00:21:32,360 and then there was things that we didn't expect to work. 359 00:21:32,360 --> 00:21:34,240 We're like that. There's no way that's going to 360 00:21:34,240 --> 00:21:35,680 work. And then it just worked. 361 00:21:35,680 --> 00:21:38,600 We're like, wow. Yeah because of the strength of 362 00:21:38,600 --> 00:21:43,560 the language. So have you thought about using 363 00:21:43,560 --> 00:21:48,280 it as I mean this came up this morning a build system in other 364 00:21:48,280 --> 00:21:52,480 words can I replace I mean not yet cuz James pointed out well 365 00:21:52,480 --> 00:21:56,080 you needed an you need an engine beneath it. 366 00:21:56,080 --> 00:22:00,920 But is this been on the? Has anyone other than me 367 00:22:00,920 --> 00:22:03,240 explored defining their build with pickle? 368 00:22:05,480 --> 00:22:09,960 Yes, people have have tried that and there's some there's there's 369 00:22:09,960 --> 00:22:13,600 someone on did I see it on a Discord or did I see it on AII 370 00:22:13,600 --> 00:22:16,920 saw it maybe in our discussions or maybe on a Discord discussion 371 00:22:16,920 --> 00:22:21,080 somewhere that that someone was working on their build system. 372 00:22:21,520 --> 00:22:27,000 The thing that I'm still working on that I'm not entirely content 373 00:22:27,000 --> 00:22:30,160 with is is multi stage definitions. 374 00:22:30,280 --> 00:22:33,080 So build systems. As long as it is a straight 375 00:22:33,080 --> 00:22:36,000 straightforward dependency definition, pickle is already 376 00:22:36,000 --> 00:22:37,640 there. It's like comfortably there and 377 00:22:37,640 --> 00:22:39,440 you don't think about it, you just write it down. 378 00:22:40,680 --> 00:22:47,000 But when the result of a of a stage in your build needs to 379 00:22:47,000 --> 00:22:51,360 inform the config of what needs to go, and you want that to 380 00:22:51,360 --> 00:22:54,000 happen in pickle. So when you run pickle multiple 381 00:22:54,000 --> 00:22:58,280 times, as it were, that's not clear to me yet what that looks 382 00:22:58,280 --> 00:23:01,520 like, other than of course just multiple pickle files, one for 383 00:23:01,520 --> 00:23:04,400 each stage, where you just provide these things as input. 384 00:23:04,840 --> 00:23:09,640 Yeah, so the in the case of gradle where where I haven't 385 00:23:09,640 --> 00:23:13,320 tried to go yet in my explorations with using pickle 386 00:23:13,520 --> 00:23:16,600 is like task definition. And I think that's an example 387 00:23:16,600 --> 00:23:19,440 you're talking about where I need to define a task and it 388 00:23:19,440 --> 00:23:23,600 turns out that the output of that task gets used as an input 389 00:23:23,600 --> 00:23:26,600 for another task. And that's where things may get 390 00:23:26,600 --> 00:23:31,040 a a little tricky. So maybe, maybe purely if I'm 391 00:23:31,040 --> 00:23:33,840 not doing kind of task definition or any kind of 392 00:23:33,840 --> 00:23:38,080 runtime dependent information, then then something like pickle 393 00:23:38,080 --> 00:23:40,280 could work. But as soon as I get into a 394 00:23:40,280 --> 00:23:46,080 space where I need programmatic runtime, uh, outputs to then be 395 00:23:46,080 --> 00:23:49,400 used as as inputs elsewhere, that's where where things get a 396 00:23:49,400 --> 00:23:52,680 little bit trickier. Yeah, and like it can be done, 397 00:23:52,680 --> 00:23:56,840 but it's it's just not it. It to me it feels less fluent 398 00:23:57,160 --> 00:23:59,520 and I and I'm not entirely sure yet because it's, you know, 399 00:23:59,520 --> 00:24:01,440 we're it's configuration language. 400 00:24:01,440 --> 00:24:04,520 It's supposed to stay simple so you also don't want to stick too 401 00:24:04,520 --> 00:24:07,680 many bells and whistles in. So not entirely sure whether 402 00:24:07,680 --> 00:24:10,400 it's a pattern that is the answer to this rather than a 403 00:24:10,400 --> 00:24:12,480 language feature or a or, you know? 404 00:24:12,880 --> 00:24:15,520 Yeah, and that that's one of the thing I've been curious about 405 00:24:15,520 --> 00:24:18,160 with Pickle. And this relates to what I've 406 00:24:18,160 --> 00:24:23,320 dubbed Getz's law Brian Getz, where he he stated and this was 407 00:24:23,320 --> 00:24:25,400 summarized from some tweets by him. 408 00:24:25,400 --> 00:24:28,480 But something along the lines of every declarative language 409 00:24:28,480 --> 00:24:32,040 slowly slides towards being a terrible, terrible general 410 00:24:32,040 --> 00:24:35,400 purpose language. And that's I I think what you're 411 00:24:35,400 --> 00:24:40,880 highlighting is this this like gravity to trying to pull this 412 00:24:40,880 --> 00:24:44,040 declarative you know this language that has all these 413 00:24:44,040 --> 00:24:47,680 constraints for good reasons on it eventually getting pulled 414 00:24:47,680 --> 00:24:51,760 down into oh, but we just need this one other thing And so how 415 00:24:51,760 --> 00:24:56,560 are you looking at that Like like how how how do you know 416 00:24:56,560 --> 00:24:59,800 where to set the boundaries for no, we're not going to do that. 417 00:25:01,920 --> 00:25:05,920 I mean in part it's just a it's just a prioritisation thing. 418 00:25:05,920 --> 00:25:07,560 It's it's a small team that works on this. 419 00:25:07,560 --> 00:25:09,760 So we're we're three people in the core team. 420 00:25:11,120 --> 00:25:18,400 Dan and Islan are my my colleagues there and so So that 421 00:25:18,400 --> 00:25:20,600 prioritises stuff with limited capacity. 422 00:25:20,720 --> 00:25:24,600 But then more so like for fun, every once in a while we or now 423 00:25:24,720 --> 00:25:29,760 other people write like Advent of Code stuff in pickle that 424 00:25:29,760 --> 00:25:33,640 very quickly runs out. If somebody reasonably says hey, 425 00:25:33,640 --> 00:25:35,720 I'm I'm getting like out of memory error. 426 00:25:35,720 --> 00:25:40,400 I'm getting an overflow here or a thing because I tried to do 427 00:25:40,400 --> 00:25:42,960 this heavy computational algorithmic thing in pickle. 428 00:25:42,960 --> 00:25:45,480 Well, you know, sorry. Like. 429 00:25:45,920 --> 00:25:48,640 That's not a priority. We have other scalability issues 430 00:25:48,640 --> 00:25:52,200 where we do have priority, and scalability in config is much 431 00:25:52,200 --> 00:25:56,480 more. For example. 432 00:25:56,480 --> 00:25:59,560 How do you, How do you maintain large mono repos of 433 00:25:59,560 --> 00:26:00,400 configuration? Right? 434 00:26:00,400 --> 00:26:04,520 Infrastructure is code sort of design philosophy where you have 435 00:26:04,560 --> 00:26:08,280 multiple teams maintaining multiple services all together 436 00:26:08,280 --> 00:26:10,640 in one sort of pattern in one mono repo. 437 00:26:12,720 --> 00:26:14,480 How do you manage that? How do you make that skill? 438 00:26:14,640 --> 00:26:18,600 How do you deal with separate ownership and versioning and 439 00:26:19,000 --> 00:26:20,880 these sorts of things? Yeah, yeah. 440 00:26:22,160 --> 00:26:25,400 Yeah. So it seems like like there's 441 00:26:26,800 --> 00:26:29,560 some just resource constraints on how far you can take pickle. 442 00:26:29,560 --> 00:26:35,040 And then there's the IT. It seems like a desire to keep 443 00:26:35,680 --> 00:26:41,000 to maintain the ability to deterministically create static 444 00:26:41,720 --> 00:26:44,400 static representations of the configuration. 445 00:26:45,640 --> 00:26:49,880 And if you if somebody wants a feature that would break that 446 00:26:49,880 --> 00:26:52,920 ability to create a static configuration, then then at that 447 00:26:52,920 --> 00:26:56,760 point you're like, yeah, maybe we've maybe we've going too far 448 00:26:56,760 --> 00:26:59,040 or something. Those those priorities for sure 449 00:26:59,280 --> 00:27:02,240 we want reliability in our type system we want. 450 00:27:03,480 --> 00:27:06,640 So although the language itself is technically entirely dynamic, 451 00:27:06,640 --> 00:27:13,560 we do try to make it so that the IDE can actually statically 452 00:27:13,560 --> 00:27:16,520 analyse the types so that it can inform you without actually 453 00:27:16,520 --> 00:27:19,880 evaluating anything. And so that's that's a little 454 00:27:19,880 --> 00:27:21,760 bit cheating, right? We we take the best from both 455 00:27:21,760 --> 00:27:25,240 worlds because fundamentally it is dynamic and fundamentally the 456 00:27:25,240 --> 00:27:27,000 source of truth is the interpreter. 457 00:27:27,680 --> 00:27:30,720 But ideally you have on the fly type information. 458 00:27:31,040 --> 00:27:34,960 Yeah, yeah. And so in my usability of it, 459 00:27:34,960 --> 00:27:38,360 that's worked well. You know, the code hinting is is 460 00:27:38,360 --> 00:27:43,000 fast and accurate and I certainly appreciate that. 461 00:27:43,800 --> 00:27:46,760 Why thank you, no. But it does so so that that's 462 00:27:46,760 --> 00:27:51,000 certainly a a a design sort of element that we aim for to keep 463 00:27:51,640 --> 00:27:55,240 because that does something to simplicity for the configuration 464 00:27:55,240 --> 00:27:57,640 space problem. So technically it's during 465 00:27:57,640 --> 00:27:59,240 complete. So we could argue, you know, 466 00:28:00,120 --> 00:28:03,000 it's a programming language, It's a general purpose one, and 467 00:28:03,200 --> 00:28:08,600 it isn't. And it's kind of, I mean you've 468 00:28:08,840 --> 00:28:10,480 it. It looks like you've tried to do 469 00:28:10,480 --> 00:28:13,960 a lot of functional ish things with the language like 470 00:28:14,200 --> 00:28:16,800 everything is immutable, right? You don't. 471 00:28:16,800 --> 00:28:21,120 There's there's no variables, it's only values. 472 00:28:21,120 --> 00:28:24,600 Is that right? Yes, this is correct. 473 00:28:25,160 --> 00:28:27,520 OK, so that puts the. We have. 474 00:28:27,640 --> 00:28:30,480 We have variables local to expressions because we have let 475 00:28:30,480 --> 00:28:33,440 expressions. So the language purest in me now 476 00:28:33,440 --> 00:28:37,200 feels that I almost lied to you. We do have variables, but not in 477 00:28:37,200 --> 00:28:40,200 the in the reassignable. Sort of. 478 00:28:41,280 --> 00:28:45,120 Well oh God yeah. This argument, it's like, yeah, 479 00:28:45,120 --> 00:28:47,360 I've had this argument before. It's like if you're going to 480 00:28:47,360 --> 00:28:49,400 call it a variable, that means it can vary. 481 00:28:49,920 --> 00:28:53,160 So otherwise it's a value. I'm. 482 00:28:53,400 --> 00:28:56,080 I'm like mathematicians sometimes disagree. 483 00:28:56,080 --> 00:28:58,120 I'm I'm perfectly happy to leave it there. 484 00:28:58,560 --> 00:29:00,040 Yes, this is not a principle matter. 485 00:29:00,440 --> 00:29:03,160 Yeah, yeah. And it's really helpful to just 486 00:29:03,160 --> 00:29:05,320 say. It's immutable, yeah. 487 00:29:05,480 --> 00:29:07,280 Yeah, it's immutable. Everything's immutable. 488 00:29:09,160 --> 00:29:11,640 So other language features that are worth highlighting. 489 00:29:12,320 --> 00:29:14,480 So we talked a little bit about reusability. 490 00:29:14,760 --> 00:29:17,840 And reusability I think has multiple forms. 491 00:29:17,840 --> 00:29:20,920 There's, there's templates, there's objects, there's 492 00:29:20,920 --> 00:29:23,240 functions. Then you can package those 493 00:29:23,240 --> 00:29:26,120 things into modules and share your modules and. 494 00:29:26,120 --> 00:29:27,800 If we were going to ask, are there higher? 495 00:29:28,040 --> 00:29:30,240 I mean, do you have higher order functions? 496 00:29:32,280 --> 00:29:35,000 Yeah, I mean like technically, yeah, functions are are first 497 00:29:35,000 --> 00:29:37,360 class values. It there is a notational thing. 498 00:29:37,360 --> 00:29:41,600 The thing that you write down function Foo for is not. 499 00:29:41,840 --> 00:29:43,800 You can't refer to Foo without calling it. 500 00:29:45,640 --> 00:29:48,040 So if you just type Foo without the parentheses, you don't get 501 00:29:48,040 --> 00:29:49,760 an object that represents the function. 502 00:29:50,800 --> 00:29:52,880 Gotcha. So you don't have that, but you 503 00:29:52,880 --> 00:29:55,320 have lambdas instead. So you can wrap it in a Lambda. 504 00:29:56,320 --> 00:29:58,840 Yeah, that's a little finicky sort of sort of thing. 505 00:29:58,840 --> 00:30:00,720 So they're not quite 1st order, but. 506 00:30:01,520 --> 00:30:08,440 OK, yeah, but it's possible. So reusability, it's amazing. 507 00:30:08,920 --> 00:30:12,040 It's so great to to have the ability to to have all those 508 00:30:12,040 --> 00:30:15,640 different ways of of having reusability. 509 00:30:17,240 --> 00:30:19,080 So I think I don't know anyone want to say anything about 510 00:30:19,080 --> 00:30:21,960 reusability with pickle. I think it's one of the best, 511 00:30:21,960 --> 00:30:24,680 best things about it. Yeah, it's and it's. 512 00:30:25,120 --> 00:30:28,320 You mentioned type like templates and values and and 513 00:30:28,320 --> 00:30:31,480 that's a very good point because reuse of values is a very common 514 00:30:31,480 --> 00:30:37,400 pattern in in config And yeah that's been and a thing that 515 00:30:37,400 --> 00:30:40,080 I've been running into now talking to users picking it up 516 00:30:40,080 --> 00:30:43,280 who are very enthusiastic about it who do who get it. 517 00:30:43,280 --> 00:30:45,560 Like when I see the code and they go OK, clearly you're 518 00:30:45,560 --> 00:30:47,800 thinking in the same patterns that we're thinking in. 519 00:30:49,960 --> 00:30:52,920 One thing that isn't quite as obvious that pixel can actually 520 00:30:52,920 --> 00:30:57,280 do really well is it can use file structure, file name 521 00:30:57,280 --> 00:31:01,160 structure directories to inform a bunch of stuff. 522 00:31:01,160 --> 00:31:05,440 So you can read the name of a file that's very useful in a in 523 00:31:05,440 --> 00:31:07,120 structured configuration in a place. 524 00:31:08,760 --> 00:31:13,720 So for example if you you know have an object where someone I 525 00:31:14,200 --> 00:31:19,160 published code yesterday which is game state or or game model 526 00:31:19,160 --> 00:31:21,160 rather. So they define factions, and 527 00:31:21,160 --> 00:31:23,960 factions have buildings and units and these comes in types 528 00:31:23,960 --> 00:31:25,960 and stuff. And then the file name is the 529 00:31:25,960 --> 00:31:28,640 name of the building and then there's a field called name 530 00:31:28,640 --> 00:31:29,920 which is the name of the building. 531 00:31:30,080 --> 00:31:33,680 And then there's a an escape field with hyphens and such 532 00:31:34,200 --> 00:31:37,560 because you need a slug. So you have all these different 533 00:31:37,560 --> 00:31:38,960 variants of essentially the name. 534 00:31:38,960 --> 00:31:40,920 You can all of that derive that from the file name. 535 00:31:41,160 --> 00:31:44,200 Yeah. And and pickle does that very 536 00:31:44,200 --> 00:31:45,840 simply. You can do that in the template 537 00:31:45,840 --> 00:31:51,040 so that you never ever see it, but you just say this is a a a 538 00:31:51,040 --> 00:31:53,840 unit in this in this game model case. 539 00:31:54,320 --> 00:31:57,120 And a unit means, oh you know, we have these fields, but also 540 00:31:57,120 --> 00:31:59,880 these values are automatically derived from the file name. 541 00:32:00,280 --> 00:32:02,960 Yeah, yeah. So derived properties. 542 00:32:02,960 --> 00:32:08,320 That's a huge, huge thing for reusability and being able to 543 00:32:08,320 --> 00:32:11,080 run functions on values. There's a bunch of string 544 00:32:11,080 --> 00:32:16,080 functions out-of-the-box, and and so and then default values. 545 00:32:16,080 --> 00:32:20,680 Another Another great language feature that that, yeah makes. 546 00:32:20,680 --> 00:32:24,680 It makes it reuse just more concise because if something has 547 00:32:24,680 --> 00:32:26,800 a default value and I don't need to override it, then I don't 548 00:32:26,800 --> 00:32:28,400 have to see it or care that it's there. 549 00:32:29,080 --> 00:32:32,560 So that's a good one. You were gonna ask about, like, 550 00:32:33,080 --> 00:32:36,360 reading a version number off. Of Well then we discovered it. 551 00:32:36,360 --> 00:32:40,840 So one of the use cases that I have been curious about is the 552 00:32:40,840 --> 00:32:47,160 whole area of side effects. And so I think generally pickle 553 00:32:47,400 --> 00:32:52,240 doesn't support side effects except there are a few places 554 00:32:52,240 --> 00:32:55,320 where you can reach out to the external file system or external 555 00:32:55,320 --> 00:32:58,920 network or an environment variable and those become 556 00:32:59,400 --> 00:33:05,080 essentially like the way to to have some some side effect in in 557 00:33:05,080 --> 00:33:08,000 your pickle configuration. So yeah, give us the rundown on 558 00:33:08,000 --> 00:33:11,160 on your thoughts around side effects, what what, how you 559 00:33:11,160 --> 00:33:15,800 decide what side effects should be allowed and and how that ends 560 00:33:15,800 --> 00:33:18,280 up working in pickle configuration and keeping it 561 00:33:19,160 --> 00:33:23,440 deterministic in air quotes. Yeah, so I mean the the letting 562 00:33:23,440 --> 00:33:26,760 it be deterministic is is sort of a goal and you can't reach 563 00:33:26,760 --> 00:33:29,240 that entirely, right? So what's the other one? 564 00:33:29,320 --> 00:33:32,240 Works on my machine. Yeah, so the works on my 565 00:33:32,240 --> 00:33:33,040 machine. Problem. 566 00:33:33,320 --> 00:33:36,560 We try to minimize that. You can read environment 567 00:33:36,560 --> 00:33:40,320 variables, so you know you can read files. 568 00:33:40,320 --> 00:33:44,840 So maybe you still run into works on my machine problems, 569 00:33:45,160 --> 00:33:53,840 but these seem simple and like detectable and resolvable and so 570 00:33:53,840 --> 00:33:55,760 all. We do allow inputs because that 571 00:33:55,760 --> 00:33:59,440 is often necessary, but all inputs are cached. 572 00:33:59,880 --> 00:34:03,600 So you can read an HTTP resource, but it doesn't mean 573 00:34:03,600 --> 00:34:06,520 you can like back and forth on an API, because if you have the 574 00:34:06,520 --> 00:34:09,920 same request twice, you will get the same answer twice, even if a 575 00:34:09,920 --> 00:34:11,400 service would give you a different answer. 576 00:34:12,000 --> 00:34:16,040 Interesting. Because every resource is cached 577 00:34:16,040 --> 00:34:19,760 by its URL. And as an upside, it makes it 578 00:34:19,760 --> 00:34:22,239 makes pickle much more predictable, much more reliable, 579 00:34:24,080 --> 00:34:28,760 and much more intuitive. So so lower surprise basically. 580 00:34:28,880 --> 00:34:33,679 Yeah, and that's the main. Side effects gives you mostly 581 00:34:33,679 --> 00:34:39,360 deterministic behavior and and when needed there's a bit of an 582 00:34:39,360 --> 00:34:42,159 escape hatch there. So the the use case that Bruce 583 00:34:42,159 --> 00:34:44,320 was pointing out was. One thing that I have to do in 584 00:34:44,320 --> 00:34:49,639 my gradle builds is I read the git tag to determine what the 585 00:34:49,639 --> 00:34:55,120 great old version should be set as and and one way to do that 586 00:34:55,120 --> 00:34:57,640 with pickle would be to just pass it in through an 587 00:34:57,640 --> 00:34:59,440 environment variable. But then I need to move, 588 00:34:59,520 --> 00:35:02,360 potentially my, you know, move the logic that sets that 589 00:35:02,440 --> 00:35:04,320 environment variable out to somewhere else. 590 00:35:04,760 --> 00:35:06,640 But then we were reading through the documentation. 591 00:35:06,640 --> 00:35:09,120 I hadn't even known that the other possible side effects were 592 00:35:09,120 --> 00:35:12,560 reading a file, and so it seems theoretically possible that I 593 00:35:12,560 --> 00:35:17,000 could read, you know, the git git information from a file or 594 00:35:17,000 --> 00:35:19,200 something like that. Which maybe, I don't know how 595 00:35:19,200 --> 00:35:20,880 hard person to read that file is. 596 00:35:21,840 --> 00:35:25,720 It seems like maybe there's some potential way to to get to what 597 00:35:25,720 --> 00:35:28,960 I was trying to do there. There certainly is through 598 00:35:28,960 --> 00:35:31,320 environment variables, but maybe through the file access if the 599 00:35:31,320 --> 00:35:32,960 if. The file in question is Jason or 600 00:35:32,960 --> 00:35:34,360 Yamo. We actually have parsers for 601 00:35:34,360 --> 00:35:36,320 that and pickle that. You can use to consume it as if 602 00:35:36,320 --> 00:35:40,280 it's a pickle structure. Yeah, but so, so for that kind 603 00:35:40,280 --> 00:35:44,080 of scenario that we do have that instrumentation specifically for 604 00:35:44,080 --> 00:35:48,000 that so that you can read that you know git repo state or 605 00:35:48,000 --> 00:35:51,800 something, but only once per execution and that's that's a 606 00:35:51,800 --> 00:35:53,760 distinct choice. That's where it's not a general 607 00:35:53,760 --> 00:35:56,320 purpose language. That's where it really has that 608 00:35:56,600 --> 00:35:58,560 that application of configuration in mind. 609 00:35:58,920 --> 00:36:01,680 Yeah, well, no. I have thought about it totally 610 00:36:01,680 --> 00:36:05,000 fine to to to have that single read. 611 00:36:06,160 --> 00:36:08,400 That would be fine for that particular use case. 612 00:36:09,320 --> 00:36:13,480 Right I I have thought about just to nerd out and if if this 613 00:36:13,480 --> 00:36:15,720 is too far down the rabbit hole for your taste then I like it 614 00:36:15,720 --> 00:36:18,640 homies, let me know. But about the DAG problem, 615 00:36:19,800 --> 00:36:23,120 because you can use pickle as a library, and because it is lazy, 616 00:36:23,640 --> 00:36:25,480 The thing when you use it as a library, you can make 617 00:36:25,480 --> 00:36:27,680 consecutive calls to read properties. 618 00:36:30,240 --> 00:36:33,680 And since properties are only evaluated when asked for them, 619 00:36:34,720 --> 00:36:38,600 you could basically ask for the stage 1 result interpret in your 620 00:36:38,600 --> 00:36:41,320 programming language, whatever you need to interpret, run your 621 00:36:41,440 --> 00:36:46,400 your your build stage, read your file, inform it, and then in the 622 00:36:46,400 --> 00:36:49,520 next stage have pickle read an environment variable that you 623 00:36:49,520 --> 00:36:52,480 only set when you call back into, yeah, pickle. 624 00:36:52,880 --> 00:36:56,320 So there's. There is a potential way to to 625 00:36:56,360 --> 00:36:59,800 create a terrain complete system there with. 626 00:37:00,400 --> 00:37:01,760 But you don't. Well, you don't have a feedback 627 00:37:01,760 --> 00:37:03,720 loop unless you build it explicitly, right? 628 00:37:04,240 --> 00:37:07,040 And that means that it's still very unlikely that you shoot 629 00:37:07,040 --> 00:37:11,160 yourself in the foot. Yeah, so other features that are 630 00:37:11,160 --> 00:37:15,160 worth highlighting, nullability, being built in, I love. 631 00:37:16,040 --> 00:37:19,920 I've been doing a lot of Kotlin and so it definitely seems like 632 00:37:19,920 --> 00:37:24,680 pickle has some common language features with with Kotlin like 633 00:37:24,680 --> 00:37:27,440 nullability and it just is one of those things where I'm like 634 00:37:27,560 --> 00:37:31,200 oh thank God that's in there and I don't have to deal with with 635 00:37:31,320 --> 00:37:33,600 null pointer exceptions and all that. 636 00:37:33,600 --> 00:37:37,520 So and then the nice like do you? 637 00:37:37,520 --> 00:37:40,120 Does pickle use the Elvis operator for a default value on 638 00:37:40,120 --> 00:37:42,160 a nullable I? Forgot we have the the double 639 00:37:42,160 --> 00:37:43,800 question mark. OK, double question. 640 00:37:43,800 --> 00:37:46,280 But yes, null coalescence is extremely important. 641 00:37:46,280 --> 00:37:49,000 Like nullability is nowhere near as comfortable without us. 642 00:37:49,320 --> 00:37:52,000 Yeah yeah. And for configuration like the 643 00:37:52,000 --> 00:37:56,360 last thing you want is is to have a null like crash your 644 00:37:56,360 --> 00:37:59,480 production system. So yeah, having that in there is 645 00:37:59,480 --> 00:38:02,240 is huge. And then I think the other 646 00:38:02,240 --> 00:38:05,240 language features, I think that there's something like some 647 00:38:05,240 --> 00:38:08,360 types in pickle. Am I remembering that correctly? 648 00:38:08,360 --> 00:38:10,360 Like the ability. So it's like an enum, right? 649 00:38:10,440 --> 00:38:13,840 There is enum so it's it's essentially like like the the 650 00:38:13,840 --> 00:38:17,000 way to create a some type. Enum is also a little bit of of 651 00:38:17,000 --> 00:38:20,080 a term that depends what language you're from, how you 652 00:38:20,080 --> 00:38:21,680 interpret it. Enum is a different thing in 653 00:38:21,680 --> 00:38:24,240 Swift than it is in No Camel, and it's different there than it 654 00:38:24,240 --> 00:38:29,080 is in Go. But we have we have union types 655 00:38:30,360 --> 00:38:33,560 and the the sort of the base case enum where you just have 656 00:38:33,560 --> 00:38:38,840 static labels. Basically as a subtype of int is 657 00:38:38,920 --> 00:38:41,080 an A union of string literal types. 658 00:38:41,520 --> 00:38:44,680 So string literal types is where where the type is 1 string 659 00:38:44,680 --> 00:38:46,600 constant. So it can only be precisely That 660 00:38:46,600 --> 00:38:49,760 String is incredibly useful. I love this. 661 00:38:50,880 --> 00:38:52,720 Yeah. Yeah, when when I was doing the 662 00:38:52,720 --> 00:38:57,080 GitHub Action thing, it's like there's let's say platforms and 663 00:38:57,080 --> 00:38:59,240 platforms in GitHub Actions. You know, there's twelve 664 00:38:59,240 --> 00:39:01,040 different options for platforms or whatever. 665 00:39:01,280 --> 00:39:04,320 And the fact that I get like code completion on the possible 666 00:39:04,320 --> 00:39:07,720 platforms when I when I set that property or the platform 667 00:39:07,720 --> 00:39:10,360 property just like, oh thank God amazing. 668 00:39:10,920 --> 00:39:13,920 Right, but it's. But that is not just normal like 669 00:39:13,960 --> 00:39:15,960 limited enum. So it's not strictly of some 670 00:39:15,960 --> 00:39:18,800 type, right? It's a type union. 671 00:39:18,960 --> 00:39:23,200 So you can do you know my dev environment and my prod 672 00:39:23,200 --> 00:39:27,600 environment and my QA environment or string. 673 00:39:28,000 --> 00:39:31,600 And that means you get the autocomplete right? 674 00:39:31,600 --> 00:39:35,960 Because the alternatives are known to the IDE, but also you 675 00:39:35,960 --> 00:39:38,440 have the flexibility to do the the thing. 676 00:39:39,040 --> 00:39:40,360 Escape. Yeah, yeah. 677 00:39:40,360 --> 00:39:42,280 You have the escape edge for your system where you know what 678 00:39:42,280 --> 00:39:45,440 you're doing, yeah? Yeah, so just to summarize that, 679 00:39:45,440 --> 00:39:53,360 you can you can define a type which is Windows X86 or Linux 680 00:39:53,360 --> 00:39:59,720 X86 or string and that gives you the ability to then then have a 681 00:39:59,720 --> 00:40:04,520 property of that type that can be those two that I said or just 682 00:40:04,520 --> 00:40:08,640 whatever the user wants. So, but that's if you want that. 683 00:40:08,640 --> 00:40:11,280 If you really did want to constrain the user to just the 684 00:40:11,280 --> 00:40:14,040 two that you have have specified, then don't put. 685 00:40:14,120 --> 00:40:15,320 With the OR string on the end right. 686 00:40:15,760 --> 00:40:19,720 Exactly, exactly. Yeah, so so union types. 687 00:40:20,520 --> 00:40:24,320 Great feature there. Yeah, there are so many 688 00:40:24,320 --> 00:40:27,560 out-of-the-box like string functions which which I found 689 00:40:27,560 --> 00:40:31,200 really handy for. It's like why would I want to 690 00:40:31,440 --> 00:40:35,880 have to have some preprocessor for my configuration just so 691 00:40:35,880 --> 00:40:40,040 that I can like do do some little string manipulation in my 692 00:40:40,040 --> 00:40:41,920 configuration. So great to just have those 693 00:40:41,920 --> 00:40:47,000 things built in, like lists, maps, listings, listings. 694 00:40:47,000 --> 00:40:52,560 Yeah, question for you. Give us the reasoning for the 695 00:40:52,560 --> 00:40:57,920 naming convention there of listings and mappings Set 696 00:40:58,080 --> 00:41:00,880 settings. Yeah, this is weird huh? 697 00:41:01,000 --> 00:41:03,440 Set gets cuz there is a set right? 698 00:41:03,560 --> 00:41:07,360 But we don't have settings. Because that would be. 699 00:41:07,680 --> 00:41:09,280 Confusing. That would be weird, yeah. 700 00:41:09,800 --> 00:41:15,520 But also the things, the things that we have are are are 701 00:41:15,520 --> 00:41:20,960 structurally not set. So because of the underlying 702 00:41:20,960 --> 00:41:23,880 framework we wrote this on, on Truffle, which is a language 703 00:41:23,880 --> 00:41:26,200 framework, you write an interpreter, you get a compiler. 704 00:41:27,360 --> 00:41:29,880 It is. It is a very nice and powerful 705 00:41:29,880 --> 00:41:35,040 framework, but but it does lead to some sort of operations being 706 00:41:35,040 --> 00:41:38,160 more expensive than others for us with immutability and the 707 00:41:38,160 --> 00:41:40,920 like. So if you do a whole bunch of 708 00:41:40,920 --> 00:41:45,840 like, filter, filter, map, map, map, sort of things on your 709 00:41:45,840 --> 00:41:48,800 collections, then at some point that becomes expensive. 710 00:41:48,800 --> 00:41:52,920 We didn't optimize for that. At some point we might, you 711 00:41:52,920 --> 00:41:55,880 know, if someone has a bright idea on how to do it, great. 712 00:41:56,640 --> 00:42:00,400 But we had sort of basically these two different scenarios. 713 00:42:00,400 --> 00:42:04,560 One was optimized for notation and those are the things, so the 714 00:42:04,560 --> 00:42:10,040 listing and the mapping and and the other one is OK. 715 00:42:10,040 --> 00:42:13,520 At some point you want to do all those computations because you 716 00:42:13,520 --> 00:42:17,840 know you simply need to to sum all the resources that you've 717 00:42:17,840 --> 00:42:20,320 defined for your system, or you know stuff like that. 718 00:42:22,040 --> 00:42:24,640 And so the the the short versions list, map, set. 719 00:42:25,120 --> 00:42:29,120 They're made for computation and you can go back and forth 720 00:42:29,120 --> 00:42:31,320 between them. Yeah, yeah. 721 00:42:31,320 --> 00:42:34,440 So two different APIs for working with with collection 722 00:42:34,440 --> 00:42:37,080 structures. Well, two different ones for 723 00:42:37,080 --> 00:42:41,760 each type of collection. So List and listings and so 724 00:42:42,000 --> 00:42:45,160 depending on what you're doing and what you need, you can pick 725 00:42:45,160 --> 00:42:48,480 between those those two for a list structure. 726 00:42:48,720 --> 00:42:53,680 So there's yeah lists, then there's maps, but no set. 727 00:42:55,280 --> 00:42:58,520 So there is a set, but not a setting because there's this one 728 00:42:58,520 --> 00:43:01,160 other language feature that is so transparent in pickle. 729 00:43:01,160 --> 00:43:04,960 I was I was kind of just hearing you out on language features to 730 00:43:04,960 --> 00:43:09,160 see whether you would mention it because the foundational 731 00:43:09,160 --> 00:43:13,760 language feature is amending. So it's where you say this 732 00:43:13,760 --> 00:43:18,440 object is like that object except and what that does in 733 00:43:18,440 --> 00:43:23,680 file hierarchies is you can you can say this file amends dot dot 734 00:43:23,680 --> 00:43:26,240 dot which means you know go up until you find a file with the 735 00:43:26,240 --> 00:43:30,800 same name as me and then everything else in the file is 736 00:43:30,880 --> 00:43:33,720 except. So you can make these things 737 00:43:33,720 --> 00:43:37,520 where you have your service definition and then you make AQA 738 00:43:37,760 --> 00:43:41,160 sub definition that says it's exactly like the the normal 739 00:43:41,160 --> 00:43:46,600 production service but with only one, only one core or you know 740 00:43:47,080 --> 00:43:49,240 on a different cluster or stuff like that. 741 00:43:50,160 --> 00:43:52,120 And then that's the one thing that you see. 742 00:43:52,840 --> 00:43:54,360 And we also have that in objects. 743 00:43:54,360 --> 00:43:57,560 So you can say this object is like that object except so you 744 00:43:57,560 --> 00:44:00,400 say object name between parentheses and then curly 745 00:44:00,400 --> 00:44:04,680 grace, and then you start saying these things are now different 746 00:44:04,920 --> 00:44:07,960 from from that other thing, and that's incredibly powerful. 747 00:44:08,200 --> 00:44:11,640 An override. It's an override, yes, but it's, 748 00:44:11,640 --> 00:44:13,440 so it's. It's a prototype override, 749 00:44:13,600 --> 00:44:17,080 right? Like JavaScript objects, OK, the 750 00:44:17,120 --> 00:44:21,480 type overwrite sure, because it's value value chaining. 751 00:44:22,360 --> 00:44:27,600 OK, so amends with settings would be problematic. 752 00:44:27,600 --> 00:44:32,200 Is that what you're getting at? So for collections amends is 753 00:44:32,440 --> 00:44:36,080 additive, like for properties. If you have an object with you 754 00:44:36,080 --> 00:44:41,160 know, CPUs and memory, then if I amend it and say CPUs is five, 755 00:44:41,400 --> 00:44:46,000 then clearly that should mean it overwrites the the existing 756 00:44:46,000 --> 00:44:48,120 property. But for collections that's not 757 00:44:48,120 --> 00:44:51,400 necessarily the obvious thing. For like lists it it it's 758 00:44:51,400 --> 00:44:54,160 actually slightly more obvious to add stuff. 759 00:44:54,880 --> 00:44:58,760 So if you amend a listing then you add elements to it. 760 00:45:02,000 --> 00:45:05,080 So that sounds a little finicky, but if you see it written down, 761 00:45:05,240 --> 00:45:07,840 it just makes more sense it. Makes sense, yeah, yeah. 762 00:45:08,280 --> 00:45:11,080 And mappings as well, right? You if if there you have the 763 00:45:11,080 --> 00:45:14,640 ambivalence that if keys already exist then you change the key, 764 00:45:15,320 --> 00:45:17,200 so then you override. If the keys don't exist, then 765 00:45:17,200 --> 00:45:20,160 you add the key. Yeah, and so is it. 766 00:45:20,160 --> 00:45:26,640 Was there a a challenge with doing settings because of the 767 00:45:26,640 --> 00:45:29,320 amend amending? Well, if it's strictly additive, 768 00:45:29,320 --> 00:45:31,920 you get an order problem. Right now it becomes very hard 769 00:45:31,920 --> 00:45:34,240 to understand what you actually intended, but you can just have 770 00:45:34,240 --> 00:45:36,640 a listing and at the end of it say I want that listing except 771 00:45:36,640 --> 00:45:38,480 distinct. Yeah, and distinct. 772 00:45:38,480 --> 00:45:40,240 We give you this, yeah. Sure. 773 00:45:40,240 --> 00:45:45,640 Yeah. And then with errors, you do not 774 00:45:45,640 --> 00:45:48,960 have any recovery mechanism. Everything is basically a panic. 775 00:45:48,960 --> 00:45:51,800 Is that correct? Yes, because otherwise you can 776 00:45:51,800 --> 00:45:53,920 make errors into a Turing machine as well. 777 00:45:53,920 --> 00:45:57,720 And then and then yeah. So ultimately you shouldn't want 778 00:45:57,720 --> 00:45:59,960 to catch 'cause if you want to. If you're doing a catch, you're 779 00:45:59,960 --> 00:46:03,120 you're doing a type of computation that isn't the 780 00:46:03,120 --> 00:46:06,720 conflict domain, and you're making it hard to follow where 781 00:46:06,720 --> 00:46:10,360 values come from. Where do you see people using 782 00:46:10,360 --> 00:46:13,440 the exception or panic mechanism and pickle? 783 00:46:13,440 --> 00:46:15,040 What do? What do people use that for? 784 00:46:17,360 --> 00:46:22,920 I mean, they use it for for more complicated failures. 785 00:46:22,920 --> 00:46:27,520 So sometimes you layout your config because you have a target 786 00:46:27,520 --> 00:46:30,280 system and you want to lay it out the way it's laid out in the 787 00:46:30,280 --> 00:46:32,720 target system. But that does sometimes mean 788 00:46:33,640 --> 00:46:38,520 that the targets if the target system's layout is not designed 789 00:46:38,520 --> 00:46:41,160 to avoid non existent states or illegal states. 790 00:46:41,720 --> 00:46:46,520 So if they are expressible then they are expressible in your, in 791 00:46:46,520 --> 00:46:50,120 your set up, in your configuration, in your template. 792 00:46:50,440 --> 00:46:58,080 So a way to then to catch that is is when when you have a null 793 00:46:58,080 --> 00:47:00,560 when it shouldn't be. At some point you have a 794 00:47:00,560 --> 00:47:02,240 function that makes a non nullable. 795 00:47:02,800 --> 00:47:05,640 That makes it a nullable and non nullable simply by asserting. 796 00:47:06,280 --> 00:47:08,200 OK, that's a point where it might break. 797 00:47:08,240 --> 00:47:09,520 And if it breaks, what do you do? 798 00:47:09,520 --> 00:47:11,960 Well, there's no recovery that's meaningful in that position. 799 00:47:12,520 --> 00:47:14,160 So the only recovery is an error. 800 00:47:15,720 --> 00:47:19,400 I see. So so uh, you may have a case 801 00:47:19,400 --> 00:47:24,440 where you've got some particular set in and some systems it can 802 00:47:24,440 --> 00:47:29,120 can be null and that's OK. But then in some other places 803 00:47:29,120 --> 00:47:31,720 you actually don't want to allow the null, but you want to reuse 804 00:47:31,720 --> 00:47:34,080 that property. And so in those systems you can 805 00:47:34,080 --> 00:47:36,800 say, all right here I'm going to now throw throw the exception 806 00:47:36,800 --> 00:47:40,000 which is going to panic and not allow the configuration to be 807 00:47:40,000 --> 00:47:42,600 generated for for that one because I haven't said it. 808 00:47:43,120 --> 00:47:46,320 Yeah, and so there's there's one other thing that I've started 809 00:47:46,320 --> 00:47:50,760 using it for, and that is when you have things that simply fail 810 00:47:50,760 --> 00:47:54,960 hard when constraints on types, right, you can have arbitrary 811 00:47:54,960 --> 00:47:56,600 functions there. You can say that you know a 812 00:47:56,600 --> 00:48:00,840 string that only contains letters, hyphens, and and digits 813 00:48:00,840 --> 00:48:03,120 because it's a name that goes to a system somewhere. 814 00:48:03,920 --> 00:48:09,360 OK, great. Now that that function, when 815 00:48:09,360 --> 00:48:12,120 that fails, you get a regular expression didn't match. 816 00:48:13,800 --> 00:48:15,560 This is still a straightforward example. 817 00:48:15,560 --> 00:48:19,200 You can see you know node name has to match this regular 818 00:48:19,200 --> 00:48:21,840 expression and this condition failed. 819 00:48:21,840 --> 00:48:26,200 OK, that might be comprehensible for someone who experiences the 820 00:48:26,200 --> 00:48:29,240 error, but very often there's a distance between the template 821 00:48:29,240 --> 00:48:32,400 author and the end user. And so instead of doing that, 822 00:48:32,400 --> 00:48:36,760 you can say condition or condition or condition or throw 823 00:48:37,680 --> 00:48:40,320 and then a message that is an actual explanation of the 824 00:48:40,320 --> 00:48:44,440 specific constraint that failed. So you have a node name here 825 00:48:44,600 --> 00:48:47,920 which may only contains these these symbols because it goes to 826 00:48:47,920 --> 00:48:50,520 that system and that system only accepts that and otherwise it 827 00:48:50,520 --> 00:48:53,160 breaks. Yeah, you know, so you can make 828 00:48:53,160 --> 00:48:57,520 it more informative so you can actually throw is very important 829 00:48:57,520 --> 00:49:01,360 for UX is what I'd say. Yeah that makes sense giving 830 00:49:01,360 --> 00:49:03,720 people good error messages. And I just want to come back and 831 00:49:03,720 --> 00:49:06,760 highlight this because another great language feature is the 832 00:49:06,760 --> 00:49:10,360 conditions. So you can define and and it's 833 00:49:10,360 --> 00:49:12,920 been a while since I've played with conditions so you can 834 00:49:12,920 --> 00:49:16,360 correct me if I'm wrong. But what I remember is that I 835 00:49:16,360 --> 00:49:20,360 can have a type like let's say a string, and then on that string 836 00:49:20,360 --> 00:49:24,680 I can set conditions must start with an uppercase letter for 837 00:49:24,680 --> 00:49:30,120 example, and I will get an error when I try to actually evaluate 838 00:49:30,120 --> 00:49:34,120 my pickle if I try to give set this property to a string that 839 00:49:34,120 --> 00:49:35,600 doesn't start with an uppercase letter. 840 00:49:35,880 --> 00:49:38,120 So I think in functional programming world we would call 841 00:49:38,120 --> 00:49:40,520 this like almost like value dependent types or something 842 00:49:40,520 --> 00:49:43,680 like that where you can't actually construct that string 843 00:49:43,680 --> 00:49:47,840 and set it to something unless your conditions are valid. 844 00:49:48,240 --> 00:49:51,120 Did I get any of that right? No, you got that exactly right, 845 00:49:51,120 --> 00:49:53,880 except we call them constraints, not conditions. 846 00:49:54,960 --> 00:49:58,680 Other than that, spot on and it's and it is very. 847 00:49:58,880 --> 00:50:01,760 Out-of-the-box ones that you can use and then you can create your 848 00:50:01,760 --> 00:50:03,120 own. So it's a different way to 849 00:50:03,120 --> 00:50:06,080 create a type. I mean, because you are by 850 00:50:06,280 --> 00:50:09,360 putting that constraint on it, you're defining a new type, 851 00:50:09,400 --> 00:50:11,120 yeah? And and you have pattern 852 00:50:11,120 --> 00:50:12,920 matching. I mean not pattern matching, but 853 00:50:12,920 --> 00:50:14,800 regular expressions. You said as well. 854 00:50:14,800 --> 00:50:18,680 We have regular expressions and. But, but. 855 00:50:18,680 --> 00:50:21,920 But these constraints can be arbitrary functions, sure, so. 856 00:50:21,920 --> 00:50:26,680 So these can be anything, right? And indeed that is exactly like 857 00:50:26,680 --> 00:50:29,080 dependent types. But the downside of a 858 00:50:29,080 --> 00:50:33,120 dependently typed language like a, an Idris or a or a these 859 00:50:33,120 --> 00:50:36,840 sorts of things is that as like whatever you write down in the 860 00:50:36,840 --> 00:50:42,880 type you must provide a proof for, and that proof is is in 861 00:50:42,880 --> 00:50:44,760 code. But then a whole separate sort 862 00:50:44,760 --> 00:50:48,480 of can of problems is how do you now prevent other other 863 00:50:48,480 --> 00:50:51,040 programmers from ever using that code? 864 00:50:51,040 --> 00:50:53,880 Because that code was never intended to be used as a value, 865 00:50:53,880 --> 00:50:57,000 and it's very expensive, so you don't actually want to compute 866 00:50:57,000 --> 00:50:59,000 it, you know so. So it's it's awful. 867 00:50:59,960 --> 00:51:03,800 It's an awful lot of work for a noble 'cause we just check 868 00:51:03,800 --> 00:51:06,680 values as they pass. Yeah, that's and that's the 869 00:51:06,680 --> 00:51:09,840 great thing about pickle. Because of the constraints, it 870 00:51:09,840 --> 00:51:13,120 allows you to have essentially value dependent types, but 871 00:51:13,120 --> 00:51:16,160 without all of the pain and headache normally associated 872 00:51:16,160 --> 00:51:19,200 with value dependent types. Exactly, exactly. 873 00:51:19,200 --> 00:51:22,720 So you you you are as expressive in your constraints as with full 874 00:51:22,720 --> 00:51:25,360 dependent types and you have to do none of the work. 875 00:51:25,680 --> 00:51:29,040 Yeah, it's amazing. One of the really cool things 876 00:51:29,040 --> 00:51:32,200 about pickle and and this can apply. 877 00:51:32,240 --> 00:51:34,920 You can apply constraints to any type, right? 878 00:51:34,920 --> 00:51:38,160 So if you want to constrain an int to be within a specific 879 00:51:38,160 --> 00:51:42,680 range, you can do that. Yeah, and then think of what 880 00:51:42,680 --> 00:51:46,880 that does to union types and collection types. 881 00:51:47,000 --> 00:51:51,080 Because if I have a mapping of string to int, then I can put a 882 00:51:51,080 --> 00:51:53,560 constraint on the string, I can put a constraint on the int, I 883 00:51:53,560 --> 00:51:55,240 can put a constraint on the entire mapping. 884 00:51:55,560 --> 00:52:00,360 Yeah, And with unions I can have all kinds of separate types of 885 00:52:01,840 --> 00:52:04,160 things that I'll accept. So it's a super powerful 886 00:52:04,160 --> 00:52:08,080 mechanism. Yeah, and for me, I guess this 887 00:52:08,080 --> 00:52:10,240 is the Haskell ISM or something like that, which I've never 888 00:52:10,240 --> 00:52:14,440 really done Haskell, but I love the philosophy of make illegal 889 00:52:14,440 --> 00:52:18,400 states unrepresentable, and to be able to do that in 890 00:52:18,400 --> 00:52:21,640 configuration back to where we started in this conversation was 891 00:52:21,840 --> 00:52:26,320 being able to verify that my configuration is correct before 892 00:52:26,320 --> 00:52:30,000 I push it out to production. This is just one more piece to 893 00:52:30,080 --> 00:52:31,720 being able. To well and you combine that 894 00:52:31,720 --> 00:52:35,560 with immutability means that you go, OK, I created this thing 895 00:52:35,560 --> 00:52:37,520 successfully. I never have to think about it 896 00:52:37,520 --> 00:52:41,000 again. Yeah, yeah. 897 00:52:41,000 --> 00:52:44,080 And and and what is it? It's what you wrote down. 898 00:52:44,480 --> 00:52:46,720 Yes, right. Exactly. 899 00:52:46,920 --> 00:52:49,640 But what if this happens first? There is no first does not 900 00:52:49,640 --> 00:52:51,120 exist. That's right. 901 00:52:51,120 --> 00:52:53,960 And where did the idea of constraints come from? 902 00:52:53,960 --> 00:52:57,000 Is this? Did did you invent that for this 903 00:52:57,000 --> 00:52:59,160 language or did you find it somewhere else? 904 00:53:00,120 --> 00:53:02,280 I mean there. So there is the notion of 905 00:53:02,280 --> 00:53:04,920 dependent types that are essentially the same thing. 906 00:53:05,040 --> 00:53:09,360 OK, but in in this case specifically, it's OK Now you've 907 00:53:09,360 --> 00:53:13,000 got string and int and such checking, but now you still make 908 00:53:13,000 --> 00:53:15,760 typos, you just don't make it in your YAML structure, you make it 909 00:53:15,760 --> 00:53:18,720 in your identifier. But but you're still a foot gone 910 00:53:18,720 --> 00:53:25,000 away from from an outage, right? So OK, now these these 911 00:53:25,000 --> 00:53:28,560 identifiers should actually be this limited set or should all 912 00:53:28,560 --> 00:53:31,480 comply with this or you know? Yeah. 913 00:53:32,200 --> 00:53:35,000 But the number shouldn't be a billion. 914 00:53:36,320 --> 00:53:41,280 But I could see this concept being used being added to a lot 915 00:53:41,280 --> 00:53:43,280 of other languages as well. That's what I'm. 916 00:53:43,520 --> 00:53:48,240 But you can't in a general purpose language without a lot 917 00:53:48,240 --> 00:53:52,440 of challenges because the. So the typical way that you 918 00:53:52,440 --> 00:53:57,200 would do this in a in a non dependently typed language is 919 00:53:57,520 --> 00:54:01,560 when you you would have like a constructor function and then 920 00:54:01,560 --> 00:54:04,480 you would apply your constraints on that and then you would like 921 00:54:04,480 --> 00:54:09,160 return an Option to say like hey you know you're I'm giving you a 922 00:54:09,160 --> 00:54:12,440 none back because or a null or something because I couldn't 923 00:54:12,440 --> 00:54:15,360 actually validate that this was correct. 924 00:54:15,560 --> 00:54:19,840 But in the case of pickle, because it's constrained, it can 925 00:54:19,840 --> 00:54:23,680 actually say I'm not going to actually allow you to construct 926 00:54:23,680 --> 00:54:26,320 this type when I evaluate your configuration. 927 00:54:26,560 --> 00:54:30,520 Because it's it's been able to run the the constraints before 928 00:54:30,520 --> 00:54:34,240 construction of of the thing. And because it's like, you know, 929 00:54:34,360 --> 00:54:37,120 kind of, I'm thinking about it as like a single pass through 930 00:54:37,120 --> 00:54:41,800 the configuration processing. It can then stop and say I'm not 931 00:54:41,800 --> 00:54:44,200 going to allow this configuration processing to 932 00:54:44,200 --> 00:54:49,840 continue because you you did not pass me a valid value for this 933 00:54:49,840 --> 00:54:51,880 thing. Yeah, that's exactly right. 934 00:54:52,320 --> 00:54:54,720 Yes. And it only happens when you 935 00:54:54,720 --> 00:54:59,360 need it, right. So the other thing is you can 936 00:54:59,360 --> 00:55:06,480 write down these these, you can write down expressions that are 937 00:55:06,480 --> 00:55:12,160 not well typed wilfully. As long as you don't use them, 938 00:55:12,800 --> 00:55:15,840 you know that doesn't matter, they don't get evaluated. 939 00:55:16,120 --> 00:55:19,240 And so for the constraints the you can write arbitrary 940 00:55:19,240 --> 00:55:22,160 functions because unlike with the normal with with let's say 941 00:55:22,240 --> 00:55:25,480 Kotlin or Swift or Java, you compile right? 942 00:55:25,480 --> 00:55:27,560 And at compile time you have to check the types. 943 00:55:27,560 --> 00:55:31,040 That means that you infer all the possible type, all the 944 00:55:31,040 --> 00:55:35,400 possible values that could happen in a space, what types do 945 00:55:35,400 --> 00:55:37,200 they have? And then check it against the 946 00:55:37,200 --> 00:55:42,360 declare types. We don't have to do that because 947 00:55:42,880 --> 00:55:46,320 at the time that we compile is the same time that we run. 948 00:55:46,320 --> 00:55:49,520 So whatever values we see, we can check because we don't have 949 00:55:49,520 --> 00:55:53,200 to extrapolate all values, we just have the values that we 950 00:55:53,200 --> 00:55:56,320 actually see, yeah? Exactly, yeah. 951 00:55:56,320 --> 00:55:59,680 So being able to not having a compile that creates a program 952 00:55:59,680 --> 00:56:02,960 that then at runtime wants to apply constraints, you just 953 00:56:03,160 --> 00:56:07,040 you're in like 1 one phase of. Now you go through the whole 954 00:56:07,040 --> 00:56:08,360 thing and make sure it's all valid. 955 00:56:09,720 --> 00:56:17,600 Exactly. Yeah, you I noticed you have a, 956 00:56:17,960 --> 00:56:22,400 you know, a limited set of output formats that like you 957 00:56:22,400 --> 00:56:26,120 don't include Tamil for example. Are you going? 958 00:56:26,120 --> 00:56:29,120 Is that just because, oh, we're just getting started and we will 959 00:56:29,120 --> 00:56:33,680 add other output formats? We've even been discussing 960 00:56:33,680 --> 00:56:37,400 whether we should be removing output formats as in as in. 961 00:56:37,400 --> 00:56:40,440 Let me caveat that. Very importantly, no panic. 962 00:56:41,600 --> 00:56:44,920 There is a tomo renderer that we have in pickle pantry. 963 00:56:44,920 --> 00:56:50,640 So in pickle you can write a valid renderer for tomo, and so 964 00:56:50,640 --> 00:56:52,360 we've been talking. About reusability. 965 00:56:52,720 --> 00:56:56,480 Because there is reusability. A renderer and the renderer then 966 00:56:56,480 --> 00:56:58,960 does your. So it's great that renderers are 967 00:56:58,960 --> 00:57:03,640 not built into it, they're actually just calling other 968 00:57:03,640 --> 00:57:05,960 pickled things to do the rendering, right? 969 00:57:06,640 --> 00:57:10,680 Exactly right now, except that some renderings become very 970 00:57:10,680 --> 00:57:12,440 involved. You wouldn't it. 971 00:57:12,480 --> 00:57:16,120 It's surprising if you think that Yamo was actually intended 972 00:57:16,120 --> 00:57:20,720 to simplify syntax, but rendering YAML involves a lot of 973 00:57:20,720 --> 00:57:23,520 decisions about do I actually need to quote this string? 974 00:57:23,520 --> 00:57:26,680 And you know, people prefer unquoted string, so if I don't 975 00:57:26,680 --> 00:57:29,840 need to quote this string, I'm going to put it on unquoted. 976 00:57:29,840 --> 00:57:31,920 So are there spaces in? Are there new lines in? 977 00:57:31,920 --> 00:57:32,840 Isn't it? Remember. 978 00:57:32,840 --> 00:57:35,720 The winner tech form where we're like reading the YAML spec and 979 00:57:35,720 --> 00:57:38,840 we're like, is this thing supposed to be quoted or not? 980 00:57:39,000 --> 00:57:42,760 And it's like, what's the correct list syntax for this 981 00:57:42,760 --> 00:57:45,280 given thing? And then there was actually 982 00:57:45,280 --> 00:57:49,720 differences between the YAML spec version for different ways 983 00:57:49,720 --> 00:57:51,880 that it handled those things. And it's like, wait, which 984 00:57:51,880 --> 00:57:54,360 version of the YAML spec does GitHub Actions use? 985 00:57:54,400 --> 00:57:56,640 I don't even know. You know it's. 986 00:57:56,720 --> 00:57:58,240 Minor versions might I add. Oh. 987 00:57:58,680 --> 00:58:00,200 My God. Oh my God. 988 00:58:00,920 --> 00:58:04,520 Which is also for for the point about Tamil is uh, at the moment 989 00:58:04,800 --> 00:58:08,720 we're still awaiting Tamil 1.1, I think. 990 00:58:08,720 --> 00:58:10,720 I think at this point I'm not entirely sure. 991 00:58:11,840 --> 00:58:13,840 It might not even it might have stalled entirely. 992 00:58:14,320 --> 00:58:20,520 Yeah so yeah who knows. So very possible and to create a 993 00:58:20,520 --> 00:58:23,200 Tamil render and there is one that exists in the pickle 994 00:58:23,200 --> 00:58:26,000 pantry. Two quick things I want to one 995 00:58:26,000 --> 00:58:30,200 thing I want to ask about first. Is there a future that you 996 00:58:30,200 --> 00:58:35,720 imagine where instead of having to have the yaml file for GitHub 997 00:58:35,720 --> 00:58:40,320 actions or Kubernetes or whatever, where I just give 998 00:58:40,400 --> 00:58:43,960 GitHub actions my pickle file and it deals with it? 999 00:58:44,360 --> 00:58:47,440 Or is that not the future that that I should hope for? 1000 00:58:48,040 --> 00:58:51,440 I I I mean, everyone in the future will use pickle of 1001 00:58:51,440 --> 00:58:55,160 course. I mean, if I can help it, sure. 1002 00:58:56,800 --> 00:59:00,400 There's there's just a AWS cloud Foundation just published their 1003 00:59:00,400 --> 00:59:02,680 their templates. So it's starting. 1004 00:59:05,280 --> 00:59:07,080 Will we conquer the entire world? 1005 00:59:07,080 --> 00:59:08,280 You. Just give it a pickle file and 1006 00:59:08,280 --> 00:59:10,880 that's all they need. You just give it a pickle file. 1007 00:59:10,880 --> 00:59:12,400 That's it. That's the definition you give. 1008 00:59:12,400 --> 00:59:14,160 That's the authoritative definition. 1009 00:59:14,560 --> 00:59:16,480 Love it. So yeah. 1010 00:59:16,520 --> 00:59:21,800 And I I genuinely believe that that it solves problems as your 1011 00:59:21,800 --> 00:59:24,680 reaction as as reactions that we've seen from community. 1012 00:59:25,600 --> 00:59:31,280 It genuinely solves problems and and people everywhere who who 1013 00:59:31,400 --> 00:59:35,440 work in like systems whether open source or or from large 1014 00:59:35,440 --> 00:59:38,800 corporations, right. They want to solve those 1015 00:59:38,800 --> 00:59:40,240 problems. That's why they're employed 1016 00:59:40,640 --> 00:59:42,560 right here is a tool. Yeah. 1017 00:59:42,840 --> 00:59:47,760 Fewer thumbs, better hammer. Because at the end of the day, 1018 00:59:47,760 --> 00:59:51,080 why do we need that intermediate representation? 1019 00:59:51,640 --> 00:59:56,080 It only It only is there because it's easy for GitHub Actions to 1020 00:59:56,080 --> 00:59:57,840 parse. It's easy for Kubernetes to 1021 00:59:57,840 --> 01:00:02,360 parse and do something with. But if we could give it a more 1022 01:00:02,360 --> 01:00:06,800 full-featured definition of what we're trying to do on this other 1023 01:00:06,800 --> 01:00:08,760 system. Why not? 1024 01:00:08,840 --> 01:00:10,520 Why? Why have to go through that 1025 01:00:10,520 --> 01:00:14,560 intermediate representation that's parsable when I could 1026 01:00:14,560 --> 01:00:19,560 just give it a pickle file, let it use pickle to then run the 1027 01:00:19,560 --> 01:00:23,800 pickle, maybe even programmatically, and then it 1028 01:00:23,800 --> 01:00:27,320 get an API to the configuration and decide what the system does. 1029 01:00:27,320 --> 01:00:30,040 And it's all sandboxed and all the wonderful, you know, 1030 01:00:30,040 --> 01:00:31,640 constraints that pickle provides. 1031 01:00:31,960 --> 01:00:36,640 So I certainly hope that we get to the point where pickle just 1032 01:00:36,640 --> 01:00:40,280 becomes the language and we don't even need the renders. 1033 01:00:40,280 --> 01:00:43,040 Anymore, because right now with GitHub Actions, to find out 1034 01:00:43,040 --> 01:00:46,080 whether your thing works, you actually have to run it. 1035 01:00:46,200 --> 01:00:49,200 Right to render the yaml and then give GitHub actions the 1036 01:00:49,200 --> 01:00:49,760 yaml. Uh huh. 1037 01:00:50,440 --> 01:00:52,160 And so you've gone from this. Very nice. 1038 01:00:52,320 --> 01:00:55,280 It's great that pickle can generate the yaml, but why? 1039 01:00:55,320 --> 01:00:57,960 Why is it even necessary? I'm just trying to tell GitHub 1040 01:00:58,440 --> 01:01:02,920 here is my workflow and I don't like, I don't wanna use this 1041 01:01:02,920 --> 01:01:06,400 very terrible declarative language to do that. 1042 01:01:06,480 --> 01:01:10,560 But what I'm saying is that if you're just using YAML for 1043 01:01:10,560 --> 01:01:16,160 GitHub Actions, you can't check it until you upload it to GitHub 1044 01:01:16,160 --> 01:01:19,600 Actions, whereas if you're using pickle, you get a whole bunch of 1045 01:01:19,600 --> 01:01:21,840 checks. So that's right, the schema 1046 01:01:21,840 --> 01:01:23,760 validation. Yeah, all of the validations 1047 01:01:23,760 --> 01:01:27,080 that I've started putting into you my GitHub Action, pickle 1048 01:01:27,080 --> 01:01:31,600 module all give you some level of confidence. 1049 01:01:31,800 --> 01:01:34,840 But you're you're right that GitHub Actions doesn't provide 1050 01:01:34,840 --> 01:01:39,360 any way to actually validate that the thing actually is valid 1051 01:01:39,600 --> 01:01:42,840 and tell you upload it up to to GitHub, right? 1052 01:01:43,160 --> 01:01:45,240 Yeah, and I think so. So an important bit there is 1053 01:01:45,240 --> 01:01:49,120 that a trade off? You said fast to parse, right? 1054 01:01:49,240 --> 01:01:52,520 And then we already discussed a whole bunch of ambiguities in in 1055 01:01:52,520 --> 01:01:53,240 YAML. So. 1056 01:01:53,280 --> 01:01:58,120 So, caveat. Caveat, yeah, but it's also that 1057 01:02:00,400 --> 01:02:03,080 where is that choice to be fast apart? 1058 01:02:03,080 --> 01:02:06,000 Where is that critical? If it's data that your system 1059 01:02:06,000 --> 01:02:08,680 rolled out, yeah, sure, you want it to be like, fast, but then 1060 01:02:08,680 --> 01:02:11,760 you also trust it if. If the whole point is that it 1061 01:02:11,760 --> 01:02:14,920 comes from human users with different levels of knowledge 1062 01:02:14,920 --> 01:02:17,400 about your system, calibrated on different versions of your 1063 01:02:17,400 --> 01:02:19,120 system with different histories, blah blah blah. 1064 01:02:19,200 --> 01:02:22,800 I don't know. Different locale settings, so 1065 01:02:23,240 --> 01:02:24,760 different kind of characters sneak in. 1066 01:02:27,040 --> 01:02:31,080 Maybe that's the side where you need to stick in some, you know, 1067 01:02:31,080 --> 01:02:38,000 instrumentation to safeguard invariants and and so that's if. 1068 01:02:38,280 --> 01:02:42,120 If that is the the cost consideration, that's a great 1069 01:02:42,120 --> 01:02:43,480 application for pickle, basically. 1070 01:02:46,040 --> 01:02:48,960 I sure hope that Kubernetes and gab actions and all these 1071 01:02:48,960 --> 01:02:51,920 systems just give me the ability to, well first give me the 1072 01:02:51,920 --> 01:02:56,880 schema like I want, the schema like that's that's critical, and 1073 01:02:56,880 --> 01:03:00,880 the ability in pickle to define the schema amazing. 1074 01:03:01,200 --> 01:03:03,920 Thank you for giving me the ability to at least validate 1075 01:03:03,920 --> 01:03:07,520 that this thing is correct before I upload it to you and 1076 01:03:07,520 --> 01:03:11,520 then give me the ability to just push my pickle file to you and 1077 01:03:11,520 --> 01:03:14,320 so that all that would be amazing. 1078 01:03:14,640 --> 01:03:17,280 And this is if I. Might point out if I might point 1079 01:03:17,280 --> 01:03:20,560 out just just on that point. Uh, there's also written in 1080 01:03:20,560 --> 01:03:23,840 pickle a thing that translates open API spec to a pickle 1081 01:03:23,840 --> 01:03:25,120 template. So. 1082 01:03:25,120 --> 01:03:27,640 So you want the templates. Well, if they don't give you the 1083 01:03:27,640 --> 01:03:30,240 templates, but they give you the Open API spec, we will give you 1084 01:03:30,240 --> 01:03:32,000 the tool with which you can get the template. 1085 01:03:32,200 --> 01:03:34,560 And I think I saw that you're using that for. 1086 01:03:34,560 --> 01:03:39,440 Maybe the Circle CI UMM pickle pantry module is how those are 1087 01:03:39,440 --> 01:03:42,560 being generated from the Open API Opening API for Circle CI. 1088 01:03:43,360 --> 01:03:45,000 Maybe. It's the, maybe it's the 1089 01:03:45,240 --> 01:03:47,200 Kubernetes. Circle CI we haven't done the 1090 01:03:47,200 --> 01:03:48,280 generate. The Kubernetes is one we 1091 01:03:48,280 --> 01:03:50,320 generate OK, the circle CI doesn't. 1092 01:03:50,920 --> 01:03:52,520 I don't believe it publish open API. 1093 01:03:52,560 --> 01:03:54,520 Yeah, so. I may be wrong, in which case 1094 01:03:54,520 --> 01:03:57,520 great no, this is just because because our repository. 1095 01:03:57,520 --> 01:04:01,360 Method exists in Open API form. You can generate the pickle 1096 01:04:01,360 --> 01:04:03,320 schema from it. And there you go. 1097 01:04:03,320 --> 01:04:04,640 Amazing there. You go. 1098 01:04:05,400 --> 01:04:08,320 So I think it's worth talking for just a second about modules, 1099 01:04:08,320 --> 01:04:13,560 because in this whole concept of reusability, it's great that me 1100 01:04:13,560 --> 01:04:16,680 as a developer I can build reusable things for me and my 1101 01:04:16,680 --> 01:04:19,320 team. But the fact that pickle 1102 01:04:19,400 --> 01:04:21,800 out-of-the-box said we're gonna allow you to publish these 1103 01:04:21,800 --> 01:04:27,040 modules and then have an import from an HTTP URL for that 1104 01:04:27,040 --> 01:04:29,160 module. So now you can reuse modules. 1105 01:04:29,600 --> 01:04:33,720 Amazing because now we can have the whole ecosystem of people 1106 01:04:33,720 --> 01:04:37,520 building Pickles and reusing them anywhere. 1107 01:04:37,600 --> 01:04:40,040 It's just the the whole like library ecosystem for 1108 01:04:40,040 --> 01:04:42,800 configuration. And this of course is all 1109 01:04:42,800 --> 01:04:45,800 supported today. And pickle and and if you want 1110 01:04:45,800 --> 01:04:48,760 to use my GitHub action pickle, just import it. 1111 01:04:48,800 --> 01:04:50,280 It's. I don't know, I don't remember 1112 01:04:50,280 --> 01:04:54,080 the URL for it somewhere on my GitHub, but but you point to my 1113 01:04:54,080 --> 01:04:57,320 URL and great, now you're defining your your GitHub 1114 01:04:57,320 --> 01:05:00,400 actions as in pickle and you didn't have to write it. 1115 01:05:00,600 --> 01:05:03,760 And I should say this whole GitHub action thing that I've 1116 01:05:03,760 --> 01:05:06,080 been working on. It's not very far along so it 1117 01:05:06,080 --> 01:05:09,560 needs a lot more work but but at least as a start and highlights 1118 01:05:09,560 --> 01:05:12,600 that this is all possible. And another amazing thing about 1119 01:05:12,600 --> 01:05:16,840 this is you said when you have a published module for pickle, you 1120 01:05:16,840 --> 01:05:19,600 probably also want documentation for that module. 1121 01:05:19,640 --> 01:05:23,760 Because now that we've got a schema we can now define, we can 1122 01:05:23,760 --> 01:05:26,720 now have documentation so that people know how to use the thing 1123 01:05:26,720 --> 01:05:28,400 and know what this property actually means. 1124 01:05:28,400 --> 01:05:31,840 And all that so you can generate the pickle doc for your modules 1125 01:05:31,840 --> 01:05:33,240 as well. Just love it. 1126 01:05:34,160 --> 01:05:36,840 Including hover over support in the IDE. 1127 01:05:36,840 --> 01:05:39,600 I'd like to oh, I love that. Yeah, exactly. 1128 01:05:39,880 --> 01:05:44,040 Which is incredibly valuable when when names are in terms of 1129 01:05:44,040 --> 01:05:48,640 art of the target system and you don't speak that language, then 1130 01:05:48,640 --> 01:05:51,320 a little hover over with a little bit of explanation does a 1131 01:05:51,320 --> 01:05:54,520 lot of work. By the way, you said modules and 1132 01:05:54,520 --> 01:05:57,040 you can directly import them through HTTPS. 1133 01:05:57,360 --> 01:06:01,440 But then of course if the host changes the thing that they 1134 01:06:01,440 --> 01:06:03,480 serve, your behaviour suddenly changes. 1135 01:06:03,480 --> 01:06:07,800 We also have packages and. Packages give you versioning and 1136 01:06:07,800 --> 01:06:10,520 version resolution of dependencies and the like. 1137 01:06:10,800 --> 01:06:15,400 So if you want to not trust the vendor of your template, don't 1138 01:06:15,440 --> 01:06:18,080 HTTPS directly to their module, Use a package. 1139 01:06:18,240 --> 01:06:20,560 Yeah. So that's like like essentially 1140 01:06:20,560 --> 01:06:24,360 importing that package to your to your environment so that then 1141 01:06:24,360 --> 01:06:27,440 it's kind of statically locked or something to to the version 1142 01:06:27,440 --> 01:06:28,880 that you've that you've pulled down. 1143 01:06:29,160 --> 01:06:30,720 Yeah, we published them with Shaws. 1144 01:06:30,720 --> 01:06:33,640 So. So version one has this Shaw and 1145 01:06:33,640 --> 01:06:35,280 then forever shall it have that Shaw? 1146 01:06:35,280 --> 01:06:36,960 Yeah. Great. 1147 01:06:37,200 --> 01:06:40,320 So you can do that initial kind of import to your environment 1148 01:06:40,600 --> 01:06:44,040 and then never have to reach back out to that HTTP URL 1149 01:06:44,160 --> 01:06:46,760 because it may go away. You know, we've seen node 1150 01:06:46,760 --> 01:06:50,160 modules just disappear and that breaks builds. 1151 01:06:50,160 --> 01:06:54,720 And so pickle packages allow you to avoid build breakages by by 1152 01:06:54,720 --> 01:06:59,400 cloning that that pickle locally and and and maintaining the Shaw 1153 01:06:59,680 --> 01:07:02,320 reference there, so you can be guaranteed that it's not 1154 01:07:02,320 --> 01:07:05,600 changed. Great. 1155 01:07:06,160 --> 01:07:08,240 What? What else did we miss? 1156 01:07:08,240 --> 01:07:11,760 That's like I don't know great about pickle well. 1157 01:07:12,240 --> 01:07:17,400 We also, I think we're going to talk about your aspirations for 1158 01:07:17,400 --> 01:07:20,760 the future. Not a road map, you said, but 1159 01:07:20,760 --> 01:07:25,320 aspirations, ideas. I mean so. 1160 01:07:26,320 --> 01:07:31,160 So I think we're we're this one item that I already mentioned 1161 01:07:31,480 --> 01:07:35,800 that it wasn't easy yet to write things where you use the results 1162 01:07:35,800 --> 01:07:38,920 from previous stages where you do a multi stage build a pickle. 1163 01:07:38,920 --> 01:07:40,400 So that's something that I've been thinking about. 1164 01:07:40,680 --> 01:07:43,680 I don't know whether that is a pattern or a language feature as 1165 01:07:43,680 --> 01:07:48,920 I said and with that regard, we're thinking of aggregating a 1166 01:07:48,920 --> 01:07:51,840 bunch of what we think are good patterns, but we also want to 1167 01:07:51,840 --> 01:07:53,560 like properly put them to the test. 1168 01:07:54,600 --> 01:07:57,760 There's small patterns, you know, like how how you do if you 1169 01:07:57,760 --> 01:08:00,440 have a bunch of constraints to check, how do you make a nice 1170 01:08:00,680 --> 01:08:04,640 user experience and such. There'll be blog posts and and 1171 01:08:04,640 --> 01:08:07,440 there's ongoing discussion in community because we're not 1172 01:08:07,440 --> 01:08:09,520 necessarily the one and true source of patterns. 1173 01:08:09,680 --> 01:08:13,640 People are using it and saying, oh this is convenient, which is 1174 01:08:13,640 --> 01:08:17,319 great. So a pattern collection is is 1175 01:08:17,319 --> 01:08:21,920 very much in future and there's ongoing work, right. 1176 01:08:21,920 --> 01:08:25,439 So we're currently working on on on LSB. 1177 01:08:25,439 --> 01:08:28,920 So to cover more editors with the language server protocol, 1178 01:08:29,840 --> 01:08:35,800 and also to connect to other more build maintenance and and 1179 01:08:35,800 --> 01:08:37,439 code maintenance sort of style tooling. 1180 01:08:37,600 --> 01:08:40,680 Yeah, lintors and and the. Like, yeah, Lintors, Yeah, that 1181 01:08:40,680 --> 01:08:45,439 makes sense. One of the things that stood out 1182 01:08:45,439 --> 01:08:49,160 when I first saw Pickle was often times when somebody 1183 01:08:49,160 --> 01:08:52,920 announces some new new language or new declarative language or 1184 01:08:52,920 --> 01:08:56,080 whatever, they're like, we've made it declarative so that we 1185 01:08:56,080 --> 01:08:59,640 can have great tooling and then guaranteed, like the great 1186 01:08:59,640 --> 01:09:02,680 tooling never comes. You know, it's like, like you 1187 01:09:02,680 --> 01:09:04,920 said, you could have great tooling, but you never actually 1188 01:09:04,920 --> 01:09:07,359 built the great tooling around this declarative language. 1189 01:09:07,359 --> 01:09:11,200 Possible, but it's possible it just never happens and out of 1190 01:09:11,200 --> 01:09:12,800 the gate. With Pickle, it's like, oh, 1191 01:09:13,000 --> 01:09:15,840 you've got your Intellij plug in, you've got your VS Code plug 1192 01:09:15,840 --> 01:09:19,240 in. You've got a build system that 1193 01:09:19,240 --> 01:09:22,520 can, you've got the repple like, you've got all the like things 1194 01:09:22,520 --> 01:09:25,520 that you've got the documentation for Pickles, like 1195 01:09:25,520 --> 01:09:29,200 you've got all these things that people hope to someday get to 1196 01:09:29,200 --> 01:09:30,840 when they create their new declarative language. 1197 01:09:30,840 --> 01:09:32,560 And pickle just has it. And I love that. 1198 01:09:32,880 --> 01:09:36,479 Wasn't just like we can do all these great things. 1199 01:09:36,760 --> 01:09:39,399 It's like, no, pickle did all the great things. 1200 01:09:39,880 --> 01:09:43,880 So I I appreciate that. Well, thanks very much, but 1201 01:09:43,880 --> 01:09:45,800 there's more things and and there's more great things that 1202 01:09:45,800 --> 01:09:49,439 we don't even know about because it it, it is fun to see the 1203 01:09:49,439 --> 01:09:53,640 world pick it up and and do stuff with it where you just 1204 01:09:53,640 --> 01:09:55,000 don't expect it. Oh. 1205 01:09:55,480 --> 01:09:58,160 Yeah, that's not that's entirely not what we intended the 1206 01:09:58,160 --> 01:10:00,480 language for, but it's undeniably a great fit. 1207 01:10:00,720 --> 01:10:05,280 Yeah. Well, the, I mean, the problem 1208 01:10:05,280 --> 01:10:10,240 you're solving is so obvious and huge. 1209 01:10:10,240 --> 01:10:13,640 Like if we're getting all of these failures because of 1210 01:10:13,640 --> 01:10:18,560 configuration and they're causing who knows how much money 1211 01:10:18,560 --> 01:10:21,600 and waking people up in the middle of the night and all that 1212 01:10:21,600 --> 01:10:24,800 kind of stuff, you know, it's like, oh, obviously we need 1213 01:10:24,800 --> 01:10:28,440 this, yeah. Yes, we do. 1214 01:10:28,680 --> 01:10:36,120 So anything else to add, Phil? No, I think, I think we've 1215 01:10:36,120 --> 01:10:38,800 covered a lot of ground and I think at this point everyone 1216 01:10:38,800 --> 01:10:43,240 might be reeling a bit. Of course for people to to come 1217 01:10:43,240 --> 01:10:49,240 and have a look PKL hyphen lang.org there's there's 1218 01:10:49,240 --> 01:10:54,720 communities sprouting up so so Google for for pickle things and 1219 01:10:55,800 --> 01:10:58,520 and that. I've really enjoyed the 1220 01:10:58,520 --> 01:11:03,200 reception because launching new stuff can go in one of two ways 1221 01:11:04,440 --> 01:11:08,200 and so far this has been an absolute joy and and to see what 1222 01:11:08,200 --> 01:11:11,720 people do with it is is great. Yeah, I'm sure there's a lot of 1223 01:11:11,760 --> 01:11:15,600 thank you for doing this. You're making my life easier. 1224 01:11:17,080 --> 01:11:20,160 There's a lot of that and and like a Bunch is former 1225 01:11:20,160 --> 01:11:22,920 colleagues because they used it before and they know about it 1226 01:11:22,920 --> 01:11:25,640 and they were they were looking for it to be published. 1227 01:11:26,120 --> 01:11:28,680 And then a bunch is people who'd never heard of it before, who 1228 01:11:28,680 --> 01:11:30,800 have no connection to any of these people. 1229 01:11:31,160 --> 01:11:34,080 And then just sort of stumbled across it and went, oh, this 1230 01:11:34,080 --> 01:11:38,360 looks fun. And are you looking at, I don't 1231 01:11:38,400 --> 01:11:42,000 know, community building, the process of doing that, because 1232 01:11:42,000 --> 01:11:46,880 you know that can without some care, you can. 1233 01:11:48,720 --> 01:11:52,240 We definitely are. So we the main the main 1234 01:11:52,240 --> 01:11:55,640 community that we build is is on our GitHub. 1235 01:11:55,640 --> 01:11:58,320 So we try to be very responsive to to discussions. 1236 01:11:58,320 --> 01:12:02,600 We try to be receptive and and when things you know are 1237 01:12:02,600 --> 01:12:05,360 reasonable requests but won't line up with us then we try to 1238 01:12:05,360 --> 01:12:07,920 be receptive of contributions and to make that clear and touch 1239 01:12:09,800 --> 01:12:14,320 and and we do engage with with community sometimes where they 1240 01:12:14,320 --> 01:12:16,160 are. So we do, we do, you know code 1241 01:12:16,160 --> 01:12:18,120 reviews and we and we have chats and stuff. 1242 01:12:18,840 --> 01:12:23,320 There's a community Discord, so you know, there's there's 1243 01:12:23,320 --> 01:12:26,120 there's things that we that that we hang out with, but also 1244 01:12:27,000 --> 01:12:29,280 there's already a bunch of users that that know what they're 1245 01:12:29,280 --> 01:12:33,120 talking about. So it it seems to also grow 1246 01:12:33,120 --> 01:12:37,120 naturally, which I'm very happy. About and I in my experience 1247 01:12:37,120 --> 01:12:39,920 with with you all the maintainers in the community 1248 01:12:40,280 --> 01:12:43,960 it's been really positive and I've asked the the dumb 1249 01:12:43,960 --> 01:12:49,760 questions and been greeted with kindness and and yeah that's 1250 01:12:49,960 --> 01:12:53,240 that's it's felt good to to be part of that community and and I 1251 01:12:53,240 --> 01:12:56,240 certainly appreciate your all's responsiveness your and the 1252 01:12:56,240 --> 01:13:00,640 team's responsiveness to my questions and and my you know 1253 01:13:01,080 --> 01:13:03,280 bug filings and you know all that kind of stuff. 1254 01:13:03,280 --> 01:13:06,240 I feel like it's it's you've you've all done a great job of 1255 01:13:06,240 --> 01:13:10,000 kind of stewarding the the community and and my 1256 01:13:10,000 --> 01:13:11,720 interactions with you. So thank you. 1257 01:13:11,840 --> 01:13:15,880 And the core team, the three of you, is this all you're doing or 1258 01:13:16,120 --> 01:13:23,080 do you have other work as well? I mean I there's there's 1259 01:13:23,080 --> 01:13:29,960 generally like other style work in in terms of so I I help 1260 01:13:29,960 --> 01:13:33,600 people hold it right as well so so that's that's quite a bit of 1261 01:13:33,600 --> 01:13:38,160 time to to sort of design review and stuff and like oh we want to 1262 01:13:38,160 --> 01:13:41,120 build a system like this can you look at that and which is 1263 01:13:41,120 --> 01:13:44,440 essentially building pickle but it's it it does mean that 1264 01:13:44,440 --> 01:13:47,000 there's a lot of like other technical work that that happens 1265 01:13:47,000 --> 01:13:48,800 which takes a lot a lot of time sure. 1266 01:13:50,160 --> 01:13:54,200 But your focus is all on. But the core focus is is is very 1267 01:13:54,200 --> 01:13:56,080 hard on on pickle. Yeah. 1268 01:13:56,080 --> 01:14:01,640 And and in that regard, it has been very easy for the team to 1269 01:14:01,640 --> 01:14:04,480 be quite kind and receptive on the get up stuff because people 1270 01:14:04,480 --> 01:14:08,440 finding bug reports is sort of exactly what we were hoping for 1271 01:14:08,440 --> 01:14:10,880 and it has massively accelerated what we do. 1272 01:14:10,880 --> 01:14:14,600 So you know we're doing it for selfish reasons, is what I'm 1273 01:14:14,600 --> 01:14:15,720 saying. That's right. 1274 01:14:15,880 --> 01:14:16,600 Yeah. Yeah. 1275 01:14:16,600 --> 01:14:19,760 It works in both for both, both parties. 1276 01:14:21,600 --> 01:14:23,040 Awesome. Well, thank you so much for 1277 01:14:23,040 --> 01:14:26,000 joining us, Phil. Look forward to very bright 1278 01:14:26,000 --> 01:14:29,000 future with pickle and thanks for for teaching us all about 1279 01:14:29,000 --> 01:14:31,000 it. A pleasure and a delight.