Brought to you by Michael and Brian - take a Talk Python course or get Brian's pytest book


Transcript #287: Surprising ways to use Jupyter Notebooks

Return to episode page view on github
Recorded on Tuesday, Jun 7, 2022.

00:00 Hello and welcome to Python Bytes, where we deliver Python news and headlines directly to

00:04 your earbuds. This is episode 287, recorded June 7th, and I am Brian Okken.

00:09 I'm Michael Kennedy.

00:10 It's good to talk to you, Michael.

00:12 Yeah, good to see you again, Brian.

00:13 Yeah.

00:14 Again, we've got our wardrobe matching our background here, which is fantastic.

00:18 Yeah. We like, you know, texted each other in the morning to make sure.

00:22 Feeling purple. I'm going to get a new shirt. No, it's great. Good to see you as always.

00:28 Lots of fun Python things to talk about here.

00:30 Yeah. Yeah. Well, let's jump into the first one.

00:32 The first thing that I want to talk about here is distributing Python applications.

00:38 Now, this is a little bit in the Python GUIs side of thing, something you just can't get enough of

00:45 in terms of like, hey, could we have more ways to do this that are like awesome?

00:49 How about if we had ways that were automatic?

00:51 Yeah.

00:52 So I want to talk about this thing by Brent Bola-Bregretz called AutoPy2exe.

01:00 And it basically does what it says right in the name there.

01:03 Converts a .py file to a .exe using a simple graphical interface.

01:10 Now, this GitHub description is a bit of a Windows bias because it will also create it to Mac apps as well,

01:18 to .app files. So it's not just a Windows thing.

01:21 Cool.

01:21 It's pretty popular. It has 2,000 stars, 400 forks. And what it is, is a UI on top of things like PyToApp or PyInstaller,

01:30 specifically PyInstaller. So what you do is you fire this thing up and out pops this user interface

01:37 that if you're watching the YouTube stream, you can see there's a user interface here.

01:41 And it just says, pick the starting Python file for your application. And you can say, what do you want the output to be?

01:48 One file or one directory?

01:51 Okay.

01:52 I think we all want it to be one file, probably generally, but maybe a directory. I don't know.

01:56 What else you're going to, maybe you want to do some other things there.

01:59 But what I did is I tried this against my URL by little appy thing, which let me pull that up.

02:08 This is something I built a while ago with rumps. It's fantastic. Ridiculously uncomplicated menu bar apps or something like that for Mac.

02:18 And all it is, is a little thing that goes up in your Mac bar and it has like, you know, sluggify text or trim it or lower cases.

02:26 It's just, I'm constantly taking names of like file names and turning them into something I could put as a URL or like a title of a video or something and turning it into something that would be a good URL.

02:39 So that's what this little app is for. But here's the thing is it's a Python app that runs in the menu bar on my Mac with no terminal view.

02:47 And I wanted to be able to distribute it to people. And so the way you get it is you just download a zip file, which is just the zip up dot app executable.

02:56 Right. So I had done a bunch of stuff with the setup and all those kinds of things with pi installer to build this.

03:02 So my test case was, well, let me take this auto pi to exe thing and just point it at that and see what happens.

03:10 And what happened was good things. It was really interesting.

03:14 There's an app dot pi, but there's dependent Python files that it uses. I mean, I'm not a beast. I don't write my entire application in one file.

03:23 Like there's other things broken apart in there and that gets bundled up and it somehow discovered that all those all in.

03:29 So I just picked the top level file and it found the dependencies, you know, the requirements dot txt type dependencies and so on.

03:37 And it created a dot app file that as far as I could tell ran just fine.

03:42 That's cool.

03:42 Isn't that cool?

03:43 Yeah, I like it.

03:44 You can decide if it's a window based application.

03:47 So hide the console, which is what I said because I want it to run in the menu bar.

03:51 But if it was a console based app, but you just wanted to distribute it as a single thing with no Python, well, no Python requirements.

03:58 You could create a console based app.

04:00 You set the icon.

04:01 You can add in additional files.

04:03 So if there's like, you know, JSON configuration files or YAML files or images or something like that, you need to take a long, you can configure that there.

04:12 And then there's an advanced section that expands out to be like pages of stuff that I don't remember.

04:16 Same thing for settings.

04:17 And then you just click the big convert to pie to EXE button and you get ironically not an EXE, but a dot app file.

04:24 And there you go.

04:25 That's cool.

04:26 Isn't that cool?

04:26 So for people who are playing around with this, I think they, you know, they even have, they must be listening to us here.

04:32 They even have a little animated GIF of how this all works right on the GitHub.

04:38 That's pretty good.

04:38 So if you want to see how it works, I guess there's not a whole lot, but you browse for the icon.

04:42 You go in there and you check off some things and then you just hit build.

04:45 And it takes a little while, but you know, that's pie to EXE.

04:49 That's how it goes.

04:49 And it just sits there and it cranks away for a while, bundles it all up and yeah, got a little executable.

04:55 So if this is something you want to play with, but you're like, ah, it's kind of a real pain to go and figure out, you know,

05:02 all the, the setup pie commands in order to get it to do the pie installer commands and whatnot, then, you know, you can definitely give this a shot.

05:11 I think it's pretty neat.

05:12 I think with mine, I didn't use pie to installer.

05:15 I think I use pie to app.

05:16 Yeah.

05:17 That's what I used.

05:17 So pretty neat.

05:18 Yeah.

05:19 Check that out.

05:19 Nice.

05:20 I think people will find it helpful for ways to distribute Python apps.

05:23 Yeah.

05:24 And I like that it looks pretty professional looking.

05:27 And then also, especially, I mean, especially with internal, like internal company stuff, there's, that happens a lot where you want to share something.

05:34 Yeah.

05:35 Around.

05:35 Yeah.

05:36 Yeah.

05:36 Like just download this and run it.

05:37 Please don't ask me how to set up a path so that your Python, that's not Python three, three.

05:42 Yeah.

05:43 So whatever, right, is the one that runs it.

05:45 Nobody needs to know that it's Python underneath.

05:47 So.

05:47 Yeah, exactly.

05:48 So.

05:49 Oh, cool.

05:50 I like it.

05:50 Oh, one other thing, by the way, it's a GUI application.

05:54 It's self-written in Python.

05:56 So you may wonder, well, what is it doing, right?

05:59 Maybe it's bundled itself.

06:01 Obviously, that'd be very meta, right?

06:02 Like if autopy2xc could deliver an autopy2xc itself, that's obviously lovely.

06:07 It reminded me that I have Chrome installed when I ran it.

06:13 So what it does is it runs something in the background, then it fires up Chrome, which

06:17 becomes the UI in this kind of Windows looking Chrome window.

06:23 And it's not quite an Electron app, but it's Electron in a style.

06:28 So anyway, it's an interesting little UI app itself.

06:32 I'm not sure what it's doing, but it works.

06:34 Nice.

06:35 All right.

06:35 Well, I'd like to talk about Jupyter.

06:38 So Jupyter Notebooks.

06:40 Oh, yeah.

06:40 So this is.

06:41 How do you use it?

06:42 How do you use it?

06:43 So like, I was just fascinated by the clickbaitiness of this, but it's okay.

06:49 Eight surprising ways to, eight surprising ways how to use Jupyter Notebooks.

06:54 And I got to say, I didn't know you could do some of this stuff with Jupyter.

06:57 So it's pretty cool.

06:58 So the first one, package development.

07:01 Why would you?

07:02 I don't know why.

07:03 But, you know, some people that are more comfortable in Jupyter than they are in IDE or something.

07:08 Maybe it's good.

07:09 So there's a package called MB Dev that you can use to, and it's by a company called Fast

07:16 AI that you can use to help with package development, including, you know, trying to get your CI working

07:25 and your tests all in one place and demos and documentation and stuff.

07:30 So that's kind of neat.

07:31 Like that idea.

07:32 Oh, I definitely should try to play with that to see how that works.

07:36 Apparently there's a video.

07:38 Somebody gave a talk around it, I guess, maybe.

07:42 Lovely.

07:42 Yeah.

07:43 Build a web app.

07:44 So building a web app with Jupyter.

07:47 I think that's actually a pretty cool idea.

07:49 There's several suggestions using Voila.

07:51 I think we covered that.

07:53 I think, yeah, we've covered that before.

07:55 But the other one, I don't think we have.

07:56 PyPy widgets.

07:57 I'm not sure what that one is.

08:00 So I haven't looked at the widgets thing.

08:03 But, you know, more widgets within your window.

08:06 Sure.

08:06 Why not?

08:06 Why are there no?

08:07 It's a widgets thing.

08:08 You'd think there'd be images on the readme.

08:10 Anyway.

08:11 And then a framework called Mercury.

08:14 And this shows up several times in this.

08:17 So Mercury does a lot of stuff around Jupyter Notebooks and doing extra things.

08:25 So this shows up several times in this list.

08:27 So for one, for creating a web app, which is kind of neat, especially if you're sharing data and have interactive stuff,

08:36 you might have doing stuff with a web application.

08:40 That would be cool.

08:40 Slide deck.

08:42 Got to love it.

08:43 I definitely want to try this out because using NB Convert or Mercury, apparently Mercury does that too, uses Reveal.js.

08:54 I think a lot of people have tried Reveal.js before for slides.

08:57 But building it within notebooks, building your slide decks within notebooks,

09:01 and then having that just run, that's cool.

09:06 Building a book.

09:07 This is something else that sounds pretty interesting.

09:09 I'd like to try doing some code, a notebook, a book-like thing.

09:14 Now, I don't have, I'm curious about this.

09:17 So the book, you build a website that looks like a book, but that's not a book.

09:22 So it says it can be exported to a PDF file, but I don't see anywhere you're exporting to an EPUB or MOBI.

09:32 So, you know, I call BS on whether that this is a book.

09:36 This is a website that holds book contents as far as I can tell.

09:39 Still cool, though.

09:40 Running a blog.

09:41 This is something I had no idea Nicola could do.

09:44 So Nicola?

09:45 Nicola?

09:46 I don't know how to pronounce that.

09:48 I've ran across it before.

09:50 I'm not sure what we've covered it, but it's a static site generator.

09:56 And it apparently can take notebooks files and just run notebooks as a blog.

10:02 So that's pretty cool.

10:04 Notebooks as a blog.

10:05 Oh, that's interesting.

10:06 Well, yeah.

10:07 Especially if you're going to write about like some Python technique or something, you just do a little demo of it.

10:11 And then publish that as a text thing, or I don't know if it outputs.

10:15 I didn't read it close enough.

10:17 Outputs the exports every notebook to an HTML file and then publish all the files on a static website.

10:23 That's pretty neat.

10:24 Doing reports and dashboards, that's kind of like Jupyter would rock at that.

10:30 And I think we've covered stuff like this before.

10:32 But one of the things in the dashboard section that I thought was neat was this Mercury tool has a schedule option.

10:39 So once you set up the report, you can schedule it to execute, you know, like once a day or every hour or something like that.

10:47 And that's pretty neat to not have it do constantly, but update your dashboard at a time.

10:54 I do like that.

10:55 That's really cool.

10:56 So you could have some kind of dashboard instead of creating it in the full web app.

11:00 You just publish this.

11:01 But obviously you want it to refresh, right?

11:03 Yeah.

11:03 Yep.

11:04 So anyway, that.

11:06 Oh, last one.

11:07 REST API.

11:08 This is interesting.

11:12 I wouldn't have thought to build a REST API with Jupyter.

11:14 So I guess you can do all this stuff.

11:18 Whether or not you should, I guess it's up to you.

11:20 But anyway.

11:21 Yeah, for sure.

11:22 Anthony on the audience says, Nicola works well as a static blog generator, preferred over Pelican.

11:28 Well, that's saying something.

11:31 Nice.

11:31 That is.

11:32 Yeah.

11:34 Brian, wouldn't it be good to know which ones are like more popular, which ones maybe you should depend upon?

11:39 Yeah.

11:40 All right.

11:41 Well, Al.

11:41 I took it over.

11:42 Let's.

11:42 That's all right.

11:44 So this one is from, let me get it right here.

11:47 This one is from Tankala Ashok.

11:50 And they built this one, this thing called pip Trends.

11:55 It's modeled a little bit after NPM Trends.

11:57 And it just lets you compare the popularity of packages based on their GitHub statistics.

12:04 So GitHub statistics, you know, that's one metric of popularity, but let's give it a bit of a run.

12:10 So what about if we type Flask says, it immediately pulls up a nice little autocomplete that says Flask, a simple web framework for building complex web applications.

12:19 But then all the other ones like Flask to Postman and so on.

12:22 It's kind of interesting.

12:23 I didn't really, didn't really know about Flask to Postman.

12:26 Maybe that we'll talk about that next time, but let's pick Flask.

12:28 And then immediately, immediately says, well, what else might you consider along with this?

12:34 Like, well, how about FastAPI and Django?

12:37 And what do we have?

12:39 It also suggested Bottle for a little while.

12:41 So we'll throw Bottle in there maybe.

12:42 And let's do a search.

12:43 And it comes up with a graph that honestly surprised me a fair amount.

12:47 There's different levels of popularity, but that's not the first thing that surprised me.

12:52 The first thing that surprised me is the regular cycles that all of these packages seem to go through.

12:58 Does that seem strange to you?

13:00 Well, I've noticed it before and I don't really know what's going on.

13:04 Is it the weekends?

13:05 Yes.

13:05 Very good.

13:06 So four or five was the weekend.

13:08 Six, four, six, five.

13:10 And that's where the dip is.

13:11 So people download stuff less on the weekends because there's less.

13:14 Create me a new environment.

13:15 Create me a new project.

13:16 Check it out.

13:17 Set it up.

13:18 All that kind of stuff, which is healthy, but there's still a decent number of downloads going on the weekend there.

13:22 Yeah, I kind of wish that I'd like to see a seven-day moving window, moving average for PyPI.

13:29 Yeah, yeah, like a different window averaging or projecting function.

13:34 Anyway, what we get here is we see that Flask, sorry, FastAPI and Django are super similar,

13:40 like almost tied according to GitHub statistics.

13:44 And these are downloads.

13:45 I don't think you get downloads from GitHub.

13:47 I think this is probably from PyPI or BigQuery or something.

13:50 I'm not sure where those numbers are coming from.

13:52 Because I don't know where those are on these like time series download numbers are on GitHub.

13:58 So they're probably coming from somewhere else.

14:00 But yeah, you can throw different projects in here and say, oh, this one's relatively popular compared to that or whatever.

14:07 What do you think?

14:08 I think it's kind of neat, especially with comparing.

14:10 I mean, I've used to, there's other ways to get the stats, but having, being able to grab a few related ones,

14:16 having suggestions is kind of neat too.

14:18 Yeah.

14:19 Yeah.

14:19 So it looks.

14:20 It also has some more information about the package.

14:22 Like if you go to Flask, it's 12 years old.

14:24 It has 45 versions.

14:26 Its last release was one month ago.

14:29 Its dev status is stable.

14:31 It requires Python 3.7.

14:32 Gives the license and who it's intended for.

14:34 And you can see similarly for FastAPI, for Django and Bottle and so on.

14:40 Oh, cool.

14:41 Also down here in the GitHub stats, you can see like Flask, there's 59,000 stars.

14:47 For Django, there's 64,000 stars.

14:49 Number of open PRs.

14:51 Wow, FastAPI has a lot of open PRs and issues.

14:54 That's crazy.

14:55 When it was last updated and so on.

14:57 So yeah, and it also gives you more comparisons down here.

15:00 Like, well, that was fun.

15:01 What about Flask versus Django versus FastAPI, which is what we did.

15:05 Or NumPy versus Pandas, for example.

15:07 You can see them and so on.

15:09 That's pretty neat.

15:09 I like it.

15:10 Yeah.

15:10 Yeah.

15:11 So piptrends.com, you can check it out.

15:13 So I want to talk about, what do I want to talk about?

15:17 Class, being classy.

15:19 Actually, being callable.

15:22 So Trey Hunter put this blog post out called, is it a class or a function?

15:27 It's a callable.

15:28 And this is actually something that I guess I realized I just sort of got used to with Python.

15:34 It's a lot more, if you call something.

15:38 Like, as if you would call a function, it might not be a function.

15:42 It might be a class.

15:44 It might be an object that's callable.

15:46 It might be a class object.

15:47 All sorts of stuff you could do.

15:50 Like, just to be clear, we were talking about, or he talks about classes are callables.

15:57 So in like JavaScript or C++, you'd have to say new something.

16:03 So you'd have to say like a new date object or something.

16:07 But in Python, you just call date time with some parameters and you get back a date time object.

16:12 That's neat.

16:13 But so it's just, I guess, this is a good article to go through just to realize that you don't really have to care.

16:21 There's a whole bunch of stuff that act like functions.

16:25 And it's okay if they're not functions.

16:27 You just have to know if it's callable.

16:29 And he talks a little bit about using a knit, a dunder a knit, to make something callable.

16:37 That works.

16:37 Properties are like decorators or a thing that are a callable item.

16:43 There's some, it's just a good discussion about all of this.

16:50 I thought this was a fascinating article.

16:52 And I'm not sure I ever really thought about partials before.

16:56 Like a partial function is a, is a, like a function that creates a, almost creates an object.

17:03 And then you call it with some more stuff and then it creates a, the rest of it or creates an, anyway.

17:07 Maybe I got that wrong.

17:08 Yeah.

17:09 From functools.

17:10 I'd never used partial before.

17:11 Okay.

17:12 Yeah.

17:13 And then there's a, there's a call decorator or a call dunder method that you can use that

17:20 is helps out with making partials.

17:22 And, and talks about iterators and decorators and all sorts of stuff like that, that actually

17:31 act like callables, but they're not, they're like objects.

17:33 The thing that I don't know where this is, but the thing, there's a, a statement in here

17:39 that I thought was amazing.

17:40 So there's a, there's a page on the PyPI documentation of the built-in functions within Python.

17:47 And, and Trey points out that of the 69, there's 69 listed built-in functions within Python.

17:56 Only 42 are actually implemented as functions.

17:59 26 of them are, 26 are classes.

18:02 And, and one is a instance of a callable class.

18:06 So like, and some of them have in Python two, there were more.

18:11 And some of the, some of them got converted like a map and filter and range and zip used

18:17 to be functions.

18:17 And now they're objects or classes or something.

18:21 The len function, they use that all the time, right?

18:24 It's not a function.

18:25 Right.

18:25 It's a callable class.

18:27 Okay.

18:28 And zip, the like reversed enumerate range filter use those all the time.

18:34 They're not functions, but they're callable.

18:36 So anyway, I just thought that was an interesting take on Python is different than other languages.

18:42 It's different.

18:44 Yeah.

18:44 A lot of, a lot of languages you would never have that ambiguity, right?

18:48 But it's the kind of ambiguity that you don't need to know or be aware of.

18:51 So yeah.

18:53 So maybe ignore this article, but no, no, no.

18:56 I mean, it's interesting to know.

18:57 I'm just saying like, it's, it's not necessarily a problem that it's not super clear whether it's

19:01 a class or function because you call it and it does the thing you want it to do.

19:04 So you're good to go.

19:05 Yeah.

19:05 Like Sam, Sam Morley pointed out here.

19:09 Partial is useful.

19:10 I think, I think it can be pickled unlike typical closures that can't might be wrong.

19:16 But it just made me think about we, in other languages, they really do talk about closures

19:21 a lot and things like that.

19:22 And we just don't have to care.

19:24 It just works.

19:25 I don't know.

19:25 It just works.

19:26 Yep.

19:27 Very nice.

19:28 Very nice.

19:28 Well, we're at the.

19:30 Brian, we, yeah, we flew through those.

19:32 We did fly through them.

19:33 So, and we forgot to plug our stuff.

19:35 So we did.

19:37 Instead of a sponsor today, we've got work sponsored by us.

19:41 So I want to make sure that everybody that is thinking about trying to learn something new

19:45 in Python first, check out Talk Python Training because Michael has a whole bunch of awesome

19:51 courses and, and you can, I'm sure you can learn something for just a few bucks.

19:56 So good prices.

19:58 And a new book version two edition two.

20:01 Yeah.

20:01 I've had a lot of good, a lot of good feedback.

20:03 I love, one of the things I love is getting pictures.

20:05 I don't know why, but having somebody take a picture either of themselves holding the Python

20:11 testing with pytest second edition.

20:13 Heck, you can do the first edition too, if that's what you got, but either holding it somewhere

20:17 unique, like out in a park or at, you know, near a monument or something.

20:22 That would be so cool.

20:23 I love it when people send me pictures.

20:24 So yeah, that's awesome.

20:26 Got any extras?

20:27 I have some extras.

20:28 Yes.

20:29 You know that I do.

20:29 All right.

20:30 So this first one here, let's, let's check this out.

20:33 So this is interesting.

20:35 This comes by way of Dan Bader and it's the Orion browser.

20:40 Just when you thought there was no more room for new browsers, here's the new browser.

20:44 This one is different.

20:45 So you can see I'm running Vivaldi these days.

20:47 I love that.

20:48 Other people are using Brave, right?

20:51 And so all of those browsers take the Chromium engine, strip off the Google stuff, and then

20:57 put their own shell, many times more private privacy protecting and so on around them.

21:05 Right.

21:06 And we've got Firefox, which is awesome.

21:08 It's got its own engine.

21:09 It doesn't do that.

21:10 But almost every other browser is let's take Chrome and Chromium and wrap it up in our own

21:15 flavor of our thing with our own philosophy on how the web should be.

21:19 So this Orion browser is that, but for Safari.

21:23 Interesting.

21:24 So if you're into Safari, you know, it has things like on your Mac, it has better battery

21:29 life and so on.

21:30 But think of it as like, I think Brave is probably the closest analogy.

21:35 It's like Brave for Safari without the crypto, but it's, you know, got built in ad blocking.

21:40 It's got built in tracker blocking and all that.

21:43 One of the big drawbacks of Safari is you don't get access to the Firefox or the Chrome extensions,

21:51 right?

21:52 You just get the Safari ones.

21:54 But this one has compatibility both for Firefox and Chrome extensions.

21:59 Wow.

22:00 In there.

22:00 So you could, isn't that cool?

22:02 So you can run this privacy protecting anti-tracker Safari with Chrome extensions.

22:09 So it's just out in beta, I believe.

22:11 It's not, yeah, it's out in beta right now.

22:13 So I'm not sure where it is or where it's going to go, but it's a pretty interesting take,

22:18 isn't it?

22:18 Yeah.

22:19 It's certified snappy.

22:20 Certified snappy.

22:23 I like it.

22:23 And it's, I really like its privacy aspect.

22:27 So I think the privacy space, and you brought this up, the privacy space is, there's convenience

22:35 and there's speed, but I think that's a place where people can, we can open up the browser

22:41 wars again.

22:41 Yes.

22:43 Because in a good way to try to limit some of the privacy concerns or minimize them.

22:50 Yeah.

22:51 Nobody at Mozilla asked me, but I'll give it, you know, Firefox is having trouble sort

22:57 of keeping its market share.

22:58 I think if it could triple down as the browser that you cannot be tracked with the browser

23:04 that will absolutely preserve your privacy and then add services around that.

23:09 I think that would be great.

23:10 The big challenges.

23:11 Well, I guess, you know, they're 99, 90% funded by Google, an ad company who doesn't want

23:17 that.

23:18 So there's this, this interesting tension, but I think, you know, that's a path that I think

23:22 Firefox should be taking as well.

23:24 But I guess I forgot about that, that Google was so, such a big stake in Firefox.

23:31 Right.

23:31 I think that limits their, their playbook.

23:33 I think they can't do things like we're going to make it.

23:35 So we're invisible.

23:36 If you use Firefox basically, because their biggest supporter would not totally love that,

23:42 would they?

23:43 So anyway, this is a zero telemetry browser and whatnot.

23:48 And you can go and download it.

23:50 Apparently it works on Apple Silicon and Intel, but obviously being a Safari wrapper, I believe

23:57 it only works on, I think, Mac and iOS things, iOS, iPad and macOS.

24:04 But if you're on those, it's a pretty interesting take.

24:07 And just from the browser wars in general, I think it's pretty interesting to track.

24:10 Yeah, definitely.

24:12 It's cool.

24:12 All right.

24:13 One more quick extra and then off to you.

24:15 So last year we all did the PSF plus JetBrains developer survey, which is supported by and

24:23 analyzed by JetBrains, but is really a PSF survey.

24:26 And we had 23,000 Python developers and enthusiasts participate.

24:32 Well, the results are out.

24:33 So people can go check those out.

24:35 Now I've got a whole lot more analysis that I'd like to do before I talk about it, but they're,

24:41 they're already out.

24:42 So people can start looking around there and I'll give you more details next week.

24:45 Yeah.

24:46 Cool.

24:46 Yeah.

24:47 We should definitely cover it next week.

24:48 That'd be fun.

24:49 Absolutely.

24:50 All right.

24:51 How about you?

24:51 I've got a small thing.

24:53 I'm not sure.

24:54 sure.

24:55 It really needed an entire section, but Ned Batchelder did what's in which Python.

25:01 So it's a page that has basically everything from, what did he have?

25:07 From 2.1 to 3.11.

25:10 3.11.

25:12 Not like everything that's in every version, but some of the big hitters that you might know.

25:17 So like 3.10 has union types and structural pattern matching.

25:22 And what do you get with 3.11?

25:26 Well, we know it's faster, but do we get like how much?

25:29 And it's 10 to 60% faster than 3.10.

25:32 That's amazing.

25:33 And then exactly.

25:35 That's really amazing that after 30 years, they're like, oh, you know, this year we're going to make it 50% faster.

25:41 Like that's, that's incredible.

25:42 I'm glad that's happening.

25:43 Yeah.

25:43 And then a new module Toml lib is coming.

25:46 So like, which is interesting that we've got pyproject.toml and it's, it wasn't part of the standard library yet.

25:54 So, but a whole bunch of things, like if you can't remember, like if for some reason you forgot f-strings came in and what was it?

26:03 3.6.

26:04 Apparently I forgot.

26:05 So they came in in 3.6 because it's on the list unless, unless Ned got it wrong, which probably didn't.

26:11 So now I think 3.6, I think that's the biggest mover for 3.6 there.

26:14 Yeah.

26:15 Yep.

26:16 And data classes in 3.7.

26:18 Yeah.

26:19 So lots of cool stuff.

26:20 Fantastic.

26:21 Marie Schreiner out of the audience says it's the top features from each of the versions since 3.0.

26:27 So not everything, not extensive, but like sort of the big hitters.

26:31 Yeah.

26:32 I wasn't going to say top because, you know, there's a lot of people that worked on a whole bunch of other stuff that are on the list and I appreciate them as well.

26:38 Yeah, absolutely.

26:40 And some of it's just setting the groundwork for the next amazing thing.

26:43 Yeah.

26:44 Well, let's, let's wrap up the show with something funny.

26:47 All right.

26:48 Ready for a joke.

26:49 All right.

26:49 This is a joke by Jen Gentleman, but called to our attention by Luke Morley.

26:54 And it says, Jen says, a programmer had a problem.

26:58 He thought, I know, I'll solve it with async.

27:00 Has problems now, period, too.

27:02 He.

27:02 Because of race conditions, of course.

27:05 Yeah.

27:06 I like it.

27:09 I like it, too.

27:09 Quick and simple, but yeah.

27:11 There's a lot of variations on that joke and they're all good.

27:14 Yeah.

27:14 Most of them are good, I guess.

27:16 Anyway.

27:16 Well, thanks again, Michael, for joining me today.

27:19 And it's a great episode.

27:20 Yeah.

Back to show page