WEBVTT

00:00:00.001 --> 00:00:58.460
As Python developers, we're incredibly lucky to have over half a million packages that we can choose to build our applications from over at PyPI. However, when it comes to choosing a UI framework, the options get narrowed down very quickly. Intersect those choices with the ones that work on mobile, and you have a very short list. Flutter is a UI framework for building desktop and mobile applications, and is in fact the one that we use to build the Talk Python courses app, which you'll find at talkpython.fm/apps. That's why I'm so excited about Flet. Flet is a Python UI framework that is distributed and executed on the Flutter framework, making it possible to build mobile apps and desktop apps with Python. We have Fedor Fitzner back on the show after he launched his project a couple of years ago to give us an update on how close they are to a full featured mobile app framework in Python. This is Talk Python To Me, Episode 491 recorded December 17th, 2024.

00:00:59.420 --> 00:01:01.120
- Are you ready for your host, please?

00:01:01.840 --> 00:01:04.660
- You're listening to Michael Kennedy on Talk Python To Me.

00:01:05.160 --> 00:01:08.300
Live from Portland, Oregon, and this segment was made with Python.

00:01:11.540 --> 00:01:14.440
- Welcome to Talk Python To Me, a weekly podcast on Python.

00:01:14.840 --> 00:01:16.640
This is your host, Michael Kennedy.

00:01:16.980 --> 00:01:24.980
Follow me on Mastodon, where I'm @mkennedy, and follow the podcast using @talkpython, both accounts over at fosstodon.org.

00:01:25.420 --> 00:01:29.900
And keep up with the show and listen to over nine years of episodes at talkpython.fm.

00:01:30.400 --> 00:01:34.380
If you want to be part of our live episodes, you can find the live streams over on YouTube.

00:01:34.780 --> 00:01:40.740
Subscribe to our YouTube channel over at talkpython.fm/youtube and get notified about upcoming shows.

00:01:40.980 --> 00:01:44.820
This episode is sponsored by Posit Connect from the makers of Shiny.

00:01:45.440 --> 00:01:49.340
Publish, share, and deploy all of your data projects that you're creating using Python.

00:01:49.740 --> 00:01:56.080
Streamlit, Dash, Shiny, Bokeh, FastAPI, Flask, Quarto, Reports, Dashboards, and APIs.

00:01:56.800 --> 00:01:58.400
Posit Connect supports all of them.

00:01:58.680 --> 00:02:02.820
Try Posit Connect for free by going to talkpython.fm/posit.

00:02:03.160 --> 00:02:04.040
P-O-S-I-T.

00:02:05.020 --> 00:02:08.560
And it's also brought to you by us over at Talk Python Training.

00:02:09.020 --> 00:02:13.180
Did you know that we have over 250 hours of Python courses?

00:02:13.860 --> 00:02:14.360
Yeah, that's right.

00:02:14.500 --> 00:02:16.299
Check them out at talkpython.fm/courses.

00:02:16.300 --> 00:02:17.020
Flash courses.

00:02:17.620 --> 00:02:19.740
Peter, welcome back to Talk Python To Me.

00:02:20.000 --> 00:02:20.560
Awesome to have you here.

00:02:20.820 --> 00:02:23.340
>> I'm Michael, fellow Python developers.

00:02:23.820 --> 00:02:25.080
>> Yeah, it's real good to have you here.

00:02:25.300 --> 00:02:28.060
I know that there was a lot of excitement about Flutter.

00:02:28.360 --> 00:02:42.660
In fact, I got a message just a couple of weeks ago from somebody saying, "Is Flutter what you use to write your mobile apps?" And I'm like, "No, because that was a while ago." And I kind of wish that was an option, but it wasn't an option for us at the time.

00:02:42.920 --> 00:02:46.180
Anyway, I think Flutter is going strong.

00:02:46.260 --> 00:02:48.400
I think there's a lot of excitement around it.

00:02:48.740 --> 00:02:52.880
And certainly there's an excitement for building mobile applications in Python.

00:02:53.280 --> 00:02:53.360
Yeah.

00:02:53.540 --> 00:02:55.620
Flutter is getting stronger and stronger.

00:02:55.720 --> 00:03:06.600
You know, like recently I saw there was an attempt to fork Flutter, you know, because like it was a feeling in the community that it's not moving anywhere.

00:03:06.740 --> 00:03:14.800
You know, but I don't believe that even that guy mentioned that there are like 50 developers working on Flutter right now at Google.

00:03:15.000 --> 00:03:21.140
So yeah, Flutter is getting better and better and their release cycle is pretty awesome, you know?

00:03:21.400 --> 00:03:24.700
Sometimes it's really hard to catch up, but still, yeah.

00:03:24.820 --> 00:03:25.880
- That can actually be a problem.

00:03:25.980 --> 00:03:29.080
I just updated Flutter on my Mac mini.

00:03:29.880 --> 00:03:35.680
I had out of date CocoaPods and Ruby and there's a whole tool chain that people need to know about.

00:03:35.720 --> 00:03:41.880
Maybe we can talk a little bit about the tool chain, but yeah, you're constantly chasing versions and releases and updates.

00:03:42.320 --> 00:03:43.960
You've got Android Studio versions.

00:03:44.240 --> 00:03:45.800
You've got Xcode.

00:03:46.240 --> 00:03:46.740
There's a lot there.

00:03:46.900 --> 00:03:52.460
We recently started using Flutter version manager FBM and it's pretty good.

00:03:52.800 --> 00:03:57.500
Yeah, because the updating is so fast, you know, it's really hard to catch up.

00:03:58.920 --> 00:04:01.760
This portion of Talk Python To Me is brought to you by the folks at Posit.

00:04:02.380 --> 00:04:05.360
Posit has made a huge investment in the Python community lately.

00:04:05.980 --> 00:04:11.440
Known originally for RStudio, they've been building out a suite of tools and services for team Python.

00:04:12.680 --> 00:04:17.040
Today, I want to focus on hosting your Python-based data science workloads.

00:04:17.519 --> 00:04:23.780
This includes dashboards, reports, plots, interactive web apps, all the way to custom Flask and Django apps.

00:04:24.400 --> 00:04:25.600
Their service is Posit Connect.

00:04:26.440 --> 00:04:31.080
Posit Connect makes it easy for data scientists to share work built with Python code.

00:04:31.899 --> 00:04:44.600
If you have a Streamlit app, Dash, dashboard, Plotly, interactive plot, a FastAPI service, or even a Quarto report, just give Posit Connect the code it needs to maintain the asset and Connect automatically does the rest.

00:04:45.100 --> 00:04:48.640
Connect will manage your APIs and serve your interactive apps for you.

00:04:49.140 --> 00:04:53.220
And if you want, you can update your reports and dashboards on a scheduled basis.

00:04:53.640 --> 00:04:59.360
That's right, no need to explain to the stakeholders why that dashboard or plot stopped updating last week.

00:04:59.880 --> 00:05:06.740
You get to focus on your data science and leveraging your skillset while Connect makes you look good, keeping your code running and private.

00:05:07.480 --> 00:05:14.040
With Connect, you get a private URL on your Connect server, ensuring that your asset is continuously available to your shareholders.

00:05:14.620 --> 00:05:18.260
And you can control which users have access to the asset.

00:05:18.720 --> 00:05:22.600
Let Posit Connect handle the delivery and DevOps involved in sharing your work.

00:05:22.960 --> 00:05:24.400
You focus on what you do best.

00:05:25.140 --> 00:05:30.600
So if you work on a data science team, you owe it to you and your org to check out Posit Connect.

00:05:31.060 --> 00:05:37.000
Visit talkpython.fm/connect today and get a three-month free trial to see if it's a good fit.

00:05:37.600 --> 00:05:39.700
That's talkpython.fm/connect.

00:05:40.060 --> 00:05:41.760
The link is in your podcast player show notes.

00:05:42.360 --> 00:05:44.720
Thank you to Posit for supporting Talk Python To Me.

00:05:46.100 --> 00:05:47.240
Maybe a quick introduction.

00:05:47.780 --> 00:06:05.940
It has been, you know, we, I guess it's worth giving a shout out back in summer 2022, you were on the show when Flutter first came out to tell everyone about, sorry, when Flutter first came out to tell everyone about Flut and how it's basically Flutter plus Python for UI, but it's been a while.

00:06:06.100 --> 00:06:11.180
So, you know, tell people quickly who you are and we can get into the project.

00:06:11.460 --> 00:06:13.260
My name is Peter Fitzner.

00:06:13.660 --> 00:07:02.520
I'm the founder and developer of a flat framework, like Flutter for Python, for Flutter, yeah, it's been two and a half years since we released the first version. It's not like the first release of web and since that time we gained really great traction. To my mind like we got 12,000 stars on GitHub, 72 contributors, 5k members on discord channel and I found the statistics for PyPy. It's like almost 3 million downloads from PyPy of web package. So It's a great community, great people, a lot of feedback, a lot of issues.

00:07:03.120 --> 00:07:03.920
So it's pretty nice.

00:07:04.120 --> 00:07:04.580
That's awesome.

00:07:04.700 --> 00:07:06.980
And it definitely seems like it's going strong.

00:07:07.120 --> 00:07:15.480
I do think maybe it's worth actually talking a bit about what Flutter is before we dive into Python for Flutter with Flut, right?

00:07:15.580 --> 00:07:18.640
Give people a quick sense of what is this Flutter thing that we're talking about?

00:07:18.780 --> 00:07:22.260
Flutter is a cross-platform framework.

00:07:22.880 --> 00:07:27.600
It works for web, iOS, Android, and all desktop platforms.

00:07:28.220 --> 00:07:34.320
It allows you to write nice apps, really nice apps with great UI in Dart language.

00:07:34.920 --> 00:07:37.120
So you have to learn a new language.

00:07:37.480 --> 00:07:40.220
And Flutter is a framework.

00:07:40.520 --> 00:07:43.620
So it's like, it's not just UI, it's application framework.

00:07:44.060 --> 00:07:49.760
It has all the things to build the app.

00:07:49.920 --> 00:08:10.380
There's the language, which is Dart, not Flutter, but then Flutter has all the UI widgets and the mechanisms, but it also is a whole series of build tools that will take that and create things that you can upload to the mobile app stores like app, Apple's app store or Google play or other places, right?

00:08:10.460 --> 00:08:11.280
Like desktop apps.

00:08:11.740 --> 00:08:15.160
So there's a bunch of layers to what Flutter really is.

00:08:15.220 --> 00:08:21.620
I think Also, the interesting part about Flutter is that it has a painted UI.

00:08:22.120 --> 00:08:27.640
So it started from the Skia engine and now they have their own engine in Palo Alto.

00:08:28.140 --> 00:08:31.920
So the UI is basically painted on the canvas.

00:08:32.640 --> 00:08:36.219
So it looks similar everywhere on every device.

00:08:36.599 --> 00:08:41.900
Like some frameworks, like for example React Native, they use native controls.

00:08:44.300 --> 00:08:47.740
But Flutter, it looks similar on every device.

00:08:48.900 --> 00:08:51.820
It's cool that it runs everywhere, but sometimes that can fall short.

00:08:52.120 --> 00:08:55.220
The biggest example of this for me is Java applications.

00:08:55.540 --> 00:09:01.420
When they have their own file browsing dialogue, you're like, Oh, this is clearly not a native sort of thing going on here.

00:09:01.620 --> 00:09:05.420
You know, on a, on a desktop situation, they don't look like windows dialogues.

00:09:05.620 --> 00:09:07.100
They don't look like macOS dialogues.

00:09:07.200 --> 00:09:08.380
They just look like Java dialogues.

00:09:08.720 --> 00:09:11.780
But so that can be a problem or limitation.

00:09:12.240 --> 00:09:16.560
But Flutter tries to look like the native controls.

00:09:17.020 --> 00:09:18.500
There's the, what do they call them?

00:09:18.540 --> 00:09:25.720
The Cupertino widgets and the material design widgets that, so it tries to adapt to the platforms it's on.

00:09:25.980 --> 00:09:27.620
That's why it's called Adaptive.

00:09:27.760 --> 00:09:27.940
Yeah.

00:09:28.280 --> 00:09:33.560
It's like this material design is built in, there is Cupertino controls.

00:09:33.680 --> 00:09:39.860
It also, I thought there are, think body packages for micro-OS and Windows like Fluent Design.

00:09:40.480 --> 00:09:47.620
By the way about dialogue, you know, if like this it's called file picker and it looks different for all platforms.

00:09:48.000 --> 00:09:51.200
So it's not always drawn like the UI.

00:09:51.620 --> 00:09:56.880
You can write like a native package, like using the underlying operating system API.

00:09:57.100 --> 00:10:02.360
So the dialogue looks pretty standard on macOS or windows.

00:10:02.880 --> 00:10:04.860
So yeah, it's not always so bad.

00:10:05.020 --> 00:10:12.560
It is for building apps all over the place, Flutter, but I would say it's real seems to be in the mobile app space, right?

00:10:12.820 --> 00:10:13.380
What do you think?

00:10:13.680 --> 00:10:15.720
Primarily iOS and Android?

00:10:15.920 --> 00:10:20.280
- Some recently asked me about like, why not React Native?

00:10:20.800 --> 00:10:27.180
So why you chose, and I went to Google, like, you know, like typing like Flutter, yes, React Native.

00:10:27.540 --> 00:10:33.180
And the interesting, it became more popular this year, 2024.

00:10:33.780 --> 00:10:39.540
So it's a little bit ahead of React Native, Flutter, in this year.

00:10:39.540 --> 00:10:46.680
So, yeah, so it's, it's according to stick with floor questionnaire, something like that.

00:10:46.800 --> 00:10:48.640
So it's gaining popularity.

00:10:48.900 --> 00:11:00.600
And I would say that yes, Flutter is more a mobile fast framework, despite they have awesome support for desktop platforms or web, it's still mobile first.

00:11:00.820 --> 00:11:09.700
And when we talked about Flutter, we should probably talk first about mobile devices and these benefits it brings to mobile development.

00:11:10.060 --> 00:11:10.380
That's right.

00:11:10.660 --> 00:11:11.140
It's a pretty interesting.

00:11:11.240 --> 00:11:12.960
I just looked on Stack Overflow trends.

00:11:13.520 --> 00:11:14.580
Let's see if I can find it.

00:11:15.540 --> 00:11:16.500
Yeah, look at that.

00:11:17.040 --> 00:11:20.300
The flutter is quite a bit higher than React Native.

00:11:20.640 --> 00:11:21.520
More than I expected.

00:11:22.220 --> 00:11:26.260
I'll put a link to that in the show notes for the Stack Overflow trends graph.

00:11:26.340 --> 00:11:27.740
What are the reasons behind that?

00:11:28.420 --> 00:11:39.540
Maybe it's ecosystem, maybe because it's pretty easy to find an extension to find some nice package on pub.dev.

00:11:40.220 --> 00:11:47.500
Maybe it's because it looks nice on both iOS and Android, and it looks similar, maybe.

00:11:48.020 --> 00:12:01.240
Maybe because Dart itself, I know people tend to criticize Dart, but I have some experience writing in JavaScript, TypeScript, and I can say that it was really nice learning Dart.

00:12:02.180 --> 00:12:04.100
It's a great language.

00:12:04.240 --> 00:12:10.680
And honestly, I know it's unpopular, but I feel it's kind of like better than JavaScript.

00:12:11.340 --> 00:12:12.660
It's just my opinion.

00:12:13.260 --> 00:12:16.120
So once you learn it, you can do everything.

00:12:16.300 --> 00:12:17.060
It's pretty nice.

00:12:17.340 --> 00:12:18.420
Maybe because of that.

00:12:18.540 --> 00:12:18.760
- Perhaps.

00:12:19.160 --> 00:12:24.460
And before we move off Flutter, just real quick, I wanna give a quick shout out to Lauren, the developer I worked with.

00:12:24.700 --> 00:12:32.740
He and I built the Talk Python courses apps in Flutter, which is why I have more than just like reading the docs experience in it.

00:12:32.760 --> 00:12:35.420
And those apps are going strong today.

00:12:35.520 --> 00:12:36.040
They're really great.

00:12:36.340 --> 00:12:46.060
Although I'm about to release a new version because you never stop releasing new versions, even if you think you're done and something changes behind the scenes with iOS or Android this time it's Android.

00:12:46.620 --> 00:12:46.800
Yeah.

00:12:46.920 --> 00:12:49.820
They go that all the time, that package that used to do this thing.

00:12:49.880 --> 00:12:50.660
It doesn't do it anymore.

00:12:50.760 --> 00:12:51.320
Like, Oh no.

00:12:51.520 --> 00:12:51.800
Okay.

00:12:52.160 --> 00:12:52.460
Okay.

00:12:52.560 --> 00:12:54.440
So that's the foundation that's Flutter.

00:12:55.000 --> 00:12:55.400
Flet.

00:12:55.480 --> 00:12:56.320
Tell us about Flet.

00:12:56.580 --> 00:13:00.100
I mean, you talked about the downloads, but like, where does it fit in this Flutter ecosystem?

00:13:00.360 --> 00:13:02.640
Flet is a native framework.

00:13:03.060 --> 00:13:08.400
As you can think, it's not just translated from Python to Dart.

00:13:08.680 --> 00:13:22.840
It's not just bindings for Flutter widgets, like PyQt, PySite, for example, but it's a standalone framework that uses Flutter for each UI.

00:13:23.320 --> 00:13:25.200
So Flet is an application framework.

00:13:25.520 --> 00:13:29.900
It's not just UI, and it uses Flutter to build each UI.

00:13:30.040 --> 00:13:43.620
I see. So people should think of it more as an independent UI and application framework for Python, not so much as a extension of Flutter into the Python world. Is that maybe the way to think of it?

00:13:43.820 --> 00:14:12.240
Right. We're still trying to go away from this label, you know, it's kind of, but it works really nice, like, right. Flutter, Epson, Python, it works pretty good, like in terms of a CEO, for example, but, but it's not true. Like It's a framework that uses, we could, I mean, potentially we could replace it with something else like this backend, you know, with like Compose or, you know, React Native, but no, it's Flutter.

00:14:12.620 --> 00:14:14.580
And it's really great.

00:14:15.260 --> 00:14:29.500
We, we, we have our own controls and it's not always one-to-one maybe, maybe, but it's like maybe of Flutter controls, they are built out of like multiple Flutter widgets.

00:14:29.780 --> 00:14:33.540
So we combine multiple Flutter widgets into controls.

00:14:34.260 --> 00:14:42.240
Because sometimes if you have some Flutter experience, sometimes you can notice that it's getting really...

00:14:42.240 --> 00:14:52.640
the UI getting really complex or, like, you know, later, like a lot of controls, like, wrapped into other widgets.

00:14:54.800 --> 00:15:03.160
Like, for example, if you want to center something, There is a center widget if you want to limit the size, the resize box.

00:15:03.680 --> 00:15:10.180
So Flag combines many widgets into more like controls and those are properties.

00:15:10.860 --> 00:15:18.240
So it's like it's cluttered in serve to Python developers in Pythonic way, I would say.

00:15:18.420 --> 00:15:21.920
On your, if people want to browse these controls, widgets, what do you want to call them?

00:15:22.220 --> 00:15:36.300
There's a whole controls section in your docs and I'll link to the docs, but the left it says controls and you go there, there's layout controls, navigation controls, you know, app bar type things that you might expect from standard mobile apps.

00:15:36.620 --> 00:15:43.300
And of course, like I sort of pointed out, you got the Cupertino versions and you've got the non Cupertino material design versions.

00:15:43.520 --> 00:15:49.740
So people can have a look at that and just get a sense for all the controls, but there are many, how many controls do you know off the top of your head?

00:15:49.940 --> 00:15:52.220
Oh, it's like a hundred plus I would say.

00:15:52.480 --> 00:15:53.600
And some really nice ones, right?

00:15:53.600 --> 00:15:58.580
Like you've got a web view, you've got maps, animations, charts.

00:15:59.100 --> 00:15:59.240
Yeah.

00:15:59.340 --> 00:16:03.960
Web view is, is not available for like all platforms at the moment.

00:16:04.360 --> 00:16:07.880
It's mostly for mobile and for my class, if I'm not mistaken.

00:16:08.360 --> 00:16:17.960
So yeah, it's kind of like there is a flat rule limitation right now that, for windows that doesn't allow to have a proper web view on windows platform.

00:16:18.700 --> 00:16:19.240
Oh yes.

00:16:19.300 --> 00:16:19.780
I remember that.

00:16:19.840 --> 00:16:20.360
That's yeah.

00:16:21.140 --> 00:16:21.920
What a hassle.

00:16:22.920 --> 00:16:25.880
There is work going on.

00:16:26.120 --> 00:16:32.720
You know, you were on the show before to talk about Flet and those were pretty early days then, right?

00:16:32.900 --> 00:16:34.400
To over two years ago.

00:16:34.800 --> 00:16:35.100
A lot.

00:16:35.280 --> 00:16:36.700
You've been, you're going strong.

00:16:36.880 --> 00:16:40.820
Like you said, you talked about the downloads and the contributors and stars and all that.

00:16:40.880 --> 00:16:41.380
That's awesome.

00:16:41.740 --> 00:16:43.780
So you, what have you all been up to?

00:16:44.100 --> 00:16:45.220
Where's this effort gone?

00:16:45.520 --> 00:16:46.760
Like what, what progress have you made?

00:16:46.960 --> 00:16:49.700
We started from a simple design.

00:16:49.720 --> 00:17:23.120
it was pre-built executable for every platform, mostly like for desktop platform, which is able to display all controls we have. And that executable was an ease part of a wheel, flat wheel you install. So if you do heap install flat, you install this executable with the Python API itself. But then we started getting more and more requests like asking Like, how would I put all this beautiful stuff to a mobile device?

00:17:23.400 --> 00:17:25.920
Or how do I do a standalone app?

00:17:26.240 --> 00:17:33.880
And, well, the answer is we should generate executable and Python should be part of it.

00:17:34.100 --> 00:17:41.780
Python, your program, set by the libraries you use for your program, all this stuff should be part of this executable.

00:17:42.120 --> 00:17:51.540
It's been a lot of work to produce a standalone package for desktop, for web, and for mobile.

00:17:51.860 --> 00:17:54.060
So Flutter is a good start for that.

00:17:54.600 --> 00:17:59.840
So the question was Python itself and third-party packages.

00:18:00.540 --> 00:18:08.940
So we decided that, like, okay, Python for desktop platform is really straightforward.

00:18:09.220 --> 00:18:19.120
You just take regular, basically regular Python and bundle it into your executable or application bundle and that's it.

00:18:19.440 --> 00:18:43.460
So it's pretty straightforward. For mobile devices, there is a challenge and we know that multiple projects when are working on this problem, like the most popular Kybee and Beware, Those guys started back, started solving this problem back in 2010, maybe 2012 if I'm not mistaken.

00:18:43.940 --> 00:18:49.700
And they did really great job and they're still doing great, you know.

00:18:49.880 --> 00:18:55.940
Yeah, I know Beware's got a lot of recent support as well through the Anaconda team, which is really great.

00:18:56.120 --> 00:19:19.160
We started from Kavi. I don't know, at that point, like two years ago, I thought that I saw maybe that Kavi is more popular And I decided to explore this way, whether Kyde could be used as a foundation for planning or we can grab portions of Kyde and make something different, you know.

00:19:19.660 --> 00:19:23.140
And it was good for the start, obviously.

00:19:24.700 --> 00:19:44.720
We managed to use Kyde tooling, like Python for Android, Python for iOS, and their command line and their libraries and their recipes to compile runtime, Python runtime and third party modules and use them in quantification.

00:19:45.460 --> 00:19:47.680
So, I mean, there was Kyvee.

00:19:47.900 --> 00:19:49.660
But you guys ended up moving off of it, right?

00:19:50.000 --> 00:20:34.380
Recipes was a great, and it's still a great idea, but there were limitations, you know, like first of all, Kyvee recipes, some of those recipes, they're outdated. So I tried building a few recipes. So I fought tidy and tried building new recipes by myself. And it wasn't easy task, you know, it's kind of so recipes, it's basically Python code. And there are a lot of historic stuff, you know, it's you should know about like a lot of debugging, I was really struggling trying to build new recipes and update existing recipes for Kairi.

00:20:34.880 --> 00:20:47.740
And also the biggest issue with Kairi's approach was you have to build all the Python runtime and all the modules like packages by yourself all the time.

00:20:48.080 --> 00:21:44.540
If you're a user, it's kind of pain. So you should enjoy SDK installed and all environment wearables in place you know like and I mean it could be a real struggle to build and it takes time sometimes like if you add NumPy pandas to your app as a dependencies it could take like half an hour to build all the packages and fingers crossed you know like whether it finishes okay you know or you get some weird pre-prepare yeah it wasn't nice it wasn't nice. I mean, it worked, this approach worked for simple things, you know, with the way your app requires fewer Python packages. But if it's not something trivial, it's either no recipe or outdated recipe, or you have to build your own recipe, etc, etc.

00:21:44.760 --> 00:21:52.960
And a recipe is basically saying how to build some particular library or Python itself for Android or for iOS or something, is that right?

00:21:53.320 --> 00:21:54.280
We can dig into that.

00:21:54.420 --> 00:21:54.520
Yeah.

00:21:54.620 --> 00:21:57.440
But it's kind of basically like settings.

00:21:57.680 --> 00:22:03.020
It's a bunch of settings for compiler for linker and how to move resulting files.

00:22:03.280 --> 00:22:05.560
You know, and basically that's it.

00:22:05.660 --> 00:22:05.780
Yeah.

00:22:05.820 --> 00:22:06.840
That doesn't sound that easy.

00:22:07.000 --> 00:22:07.860
Yeah, absolutely.

00:22:08.280 --> 00:22:08.500
Yeah.

00:22:08.680 --> 00:22:10.580
It's it's C, C++.

00:22:11.000 --> 00:22:11.220
Yeah.

00:22:11.520 --> 00:22:13.720
I can talk about this later, you know, it's.

00:22:14.200 --> 00:22:18.220
It's probably, probably people get enough of a, an idea from it.

00:22:18.680 --> 00:22:23.140
Is this, so I know that you are using or you publish serious Python.

00:22:23.400 --> 00:22:25.160
Is this sort of your answer to that?

00:22:25.400 --> 00:22:36.160
As we do open source and Kylie and other projects are open source, I thought maybe it's a good idea to contribute something to open source, right?

00:22:36.640 --> 00:22:52.600
We can do this as a part of our application templates, for example, and not dealing with this plugin, you know, but I thought maybe someone would be interested in using Python with your Clutter app.

00:22:52.980 --> 00:23:02.140
So C++ Python is a pretty low-level package that allows you to embed Python engine into your Clutter application.

00:23:02.700 --> 00:23:10.240
So, and I'm not sure if it's even popular, you know, but maybe someone can use it for some purposes.

00:23:10.860 --> 00:23:14.120
Do you do anything with Python build standalone?

00:23:14.580 --> 00:23:26.300
You know, uv has started making it really easy to install Python, all the different platforms of it by leveraging Python build standalone that was previously run by Greg now by Astral.

00:23:26.440 --> 00:23:27.000
Yes.

00:23:27.260 --> 00:23:28.420
Or do you do something else?

00:23:28.560 --> 00:23:28.700
Yeah.

00:23:28.800 --> 00:23:30.940
Like where you build, you build it for platforms.

00:23:31.240 --> 00:23:37.820
So you're talking about this GitHub project, building every version of Python for all platforms, right?

00:23:37.900 --> 00:23:38.100
Yeah.

00:23:38.340 --> 00:23:48.020
We use this repository for desktop as a, as a starting point and we don't want pre-built Python from that repo and we actually repackaged it.

00:23:48.300 --> 00:23:53.260
For mobile, now we use a different approach and I can talk about this.

00:23:53.780 --> 00:23:55.620
For web we use Pyodide.

00:23:55.720 --> 00:23:55.760
Yeah.

00:23:55.860 --> 00:24:02.640
Well, let's maybe talk for a little bit about the runtime side of things and we could talk about packaging after that.

00:24:03.140 --> 00:24:06.920
Flutter goes into all different places, more than most platforms.

00:24:07.400 --> 00:24:08.640
You can build desktop apps.

00:24:08.780 --> 00:24:09.940
You can build mobile apps.

00:24:09.980 --> 00:24:15.660
You can also build web apps, kind of a competitor to Angular or something like that.

00:24:15.760 --> 00:24:15.940
Right.

00:24:16.220 --> 00:24:26.940
And if you're going to have Python run times in these different locations, and that's kind of why I was asking about Python build standalone is, you know, there's all these variations of places that could be, which is quite tricky.

00:24:27.060 --> 00:24:27.260
Right.

00:24:27.960 --> 00:24:32.320
So the web version is WASM WebAssembly based, right?

00:24:32.520 --> 00:24:40.340
Web could be deployed in two like moments in two states, like client side and the server side.

00:24:40.820 --> 00:24:56.760
So if it's deployed as a server side app, obviously the Flutter part runs in the browser and Python runs on the server and it's standard Python with any module, you can use anything.

00:24:57.340 --> 00:25:04.020
And client part, client side, talks to server by web sockets.

00:25:04.400 --> 00:25:13.640
So all UI changes are streamed via web sockets to the client and all events go back to server side.

00:25:14.060 --> 00:25:16.780
So this is one mode, it's called server side.

00:25:16.920 --> 00:25:21.700
And another mode is client side or static web side.

00:25:21.960 --> 00:25:33.280
You can build, you can publish web app as a static website and put it on CloudFlare or GitHub pages or whatever you like.

00:25:33.420 --> 00:25:36.820
Yeah, you just put the WebAssembly files there and it just picks it up and goes, right?

00:25:36.940 --> 00:25:45.240
It's Flutter itself and Python, PyDyn, which is WebAssembly, which is Python and WebAssembly.

00:25:45.720 --> 00:25:56.480
So we don't compile Flutter part into WebAssembly yet because we have a lot of dependencies and not all of them support Wasm.

00:25:56.900 --> 00:26:04.580
But it's definitely on our roadmap and we'll have a branch trying to produce fastening builds.

00:26:04.740 --> 00:26:08.960
So it would be really nice because the size would be much smaller.

00:26:09.420 --> 00:26:12.720
The size of Flutter web would be much slower.

00:26:12.840 --> 00:26:16.340
It's probably right now it's 10 megabytes maybe.

00:26:16.740 --> 00:26:19.640
And it's going to be like two megabytes something.

00:26:20.100 --> 00:26:23.360
So it's going to be really nice when we do that.

00:26:23.520 --> 00:26:27.720
And with the right amount of caching, the right style of caching, it's not big of a deal, right?

00:26:27.880 --> 00:26:29.960
PyGuide is a pretty strong project.

00:26:30.380 --> 00:26:34.400
It has the biggest number of packages supported.

00:26:34.940 --> 00:26:36.260
So it's great.

00:26:36.440 --> 00:26:39.080
I mean, like it got really great support.

00:26:39.280 --> 00:26:49.700
I believe that the Python core devs are also working on getting Python itself to be a sort of officially built for WebAssembly.

00:26:50.240 --> 00:26:52.820
I know Brett Cannon's done a ton of work for this as well.

00:26:53.240 --> 00:26:54.460
Does that help you guys in any way?

00:26:55.160 --> 00:26:59.560
use built-in, this built-in Python support.

00:27:00.060 --> 00:27:03.260
So we migrated from Kylie to this approach.

00:27:03.760 --> 00:27:08.460
And it's thanks to the way guys, Russell and Malcolm.

00:27:09.060 --> 00:27:11.940
So Russell is iOS, Malcolm is Android.

00:27:12.620 --> 00:27:21.320
So they did a great, a really great job putting like this iOS and Android support into Python project itself.

00:27:21.720 --> 00:27:31.700
And now they, they like actually, they, they implemented the support for Python 3.13 and they ported to lower versions.

00:27:31.940 --> 00:27:32.260
Oh, nice.

00:27:32.480 --> 00:27:40.220
When I first, first saw the proposal, you know, for iOS, first of all, I really liked it.

00:27:40.500 --> 00:27:42.080
It's really great.

00:27:42.480 --> 00:28:19.780
I mean, like the way producing binary libraries, you know, like for, and packaging them, it's really good because we can use dynamic libraries versus static libraries entirely. Like entirely everything, like all these third-party modules you can file on your machine every time they produce static libraries. Basically like.a files for iOS. And finally, and they like the entire code base is like single executable at the end, you know, like everything like NumPy, like all this stuff is a single file.

00:28:20.280 --> 00:28:50.480
I mean, you cannot reuse some of those libraries, you know, like when you package them into iOS app, I really love the approach and I understood, you know, that it's probably the way going forward, you know, and you see it's kind of like it's getting like a standard now and it allows this approach allows you to have binary wheels that are prebuilt and put somewhere on not on PyPy.org yet.

00:28:50.880 --> 00:29:04.240
They don't support this model yet, but you can publish them on a custom feed, you know, and use and all users, all your users, they can download them from that location.

00:29:04.440 --> 00:29:04.980
Now that's it.

00:29:06.380 --> 00:29:07.960
Yeah, it's great.

00:29:08.320 --> 00:29:09.000
It's standard.

00:29:09.660 --> 00:29:30.520
And in the future, we can use pre-built wheels by like project maintainers, you know, like if NumPy, for example, decide releasing those wheels, we can, we can use them because we follow these standards, you know, like, so we use like standard runtime.

00:29:30.880 --> 00:29:31.000
Excellent.

00:29:31.700 --> 00:29:47.660
But NumPy folks, for example, as you said, they could use their expertise to get NumPy, this NumPy C code and Python code to build for WebAssembly and just put that in as automation and GitHub and everyone else in the world doesn't have to solve it over and over.

00:29:47.780 --> 00:29:47.960
Right?

00:29:48.140 --> 00:29:52.620
The Python 3.13 Python itself is, is pretty fresh.

00:29:52.720 --> 00:29:58.060
You know, it's many packages are still on, like don't support it.

00:29:58.400 --> 00:29:58.580
Right.

00:29:58.820 --> 00:30:11.720
So I believe like in at some point those projects will start doing their will start producing their own iOS and Android wheels and publishing them to PiPi once it's supported.

00:30:11.980 --> 00:30:16.380
So yeah, and of course, they can reuse our expertise.

00:30:16.640 --> 00:30:22.700
Yeah, you're making me dream, dream big, you know, like wheels for iOS and wheels for Android.

00:30:22.700 --> 00:30:30.940
Could you, could you imagine a day where it's as easy to just get libraries for the mobile platforms as it is for Mac or Linux or whatever?

00:30:31.180 --> 00:30:34.000
It's still not many people working in this area.

00:30:34.520 --> 00:30:45.360
And what I can tell you, it's like modern processors, modern CPUs in the Android and iOS, like Apple devices.

00:30:45.520 --> 00:30:46.800
They're pretty powerful, you know?

00:30:46.800 --> 00:31:03.560
And I remember there were a lot of like those times, like 2012, 2010, when Kylie and VWare started, there were a lot of issues trying to squeeze this desktop C code into a mobile processor.

00:31:04.100 --> 00:31:14.780
Now it's much easier. Most of those packages could be compiled as is without any tweaks, without any pictures, you know, so it's pretty, it's pretty nice.

00:31:15.080 --> 00:31:18.780
Maybe yeah, in the future we will have this as a standard thing, you know.

00:31:18.980 --> 00:31:19.060
Yeah.

00:31:19.480 --> 00:31:26.200
Last PyCon with the, maybe the Python before started, I think it was salt lake anyway, it doesn't really matter.

00:31:26.240 --> 00:31:32.940
Recently, Carol Willing at the PyCon US keynote talked about how mobile is such an important platform.

00:31:33.240 --> 00:31:38.960
And you know, there's people like you and Russell Keith-Magee and the B-Ware team working on it.

00:31:39.080 --> 00:31:53.720
But I think it feels a little chicken and an egg to me, you know, if it was a little easier, there would be a huge bunch of people that jump into it, but there's, it takes projects like Flet and the Beware one to just kind of unlock it.

00:31:53.800 --> 00:32:02.640
And then I think once it gets unlocked, people are going to realize and just go for it, you know, Kevin Python on the mobile devices is, is, is pretty awesome.

00:32:02.720 --> 00:32:11.220
You know, it's like for, for Android, for example, it's, it adds maybe like 8 megabytes of size to your app.

00:32:11.380 --> 00:32:12.600
So it's not so large.

00:32:12.940 --> 00:32:13.940
And it makes sense.

00:32:14.060 --> 00:32:15.340
Python is a great language.

00:32:15.460 --> 00:32:19.820
It's great for beginners, you know, for scientists.

00:32:20.300 --> 00:32:28.400
So it's really, I don't know, like addictive, you know, like to write apps for everything in Python.

00:32:28.800 --> 00:32:35.180
I've become like, I've been using Python for three years already, and I still love it, you know.

00:32:35.240 --> 00:32:43.160
Like I write most of my, like, even like sweets, you know, like in Python, like, so I'm looking back and all.

00:32:43.440 --> 00:32:43.540
Yeah.

00:32:43.580 --> 00:32:48.100
I've worked in a lot of programming languages, myself, static and dynamic ones.

00:32:48.180 --> 00:32:49.600
And yeah, it's Python.

00:32:49.780 --> 00:32:50.280
It's comfortable.

00:32:50.880 --> 00:32:51.320
It's nice.

00:32:51.460 --> 00:32:51.580
Yeah.

00:32:51.960 --> 00:32:52.120
All right.

00:32:52.180 --> 00:32:56.720
I want to talk about packaging and I know that's the area that you've been working on a lot as well.

00:32:57.060 --> 00:33:00.360
And as a segue, let's take a question from the audience.

00:33:00.440 --> 00:33:04.280
Alan out there asks, I'm someone taking a careful look at Flet.

00:33:04.320 --> 00:33:09.680
My question is what is the process of getting finished app reviewed by Apple or Google?

00:33:09.840 --> 00:33:23.360
I think, let me rephrase that into slightly different part because the reviewed by Apple or Google, there's like a voodoo doll and you stick it with a few pins and then you like rub it with an oil and then they, they approve your app, right?

00:33:23.420 --> 00:33:24.860
Like that seems to be the process.

00:33:25.380 --> 00:33:31.720
It's been so hard, but I think the thing is how do you get it built in a way that you can submit it to the app store?

00:33:32.120 --> 00:33:33.680
And then it's just down to, right?

00:33:33.720 --> 00:33:34.960
So what's the process?

00:33:35.340 --> 00:33:41.020
This is one of those rough questions, you know, it's, and you should have a list of rough questions.

00:33:41.240 --> 00:33:42.580
You're ready to answer.

00:33:43.020 --> 00:33:48.040
So right now you can build your APK for AAB for Android.

00:33:48.480 --> 00:33:53.860
You can sign it, but you have to upload the file manually right now into.

00:33:54.260 --> 00:33:54.500
I see.

00:33:54.620 --> 00:33:56.760
So you have to sideload it basically at the moment.

00:33:56.920 --> 00:34:03.460
YOLT command allows you to build the AAB file, which is basically APK for multiple platforms.

00:34:03.600 --> 00:34:09.399
sign it, and then you upload it by yourself through the web interface of Google Play.

00:34:09.620 --> 00:34:14.120
Oh, let me go back then. That's not side loading it. That's just not having it auto upload.

00:34:14.280 --> 00:34:14.540
Yeah.

00:34:14.720 --> 00:34:15.220
That's encouraging.

00:34:15.460 --> 00:34:32.060
So we have own Flag app in both Google Play and App Store. It's for testing apps on mobile devices. Basically, like the same flag client that connects to app through web sockets and the app itself is running on your machine.

00:34:32.639 --> 00:34:37.879
So yeah, and honestly, right now we publish it with Fastlane.

00:34:38.480 --> 00:34:45.700
So there is a CI job that publishes both iOS and Android versions with Fastlane.

00:34:46.060 --> 00:35:00.240
I'm not sure, maybe we will do the instructions how to use Fastlane because it's a great tool and it's pretty easy to synchronize certificates you know, for App Store and publish your app and make that information for app.

00:35:00.820 --> 00:35:08.240
So, yeah, but right now you can, you can build IP, you can build AAB, but you have to upload them manually.

00:35:08.460 --> 00:35:09.120
I think that's fine.

00:35:09.280 --> 00:35:09.480
Yeah.

00:35:09.520 --> 00:35:11.620
And then the review process starts.

00:35:11.760 --> 00:35:15.920
That's the voodoo doll part where you get the voodoo doll out and you hit it with the needles.

00:35:16.800 --> 00:35:29.120
People usually concerned about like, whether is it allowed to have Python or like the like stuff like that in your app and would it be approved by Apple, by Google?

00:35:29.620 --> 00:35:31.980
And I can tell you it works pretty well.

00:35:32.140 --> 00:35:34.320
We dogfood our own stuff.

00:35:34.640 --> 00:35:37.440
So we build Klet app using Klet.

00:35:37.860 --> 00:35:42.580
So the way it's packaged inside, it's getting approved.

00:35:43.140 --> 00:35:43.860
There are some issues.

00:35:43.980 --> 00:35:45.520
I can tell you there are some issues.

00:35:46.020 --> 00:35:52.260
For example, disabled, we used to disable x86 devices right away.

00:35:52.540 --> 00:36:05.200
And because they're like Google Play, usual machines, they show just like a black screen, you know, like, like the market share for those devices is pretty small right now.

00:36:05.400 --> 00:36:06.980
So we disabled that.

00:36:07.240 --> 00:36:10.700
So two plus is the review, but it works.

00:36:10.940 --> 00:36:11.280
It works.

00:36:11.860 --> 00:36:20.500
talk through the publishing workflow that you all have with the new CLI tools you got, but let's just dive into one more thing real quick.

00:36:20.840 --> 00:36:27.500
So when I have my Python code running, let's just say iOS, I have my Python code running on an iPhone.

00:36:27.840 --> 00:36:30.780
What is the runtime look like?

00:36:30.920 --> 00:36:32.600
Is that regular CPython?

00:36:33.260 --> 00:36:36.760
Can I add a standard package as a wheel?

00:36:37.100 --> 00:36:39.540
Like, could I use HTTPX?

00:36:39.620 --> 00:36:44.800
Like what is the story around the execution environment and the external packages and so on?

00:36:45.080 --> 00:36:45.700
It's CPython.

00:36:46.160 --> 00:36:51.900
As I said, right now we use, or this serious Python package, it uses Python.

00:36:52.020 --> 00:36:57.940
There is, by those scripts, which are part of Python 3.13.

00:36:58.540 --> 00:37:41.500
So like, theoretically, if you go there to Python repository and look into those, folders you will see instructions you can you can follow those instructions and build runtime like build CPython for both iOS and Android but yes this is it's not blossom it's CPython compiled into native iOS or Android code like platform for platform not like code assemble and binary packages yes you have to repackage, you have to build binary packages targeting those platforms as well. And for that purposes we use MobileForge project by DeWare.

00:37:41.880 --> 00:37:47.600
It's pretty nice, it's an awesome project, it's a brainchild of Malcolm and Russell.

00:37:48.100 --> 00:38:32.900
And yeah, in its turn it uses cross-env package, which is basically the way to simulate, like it allows you to create a virtual environment and Python thinks that it's being run on a mobile device, you know. So it's like basically MobileForge is like you do people install something and it feels like for Python it feels like it's being run this command on a mobile device and you it uses like if it's binary package and there is setup.py or pyproject.toml It uses mobile compilers, cross compilers to build.so file and produce a build.

00:38:33.100 --> 00:38:44.120
So if a pip install action requires a local build of something, it will use the mobile compilers with the target platform being like iPhone or whatever.

00:38:44.300 --> 00:39:16.620
The whole package like this cross-env, it tweaks Python into thinking it's kind of like running on a mobile device, you know, like it has these compilers, this archiver, this linker, you know, it's so nice. So like, and it's, it's pretty, it's pretty smart thing, you know, like in most cases, so you should do a recipe. But this time recipe is, is basically YAML file, it's like meta.yaml.

00:39:16.940 --> 00:39:23.660
And in most cases, if it's standard C, if it's simple package, you don't have to do anything.

00:39:24.020 --> 00:39:25.760
It works right away.

00:39:25.880 --> 00:39:27.300
You can build it for Android.

00:39:27.680 --> 00:39:28.980
You can build it for iOS.

00:39:29.380 --> 00:39:34.800
It takes literally minutes to produce a binary wheel for both platforms.

00:39:35.080 --> 00:39:36.480
I'll definitely link that in the show notes.

00:39:36.920 --> 00:39:41.620
All right, back to wherever I put it, the publishing side of things.

00:39:41.940 --> 00:39:46.560
So maybe we could talk through a little bit about the CLI and the process.

00:39:47.020 --> 00:39:49.540
Tell us, tell us how we go through this to get something built here.

00:39:49.640 --> 00:40:01.640
The first release, the first releases of web were using the like so-called web, like offering flat path command and using PyInstaller to produce executable.

00:40:01.860 --> 00:40:05.300
But it worked for desktop platforms as well only.

00:40:05.780 --> 00:41:05.680
And to produce the package, like the bundle for mobile platform, it's you need to do more. It's still possible as those guys are basically zip files inside, you know, you can build the AAB, you can build the APK, you can build the IPA by yourself or using Xcode tools. And it's like, it's the approach BWAM takes, for example. So the briefcase it builds like packages basically from scratch you know but for Flutter we use we require to use Flutter SDK so there is a new command let build which uses Flutter SDK and it's basically like a wrapper around the Flutter build command which allows you to build the app for desktop for web for mobile. So inside we take template, we take template and we create a new Flutter app and we build this Flutter app.

00:41:05.760 --> 00:41:15.640
Right. And just for people listening, the template looks something like here's a folder with a bunch of images and here's a main.py and a pyproject.toml, stuff that Python people would be familiar with.

00:41:15.760 --> 00:41:20.700
This is template for the app and template for Flutter app, it's something internal.

00:41:20.880 --> 00:41:22.640
You don't have to look into that.

00:41:22.780 --> 00:41:23.660
You know, it's like...

00:41:23.660 --> 00:41:27.300
It gets kind of complicated for the different platforms and linking them together and stuff.

00:41:27.380 --> 00:41:32.960
The problem with this, with Flutter is like the difference because we want to, we want to support extensions.

00:41:33.520 --> 00:41:39.380
We want to allow people using those nice extensions packages on pub.dev.

00:41:39.720 --> 00:41:54.360
So we cannot have the same process every time we, we should really run Flutter build to like, for example, include a media kit for video control or audio players package for audio control.

00:41:54.720 --> 00:41:55.600
It's not the same.

00:41:55.640 --> 00:41:56.180
It's always.

00:41:56.700 --> 00:42:02.980
So it should be built from dark to this code Flutter produces.

00:42:03.300 --> 00:42:04.540
That's a lot of what Flutter is.

00:42:04.900 --> 00:42:09.980
It's like orchestrating all the pieces to build into the right stuff to go into the mobile apps.

00:42:10.040 --> 00:42:10.840
Yeah, exactly.

00:42:11.020 --> 00:42:18.680
So we've got this pyproject.toml and you even have a create CLI command, like flit create my app or whatever.

00:42:19.060 --> 00:42:21.600
And it will go and get that all out there.

00:42:21.820 --> 00:42:21.960
Right.

00:42:22.080 --> 00:42:24.900
Recent stuff and still pretty rough.

00:42:25.140 --> 00:42:25.240
Yeah.

00:42:25.320 --> 00:42:41.560
And here you have flat build and then target platform and where a target platform is APK that is Android, AAB, IPA, which is iOS, web, macOS, windows, and Linux, that's a pretty impressive list of package destinations for building an executable.

00:42:41.760 --> 00:42:43.880
So if I build, let's suppose this.

00:42:43.880 --> 00:42:46.120
If I build a, let's say windows.

00:42:46.500 --> 00:42:53.720
I say target equals Windows, what files or file or executable or what do I get when I run that?

00:42:54.000 --> 00:42:58.860
Do I get just a.exe? Do I get a.exe with DLLs or a whole bunch of other stuff?

00:42:59.060 --> 00:43:35.880
Yeah, unfortunately it's not a single.exe, but it's.exe and a bunch of DLLs. Yes. It's, if you look inside the folder, you'll see like this executable, then Python itself, Python in runtime, which is a bunch of lead files, you know, and DLLs, Python files themselves, then your app coming as a zip file, also different kinds of DLLs from, from plugins, from extension packages, Flutter packages, like for video, for example, it's going to be like four more DLLs, something.

00:43:36.440 --> 00:43:39.440
So yeah, it's, it's, it's a bunch of things.

00:43:39.600 --> 00:43:39.700
Yeah.

00:43:39.920 --> 00:43:49.160
But, but it's something I could put into an installer or copy to a Windows And then you create a shortcut to the.exe and it, it looks like an app to the user.

00:43:49.340 --> 00:43:52.600
You can make self-extracting archive for MSI.

00:43:52.700 --> 00:43:52.940
Okay.

00:43:53.180 --> 00:43:54.060
And for macOS?

00:43:54.420 --> 00:43:56.340
For macOS, it's a bundle.

00:43:56.480 --> 00:43:57.440
Is that a.app bundle?

00:43:57.620 --> 00:43:57.840
Yeah.

00:43:58.140 --> 00:44:01.900
But it's a standard bundle that looks like a file, but it's a folder.

00:44:02.560 --> 00:44:05.480
Works like a charm, you know, like having the right structure.

00:44:05.960 --> 00:44:13.780
Again, the app inside is a part of the Flutter asset, which is like, it's called like car file.

00:44:13.780 --> 00:44:19.040
It's not like even the zip, it's car file and which has all the assets.

00:44:19.280 --> 00:44:19.460
Nice.

00:44:19.580 --> 00:44:22.220
It's a work in progress, you know, like to.

00:44:22.360 --> 00:44:23.960
Are you ready for the hard question now?

00:44:24.500 --> 00:44:28.360
Those are all awesome answers, but here's the one that has been driving me crazy.

00:44:28.880 --> 00:44:45.420
Is so many of these platforms by that, I mean, windows and Mac have anti malware, anti phishing protections, which is good, but that means if you build a dot app file and just try to run it.

00:44:45.640 --> 00:44:47.700
It'll say this is from an untrusted developer.

00:44:48.160 --> 00:44:49.820
We'll probably, you want to move it to the trash.

00:44:50.260 --> 00:44:50.740
You know what I mean?

00:44:50.820 --> 00:45:00.280
Like the lack of notarization or on windows, if it's not digitally signed with a trusted cert certificate, it gets treated with like a yellow warning.

00:45:00.620 --> 00:45:05.880
Is there a way to digitally sign these or notarize them through Apple?

00:45:06.240 --> 00:45:07.500
Yeah, I know flutter can do it.

00:45:07.580 --> 00:45:11.600
So maybe you could show up, maybe it shells down to the flutter side of how that works.

00:45:12.280 --> 00:45:19.320
But still, it looks pretty complicated, you know, like, even from my perspective, like, it looks pretty creepy.

00:45:19.860 --> 00:45:25.000
But I have this item on my desk right now to start from my class.

00:45:25.380 --> 00:45:31.900
Because there was a complaint from one user recently, like two days ago, and I still had this issue.

00:45:32.360 --> 00:45:38.020
So I'm gonna work on that, and I'm gonna provide, like, a definitive answer.

00:45:38.360 --> 00:45:42.180
It's not like I'm not going to say like it's do whatever you like.

00:45:42.240 --> 00:45:47.720
Like, no, I'm going to go through all this stuff because right now we honestly, we use it.

00:45:47.780 --> 00:45:52.960
We don't even use sandbox mode in produce.app file.

00:45:53.380 --> 00:46:03.340
You know, it's so we start from there and there was an issue with the loading Python binaries, like package binaries.

00:46:03.780 --> 00:46:06.540
I'm going to, I'm going to solve that problem as well.

00:46:06.880 --> 00:46:26.460
So yeah, definitely. It's our next step. Yeah. We, as you see, we're getting closer and closer to building real apps and we're getting more and more developers building real apps and they want to publish them. It's not just experimental, you know, anymore, like they want to publish them.

00:46:26.500 --> 00:46:35.200
And we are working on that right now, like publishing. And it's actually, it's our number one priority for the next year.

00:46:35.360 --> 00:46:42.300
I'll tell you, if you had that, that dialed, I mean, that means that that opens up desktop apps completely.

00:46:42.540 --> 00:46:42.980
Absolutely.

00:46:43.320 --> 00:46:43.460
Yeah.

00:46:43.700 --> 00:46:52.100
So we will, I will start from micro-ends because I have probably more, a little bit more experience with micro-ends right now.

00:46:52.220 --> 00:46:55.380
And then I want to continue with the Windows Store.

00:46:55.800 --> 00:46:58.420
I never published anything to Windows Store before.

00:46:58.680 --> 00:47:02.720
So it's going to be an interesting journey, you know, but yeah, Windows Store as well.

00:47:02.760 --> 00:47:11.220
Well, yeah, even if you just digitally signed it so that if you download it off someone else's website, it wouldn't go, Oh my gosh, this is an executable.

00:47:11.380 --> 00:47:12.580
That's untrusted runaway.

00:47:12.780 --> 00:47:18.420
You know, we actually sign our MSIs right now for, for other products.

00:47:18.560 --> 00:47:38.500
And it's kind of like conspiracy, you know, like, so you have to use a really expensive certificate to pass through what was like screen, Windows screen, something like, so it's not just even like code signing and not even easy code sign is something else.

00:47:38.620 --> 00:47:38.760
Yeah.

00:47:39.080 --> 00:47:39.360
Yeah.

00:47:39.580 --> 00:47:42.400
On MacOS it's gatekeeper and these sorts of things.

00:47:42.420 --> 00:47:42.760
Yeah.

00:47:42.940 --> 00:47:43.100
Yeah.

00:47:43.260 --> 00:47:47.280
I remember it's like $600 per year, something like that.

00:47:47.440 --> 00:47:51.700
At least if you want to pass this windows 11 screen.

00:47:52.280 --> 00:47:52.420
Yeah.

00:47:52.780 --> 00:47:54.900
Otherwise it's always a warning.

00:47:55.380 --> 00:47:55.620
Always.

00:47:55.760 --> 00:47:57.680
Where's the let's encrypt for desktop apps.

00:47:57.700 --> 00:47:59.820
Come on people, somebody help us out.

00:48:00.620 --> 00:48:03.120
Where's the cert bot for let's for desktop apps.

00:48:03.340 --> 00:48:11.420
But yeah, I, you know, like it's, it's there for a reason because people kept getting wrecked by ransomware and all sorts of stuff, but it does make building desktop apps challenging.

00:48:11.740 --> 00:48:13.060
Well, yeah, but we'll get there.

00:48:13.180 --> 00:48:13.640
No worries.

00:48:13.920 --> 00:48:14.300
I love it.

00:48:14.560 --> 00:48:14.740
All right.

00:48:14.880 --> 00:48:17.100
What else should we say about, about this here?

00:48:17.260 --> 00:48:19.000
I guess controls.

00:48:19.260 --> 00:48:20.400
I know there was a question.

00:48:20.920 --> 00:48:21.760
See a video.

00:48:21.860 --> 00:48:26.700
There was a question out in the audience also from Allen's is about camera controls.

00:48:26.800 --> 00:48:28.900
Is this a thing that you guys support yet?

00:48:29.140 --> 00:48:49.980
We started working on that, but it's not like it was kind of like testing the waters, you know, like it's kind of like at this moment we are trying to harmonize API, flat API and as I see it right now, we, we're going to split all controls into like visual controls and so-called services.

00:48:50.220 --> 00:49:04.180
So camera is going to be service because yeah, right now it's sometimes it's, it's messy, you know, like to use non-visual controls, you have to add them like to overlay or something.

00:49:04.880 --> 00:49:38.520
And like if you jump to a different page, it like audio could stop, you know, like, so we're going to re-implement that. And camera is true. Camera is the number one parameter right now. That's why there is a draft pull request and we're not closing it. So we keep it in mind The reason I even brought that up right now is because part of this packaging process, you have to state things like your permissions that you're requesting, like access to location.

00:49:39.080 --> 00:49:48.060
And you also have to include which optional controls you want to build like audio recorder or geolocation or maps and things like that.

00:49:48.140 --> 00:49:48.320
Right?

00:49:48.420 --> 00:49:53.240
This is something we're going to change by the next release as well.

00:49:53.440 --> 00:50:03.700
We will make this process more streamlined, easier to add new controls or services and include them into the build process.

00:50:03.860 --> 00:50:09.900
Well, even having them under a subsection of your pyproject.toml is pretty nice, actually.

00:50:10.120 --> 00:50:11.460
It looks standard, you know?

00:50:11.640 --> 00:50:11.760
Yeah.

00:50:11.920 --> 00:50:13.580
It looks like it belongs, which is really nice.

00:50:13.660 --> 00:50:13.840
Right.

00:50:14.160 --> 00:50:25.600
And obviously you've got icons and splash screens and all of those types of things that you have to include in order to build, especially mobile apps, but even icon for a dot app or dot exe.

00:50:25.880 --> 00:50:26.040
Yeah.

00:50:26.140 --> 00:50:36.100
I guess one more thing we got time for one more thing to call out here about this packaging side of things, or maybe, maybe two, but this one's pretty interesting is by default, flat will flat build.

00:50:36.180 --> 00:50:46.460
We'll just pile your Python app together and assume that it must be fine, but you have a --compile app option that will compile your Python files.

00:50:46.840 --> 00:50:49.640
Now people listening might think, well, but there's no Python compiler.

00:50:50.020 --> 00:50:51.020
There is a Python compiler.

00:50:51.440 --> 00:50:52.500
You just don't do anything with it.

00:50:52.760 --> 00:50:54.620
It's in the interpreter, right?

00:50:54.720 --> 00:51:00.820
So when Python loads your Python files, it converts it to a byte code and then interprets it.

00:51:00.920 --> 00:51:01.060
Right.

00:51:01.220 --> 00:51:05.780
But you can have it compile that to PYC files, which will detect problems.

00:51:05.860 --> 00:51:06.080
Right.

00:51:06.360 --> 00:51:06.900
That's kind of cool.

00:51:07.040 --> 00:51:07.220
Yeah.

00:51:07.360 --> 00:51:07.500
Yeah.

00:51:07.680 --> 00:51:08.540
Tell people about that a bit.

00:51:08.640 --> 00:51:30.200
One of the reasons we introduced those options is that if you always compile and there are some issues inside user code, the entire process fails, you know, Like even at least one single syntax error somewhere in your app leads to like a failed build process.

00:51:30.520 --> 00:51:38.200
And also you can disable compilation so it could be easy to debug your app.

00:51:38.560 --> 00:51:43.120
People asking like, is it like, can I see what's going on?

00:51:43.220 --> 00:51:49.020
Like if I am like downloaded your app and looked inside, like, can I see what's going on inside my app?

00:51:49.080 --> 00:51:50.280
Like can users see?

00:51:50.400 --> 00:51:59.880
Well, it's not the way to properly protect your app from someone looking at the logic.

00:52:00.880 --> 00:52:03.400
It's not 100% protection.

00:52:04.160 --> 00:52:06.440
So maybe you should use obfuscators.

00:52:06.740 --> 00:52:12.760
And we have some ideas to build obfuscating into Pipeline.

00:52:12.800 --> 00:52:15.740
I was thinking obfuscators were kind of like a separate thing.

00:52:16.300 --> 00:52:18.060
Imagine if it doesn't work.

00:52:18.200 --> 00:52:35.500
I mean, it's good if it works, like if you obfuscate it and it works, but Python is pretty complex thing because it's, it operates by text files, you know, like, so you can break some paths, you know, like module names, you know.

00:52:35.800 --> 00:52:36.080
Exactly.

00:52:36.380 --> 00:52:44.160
If it obfuscates the import statement or it's an import request, like that's not going to work anymore, you know, cause that's how Python works.

00:52:44.300 --> 00:52:44.880
It needs to see it.

00:52:44.980 --> 00:52:45.160
Yeah.

00:52:45.300 --> 00:52:46.040
I want to play with it.

00:52:46.040 --> 00:52:46.820
I want to play with it.

00:52:46.960 --> 00:52:56.440
If I compile my Python files, my PY files, does that omit them from the project and only include the PYC files or how does that work?

00:52:56.540 --> 00:52:58.020
We remove the PY.

00:52:58.580 --> 00:52:59.000
Yeah.

00:52:59.120 --> 00:53:01.960
That's already pretty, pretty good levels of obfuscation.

00:53:02.320 --> 00:53:12.660
There are disassemblers and decompilers for C code for, especially for.NET and Java, you can get those back to almost source level decompilation and sort of things.

00:53:12.780 --> 00:53:18.060
So yeah, that's, that's kind of close to at least close to, I would say it puts on par with.NET level of obvious cases.

00:53:18.060 --> 00:53:18.840
>> It's the star.

00:53:19.120 --> 00:53:19.260
>> Yeah.

00:53:19.540 --> 00:53:19.880
>> Yeah.

00:53:20.260 --> 00:53:20.320
All right.

00:53:20.380 --> 00:53:23.940
The last thing I guess we should talk about real quick is just permissions.

00:53:24.160 --> 00:53:32.540
So if you live in this mobile world, this is androidmanifest.xml or info.plist or.entitlements and all these things.

00:53:32.920 --> 00:53:38.340
And so you support these platform specific deals pretty much because Flutter supports them, right?

00:53:38.440 --> 00:53:40.520
>> It's not like pre-camped permissions.

00:53:41.380 --> 00:53:42.900
You can put anything you like.

00:53:42.900 --> 00:53:54.800
It's basically, it's whatever you put here into PyProject.toml or common line arguments, it goes directly to this build template.

00:53:55.360 --> 00:54:06.620
So it's, in fact, it's a big template, it's a cookie cutter template, and there are a bunch of for each statements, you know, like going through all these arrays.

00:54:06.900 --> 00:54:13.060
So whatever you put here, it goes to those entitlements, PLLs and manifest file.

00:54:13.700 --> 00:54:15.320
So it's pretty, it's pretty flexible.

00:54:15.560 --> 00:54:15.700
Yeah.

00:54:16.240 --> 00:54:17.040
But sure.

00:54:17.180 --> 00:54:19.260
We have like some predefined.

00:54:19.780 --> 00:54:23.980
When you say it's a cookie cutter thing, it's not just like a template.

00:54:24.080 --> 00:54:26.840
It literally uses the Python cookie cutter library, right?

00:54:27.020 --> 00:54:28.740
It's in a separate repository.

00:54:29.540 --> 00:54:36.500
So every flat build command downloads that template and provides the data.

00:54:36.680 --> 00:54:41.020
combined template and data and produces this Flutter app.

00:54:41.100 --> 00:54:42.700
And then it goes to Flutter build.

00:54:42.820 --> 00:54:43.380
>> It looks great.

00:54:43.540 --> 00:54:45.040
And it also looks like a lot of work.

00:54:45.660 --> 00:54:47.960
So congratulations on making it this far.

00:54:48.860 --> 00:54:49.340
>> Thank you.

00:54:50.280 --> 00:54:51.820
Yeah, it's still a lot of work.

00:54:51.900 --> 00:54:52.140
>> Yeah.

00:54:52.240 --> 00:54:52.340
Yeah.

00:54:52.380 --> 00:54:52.580
Yeah.

00:54:53.000 --> 00:54:53.580
Let's see.

00:54:53.660 --> 00:54:56.600
I wanted to just have you real quickly close out.

00:54:56.640 --> 00:55:00.800
I don't know where I stuck it somewhere in here, the roadmap for, for where you're going.

00:55:01.160 --> 00:55:03.660
So maybe tell us what's in the future.

00:55:03.820 --> 00:55:06.660
What's what's in the near term that people can count on and then we'll wrap up.

00:55:06.660 --> 00:55:22.880
Yeah, maybe this roadmap is already outdated, but yeah, first of all, we want to have this 1.0 because it's maybe it's a psychological thing, you know, it's like people, developers feel stability and all that.

00:55:23.260 --> 00:55:29.420
When there is 1.0, it says that the framework is ready for for SilverSaps.

00:55:29.580 --> 00:55:31.280
It's a commitment to sustainability.

00:55:31.480 --> 00:55:32.560
Like we think we're ready.

00:55:32.940 --> 00:55:39.620
It's commitment for sustainability and it's commitment for proper release schedule.

00:55:39.820 --> 00:55:46.380
So we'll keep this release after releasing it and we'll be providing patches to this 1.0, etc.

00:55:46.720 --> 00:55:49.740
So you can start doing real apps using 1.0.

00:55:50.180 --> 00:56:11.120
So it's 1.0 and we were doing a lot of work trying to harmonize API, trying to remove outdated stuff, trying to like have consistent naming conventions across different controls, you know, it's like property names, method names, remove different duplicates.

00:56:11.680 --> 00:56:15.660
So it's a lot of work and we're almost there.

00:56:16.220 --> 00:56:23.020
So definitely like another thing is improving developer experience, right?

00:56:23.300 --> 00:56:36.900
So improving developer experience, further improving developer experience, Like for example, we will be pre-installing all dependencies to make flood build command work really smooth on your computer.

00:56:37.180 --> 00:56:49.140
Like right now you have to install Flutter by itself, but we'll be installing correct version of Flutter on your behalf and Android is, yeah, Java, Java could be a pain, real pain.

00:56:50.200 --> 00:56:51.920
Like sending this Java home.

00:56:52.600 --> 00:57:01.200
If you're a people who have not been through Flutter projects, they don't They don't know all the little tools and the version mismatches.

00:57:01.340 --> 00:57:07.620
And I've got this version of Android Studio, but the Android SDK version wasn't checked correctly.

00:57:07.800 --> 00:57:14.160
And so now I can't, you know, like that, what you're saying is there's a lot of stuff that you could help out with and make that smoother, but it's challenging.

00:57:14.480 --> 00:57:20.700
Yeah. And still, it's still, you need Android Studio or Xcode or Visual Studio.

00:57:21.280 --> 00:57:23.940
Yeah. You can spend a lot of time configuring those things.

00:57:24.180 --> 00:57:34.300
You know what, maybe next year we're going to, we're going to work, start working on the service, you know, like I call it packaging and publishing service.

00:57:34.540 --> 00:57:39.120
So you could somehow link a GitHub branch, like a production branch or something.

00:57:39.240 --> 00:57:42.300
If you push that, you guys grab it and you'll build all the assets.

00:57:42.520 --> 00:57:42.640
Yeah.

00:57:42.760 --> 00:57:43.100
Nice.

00:57:43.200 --> 00:57:55.100
You can push your, just, you know, your code in this directory to this service and get artifact back, you know, like MSI file or ATP file.

00:57:55.600 --> 00:57:55.840
That's it.

00:57:56.040 --> 00:57:56.540
That'd be awesome.

00:57:56.920 --> 00:57:57.040
Actually.

00:57:57.300 --> 00:57:57.940
That's very cool.

00:57:57.960 --> 00:58:08.280
You don't need to deal with all these dependencies, like all this stuff, you know, it's you just do your part, your like Python code and that's it.

00:58:08.560 --> 00:58:12.080
And the rest will be done inside the, yeah, in the cloud.

00:58:12.340 --> 00:58:13.920
So that's the idea.

00:58:14.120 --> 00:58:14.780
That's the plan.

00:58:14.860 --> 00:58:15.400
Very promising.

00:58:15.920 --> 00:58:16.280
I love it.

00:58:16.600 --> 00:58:18.960
And I love all this work, all this progress you guys have made.

00:58:19.020 --> 00:58:21.680
So thanks for coming back on and sharing with everyone.

00:58:21.980 --> 00:58:22.600
Let's close it out.

00:58:23.100 --> 00:58:23.740
Final call to action.

00:58:23.820 --> 00:58:25.240
People are interested in Flet.

00:58:25.700 --> 00:58:26.160
What do you tell them?

00:58:26.360 --> 00:58:26.860
Go ahead.

00:58:27.460 --> 00:58:28.760
Download the latest version.

00:58:29.460 --> 00:58:33.400
Try doing your app and join our discord channel.

00:58:33.780 --> 00:58:34.820
Let us know what you think.

00:58:34.900 --> 00:58:35.140
Awesome.

00:58:35.520 --> 00:58:35.760
All right.

00:58:36.080 --> 00:58:36.500
Thanks a bunch.

00:58:36.840 --> 00:58:37.140
See you later.

00:58:37.320 --> 00:58:37.540
Yeah.

00:58:37.880 --> 00:58:38.580
Thank you guys.

00:58:39.020 --> 00:58:39.320
Bye.

00:58:40.600 --> 00:58:43.200
This has been another episode of talk Python to me.

00:58:43.940 --> 00:58:45.060
Thank you to our sponsors.

00:58:45.360 --> 00:58:46.640
Be sure to check out what they're offering.

00:58:46.780 --> 00:58:48.020
It really helps support the show.

00:58:48.660 --> 00:58:52.340
This episode is sponsored by Posit Connect from the makers of Shiny.

00:58:52.740 --> 00:58:56.880
Publish, share, and deploy all of your data projects that you're creating using Python.

00:58:57.360 --> 00:59:03.600
Streamlit, Dash, Shiny, Bokeh, FastAPI, Flask, Quarto, Reports, Dashboards, and APIs.

00:59:04.340 --> 00:59:05.940
Posit Connect supports all of them.

00:59:06.200 --> 00:59:11.580
Try Posit Connect for free by going to talkpython.fm/posit, P-O-S-I-T.

00:59:12.360 --> 00:59:13.240
Want to level up your Python?

00:59:13.680 --> 00:59:17.300
We have one of the largest catalogs of Python video courses over at Talk Python.

00:59:17.820 --> 00:59:22.480
Our content ranges from true beginners to deeply advanced topics like memory and async.

00:59:22.880 --> 00:59:25.160
And best of all, there's not a subscription in sight.

00:59:25.420 --> 00:59:28.040
Check it out for yourself at training.talkpython.fm.

00:59:28.800 --> 00:59:33.060
Be sure to subscribe to the show, open your favorite podcast app, and search for Python.

00:59:33.420 --> 00:59:34.240
We should be right at the top.

00:59:34.780 --> 00:59:43.600
You can also find the iTunes feed at /itunes, the Google Play feed at /play, and the Direct RSS feed at /rss on talkpython.fm.

00:59:43.900 --> 00:59:46.600
We're live streaming most of our recordings these days.

00:59:46.920 --> 00:59:54.500
If you want to be part of the show and have your comments featured on the air, be sure to subscribe to our YouTube channel at talkpython.fm/youtube.

00:59:55.340 --> 00:59:56.460
This is your host Michael Kennedy.

00:59:56.920 --> 00:59:57.800
Thanks so much for listening.

00:59:57.980 --> 00:59:58.880
I really appreciate it.

00:59:59.220 --> 01:00:00.840
Now get out there and write some Python code.