Transcript #378: Python is on the edge
Return to episode page view on github00:00 Hello and welcome to Python Bytes, where we deliver Python news and headlines directly to your earbuds.
00:06 This is episode 378, recorded April 9th, 2024.
00:12 I'm Michael Kennedy.
00:13 And I'm Brian Okken.
00:14 And you can follow us over on Mastodon.
00:18 We're all on Facedon, at Brian Okken, at M. Kennedy, and at Python Bytes.
00:22 We'd love to talk to you over there.
00:23 We're also on X Twitter, if you want to be there as well.
00:27 But we probably spend a little more time on Mastodon these days.
00:30 Support the show by supporting our work.
00:33 We have, obviously, a bunch of courses that Talk Python Training, Brian's complete pytest course, and the Patreon as well.
00:39 Be part of the live show if you wish.
00:41 You can see the video version.
00:42 Absolutely not required, but always awesome to have people in the audience to give it a little bit more of multiple perspectives.
00:49 We'll get some of that coming on in a second.
00:51 And you can check that out at pythonbytes.fm/live.
00:55 Live, usually Tuesdays at 10 a.m.
00:58 So that's Pacific time.
01:00 Finally, if you want an artisanal, handcrafted digest of what we talk about sent to you in email form, even if you don't listen,
01:08 well, head over to the website, Python Bytes.fm.
01:12 Click newsletter right in the middle and enter your email address.
01:15 We will not share it or do other nefarious things.
01:18 So we just want to be able to contact you and have a chat if you wish.
01:21 So Brian will be sending out something cool to everyone this week, as usual.
01:26 Brian, do you have health news or something you've got to share?
01:30 What's going on here, man?
01:31 Well, I've found a pacemaker.
01:35 My ticker's doing good.
01:37 No problems with that.
01:38 But you can control your heart with Python.
01:42 Oh, okay.
01:43 Actually, it's not.
01:44 You can't control your heart yet.
01:46 Actually, I don't know if you can.
01:48 But I ran across a project from Brandon Rohr called Pacemaker.
01:55 And what this does, it's not controlling your heart.
01:57 It's controlling a time per iteration loop.
02:01 So with, and I don't know if this has anything to do with UV or not, but one of the things that UV has brought us is really fast installing of lots of packages.
02:11 If you have a lot, why not?
02:13 So having, this is a small package.
02:17 So this is in Brandon's own words on the readme.
02:21 I think I saw this here.
02:24 It is, essentially, it's a glorified snippet.
02:31 Instead of a snippet, he wrote a package, which I love this.
02:34 So I'm taking a look at it.
02:37 It's a small package.
02:38 Good example, though, for how to do a package.
02:41 Like if you take a look at the pyproject.toml, it's pretty concise.
02:45 It's using setup tools, which is fine.
02:48 But it shows you how easy it is to put a package together, which is pretty fun.
02:53 And also with the code, I was taking a look at the code.
02:56 So what this does is not terribly earth-shattering, but it just sticks around.
03:04 You tell it that you want to, it's kind of like a metronome thing.
03:07 So you've got some code that you want to run.
03:10 And here's an example.
03:11 And you just say pacemaker beat, and it waits.
03:16 So it's a busy wait, or it does a sleep or something like that.
03:20 Yeah, sleep.
03:20 But it sleeps and then comes back alive, does its thing, and then goes back.
03:26 So you can have it be, like in this example, it does a beat for 100 times.
03:31 And this is important in a lot of different types of code, a lot of monitoring code, a lot
03:36 of other things.
03:37 And busy waits aren't necessarily always the greatest, but in a lot of cases, it works great.
03:43 The thing that I wanted to point out about this, there's a few things that I love about
03:46 this project, or just wanted to point out.
03:48 Really great documentation, even for a small project.
03:51 Also, I had kind of forgot about time monotonic.
03:54 So this is using time monotonic when it does the time comparisons.
03:59 Instead of normal, there's a couple times of timestamps, types of timestamps, and monotonic,
04:05 and then there's a monotonic nanoseconds.
04:06 If you really want to do really tight loops, you could modify it for that.
04:10 The thing that monotonic does is it makes sure that all time deltas are positive.
04:16 So even if something happens, like you change your system clock, during the times, between
04:24 timestamps, it'll still do it correctly so that it is monotonically increasing in times.
04:29 That's interesting.
04:30 Another thing could be, you know, like maybe even you don't change it, but we all have our
04:35 clocks set to auto-adjust, right?
04:38 And it could come online and auto-adjust or something.
04:40 Yeah, and that would be weird if like suddenly, especially with this project where like one
04:47 of the things it does, and he warns about this, is, I mean, sleeps aren't exact science.
04:53 And this isn't a real-time, especially on non-real-time operating systems, but I don't think Python's
04:59 even a real-time thing.
05:00 So it's an approximation for how long it's going to sleep, but it tries to correct it.
05:05 So if you, if you, if you slept too long, it tries to do more events so to, so that on
05:10 average you get the average amount of times you're running be correct.
05:16 So it's kind of a cool library.
05:18 Check it out.
05:18 A couple of things I wanted to point out about it.
05:21 One is the cool use of monotonic.
05:24 The other one is a good, good read me documentation, even for a small thing.
05:28 But there's, there's no tests.
05:31 Brandon, come on.
05:33 Anyway, I'm not, I actually, there's a couple of things around this.
05:37 I don't think that people should stop from putting a code online just because they don't
05:42 have tests yet.
05:43 It might be that somebody could contribute and add tests.
05:46 It also might be that for you, if you're using this all the time, if Brandon uses this all
05:51 the time, the tests are covered by the, the calling code.
05:54 So you're, you're, you're using this and you're covering it.
05:58 And I just want to, I guess I want to point out to everybody for any library you're using,
06:03 you probably should have tests that cover the part of the library that you depend on, even
06:08 if they do have tests.
06:09 So this one doesn't.
06:10 So you, you know, buyer beware, but even if they do, you probably should make sure that
06:14 it is really working the way you think it's working.
06:17 So anyway.
06:18 Yeah.
06:18 Sometimes it's just hard to have meaningful tests.
06:21 Like a while ago, I released that Umami Python event library, right?
06:26 For the analytics tracking.
06:27 And all it does is serialize the messages that come to it from the Umami API.
06:33 I can test what my perception of the API is, right?
06:37 But, but the real danger is that that API changes in some way or another, or, you know, it's just
06:44 90% of the fragility is outside of, if you mock out all that stuff, then well, you know,
06:49 you're just kind of testing your view, which hopefully is already mostly encoded.
06:53 And I mean, it's not completely useless, but it's, is there's certain things that are just
06:56 tricky to get.
06:57 Right.
06:58 And, and testing isn't, testing isn't necessarily always automated testing.
07:02 It could be like that.
07:03 You're using it.
07:04 The Umami API they're using, it's you're using it.
07:08 So you'll know when it breaks and other things are like your use of it will break or the,
07:15 the calling code.
07:16 And I just like, I don't think that people should, especially with the internal stuff,
07:20 maybe on PyPI, maybe we should have a little bit like things eventually should have tests
07:24 probably.
07:25 But the, for internal projects where you're sharing code it's better to package and share
07:30 code than to not share code.
07:32 So if, if writing testers, what's stopping you from putting it in a central repository,
07:36 don't let that stop you.
07:38 It's, it's better than just, I mean, we, we have snippets, like he said, it's a glorified
07:42 snippet.
07:42 So why not package it?
07:44 So yeah, very nice.
07:45 I like the monotonic.
07:46 That's news news to me.
07:48 I hadn't paid attention to that before.
07:49 Yeah, it's cool.
07:50 I want to try the nanosecond monotonic.
07:52 So yeah.
07:53 Other stuff that people might want to pay attention to, and this is not to drum up a bunch of
07:59 fear and concern so much.
08:02 It's not huge news in that regard to people, but is more to just sort of put on out there
08:07 what the PyPI, the Python Packaging Authority folks to deal with, you know, kind of say thanks.
08:12 So the news comes to us from bleeping computer, which usually does pretty good news, but this
08:17 article is pretty vacuous of information, but the title says a lot.
08:21 PyPI suspends new user registrations to block malware campaign.
08:26 And so there's some interesting things in here.
08:29 So it basically says, look, when was this?
08:32 It was like a couple of, this is March 28th, a little bit, a couple weeks ago.
08:35 IPI has temporarily suspended user registration in the creation of new projects to deal with
08:40 ongoing malware campaign.
08:42 Then it proceeds to tell you what, what IPI is basically.
08:46 And then it says, oh, look, there was some, some problems.
08:49 People are uploading bad stuff, but it doesn't tell you, for example, like what projects,
08:53 what did the malware do?
08:55 So if you jump over to the status.python.org, actually that tells you about the status of
09:03 Python infrastructure, which is kind of cool.
09:05 And it says same deal.
09:07 This is official reporting.
09:09 Did it say how long the event went for?
09:11 Nope.
09:12 Just that it was a thing.
09:14 I guess if I did math, that would be 10 hours, about 10 hours, 30 minutes.
09:19 That's a ways.
09:19 And this, this is the real article you want to read.
09:23 It is over on Medium, IPIs under attack, project creation and user registration.
09:27 It's been adhered to the details by Yehuda Gelb.
09:30 I hate to link to Medium.
09:31 I hate Medium.
09:33 I think it's a crummy place.
09:34 I don't know.
09:35 It just seems gross, but they have really good details.
09:38 So basically this was a typo squatting attack.
09:41 And what's interesting, it was a multi-stage attack, stealing all sorts of things.
09:47 Crypto wallets, obviously, but real sketchy is browser cookies.
09:52 So you're logged into your bank for a session that's good for 20 minutes.
09:56 You know, if they could grab that and log in as you, that might be less good, you know,
10:00 or log into your email and reset stuff and so on.
10:03 So what happened is there was a bunch of packages in here somewhere.
10:08 There's the package list.
10:09 So you can just, you can see these are all about the capturing people who, one, misspelled
10:16 things, but also just like didn't quite understand.
10:18 Like, for example, Brian, one of the packages is requirements.tx.
10:21 requirements.txt without the dot or requirements.
10:25 So if you say pip install requirements, right, without the dash R or the dot txt, you're getting
10:32 this.
10:32 And there's a bunch of others, you know, TensorFlow and Selenium and like they're all over the
10:37 requirements business.
10:38 So it's just everywhere.
10:39 And the deal was basically each one of these had a malicious setup.py, which is why I think
10:46 it's kind of interesting to look at.
10:48 And inside the malicious setup.py, it encrypted using the cryptography.fairnet library, which
10:56 just listed as a dependency, I imagine.
10:58 It then decrypts some kind of URL that it very lightly.
11:03 It's funny.
11:05 It's like using little analytics.
11:06 It'll like passes the query string of like, which one hacked me before you get going.
11:11 It downloads some kind of thing that installs and runs and basically installs a backdoor
11:16 ongoing thing.
11:17 So even if you pip uninstall this, there's this thing running that just monitors your
11:21 system, which is not ideal, to be honest.
11:24 That's not what you want.
11:25 No, one does not want this.
11:28 Yeah.
11:28 Oh, and Henry out in the audience says, in addition to all the stuff I said, that actually blocked
11:33 all uploads for a few hours and couldn't upload build 1.2.1.
11:38 You know, what a hassle, huh?
11:39 This is why we can't have nice things, you know?
11:41 Come on now.
11:42 Yeah.
11:43 So there's a, I guess there's a lesson here to make sure that you're careful when
11:48 you pip install something, because even if you catch it and you're like, oh, that's not
11:52 what I meant, you may have already done damage.
11:54 Isn't there a way, I don't remember off the top of my head, to say pip install, but don't
11:57 run, only use wheels, like don't allow anything to run?
12:00 I don't know.
12:01 I'm not sure.
12:02 I feel like there was.
12:03 There were probably some of the audiences going, yes, yes, of course.
12:06 How do you not know this?
12:07 But it doesn't mean this is not going to happen.
12:10 It just means you have to write, use the code.
12:12 You know, as opposed to just the act of installing it or sneaking it into a requirements
12:17 file somehow.
12:18 Yes.
12:19 And I knew Henry would come through and say, dash, dash, only dash binary.
12:22 Indeed.
12:23 That's it.
12:23 All right.
12:24 Well, you know, they were on top of it.
12:27 The fact that this was completely dealt with within 12 hours is pretty awesome.
12:31 The fact that it has to happen, not so much.
12:33 Yeah.
12:33 All right.
12:34 Over to you, Brian.
12:35 So I want to just, I guess the world has changed a little bit with UV and other rustified things.
12:45 So we have, there's an updated doc or an updated blog post from Hinnick.
12:52 Python projects, Python project, local virtual env management redo or redux.
12:59 And so he's just started really talking about all of the tools that he uses around virtual
13:05 environments.
13:05 And I kind of just enjoyed it because it matches my own use quite a bit.
13:10 So some caveats in here that says this is what works for me.
13:14 I'm not necessarily saying you have to use this, of course.
13:17 But it's a good list of kind of how you're, how dealing with, dealing, dealing with virtual
13:23 environments.
13:23 The major thing that happened is UV and it's changed a lot of how we deal with it, but it
13:29 makes things a lot faster.
13:30 So the, some of the things I thought I want to revisit in here.
13:35 So it's pretty great.
13:36 So he's using .venv and I in product in each project directory.
13:42 And that's, it's close to what I use.
13:44 I use the venv.
13:47 I just don't use the dot.
13:48 I do as well, Brian.
13:50 And it's, I know the dot means kind of like, just, it's not real important, put it to the
13:55 side, but I love to be able to open up a project in Finder or Explorer and look at it and go,
14:00 all right, this one has a virtual environment.
14:01 Oh, this one doesn't.
14:03 I need to make one.
14:04 And I don't want to have to keep like show hidden files, hide hidden files over and over.
14:09 So while I appreciate the dot, like I'm a hundred percent with you.
14:12 Yeah.
14:14 So I think I want to revisit this.
14:18 I've tried it a while ago, but I haven't tried it lately.
14:21 is a, is a way to, to have an ENVRC file or dot ENVRC file in your directory.
14:29 And, and that gets run when you CD into it or, or something.
14:35 Anyway, I think this is cool stuff, but I don't use it.
14:38 Do you use this Michael?
14:39 No, I love the idea of it.
14:42 And in practice, I just haven't, I just haven't done it now.
14:46 There's some cool tricks in here with it that he's using that I kind of want to get back to
14:51 trying it again.
14:52 So I guess, thanks, Sinek for bringing this up so I can take a look again.
14:56 Using Astral's UV over Rye.
14:59 I kind of never went to Rye, but it looks like he switched from Rye to UV.
15:03 Python installations.
15:05 Now switch to both, just always using python.org downloads because they're now universal builds
15:12 mostly.
15:13 And it just sort of works.
15:14 And that's what I've been using also for installing Python.
15:18 Dead snakes for Linux, of course.
15:21 And then there's a, a mention of Python build standalone for various other projects that are
15:27 needed.
15:27 So that's, that's kind of neat.
15:28 A discussion about unpinned versus pinned packages and, and then also using a dot Python version
15:36 default within a directory.
15:38 And the, the, the, the tie in back to during during during this kind of cool is, is he's,
15:44 he's got some tricks in here.
15:46 So if you, if you drop in a dot Python version default, it would just shows you, tells you
15:52 what version to, to use by default that, that in a directory and then you check it in so that
15:58 the development environment can be recreated easily.
16:00 And he's got some in VRC with that's part of during that he's got a little snippet that will
16:06 activate it based on which Python you're using, using you UV, which is kind of a neat little trick to,
16:12 to use to Renv and Python versions and, and UV altogether, which, so I'll definitely have to try that.
16:20 That's kind of a neat trick.
16:21 That is neat.
16:21 There's using all of this as well helps with GitHub actions.
16:27 He's describing how to do that with, with as input to the setup Python, GitHub action,
16:34 which is, I didn't know you could do this.
16:36 So you can say the Python version file and you can just give it that Python version default.
16:41 So the GitHub actions uses the right default version.
16:44 It's this cool trick.
16:45 he's also, he's got some, tricks on how to use, use it with the fish shell.
16:51 I don't, I don't use fish, but for those fish users, that'd be great.
16:54 The, the other part that I wanted to, that I really enjoyed seeing is because of all of this,
17:00 the, in which version and stuff you can use, oh, he's using the requires Python and
17:06 Python project Toml, which I'm, I'm using for everything now.
17:10 So, but the, he's has a way, a little, little sed snippet to parse that out of the
17:17 pyproject.toml and pass it into, using the get, get have actions, the animal file,
17:23 to pass it to a Docker build, but it's just, it's grabbing this, this version of Python.
17:29 So you could use it for other things within your, within your, I guess within get
17:34 your, your GitHub action or, or something else, or other tool, if you needed to pass what
17:39 Python version to use.
17:40 So that's pretty, some pretty clever things in here that I, some, some, something old,
17:45 something new, kind of some neat tricks.
17:47 Yeah.
17:48 Yeah.
17:48 Very interesting.
17:49 A lot of stuff to explore, interesting comments in the audience about liking or
17:53 disliking all the magic, the auto magic.
17:56 Well, and it's also another example of like, I kind of like these sort of posts, but even
18:00 for different people, just to see this is how I work.
18:03 This is the workflow I use.
18:05 not, not necessarily just focusing on one tool, but I use all these things together
18:09 and this is how they work together.
18:10 It's kind of fun to read.
18:12 Yeah.
18:12 Yeah, absolutely.
18:13 Even if you don't adopt it, it's cool to just see the tools and the things you can do.
18:17 Yeah.
18:17 Yeah.
18:18 All right.
18:18 On to the next one.
18:20 This one is super exciting.
18:22 Super exciting.
18:23 Okay.
18:23 We need to talk for just a second about Cloudflare and edge workers.
18:29 Okay.
18:30 Now this is just a Cloudflare thing, but I think it's sufficiently interesting that it's
18:35 worth calling out.
18:36 Okay.
18:37 So CDNs like Cloudflare, like bunny.net, the one that we use and stuff like that have a bunch
18:44 of what are called pops points of presence.
18:46 And traditionally these have been, how do I get my files really close to you?
18:51 So they feel immediate no matter where you are in the world.
18:55 So for example, I don't know about Cloudflare's details, like their stats, but I know bunny.net
19:00 has something like 115 servers that are points of presence throughout the world.
19:04 And so if you try to, if you visit the Python by site website, all the static content, like
19:09 images and CSS and stuff are delivered from one of those pops, like right by you.
19:13 Yeah.
19:14 Yeah.
19:14 And obviously the MP3s are as well.
19:18 Now those things have started to have programmable models where in addition to just having
19:25 the content of say a static file near you, they'll have some of the logic of the application
19:30 near you.
19:32 So if you've got like a React friend in that talks to APIs, maybe it's only talking just
19:36 down the street to the point of presence, not halfway around the world to New York where
19:40 our server lives.
19:40 Right.
19:41 And this has traditionally been JavaScript.
19:43 So here's the, with that set as the stage, Cloudflare has these things called, I think they
19:49 call them web workers.
19:50 Yeah.
19:52 Something like that.
19:52 We'll see in just a second.
19:53 And those have been traditionally done in JavaScript.
19:56 So there's a whole infrastructure about distributed databases and things like that, that these
20:01 workers can work with.
20:03 It's pretty interesting.
20:03 But the news is Cloudflare announces Python, they're bringing Python to these workers with
20:10 Pyodide and WebAssembly.
20:12 So now you can start to program these edge devices, these points of presence things like
20:16 right near each other with first class Python support.
20:19 Based on all the work of Pyodide and WebAssembly and all those things.
20:25 Isn't that excellent?
20:26 It is excellent.
20:27 This is a big announcement.
20:28 I got the omnivore page pulled up and the read time is 16 minutes.
20:33 We're not going to go through all that.
20:35 So let me just pull out some highlights here.
20:37 And so one of the things that's really made this possible, made it interesting is they've
20:41 put a huge amount of effort into optimizing the runtime for JavaScript to make it work well.
20:46 And it's Pyodide's integration with JavaScript for that sort of runtime performance implementation side to make this work really, really well.
20:57 So it says beyond just compile to WebAssembly.
21:01 So each worker is what's called a V8 isolate.
21:06 So it's kind of like a container, but just less, you know, just an isolated version of the V8 runtime,
21:13 which is the Chrome's JavaScript engine that also runs WebAssembly.
21:17 Okay.
21:17 So it says it's not just as easy as copying over the WebAssembly stuff and running it because they have thousands of these things running on one server.
21:24 And if each one had to do full on startup for WebAssembly, full on startup for Pyodide, which is six megs and take some delay to get going and so on, it would be, it wouldn't be practical.
21:36 So they've done all this work to kind of memory snapshot and almost running pip installed setup version of this and then like deliver it to you upon request.
21:47 So there's a lot of shared memory or shared processing.
21:49 And here's how you write it, Ryan.
21:51 From JavaScript, import response, async def on fetched and do your Python and return some response.
21:57 Hmm.
21:58 How cool.
21:59 Let's see.
22:00 There's a cool graph that compares what's VMs versus containers versus these isolate things.
22:06 Like I said, it's a lot more sort of put together.
22:09 And one of the things that's pretty interesting here is it has support for FastAPI in Langchain.
22:17 So there's a bunch of, like I said, this is really long, but let's look at the FastAPI version here.
22:23 There's a whole, there's a whole example I'll point people at of code Python worker examples under Cloudflare's GitHub repo.
22:30 And so if you go to the FastAPI one here and you go into source and you pull up the worker and you hide the symbol.
22:36 So we can all see, basically check this out.
22:38 So this is Python code running effectively in a node style like thing in WebAssembly on the edge of one of these workers.
22:47 And here's what you write.
22:48 From FastAPI, import FastAPI request.
22:50 From Pydantic, import base model.
22:53 Use app equals FastAPI, app.get.
22:55 Here's your document you return.
22:57 Here's your async function that you write.
23:00 You can go do async things.
23:01 Here's your Pydantic model with Python types.
23:03 What do you think?
23:04 Here's your post, your puts, your gets.
23:06 Oh, this is pretty cool.
23:08 Yeah, and they've got some sort of database thing that it integrates with so you can have persistent data and so on.
23:14 But like I said, I don't do a ton with these things, but I might start paying attention if I can do it in Python.
23:19 Yeah, definitely.
23:20 Yeah, back in my day, a V8 isolate was just carrots.
23:23 Exactly.
23:25 It's the part that like sinks to the bottom and then you take it out, right?
23:29 No, if people use Cloudflare already and those workers, this is super interesting.
23:36 And if you just want to see some cool, unique uses.
23:39 And I guess in a way, one of the real first production uses of Pyodide and Python in WebAssembly.
23:45 Yeah.
23:46 Check this out.
23:47 Definitely.
23:47 All right.
23:48 Is that, that's all of our main topics, right?
23:50 That is.
23:51 All right.
23:52 How extra are you feeling today?
23:54 I have zero extras.
23:55 Zero.
23:56 Zero extras.
23:57 Just a bad job.
23:58 Zero.
23:58 All right.
23:59 Well, I got a couple.
24:00 I'll go through quickly here for us.
24:01 First of all, Brian Skin sent both of us a message and said, look, there's a decent chance the podcast
24:07 already is, our audience has already filled you in on this.
24:10 But last week, since I talked about L-Python and the related projects are spearheaded by Andre
24:15 Sertik.
24:17 Brian, you are, Brian Skin, you are the podcast audience who has filled us in.
24:22 Thank you.
24:22 So he did a, actually Brian did a whole long, hour long interview with him on it.
24:27 And so people want to check out L-Python further, which we talked about before.
24:32 Check that out.
24:32 That's pretty cool.
24:33 Next.
24:34 I really like this idea.
24:35 We talked about just path last time.
24:38 Yeah.
24:39 And how it sort of helped you diagnose your path, you know, like duplicates, missing directories,
24:43 all that kind of stuff.
24:44 Listen to last week if you want the whole details.
24:46 But the guy behind it said, hey, that was really awesome.
24:51 You covered it.
24:51 I'm going to create a badge, a Python bytes GitHub badge for the project.
24:56 What do you think about that, Brian?
24:57 I think that's really cool.
24:58 I do too.
25:00 And so I'm going to try to set it up so that there's an automatic GitHub badge that
25:06 people can put on their readme if their project was featured in Python bytes.
25:10 And I'll put that at the top, put the code you can get for that or something at the top
25:13 of the show on the episode page.
25:14 It's not there yet, but eventually you should be able to get a cool, cool little badge like
25:19 this that says my project was featured on the podcast on this episode.
25:22 And here's a link to it all within one badge.
25:24 Yeah.
25:25 And the badge has like the little, like the number shows what episode it was on, which is.
25:30 Yeah, exactly.
25:30 Instead of saying like Python 312, it says Python bytes and the episode number.
25:35 It's excellent.
25:35 Yeah, that's pretty cool.
25:37 So yeah.
25:38 Yeah.
25:38 Thanks.
25:39 Thanks for that.
25:39 I am as well.
25:41 Let's see what else.
25:43 Oh, Brian, we have a brand new server going strong now.
25:47 Did you see?
25:47 I did.
25:48 That's pretty exciting.
25:49 Was that a lot of work?
25:50 Yes.
25:51 It was a lot of stress, not a lot of work.
25:54 So I decided it's time to upgrade the server, get some more RAM.
25:58 More CPUs is always nice, but I couldn't reasonably get more RAM without more CPUs.
26:02 So I'll just take them.
26:03 So we had some downtime for about 20 minutes actually last night.
26:09 So if you ran into that, I apologize.
26:11 That took out everything because this was not one of the Docker pieces out of the Docker.
26:16 This was the host of all the Docker clusters.
26:18 So it was gone, gone.
26:20 I couldn't even reasonably put up a, we're down page because it was the host thing that
26:25 was down, not part of the site.
26:27 Right.
26:27 Yeah.
26:28 Anyway, now is there a, I don't know where the reply went.
26:32 Oh, maybe if I were, I guess if I'm not logged in, it doesn't show me, but we now have a sweet
26:37 machine running along just like before.
26:40 So that worked out pretty well before that.
26:42 I was so happy, Brian.
26:43 We had for the last 30 days running a 99.98% global uptime.
26:49 That was awesome.
26:50 That was pretty great.
26:51 Yeah.
26:52 I know turning off the server for 20 minutes, you know, with like 20 gigs of database records,
26:59 it takes a while to copy that from one VM to another.
27:02 And so that, that's, that's what took so long.
27:05 It's only three nines though.
27:06 You need to work on that.
27:08 Well, it's three nines and then an eight on the end.
27:11 It's almost four nines.
27:12 It's so close.
27:13 I'm going to try to make it better now.
27:15 But it went down to, I think 99.94%, which I think is still pretty darn good for some random
27:23 dude in Oregon running a server.
27:24 That's pretty awesome.
27:25 My Python test went down last week for like 12 hours or something like that.
27:31 Oh no.
27:32 Was that something that had nothing to do with you?
27:34 Just the host of it or something?
27:35 It was had to something to do with me, but it was a DNS thing.
27:38 A DNS glitch then, or, you know, it wasn't really, it was, it was an accounting thing
27:45 on my part.
27:46 Like, but I got like, when it, when it got repaired, they didn't repair all the DNS records.
27:52 So I had to go recreate all the DNS records.
27:54 What a hassle.
27:55 Yeah.
27:55 Yeah.
27:55 That's a huge hassle.
27:56 All right.
27:57 Cool.
27:58 But before we, before we go on for a joke, Henry out there on his points out, what about
28:03 rich and textual?
28:03 They'll just be overrun with these badges.
28:06 Yeah.
28:08 These Python bytes badges.
28:10 We'll have to do an infinity symbol for the projects.
28:14 Exactly.
28:15 Oh, maybe some sort of like a sequence like this, you know, 100 dot, dot, dot, 400.
28:21 Yeah.
28:22 Something like that.
28:22 Also, backing up a little bit, the, the worker, the edge workers, we, from Andrew Bayer,
28:30 Pyodide works in web workers now too, which is totally different thing, but also cool.
28:35 That is very cool.
28:36 Okay.
28:36 That is very cool.
28:37 Thanks, Andrew.
28:37 I think web workers are basically like background threads on your web app, which I think there
28:44 used to be troubles with that as well.
28:45 All right.
28:46 This one, I thought of you when I got this joke, Brian.
28:49 Okay.
28:50 Okay.
28:50 So this makes us a little AI, a little bit of C++.
28:54 The graphic kind of is crumbly.
28:56 The graphic kind of is crumbly, so it's hard to read.
28:57 But Gemini, the Google AI says, this person says, Gemini is apparently told your Google account age and will answer questions with the appropriate caution.
29:10 So if you're like a minor, you're like 12 year old kid with a Gmail account.
29:16 You don't want this thing to just tell you all the secrets of life.
29:19 Like, hey kid, Santa Claus is fake.
29:22 No.
29:22 All right.
29:23 But here it is.
29:24 But here it is.
29:24 In fact, talking about something else.
29:26 It says, here is Gemini refusing to help someone with C++ because they're under 18 and advanced C++ is a danger to a young mind.
29:35 Are you ready?
29:37 Yeah.
29:38 So the person just says, I have a function.
29:40 Inline bool is key down.
29:42 Standard namespace, same as template of key auto, dot, dot, dot, dot, keys.
29:47 It's pretty intensive code, right?
29:50 And it says, Gemini says, I'd be glad to help you with that C++ code conversion.
29:55 But I'll need to refrain from providing code examples or solutions that directly involve concepts.
30:01 As you're under 18, concepts are an advanced feature of C++ that introduce potential risks.
30:07 And I want to prioritize your safety.
30:09 Here are some alternative approaches you could consider depending on your specific requirements.
30:14 Oh my God.
30:15 Traditional variadic templates and so on.
30:16 Because you're under age, I'm going to focus on traditional variadic templates?
30:23 You're good.
30:25 What do you think?
30:28 Is that a good one or what?
30:29 Oh yeah, that'll scare them away from C++.
30:32 I'll go back to Python.
30:34 Yeah.
30:34 Nice.
30:35 All right.
30:36 Okay.
30:36 I've got a quick baseball joke.
30:39 So we're just kind of just deep into baseball season now.
30:44 If you take a trip to see a baseball game, what is that called?
30:48 It's an inning outing.
30:49 An inning outing.
30:52 I love it.
30:53 That joke.
30:54 I love it.
30:54 Yeah, we have no baseball.
30:57 And we've got to dive to all of our professional sports besides soccer and basketball.
31:01 Yeah.
31:02 So it's been a while.
31:03 It's been a while since I've been to a game.
31:05 It's been a long time since I've been to a game.
31:06 It's been a long time since I've been on an in-and-outing.
31:09 In-and-outing.
31:10 Yeah.
31:11 And yet I still find t-shirts.
31:12 You can get t-shirts other places.
31:15 Yeah.
31:15 T-shirts.
31:16 They persist for sure.
31:17 That and conference t-shirts.
31:18 Yeah.
31:19 All right.
31:21 Well, thanks as always.
31:22 Thank you.
31:22 See you later.