WEBVTT

00:00:00.001 --> 00:00:04.940
Hello and welcome to Python Bytes, where we deliver Python news and headlines directly to your earbuds.

00:00:04.940 --> 00:00:09.740
This is episode 415, recorded December 23rd, 2024.

00:00:09.740 --> 00:00:11.120
And I am Brian Okken.

00:00:11.120 --> 00:00:12.100
And I'm Michael Kennedy.

00:00:12.100 --> 00:00:16.340
And we're excited that today's episode is sponsored by us.

00:00:16.340 --> 00:00:23.160
So check out Talk Python Training and PythonTest.com, where we have courses there.

00:00:23.160 --> 00:00:25.260
And also, thank you to Patreon supporters.

00:00:25.580 --> 00:00:36.240
If you'd like to connect with the show and talk with us or give us suggestions to go on the show, look for the links in the show notes for all of the Mastodon or Bluesky links.

00:00:36.240 --> 00:00:39.400
We check those, and we're on both of those.

00:00:39.400 --> 00:00:43.680
You think it's a little disingenuous that we have Bluesky, even though we live in Oregon and it's winter?

00:00:43.680 --> 00:00:46.800
And we haven't seen a Bluesky for a very long time.

00:00:46.800 --> 00:00:49.420
Hey, I saw Bluesky like three days ago.

00:00:49.420 --> 00:00:51.120
Maybe it was a couple weeks ago.

00:00:51.120 --> 00:00:53.000
Okay, we have them once in a while.

00:00:55.100 --> 00:01:01.020
And if you're listening to this in your podcast player, thank you and share it with a friend.

00:01:01.020 --> 00:01:06.340
And also, occasionally, it may be fun to switch over and watch us live.

00:01:06.340 --> 00:01:11.240
So go to pythonbytes.fm/live and you can see when we're going to record next.

00:01:11.240 --> 00:01:16.600
Except for on weird days like today where I contacted Michael and said, hey, can we record early?

00:01:16.600 --> 00:01:17.500
So we did.

00:01:17.500 --> 00:01:20.700
Well, it's Christmas Eve Eve.

00:01:21.000 --> 00:01:24.780
Which makes it, which makes the schedule a little wacky.

00:01:24.780 --> 00:01:25.020
Yeah.

00:01:25.020 --> 00:01:28.560
And while we're on that, Brian, this is our last episode of the year.

00:01:28.560 --> 00:01:32.300
Next episode, we'll just put a little seasons greeting or something.

00:01:32.300 --> 00:01:36.720
And so people have to appreciate this one for all of 2024, right?

00:01:36.720 --> 00:01:37.440
Because this is it.

00:01:37.440 --> 00:01:37.920
Yeah.

00:01:37.920 --> 00:01:38.460
Yeah.

00:01:38.540 --> 00:01:40.900
And I really had fun this year.

00:01:40.900 --> 00:01:42.860
So I'm grateful for everybody to stick around.

00:01:42.860 --> 00:01:43.580
Stick it around.

00:01:43.580 --> 00:01:44.240
Yes, I am too.

00:01:44.780 --> 00:01:49.400
And the final thing I want to say is, if you haven't already, why don't you head over to

00:01:49.400 --> 00:01:54.740
pythonbytes.fm and click on newsletter and sign up for the newsletter so that you can get all

00:01:54.740 --> 00:01:59.300
of the links that we talk about in the show and some commentary around it and some notes

00:01:59.300 --> 00:02:02.140
just delivered right to your inbox.

00:02:02.140 --> 00:02:03.300
So that would be nice.

00:02:03.300 --> 00:02:05.620
So everyone needs some artisanal notes.

00:02:05.620 --> 00:02:06.960
Artisanal notes.

00:02:06.960 --> 00:02:07.320
Yes.

00:02:07.320 --> 00:02:10.380
Fresh Oregon artisanal made in Oregon.

00:02:10.380 --> 00:02:12.120
So probably still dripping wet.

00:02:13.760 --> 00:02:15.280
Maybe a little moss on it.

00:02:15.280 --> 00:02:16.340
Yeah, exactly.

00:02:16.340 --> 00:02:20.000
Well, why don't you take it off with the first topic, Michael?

00:02:20.000 --> 00:02:21.880
All right, let's do it.

00:02:21.880 --> 00:02:25.980
So I would like to talk about durable software.

00:02:25.980 --> 00:02:29.600
Honestly, this is something I don't hear a ton of in the Python space.

00:02:29.600 --> 00:02:31.100
So I thought I'd shine a little light.

00:02:31.100 --> 00:02:38.320
Both projects that I'm highlighting today for the main topics on my end are sub 500 GitHub

00:02:38.320 --> 00:02:38.760
stars.

00:02:38.760 --> 00:02:41.660
So they're used by people, but they're not major projects.

00:02:41.660 --> 00:02:44.280
But I think they could be really useful.

00:02:44.280 --> 00:02:49.000
And so I'm kind of shining a light on some up and coming ones, let's say.

00:02:49.000 --> 00:02:52.980
So the first one is DbOS transact pi.

00:02:53.220 --> 00:02:57.720
And the H2 is ultralight durable execution in Python.

00:02:57.720 --> 00:02:58.820
So what the heck does that mean?

00:02:58.820 --> 00:02:59.480
What is durable?

00:02:59.480 --> 00:03:01.140
Like does it have try except somewhere?

00:03:01.140 --> 00:03:02.400
No, more than that.

00:03:02.400 --> 00:03:04.720
Way, way more than just error handling.

00:03:04.720 --> 00:03:09.400
So what you do, imagine, Brian, that you've got some long running process.

00:03:09.860 --> 00:03:16.160
Like one step of this process is I want to wait until a file shows up in this directory.

00:03:16.160 --> 00:03:19.240
And then when it does, we're going to process it, save it over here.

00:03:19.240 --> 00:03:24.020
Some other system, maybe you don't have direct conversation, like direct connections with, does

00:03:24.020 --> 00:03:26.320
some things, processes it, gives you a response.

00:03:26.320 --> 00:03:27.640
Then you take on the next step.

00:03:27.700 --> 00:03:31.660
Like it's like a long running, it's not just going to happen all at once, right?

00:03:31.660 --> 00:03:34.060
And also it has to keep going.

00:03:34.060 --> 00:03:38.400
You know, if it's long running and you've got to restart your server or you want to deploy

00:03:38.400 --> 00:03:40.600
a new version of the app, or there's even a bunch of stuff.

00:03:40.600 --> 00:03:48.140
If you're doing API style things where the worker processes periodically get restarted for

00:03:48.140 --> 00:03:51.820
memory in case they get hung up just to keep them sort of fresh, right?

00:03:51.860 --> 00:03:55.900
So there's all sorts of reasons your long running thing might get shut down in the middle.

00:03:55.900 --> 00:03:57.380
So that's what this thing handles.

00:03:57.380 --> 00:04:01.740
So you write a Python function, you give it a workflow decorator, and then it calls a bunch

00:04:01.740 --> 00:04:05.820
of sub functions to do its steps and they're decorated with at step.

00:04:05.820 --> 00:04:12.240
And then what happens is when this runs each step before, and then basically what workflow

00:04:12.240 --> 00:04:18.660
is happening, what step is running, what data was passed into it is serialized into a Postgres,

00:04:18.660 --> 00:04:19.600
right?

00:04:19.720 --> 00:04:22.760
And so if it crashes, it just goes, oh, well, what workflows do I have going?

00:04:22.760 --> 00:04:24.160
Oh, I see these.

00:04:24.160 --> 00:04:25.220
And this one is at step five.

00:04:25.220 --> 00:04:25.900
And here's the status.

00:04:25.900 --> 00:04:27.280
So just run step five again.

00:04:27.280 --> 00:04:27.760
Wow.

00:04:27.760 --> 00:04:28.360
And off it goes.

00:04:28.360 --> 00:04:28.900
Okay.

00:04:28.900 --> 00:04:29.340
Isn't that cool?

00:04:29.340 --> 00:04:30.340
That's really cool.

00:04:30.340 --> 00:04:33.240
It's not something I totally need all the time.

00:04:33.240 --> 00:04:36.080
You know, it's not something I feel like is a real common thing.

00:04:36.080 --> 00:04:40.820
But if you were doing like a lot of email, I'm sitting on an email process, right?

00:04:40.820 --> 00:04:43.860
I'm managing myself, which no, I'm not.

00:04:43.860 --> 00:04:48.160
But well, I guess with less mucking sort of indirectly with the self-husted thing.

00:04:48.240 --> 00:04:52.400
Anyway, you know, you're contacting a bunch of things or you're calling a bunch of APIs

00:04:52.400 --> 00:04:56.560
or you're uploading a bunch of files over an API, like over S3 or something.

00:04:56.560 --> 00:04:57.920
And the thing goes down.

00:04:57.920 --> 00:05:00.500
You know, you could do this to just go, all right, well, where was I?

00:05:00.500 --> 00:05:01.640
Pick it up and keep going.

00:05:01.640 --> 00:05:02.680
So let's see.

00:05:02.680 --> 00:05:05.760
It says, all you need to do is use a Postgres database to connect to it.

00:05:05.760 --> 00:05:08.420
There's no need for a workflow server, which is cool.

00:05:08.500 --> 00:05:14.460
And apparently there's this thing called AWS Step Functions, because of course there are at AWS.

00:05:14.460 --> 00:05:21.560
If there's any sort of possible type of programming or execution, there's a AWS service for it.

00:05:21.560 --> 00:05:24.140
Anyway, it says it's 25 times faster than that, which I guess is good.

00:05:24.140 --> 00:05:25.280
More cool features.

00:05:25.280 --> 00:05:26.400
Schedule jobs.

00:05:26.400 --> 00:05:29.260
Run your workflows exactly once per time interval.

00:05:29.260 --> 00:05:30.780
So on job sort of deal.

00:05:31.120 --> 00:05:32.780
Exactly once event processing.

00:05:32.780 --> 00:05:35.720
Use a workflow to process incoming events.

00:05:35.720 --> 00:05:38.540
For example, a Kafka topic exactly once.

00:05:38.540 --> 00:05:39.300
That's pretty cool.

00:05:39.300 --> 00:05:44.120
In observability, all workflows are automatically emit open telemetry traces.

00:05:44.120 --> 00:05:48.980
So you can, anything that integrates with open telemetry, which is a bunch of the different systems out there,

00:05:48.980 --> 00:05:51.940
like air monitoring and sentry type things, plug that in.

00:05:51.940 --> 00:05:52.840
That's pretty cool.

00:05:52.840 --> 00:05:55.380
So it clearly works on the cloud.

00:05:55.380 --> 00:05:58.000
Does it, could it work as a local thing as well?

00:05:58.000 --> 00:05:59.880
Yeah, it just needs a Postgres database.

00:06:00.200 --> 00:06:03.820
So if you, if you could run a Postgres database or if you can run Docker,

00:06:03.820 --> 00:06:06.860
then you could just run the Postgres image locally.

00:06:06.860 --> 00:06:09.900
And you know, it's the same, just same port, same connection string.

00:06:09.900 --> 00:06:10.340
Cool.

00:06:10.340 --> 00:06:10.740
Yeah.

00:06:10.740 --> 00:06:11.300
There you go.

00:06:11.300 --> 00:06:12.120
Over to you.

00:06:12.120 --> 00:06:17.020
I was just thinking about like recently you mentioned going through and doing,

00:06:17.020 --> 00:06:20.120
redoing a lot of the transcripts.

00:06:20.120 --> 00:06:24.560
Could it possibly do something like this to, if it ever dies to restart it.

00:06:24.560 --> 00:06:25.480
Yeah, exactly.

00:06:25.480 --> 00:06:27.960
If you're doing or video file processing.

00:06:27.960 --> 00:06:28.340
Yeah.

00:06:28.340 --> 00:06:29.820
If you want, that's a super common.

00:06:29.820 --> 00:06:33.560
You know, I want to run conversions for these files,

00:06:33.560 --> 00:06:35.000
but it's going to take two days.

00:06:35.000 --> 00:06:35.440
Yeah.

00:06:35.440 --> 00:06:38.000
The audience says, that sounds interesting.

00:06:38.000 --> 00:06:41.820
I've been trying to adopt Airflow for a particular set of scheduled jobs I have,

00:06:41.820 --> 00:06:43.660
but it's super complicated to set up.

00:06:43.660 --> 00:06:43.880
Yeah.

00:06:43.880 --> 00:06:44.280
Very cool.

00:06:45.580 --> 00:06:49.460
I want to talk about a survey a little bit that I didn't know about,

00:06:49.460 --> 00:06:50.940
and I'm still a little confused.

00:06:50.940 --> 00:06:57.780
But there's a, there's an article on engineering at meta called typed Python in 2024.

00:06:57.780 --> 00:07:01.100
Well-adopted yet usability challenges persist.

00:07:01.100 --> 00:07:07.100
But, and I'll get into the topic a little bit, but I was a little confused by the survey.

00:07:07.100 --> 00:07:10.300
It says this summer, JetBrains meta and Microsoft collaborated,

00:07:10.300 --> 00:07:14.980
collaborated to conduct a comprehensive survey on the state of Python typing.

00:07:15.520 --> 00:07:19.100
And perhaps I just missed that, or it wasn't the results were announced,

00:07:19.100 --> 00:07:20.420
or maybe this is the announcement.

00:07:20.420 --> 00:07:22.780
Because this is not the JetBrains developer survey.

00:07:22.780 --> 00:07:23.720
This is something else.

00:07:23.720 --> 00:07:30.700
This is a survey that happened through July, through October, beginning of October, I guess.

00:07:31.260 --> 00:07:34.560
Anyway, so back to the topic at hand.

00:07:34.560 --> 00:07:40.900
So the idea is 10 years after the introduction of PEP 484 with,

00:07:40.900 --> 00:07:42.600
I didn't, can't believe it's been 10 years.

00:07:42.600 --> 00:07:48.320
We surveyed the current state of Python type systems and the tool developed tools developers are using.

00:07:48.320 --> 00:07:52.920
And like I said, it's a, it was a JetBrains meta Microsoft thing.

00:07:52.920 --> 00:07:59.860
So the findings, 88% of respondents always or often use types in their Python code.

00:08:00.300 --> 00:08:08.240
The IDE tooling documentation and catching bugs are drivers for the high adoption of types in survey responses.

00:08:08.240 --> 00:08:12.660
So, and we'll get to the, there's a, there's a couple other things in here too,

00:08:12.660 --> 00:08:19.740
but I wanted to highlight this because like catching bugs, that's, that's what I thought people would use this for.

00:08:19.740 --> 00:08:27.380
Using PyPy or mypy and, and other, you know, other tools to, to check for type errors.

00:08:27.940 --> 00:08:33.900
But I think that the big, the big wins are in documentation and IDE tooling.

00:08:33.900 --> 00:08:42.260
I, I started using it for documentation primarily to document how somebody should use a method to,

00:08:42.260 --> 00:08:46.840
and I think it's super helpful to say, yeah, it's going to be a list of strings that you're going to pass in here.

00:08:47.620 --> 00:08:52.380
It just helps to understand how, especially for non-obvious things.

00:08:52.380 --> 00:08:53.700
Is it going to be a tuple?

00:08:53.700 --> 00:08:54.320
Is it a list?

00:08:54.320 --> 00:08:55.320
I guess it doesn't matter.

00:08:55.320 --> 00:08:56.060
It's an iterable.

00:08:56.060 --> 00:08:58.980
But that's really helpful.

00:08:58.980 --> 00:09:06.120
Then the IDE tooling came out, came along and started making it a lot easier just to, to have type hints and everything work right.

00:09:06.360 --> 00:09:14.960
When using you, now I don't have to hop over to another screen or another, like find the definition of a function to find out what's in there.

00:09:14.960 --> 00:09:22.260
I can get type hints to help me and the pop-up dialogues, the, whatever, what the code, what are those things called?

00:09:22.260 --> 00:09:23.480
Anyway.

00:09:23.480 --> 00:09:25.680
The ones where it's in a separate file?

00:09:25.680 --> 00:09:26.200
No.

00:09:26.200 --> 00:09:26.520
Yeah.

00:09:26.560 --> 00:09:31.800
Well, like if you, if you start typing a function and you hit print, print, print, and it's in the ID tells you.

00:09:31.800 --> 00:09:32.760
Oh, autocomplete.

00:09:32.760 --> 00:09:33.120
Yeah.

00:09:33.120 --> 00:09:34.100
Autocomplete stuff.

00:09:34.100 --> 00:09:38.660
It's really helpful to be able to know, oh yeah, it's going to go in here.

00:09:38.660 --> 00:09:42.820
I wish that there was a way to shorten it because some stuff that has so many.

00:09:42.820 --> 00:09:44.600
So I'm using all the time.

00:09:44.600 --> 00:09:49.560
And there's, there's so many arguments that it's like this big giant blob thing and it's not helpful.

00:09:49.560 --> 00:09:50.080
But anyway.

00:09:50.080 --> 00:09:52.520
Got to decrease your font size there, you know?

00:09:52.520 --> 00:09:53.240
Maybe.

00:09:53.240 --> 00:09:56.540
Or just like, yeah, just the standard.

00:09:56.540 --> 00:09:58.040
Library stuff that I'm using all the time.

00:09:58.040 --> 00:09:59.160
Don't keep popping that up.

00:09:59.160 --> 00:10:01.260
I don't need type hints for print.

00:10:01.260 --> 00:10:02.200
Just saying.

00:10:02.200 --> 00:10:05.660
So, or I need type hints.

00:10:05.660 --> 00:10:07.140
I just don't need that pop-up.

00:10:07.140 --> 00:10:07.520
Anyway.

00:10:07.520 --> 00:10:09.820
So interesting survey.

00:10:09.820 --> 00:10:18.080
The, the, one of the interesting things here was that people were using it even for personal stuff, just personal projects.

00:10:18.080 --> 00:10:24.800
66% of respondents said they use, still use type hints always or often.

00:10:25.200 --> 00:10:27.400
And 78% of professionals.

00:10:27.400 --> 00:10:28.360
That makes sense.

00:10:28.360 --> 00:10:31.500
It was, it'd be more when, with your work code than personal code.

00:10:31.500 --> 00:10:33.300
But I'm finding that myself.

00:10:33.300 --> 00:10:35.160
I'm, I'm using it even for personal stuff.

00:10:35.160 --> 00:10:36.920
I'm using type, type hints.

00:10:36.920 --> 00:10:41.060
So a little bit of interesting things on which IDs are people using.

00:10:41.060 --> 00:10:43.800
It's a little different from, from the developer survey.

00:10:43.800 --> 00:10:48.900
But maybe they had a different set of list, list set that people could choose from.

00:10:48.900 --> 00:10:53.880
So mostly VS Code, PyCharm up there, plus Emacs and NeoVim.

00:10:53.880 --> 00:10:55.920
Emacs or NeoVim and other.

00:10:55.920 --> 00:11:04.760
But like the developer survey had, had mostly what, oh, IDE was VS Code, PyCharm, Vim, Jupyter, Notebooks.

00:11:04.760 --> 00:11:05.580
Anyway.

00:11:05.580 --> 00:11:08.540
So had probably just more selection or something.

00:11:08.540 --> 00:11:11.560
I think there was more, there were many options in the PSF one.

00:11:11.800 --> 00:11:12.000
Yeah.

00:11:12.000 --> 00:11:16.340
The PyCharm was the same, but VS Code was smaller.

00:11:16.340 --> 00:11:17.080
Interesting.

00:11:17.080 --> 00:11:17.620
Yeah.

00:11:17.620 --> 00:11:18.480
It's a different audience as well.

00:11:18.480 --> 00:11:18.780
Who knows?

00:11:18.780 --> 00:11:19.100
Yeah.

00:11:19.100 --> 00:11:19.600
Anyway.

00:11:19.600 --> 00:11:28.300
So I, what are the real takeaways here though, for, for me as a trainer and other people that

00:11:28.300 --> 00:11:31.740
try to teach people is I think we need to do a better job at teaching.

00:11:31.740 --> 00:11:39.740
Some of the reasons why people are not using types and are what we've got not required for

00:11:39.740 --> 00:11:41.440
my project, lack of familiarity.

00:11:41.440 --> 00:11:48.860
They're too complex and it's hard to, hard to use or set up and push back from coworkers

00:11:48.860 --> 00:11:53.700
or co-maintainers is the, is like 50, 50 people.

00:11:53.700 --> 00:11:54.220
Anyway.

00:11:55.080 --> 00:11:55.820
Oh wow.

00:11:55.820 --> 00:11:58.460
It's not percent because the top is 150.

00:11:58.460 --> 00:11:59.700
So I'm not sure what's going on here.

00:11:59.700 --> 00:12:03.040
So that's otherwise known as 33%.

00:12:03.040 --> 00:12:05.200
34.

00:12:05.200 --> 00:12:05.680
I don't know.

00:12:05.680 --> 00:12:14.020
But the, what I found is that, that I, there were, I always run into something that's complex

00:12:14.020 --> 00:12:18.060
like a, you know, a, a, a pytest fixture.

00:12:18.060 --> 00:12:18.660
I don't know.

00:12:18.660 --> 00:12:20.760
I still don't know how to type those correctly.

00:12:21.180 --> 00:12:24.680
But you can type, you can do type hints for most things.

00:12:24.680 --> 00:12:27.500
And if you run into complex stuff, just don't worry about it.

00:12:27.500 --> 00:12:27.920
Move on.

00:12:27.920 --> 00:12:30.060
That's my recommendation.

00:12:30.060 --> 00:12:34.520
There's, you can jump, go down that rabbit hole and try to try to do things.

00:12:34.520 --> 00:12:38.260
But I think that that's something that people would train when training.

00:12:38.700 --> 00:12:41.760
teach people how to use type hints in simple things like this.

00:12:41.760 --> 00:12:43.580
Hey, if it's an int, do this.

00:12:43.580 --> 00:12:48.820
But I think it's important to maybe say, Hey, sometimes it's complex.

00:12:48.820 --> 00:12:53.840
Just like there's, there's ways to do that, but you also don't need to worry about it.

00:12:53.840 --> 00:12:55.900
People can look up the docs for that.

00:12:55.900 --> 00:13:03.200
I do appreciate the addition of not having to import like capital list and capital, you

00:13:03.200 --> 00:13:05.220
know, whatever the other ones.

00:13:05.480 --> 00:13:05.640
Yeah.

00:13:05.640 --> 00:13:08.120
Like dict and set and all them.

00:13:08.120 --> 00:13:08.280
Yeah.

00:13:08.280 --> 00:13:08.720
Yeah.

00:13:08.720 --> 00:13:13.180
And you can just do lowercase list and dict and stuff like that now, which is better.

00:13:13.180 --> 00:13:14.200
That's 310 and above.

00:13:14.200 --> 00:13:14.680
Yeah.

00:13:14.680 --> 00:13:18.500
So anyway, some interesting information here on the, on typing.

00:13:18.500 --> 00:13:19.500
Nice.

00:13:19.500 --> 00:13:20.100
Awesome.

00:13:20.100 --> 00:13:21.300
Well, you know what?

00:13:21.300 --> 00:13:22.780
I think we just, more typing.

00:13:22.780 --> 00:13:27.600
Let's just, it's all typing all to close out 2024.

00:13:28.060 --> 00:13:31.680
So I would like to talk about RightTyper.

00:13:31.680 --> 00:13:32.200
Okay.

00:13:32.200 --> 00:13:33.500
R-I-G-H-T typer.

00:13:33.500 --> 00:13:40.160
A fast and efficient type assistant for Python, including tensor shape interfaces and data science

00:13:40.160 --> 00:13:40.600
thingies.

00:13:40.600 --> 00:13:41.920
So what the heck is this?

00:13:41.920 --> 00:13:47.760
So you're saying, Brian, that a lot of developers will write types when they write their functions.

00:13:47.760 --> 00:13:54.320
But if you adopt a code base and it doesn't have typing or you have some colleague who

00:13:54.320 --> 00:13:58.080
utterly resists it, resists adding types, like I will not do this.

00:13:58.080 --> 00:14:00.160
But as a group, you've decided, yeah, we're doing it.

00:14:00.160 --> 00:14:01.780
And somehow that person still works there.

00:14:01.780 --> 00:14:04.700
You could use this thing, right?

00:14:04.700 --> 00:14:08.300
So this would be good for old projects, just untyped projects, whatever.

00:14:08.300 --> 00:14:13.620
You know, a lot of examples of projects that didn't have typing were things that traditionally

00:14:13.620 --> 00:14:16.100
supported two and three, Python two and three.

00:14:16.100 --> 00:14:16.600
Oh yeah.

00:14:16.600 --> 00:14:16.820
Right.

00:14:16.820 --> 00:14:20.240
And like, like, well, we can't have types because we want to support Python two.

00:14:20.240 --> 00:14:21.340
And now they're like, you know what?

00:14:21.340 --> 00:14:23.100
Take, take a hike Python two.

00:14:23.100 --> 00:14:25.120
Maybe it's time to add types to them.

00:14:25.120 --> 00:14:25.320
Right.

00:14:25.320 --> 00:14:26.820
So that's what this thing could do.

00:14:26.820 --> 00:14:30.060
So what you do is you run your Python program.

00:14:30.060 --> 00:14:32.620
You say like Python three dash M RightTyper.

00:14:32.620 --> 00:14:35.200
And then you can even use, do it via testing.

00:14:35.200 --> 00:14:37.140
I've never seen a nested dash M.

00:14:37.140 --> 00:14:37.580
I love it.

00:14:37.580 --> 00:14:37.820
Okay.

00:14:37.820 --> 00:14:43.080
So Python dash M RightTyper dash M py test dash continue on collect.

00:14:43.080 --> 00:14:43.420
All right.

00:14:43.420 --> 00:14:44.100
You could do that.

00:14:44.280 --> 00:14:48.400
And what it will do in this case is it'll run all of your tests and it'll look at the

00:14:48.400 --> 00:14:50.260
data exchanged for each function.

00:14:50.260 --> 00:14:56.020
And then it will create the signatures of those functions with typing automatically.

00:14:56.020 --> 00:14:56.920
Oh, wow.

00:14:57.280 --> 00:14:57.460
Yeah.

00:14:57.460 --> 00:15:02.280
So it efficiently computes type annotation coverage for files and directories in it in

00:15:02.280 --> 00:15:04.780
first shapes of annotations for data science thingies.

00:15:04.780 --> 00:15:11.220
Like I said, numpy jacks, py torch, et cetera, compatible with jacks typing, beartype and typeguard.

00:15:11.500 --> 00:15:12.980
We've covered beartype and typeguard.

00:15:12.980 --> 00:15:13.220
Both.

00:15:13.220 --> 00:15:13.600
Awesome.

00:15:13.600 --> 00:15:14.440
Jacks typing.

00:15:14.440 --> 00:15:15.460
Don't know jacks.

00:15:15.460 --> 00:15:20.160
Apparently there are some other tools like monkey type and py annotate.

00:15:20.320 --> 00:15:23.660
But if you look at the timing performance, it's pretty good.

00:15:23.660 --> 00:15:27.080
So it's like significantly faster than some of these tools.

00:15:27.080 --> 00:15:27.500
Right.

00:15:27.500 --> 00:15:29.300
So near zero overhead.

00:15:29.300 --> 00:15:31.840
So you can kind of run it on a complicated app and so on.

00:15:31.840 --> 00:15:32.300
Okay.

00:15:32.300 --> 00:15:33.220
This looks great.

00:15:33.740 --> 00:15:33.940
Yeah.

00:15:33.940 --> 00:15:35.680
And you can run a particular script.

00:15:35.680 --> 00:15:41.580
And then what it'll do is it'll output, I believe, a separate file.

00:15:41.580 --> 00:15:43.900
And it says, look, you just had def barnacle.

00:15:43.900 --> 00:15:44.480
It took an X.

00:15:44.480 --> 00:15:48.420
But no, that X is a colon numpy.ndarray.

00:15:48.420 --> 00:15:50.500
And this function returns an ndarray.

00:15:50.500 --> 00:15:50.960
Right?

00:15:50.960 --> 00:15:51.580
Yeah.

00:15:51.580 --> 00:15:52.540
That's cool.

00:15:52.540 --> 00:15:57.100
Or if you want to have it annotate bear type, remember bear type will verify that it's

00:15:57.100 --> 00:15:58.140
actually right at runtime.

00:15:58.140 --> 00:15:59.980
You can have it do that sort of deal.

00:16:00.080 --> 00:16:05.320
Or even if you have a partially annotated, but not entirely annotated thing, it will annotate

00:16:05.320 --> 00:16:05.820
that as well.

00:16:05.820 --> 00:16:06.160
Yeah.

00:16:06.160 --> 00:16:10.500
So you can specify the output top files, whether or not overwrite your files.

00:16:10.500 --> 00:16:14.080
Obviously, the assumption would be that that is in source control.

00:16:14.080 --> 00:16:15.280
You've committed it.

00:16:15.280 --> 00:16:16.600
You run this and override it.

00:16:16.600 --> 00:16:18.240
Then you look at the diff and you decide.

00:16:18.240 --> 00:16:19.960
I think that would be the best way to use it.

00:16:19.960 --> 00:16:20.180
Right?

00:16:20.180 --> 00:16:23.240
That way you can view the diff and go, looks good.

00:16:23.240 --> 00:16:24.000
Accept that change.

00:16:24.000 --> 00:16:24.420
Looks good.

00:16:24.420 --> 00:16:25.160
Accept that change.

00:16:25.160 --> 00:16:26.020
I don't know about that one.

00:16:26.020 --> 00:16:26.900
Skip that change.

00:16:26.900 --> 00:16:28.400
You know, that kind of deal.

00:16:28.400 --> 00:16:28.880
Yeah.

00:16:29.140 --> 00:16:33.140
Anyway, I think this is pretty awesome and it could be real helpful for people.

00:16:33.140 --> 00:16:35.540
It's kind of one of those tools you don't use often.

00:16:35.540 --> 00:16:39.420
It's like Fluent or one of these other upgrade things.

00:16:39.420 --> 00:16:40.480
It's like, well, I ran it once.

00:16:40.480 --> 00:16:42.140
I got the old code to the new code.

00:16:42.140 --> 00:16:43.580
Now I just work new code style.

00:16:43.580 --> 00:16:47.200
But at the same time, that's real serious drudgery that you could avoid.

00:16:47.200 --> 00:16:47.940
Yeah.

00:16:47.940 --> 00:16:54.840
Now I got to try it on my code base is partly, like I said, I sometimes trip up on fixtures

00:16:54.840 --> 00:16:56.640
and maybe it'll tell me how to type it.

00:16:56.640 --> 00:16:57.400
I bet it'll tell you.

00:16:57.400 --> 00:16:57.800
Yeah.

00:16:57.800 --> 00:17:00.980
I don't know what to put for fixtures either, but it'll probably discover it.

00:17:00.980 --> 00:17:01.100
Yeah.

00:17:01.100 --> 00:17:01.520
Yeah.

00:17:01.520 --> 00:17:04.540
Christian now in the audience points out faster than monkey types, Smiley.

00:17:04.540 --> 00:17:05.180
Love it.

00:17:06.800 --> 00:17:07.720
Oh, this is neat.

00:17:07.720 --> 00:17:10.000
I'm looking forward to playing with that.

00:17:10.000 --> 00:17:10.320
Cool.

00:17:10.320 --> 00:17:10.820
Indeed.

00:17:11.180 --> 00:17:11.480
All right.

00:17:11.480 --> 00:17:13.580
It's getting to the end of the year.

00:17:13.580 --> 00:17:14.580
I'm feeling a little lazy.

00:17:14.580 --> 00:17:15.300
Are you?

00:17:15.300 --> 00:17:15.720
No.

00:17:15.720 --> 00:17:16.480
Tell us more.

00:17:16.480 --> 00:17:17.620
No, I'm not.

00:17:17.620 --> 00:17:20.880
But maybe Trey Hunter is.

00:17:20.880 --> 00:17:26.360
So Trey Hunter wrote a blog post called Lazy Self-Installing Python Scripts with uv.

00:17:26.360 --> 00:17:31.860
And I think that time is right for us to go back to using our own personal scripts more

00:17:31.860 --> 00:17:35.160
because it's now so much easier with uv and Python.

00:17:35.520 --> 00:17:38.160
So I used, I mean, I thought about this.

00:17:38.160 --> 00:17:42.440
I used to have my own bin, the home directory bin directory full of a whole bunch of little

00:17:42.440 --> 00:17:42.760
scripts.

00:17:42.760 --> 00:17:43.760
I got a bin.

00:17:43.760 --> 00:17:44.800
I got a tilde bin.

00:17:44.800 --> 00:17:45.320
Come on now.

00:17:45.320 --> 00:17:45.620
Yeah.

00:17:45.620 --> 00:17:46.300
Tilde bin.

00:17:46.300 --> 00:17:53.020
So I've got, I actually, to be honest, I haven't done this much lately because it's not

00:17:53.020 --> 00:17:54.380
trivial with Python.

00:17:54.380 --> 00:17:58.040
And I don't really write a lot of bash anymore or anything.

00:17:58.040 --> 00:18:01.740
I mean, a little bit, but nothing I want to keep around.

00:18:02.060 --> 00:18:08.820
Anyway, but that's a, there's a lot of everyday Python, everyday tasks that maybe, maybe would

00:18:08.820 --> 00:18:12.100
help to, to code up with Python and it's easier now.

00:18:12.100 --> 00:18:18.600
So Trey walks through, starts out with talking about how you can, how you do this with just

00:18:18.600 --> 00:18:22.100
creating a file in a bin directory.

00:18:22.100 --> 00:18:23.540
It has to be in your path.

00:18:23.540 --> 00:18:28.400
So that's, I don't remember if he talks about that or not, but you have to possibly modify

00:18:28.400 --> 00:18:31.800
your .zhrc or your bash RC or something.

00:18:31.800 --> 00:18:35.880
To get, to get your home directory bin in your path.

00:18:35.880 --> 00:18:41.480
But after it's there, you can stick a file in there and change the permissions on it, the

00:18:41.480 --> 00:18:42.200
execute bit.

00:18:42.200 --> 00:18:43.520
And, oh yeah.

00:18:43.520 --> 00:18:47.420
And then make sure that it's a, it's a directory in your path variable.

00:18:47.420 --> 00:18:52.120
And then, and then you can just run it whenever you want from any directory.

00:18:52.120 --> 00:18:57.060
The, the slight differences of the, what pound bang.

00:18:57.060 --> 00:18:59.820
what do you, I don't know what you call this thing.

00:18:59.820 --> 00:19:00.340
Shebang.

00:19:00.340 --> 00:19:00.980
Shebang.

00:19:00.980 --> 00:19:02.060
The shebang at the top.

00:19:02.060 --> 00:19:07.380
He has an example of just, using, user bin, ENV Python three.

00:19:07.380 --> 00:19:11.800
And that's, that works fine for, for things that without dependencies.

00:19:11.800 --> 00:19:15.900
So just a little Python script, which is actually still pretty useful.

00:19:15.900 --> 00:19:18.600
the, the, it's interesting.

00:19:18.600 --> 00:19:24.020
The example though, he says, his script, like my script.py, but then he has an example

00:19:24.020 --> 00:19:28.720
of a bin zero that, just prints out 80 zeros, which is kind of cool.

00:19:28.720 --> 00:19:32.100
but that, that really wouldn't be zero dot pi.

00:19:32.100 --> 00:19:33.080
That would just be zero.

00:19:33.080 --> 00:19:36.000
So you just take off the dot pi so you can just type it.

00:19:36.000 --> 00:19:40.160
so the problem that he wants to talk about in this is, with dependencies.

00:19:40.160 --> 00:19:46.940
And he has an example that uses, that he uses, he normalizes audio, of a given

00:19:46.940 --> 00:19:53.380
video file with the FFm peg, and, and great tool, but yeah, it's something you have

00:19:53.380 --> 00:19:53.880
to install.

00:19:53.880 --> 00:20:01.700
So, or it depends, the script depends on FFm peg, normalize, and the FFm peg

00:20:01.700 --> 00:20:02.180
utility.

00:20:02.180 --> 00:20:03.960
So how do you deal with this?

00:20:03.960 --> 00:20:08.960
He said he used to be using pip X, but now uv makes it super easy.

00:20:08.960 --> 00:20:12.140
You don't have to, you don't, it doesn't even have to be installed to write the script.

00:20:12.140 --> 00:20:20.200
You use the shebang again, but instead of, of Python, you call dash S or

00:20:20.200 --> 00:20:23.660
dash capital S uv run and --script.

00:20:23.660 --> 00:20:28.740
And then you, you have these three slashes with script in there and then three slashes

00:20:28.740 --> 00:20:32.300
at the end, all in comments, but then you can require which Python.

00:20:32.300 --> 00:20:34.980
So you can say requires Python and dependencies.

00:20:34.980 --> 00:20:39.060
And it looks, it looks like there's a bunch of, I wonder how much of the, pipe project

00:20:39.060 --> 00:20:44.720
that Toml syntax goes in here, but this is very Toml like, but you got your, dependencies

00:20:44.720 --> 00:20:46.680
there and it just runs it.

00:20:46.680 --> 00:20:47.760
So what it, yeah.

00:20:47.760 --> 00:20:52.740
And by the way, not only does it install the dependencies when you run it, if they're not

00:20:52.740 --> 00:20:54.300
there, it will install Python.

00:20:54.300 --> 00:20:56.100
If Python 312 is not there.

00:20:56.100 --> 00:20:56.660
Yeah.

00:20:56.660 --> 00:21:02.000
And it checks it, everyone like, like say you haven't run something for a few weeks and

00:21:02.000 --> 00:21:04.740
there's been, it's not the correct versions anymore.

00:21:04.900 --> 00:21:06.240
They, somebody's taking something down.

00:21:06.240 --> 00:21:07.720
It'll check it and get the right thing.

00:21:07.720 --> 00:21:11.800
And it happens so fast that you don't have to worry about it if you're connected with a

00:21:11.800 --> 00:21:12.960
connection.

00:21:12.960 --> 00:21:18.720
But, the, so I tried this morning and I was thrilled to see the, it says like

00:21:18.720 --> 00:21:21.620
reading that it's, it's the output of your script.

00:21:21.620 --> 00:21:29.040
But then it also says, reading inline script metadata from, and then it has the title

00:21:29.040 --> 00:21:29.600
of the script.

00:21:29.600 --> 00:21:32.500
And I have a lot of scripts that I pipe the output to stuff.

00:21:32.500 --> 00:21:36.440
So I was hoping that, that I wanted to like, what's going to mess up my output.

00:21:36.440 --> 00:21:40.960
It doesn't, it, this, this reading inline stuff, comes out on standard error.

00:21:40.960 --> 00:21:41.320
So.

00:21:41.320 --> 00:21:45.680
And can I, can I add a, one more command flag?

00:21:45.680 --> 00:21:46.100
Okay.

00:21:46.100 --> 00:21:48.160
To what Trey is suggesting here.

00:21:48.160 --> 00:21:51.760
You go back up to the env dash, uv command.

00:21:51.760 --> 00:21:52.240
Yeah.

00:21:52.240 --> 00:21:56.660
With the capital S just added dash lowercase Q and all that goes away.

00:21:56.660 --> 00:21:57.300
It's the same output.

00:21:57.300 --> 00:21:59.420
So what's the dash?

00:21:59.420 --> 00:22:01.140
Dash is that just script or something?

00:22:01.140 --> 00:22:04.280
I guess I've, I've never used to, I just tell it to run the script.

00:22:04.280 --> 00:22:05.860
So I don't know what the dash test is.

00:22:05.860 --> 00:22:08.400
The dash Q will get rid of, get rid of that.

00:22:08.400 --> 00:22:11.440
It'll get rid of the management output of uv.

00:22:11.440 --> 00:22:12.040
Yeah.

00:22:12.040 --> 00:22:13.260
Cause I don't really care about that.

00:22:13.260 --> 00:22:13.580
Yeah.

00:22:13.580 --> 00:22:14.560
Like you don't want that.

00:22:14.560 --> 00:22:16.080
Not in this.

00:22:16.080 --> 00:22:20.100
I think if you're trying to, this is really nice because it's a super simple way to,

00:22:20.100 --> 00:22:23.940
long as somebody has uv, that's all you need to start distributing like utilities to

00:22:23.940 --> 00:22:24.120
them.

00:22:24.120 --> 00:22:26.900
But the, you don't want them necessarily to see the.

00:22:26.900 --> 00:22:27.740
Actually.

00:22:27.740 --> 00:22:34.020
So I might, I think I'll probably leave it on because, so that I can see that it, it's,

00:22:34.020 --> 00:22:39.440
um, what it's pulling from and, where it's like when it updates things or something,

00:22:39.440 --> 00:22:41.540
if it has to install something, it'll output that.

00:22:41.760 --> 00:22:44.020
But then it doesn't mess up the output.

00:22:44.020 --> 00:22:45.780
Like I said, it's, it's going to standard error.

00:22:45.780 --> 00:22:49.240
So if your pipe standard out to something else, it'll still work fine.

00:22:49.240 --> 00:22:55.820
So, anyway, cool to, to write up like how to use command line utilities now with Python.

00:22:55.820 --> 00:23:00.620
So yeah, you've got uv tool install for the packages with entry points, all sorts of nice

00:23:00.620 --> 00:23:00.880
stuff.

00:23:00.880 --> 00:23:01.520
Yeah.

00:23:01.520 --> 00:23:02.480
UV everywhere.

00:23:02.480 --> 00:23:05.520
All right.

00:23:05.520 --> 00:23:06.720
Those are our items.

00:23:06.720 --> 00:23:09.760
I've only got one extra that I want to talk about.

00:23:09.760 --> 00:23:10.220
Do you have any?

00:23:10.220 --> 00:23:10.780
Yeah, go first.

00:23:10.840 --> 00:23:11.260
I got a couple.

00:23:11.260 --> 00:23:11.860
Okay.

00:23:11.860 --> 00:23:13.600
this is pretty quick.

00:23:13.600 --> 00:23:16.940
I really appreciate, I forget what this is called.

00:23:16.940 --> 00:23:23.080
so anyway, I've got, the complete PyTorce course of, of course I've split it up.

00:23:23.080 --> 00:23:26.920
So many people can buy it in payments if they want it, but it's, it's like 59 bucks.

00:23:26.920 --> 00:23:33.480
So on a python test.com, there's also a new, the new discord community is going really

00:23:33.480 --> 00:23:33.840
great.

00:23:33.840 --> 00:23:37.900
it's a one-time admission just to help with the costs of everything.

00:23:37.900 --> 00:23:40.540
and then, a really quick hello.

00:23:40.540 --> 00:23:44.980
Anyway, I've priced these where I think they're completely reasonable for people.

00:23:44.980 --> 00:23:50.280
However, you might not live, have a software engineering job and live in Oregon, or

00:23:50.280 --> 00:23:50.960
the U S.

00:23:51.060 --> 00:23:56.820
so I was really thrilled the other day, somebody from India just got out of college,

00:23:56.820 --> 00:24:02.200
uh, doesn't have a job yet, but is, or maybe they have a starter job, but they're, they looked

00:24:02.200 --> 00:24:03.460
at this wherever they live.

00:24:03.460 --> 00:24:05.200
And they said, this is too much for me.

00:24:05.200 --> 00:24:06.100
Can I get a discount?

00:24:06.100 --> 00:24:09.360
I don't have like the regional pricing set up.

00:24:09.360 --> 00:24:11.640
So I really parity, they pricing parity.

00:24:11.640 --> 00:24:12.160
That's it.

00:24:12.160 --> 00:24:13.820
So I really appreciate that.

00:24:13.920 --> 00:24:20.380
So if you can find me on a LinkedIn or, or a blue sky or master don and just ask or,

00:24:20.380 --> 00:24:22.540
and, and I'll, I'll work with you.

00:24:22.540 --> 00:24:25.000
So just, I appreciate people reaching out.

00:24:25.000 --> 00:24:25.580
That's it.

00:24:25.580 --> 00:24:26.380
Excellent.

00:24:26.380 --> 00:24:26.680
Excellent.

00:24:27.020 --> 00:24:27.560
All right.

00:24:27.560 --> 00:24:29.140
I have a couple here.

00:24:29.140 --> 00:24:32.040
Let's, I'll go through them quick over the blue sky.

00:24:32.040 --> 00:24:38.720
We've got Hugo VK says, Hey, Python 314 alpha three is out.

00:24:38.720 --> 00:24:41.800
And it's got the links to the, what's new and so on.

00:24:41.800 --> 00:24:46.000
And reasons I don't understand pictures of very delicious looking cake, which I'm here for.

00:24:46.000 --> 00:24:48.900
But anyway, people can check that out.

00:24:48.900 --> 00:24:51.160
That was from a couple of days ago.

00:24:51.160 --> 00:24:51.820
Yeah.

00:24:51.820 --> 00:24:54.080
Maybe a week, quite a week ago, five days ago.

00:24:54.080 --> 00:24:57.660
So the testing of Python 314 continues.

00:24:57.660 --> 00:25:02.320
Remember, I believe it's, there's supposed to be seven total releases before it goes to

00:25:02.320 --> 00:25:04.940
beta and gets kind of locked down ish.

00:25:04.940 --> 00:25:05.880
So you got that.

00:25:05.880 --> 00:25:06.920
It's not cake.

00:25:06.920 --> 00:25:08.840
It's pie 3.14.

00:25:08.840 --> 00:25:10.500
Oh my gosh.

00:25:10.500 --> 00:25:11.980
How did I miss it?

00:25:11.980 --> 00:25:13.040
How did I miss it?

00:25:13.040 --> 00:25:13.720
All right.

00:25:13.720 --> 00:25:15.120
One thing that drives me crazy.

00:25:15.120 --> 00:25:21.000
If you're a Mac person is there's almost always a command you can hit for settings.

00:25:21.000 --> 00:25:23.560
That is the same command comma, any app you want.

00:25:23.560 --> 00:25:27.320
The settings for command comma, unless it's just disrespect in its own self.

00:25:27.320 --> 00:25:28.340
It has no self-respect.

00:25:28.340 --> 00:25:30.680
Command comma will bring up whatever settings it has.

00:25:30.680 --> 00:25:33.000
Web browser, word editor, whatever.

00:25:33.000 --> 00:25:35.800
That's, but check for update is all over the map.

00:25:35.800 --> 00:25:37.760
Some apps automatically check for updates.

00:25:37.760 --> 00:25:39.080
Some only tell you there's an update.

00:25:39.080 --> 00:25:42.320
If you check for it, Firefox and Zen browser only do it.

00:25:42.400 --> 00:25:46.000
If you pull the about screen and show it, then it'll tell you.

00:25:46.000 --> 00:25:49.460
But on Vivaldi, if you pull the about screen, it won't tell you if there's an update.

00:25:49.460 --> 00:25:50.940
Like it's all, all annoying.

00:25:50.940 --> 00:25:55.220
So I went through and I added a check for update hotkey.

00:25:55.220 --> 00:25:56.640
So this is a kind of a cool trick.

00:25:56.640 --> 00:25:58.100
I thought people would appreciate it.

00:25:58.100 --> 00:26:03.040
If you go to macOS, you go to settings, you go to keyboard, you go to keyboard shortcuts,

00:26:03.040 --> 00:26:08.760
then you go to app shortcuts and pick out individual apps and say, I want this menu, whatever the

00:26:08.760 --> 00:26:13.060
menu text is, along with case sensitive spaces, everything is super annoying.

00:26:13.060 --> 00:26:13.880
You can't edit it.

00:26:13.880 --> 00:26:14.760
So get it right.

00:26:14.760 --> 00:26:15.600
Is it a capital four?

00:26:15.600 --> 00:26:17.300
Check for updates or a lowercase four?

00:26:17.300 --> 00:26:18.080
Check for updates.

00:26:18.080 --> 00:26:19.060
You got to get that right.

00:26:19.060 --> 00:26:22.200
But then you can just say control you and then you can go or whatever you want to pick.

00:26:22.200 --> 00:26:26.040
And then if you just like in any app, if you set up the ones you cared about checking,

00:26:26.040 --> 00:26:27.960
you just hit check for updates and it pulls it up.

00:26:27.960 --> 00:26:28.580
It's kind of nice.

00:26:28.580 --> 00:26:33.500
I'm just still blown away that I never knew that command comma was the settings thing.

00:26:33.500 --> 00:26:37.740
It's almost every Apple command comma will do what you're looking for.

00:26:37.740 --> 00:26:38.180
Okay.

00:26:38.180 --> 00:26:38.960
Yeah.

00:26:38.960 --> 00:26:39.400
Yeah.

00:26:39.400 --> 00:26:40.760
But there's no update equivalent.

00:26:40.760 --> 00:26:42.660
So control you now is from my computer.

00:26:42.660 --> 00:26:43.180
Okay.

00:26:43.180 --> 00:26:47.020
So I got Firefox, OBS, VS Code, Zen Browser, SourceTree.

00:26:47.020 --> 00:26:50.240
SourceTree is one of those that it'll go months without telling you there's an update.

00:26:50.240 --> 00:26:52.100
But if you check, there's almost always an update.

00:26:52.760 --> 00:26:53.000
All right.

00:26:53.000 --> 00:26:53.800
On to the next thing.

00:26:53.800 --> 00:26:54.600
What do we got next?

00:26:54.600 --> 00:27:00.080
Oh, I just wanted to talk about something really kind of fun and interesting on Talk Python.

00:27:00.080 --> 00:27:01.780
I got two things on Talk Python real quick here.

00:27:01.780 --> 00:27:08.140
But this is a fun web, more, not so much a Talk Python thing, just like a fun web design,

00:27:08.140 --> 00:27:09.240
thinking about URLs.

00:27:09.240 --> 00:27:10.120
So check this out, Ron.

00:27:10.120 --> 00:27:12.620
We can go to any episode here.

00:27:12.620 --> 00:27:15.600
So Peter Wang, it was on and Peter Wang is super fun.

00:27:15.600 --> 00:27:20.720
If you look at that episode page, you can see there's a thumbnail, like a social media image

00:27:20.720 --> 00:27:23.780
of that, which is also the YouTube thumbnail, right?

00:27:23.780 --> 00:27:24.200
Yeah.

00:27:24.520 --> 00:27:28.560
And let me see if I can make this wider so you can see it's going to be small.

00:27:28.560 --> 00:27:34.220
But up here, if I just type .jpg on the end of the URL, I get the thumbnail.

00:27:34.220 --> 00:27:39.740
And if I just type VTT, which is Web VTT transcripts, I get the transcripts.

00:27:39.740 --> 00:27:40.140
Oh, cool.

00:27:40.260 --> 00:27:41.380
Isn't that fun?

00:27:41.380 --> 00:27:41.840
Yeah.

00:27:41.840 --> 00:27:45.160
I want to encourage people to think more about, like, instead of having a bunch of different

00:27:45.160 --> 00:27:48.500
ways to get things, just, you know, think about, like, resource.

00:27:48.500 --> 00:27:49.700
I don't know what you call it.

00:27:49.700 --> 00:27:51.080
It's a little bit REST-ish.

00:27:51.080 --> 00:27:52.460
But I think it's neat.

00:27:52.460 --> 00:27:56.460
Like, maybe if I had a JSON representation, I could just put .json on the end and it would

00:27:56.460 --> 00:27:58.720
represent the data of the podcast as JSON.

00:27:58.720 --> 00:28:00.020
I don't really know what I would put there.

00:28:00.120 --> 00:28:04.460
But anyway, I thought, I just want to encourage people, you can play that at Talk Python, but

00:28:04.460 --> 00:28:10.360
encourage people to just think about making cool little URL API interactivity bits that

00:28:10.360 --> 00:28:10.560
way.

00:28:10.560 --> 00:28:10.960
Neat.

00:28:10.960 --> 00:28:11.600
I like it.

00:28:11.600 --> 00:28:11.900
Yeah.

00:28:11.900 --> 00:28:12.140
Thanks.

00:28:12.140 --> 00:28:12.440
All right.

00:28:12.440 --> 00:28:15.260
Next, I did a mega write-up.

00:28:15.260 --> 00:28:20.620
You can see that on the Talk Python blog, talkpython.fm/blog, 16 minutes reading time,

00:28:20.620 --> 00:28:21.600
it suggests, for this.

00:28:21.600 --> 00:28:27.020
I wrote up an in-depth analysis of the top Talk Python episodes, top five.

00:28:27.020 --> 00:28:31.640
And I even did a little Jupyter notebook action to come up with where are they on the scale

00:28:31.640 --> 00:28:33.860
and how does that compare against the average number of downloads?

00:28:33.860 --> 00:28:39.520
Number one is awesome text tricks with NLP and spaCy with Vincent Warmerdam.

00:28:39.520 --> 00:28:41.700
Number two, this one really surprised me.

00:28:41.700 --> 00:28:42.560
It was so popular.

00:28:42.560 --> 00:28:46.760
Being a developer with ADHD with Chris Branding.

00:28:46.760 --> 00:28:47.940
Awesome episode.

00:28:47.940 --> 00:28:49.360
I didn't expect to be popular.

00:28:49.360 --> 00:28:52.000
Version APIs with Stanislav.

00:28:52.000 --> 00:28:54.100
Handis and beyond with Wes McKinney.

00:28:54.100 --> 00:28:54.920
That's not surprising.

00:28:55.920 --> 00:28:57.940
And the State of Flask and Palance with David Lord.

00:28:57.940 --> 00:28:58.940
So those are the top five.

00:28:58.940 --> 00:29:03.760
But just super detailed dive into what was covered, what was important and stuff.

00:29:03.760 --> 00:29:05.300
So I did that Sunday?

00:29:05.300 --> 00:29:06.220
Yeah, Sunday morning.

00:29:06.220 --> 00:29:07.240
The house was quiet.

00:29:07.240 --> 00:29:07.960
People were chilling.

00:29:07.960 --> 00:29:09.240
So I'm going to write.

00:29:09.240 --> 00:29:13.380
Well, I mean, it's a 16-minute read with everybody with ADHD.

00:29:13.380 --> 00:29:15.200
I don't think anybody's going to read the whole thing.

00:29:15.200 --> 00:29:20.140
Yeah, maybe the people who were served by that podcast were not.

00:29:20.140 --> 00:29:20.360
No.

00:29:20.960 --> 00:29:24.180
You could always listen to the episodes, but it highlights what was covered.

00:29:24.180 --> 00:29:25.300
No, I think that's cool.

00:29:25.300 --> 00:29:26.240
Yeah.

00:29:26.240 --> 00:29:26.700
Neat.

00:29:26.700 --> 00:29:26.920
Yeah.

00:29:26.920 --> 00:29:27.280
Thanks.

00:29:27.280 --> 00:29:27.800
Okay.

00:29:27.800 --> 00:29:28.440
Now we're down.

00:29:28.440 --> 00:29:29.400
Oh, wait.

00:29:29.400 --> 00:29:29.620
No.

00:29:29.620 --> 00:29:30.400
One more thing.

00:29:30.400 --> 00:29:31.160
Since we talked about...

00:29:31.160 --> 00:29:32.600
I wasn't originally going to point this out.

00:29:32.600 --> 00:29:36.040
But since we talked about typing so much, and you talked about teaching and typing, I have

00:29:36.040 --> 00:29:40.300
a four and a half hour course called Rock Solid Python and Type Hints and Tools.

00:29:40.300 --> 00:29:40.940
Oh, cool.

00:29:40.940 --> 00:29:44.220
So over at Talk Python, I'll put that link in the show notes and people can check that

00:29:44.220 --> 00:29:44.300
out.

00:29:44.300 --> 00:29:48.120
This is one of my absolute favorite courses of all of our 50 or so courses.

00:29:48.120 --> 00:29:49.640
And it's a good one.

00:29:49.640 --> 00:29:51.700
This type of stuff is really neat.

00:29:51.700 --> 00:29:52.100
Neat.

00:29:52.100 --> 00:29:52.640
Okay.

00:29:52.640 --> 00:29:53.700
Are you ready for the joke?

00:29:53.700 --> 00:29:54.500
I am.

00:29:54.500 --> 00:30:00.940
This one, if you've heard of lolcode, some of these joke languages, this is one of them,

00:30:00.940 --> 00:30:04.460
but it's a little bit more Python oriented, I guess I'll say.

00:30:04.460 --> 00:30:06.820
Let me see if I can zoom in for making it a little legible.

00:30:06.820 --> 00:30:09.880
So we come down here and there's a table chart.

00:30:10.160 --> 00:30:12.180
So it's like an alternative language.

00:30:12.180 --> 00:30:17.460
So if you want to write Python like code, but you don't like it.

00:30:17.460 --> 00:30:19.000
So you've got like return.

00:30:19.000 --> 00:30:21.180
Instead of writing return, you can say it's given.

00:30:21.180 --> 00:30:26.040
And if you want to say plus one, it says riz.

00:30:26.040 --> 00:30:29.320
So this is called Python with riz or no, that's not exactly.

00:30:29.320 --> 00:30:30.700
That's its description.

00:30:30.700 --> 00:30:31.580
Pygat.

00:30:31.580 --> 00:30:33.980
And I'm not in this world very much.

00:30:33.980 --> 00:30:39.520
It kind of goes off a lot of like Twitch stream type of terminology.

00:30:39.520 --> 00:30:41.200
So you've got print.

00:30:41.200 --> 00:30:42.860
And instead of print, you yap.

00:30:42.860 --> 00:30:44.100
For true, you get Aurora.

00:30:44.100 --> 00:30:45.420
For false, it's cooked.

00:30:45.420 --> 00:30:47.360
You bop instead of def.

00:30:47.360 --> 00:30:49.660
And then for while loops, it's let him cook.

00:30:49.660 --> 00:30:50.640
Just let him cook.

00:30:52.400 --> 00:30:55.260
So for example, a wild shoe would be let him cook, Aurora.

00:30:55.260 --> 00:30:57.520
Import is glaze.

00:30:57.520 --> 00:30:59.320
Let's see.

00:30:59.320 --> 00:31:02.140
If, L, if, else is chat.

00:31:02.140 --> 00:31:02.720
Is this real?

00:31:02.720 --> 00:31:03.780
Yo, chat.

00:31:03.780 --> 00:31:04.880
Only in Ohio.

00:31:04.880 --> 00:31:05.260
Okay.

00:31:05.740 --> 00:31:06.500
That's funny.

00:31:06.500 --> 00:31:08.360
Oh, glass is skibbity.

00:31:08.360 --> 00:31:10.340
I actually get that reference.

00:31:10.340 --> 00:31:14.200
Break is just put the fries in the bag, bro.

00:31:14.200 --> 00:31:20.400
Raise is crash out.

00:31:20.400 --> 00:31:20.920
Okay.

00:31:20.920 --> 00:31:21.620
And then assert.

00:31:21.620 --> 00:31:22.460
I love assert.

00:31:22.460 --> 00:31:23.540
Assert is sus.

00:31:23.540 --> 00:31:24.240
Yeah.

00:31:24.240 --> 00:31:25.340
It's pretty sus.

00:31:25.340 --> 00:31:26.480
Oh.

00:31:26.480 --> 00:31:30.000
Sus, I think we should add to the language, maybe.

00:31:30.000 --> 00:31:31.320
Yeah, sus is pretty good.

00:31:31.320 --> 00:31:31.740
Yeah.

00:31:32.080 --> 00:31:32.520
Okay.

00:31:32.520 --> 00:31:33.280
Let's see.

00:31:33.280 --> 00:31:33.540
All right.

00:31:33.540 --> 00:31:35.040
So now let's look at an example.

00:31:35.040 --> 00:31:35.400
Okay.

00:31:35.400 --> 00:31:36.860
So we've got here.

00:31:36.860 --> 00:31:38.420
We've got here on the left.

00:31:38.420 --> 00:31:40.160
We've got glaze numpy.

00:31:40.160 --> 00:31:41.340
Ah, N, P.

00:31:41.340 --> 00:31:43.540
Lock in random glaze choice.

00:31:43.540 --> 00:31:45.960
And then skibbity, D, Rizzly.

00:31:45.960 --> 00:31:47.740
And plus pass, I guess.

00:31:47.740 --> 00:31:48.080
Anyway.

00:31:48.080 --> 00:31:49.660
Duke Dennis equals zero.

00:31:49.660 --> 00:31:50.860
Says let him cook, Aurora.

00:31:50.860 --> 00:31:51.780
Just let him cook.

00:31:51.780 --> 00:31:52.380
And chat.

00:31:52.380 --> 00:31:53.340
Is this real cooked?

00:31:53.340 --> 00:31:56.200
Crash out error.

00:31:56.200 --> 00:31:57.600
Only in Ohio.

00:31:57.600 --> 00:31:59.020
Just put it in the fries, bro.

00:31:59.020 --> 00:32:00.540
Just put the fries in the bag, bro.

00:32:01.820 --> 00:32:03.180
Ah, this is good.

00:32:03.180 --> 00:32:04.660
I think it really runs.

00:32:04.660 --> 00:32:05.400
I'm pretty sure.

00:32:05.400 --> 00:32:12.780
Well, I think that we should have like a conversion that you can take some code and convert it to this.

00:32:12.780 --> 00:32:13.700
Yeah, yeah.

00:32:13.700 --> 00:32:15.020
Like a transpiler sort of thing.

00:32:15.020 --> 00:32:15.400
Yeah, yeah.

00:32:15.400 --> 00:32:16.180
Just an upgrader.

00:32:16.180 --> 00:32:19.300
Like a two to three, but a pie to gap.

00:32:19.300 --> 00:32:19.740
Yeah.

00:32:19.740 --> 00:32:20.880
Skibbity Rizzler.

00:32:20.880 --> 00:32:21.480
Pluh.

00:32:21.480 --> 00:32:25.560
Just put the fries in the bag, bro.

00:32:25.560 --> 00:32:28.280
That might be my favorite.

00:32:28.280 --> 00:32:30.720
Or let him cook.

00:32:30.720 --> 00:32:31.560
Just let him cook.

00:32:31.560 --> 00:32:33.580
Chat, is this real?

00:32:33.580 --> 00:32:35.280
This is good.

00:32:35.280 --> 00:32:35.920
Crash out.

00:32:35.920 --> 00:32:36.560
Crash out.

00:32:36.560 --> 00:32:37.080
All right.

00:32:37.080 --> 00:32:38.740
Well, you ready to crash out on this episode?

00:32:38.740 --> 00:32:39.580
I am.

00:32:39.580 --> 00:32:40.880
Just put them in the fries, bro.

00:32:40.880 --> 00:32:42.220
Put the fries in the bag, bro.

00:32:42.220 --> 00:32:43.720
Indeed.

00:32:43.720 --> 00:32:44.780
Well, awesome.

00:32:44.780 --> 00:32:45.320
All right.

00:32:45.320 --> 00:32:48.920
Well, thanks everybody for a wonderful 2024.

00:32:48.920 --> 00:32:54.340
And we're going to, like I said, we'll have a short thank you episode next week, possibly.

00:32:54.340 --> 00:32:55.520
Possibly.

00:32:55.520 --> 00:32:58.120
And then, but we'll see everybody in 2025.

