Python for the .NET developer Transcripts
Chapter: Web frameworks
Lecture: The ASP.NET and Python web ecosystems compared

Login or purchase this course to watch this video and the rest of the course contents.
0:00 When you think about
0:01 building web applications in .NET
0:03 there's basically one, single option.
0:06 Yeah, I know there's some open source frameworks
0:08 that you could technically bring in, but if you
0:11 go out and survey .NET developers
0:12 What kind of web app are you building?
0:14 You can bet that this is an ASP.NET application.
0:18 It might be traditional ASP.NET
0:20 or it could be ASP.NET Core if those groups have moved over
0:23 to the newer version of .NET to be cross platform
0:27 and all that, but you can bet it's ASP.NET.
0:29 So here's, Okay, I'm going to go create a new
0:30 web project, in Visual Studio, what do you get?
0:32 Well, I could have a ASP.NET Core Web Application
0:35 or I could have a Blazor app.
0:37 And by the way, Blazor is incredibly impressive.
0:40 But it's backed by an ASP.NET Core app.
0:43 Or I could create another one based on ASP.NET
0:46 the .NET Framework, and it's also Web Forms, MVC
0:49 or Web API, but you can tell it's basically ASP.NET
0:52 without very small runtime change.
0:55 GRPC service, yeah, also in .NET.
0:59 There's basically one clear way
1:01 for building web applications, ASP.NET.
1:04 This is both good and bad, right?
1:06 Like, on one hand variety is the spice
1:08 of life, that's really cool.
1:10 But on the other, you kind of know what to do, the dueling
1:13 is all focused around this one thing, so that's great.
1:16 Python is actually quite the opposite
1:19 it's a little bit dizzying and if you come from
1:21 the .NET world and the ASP.NET world, you go from
1:24 this clear choice where there's like minor variations.
1:27 Oh, is it a Web API or is it
1:29 just like a MVC app, I don't know?
1:32 That just blows up into a thousand options.
1:34 So Python is quite the opposite.
1:35 We have Django, you've probably heard of Django
1:37 it's one of the more popular ways to build web apps.
1:40 My mind is a lot like web forms, a little bit.
1:43 Not in practice, but in that there's a lot of big pieces
1:47 you can kind of clunk in there and just get going
1:49 and that's got a certain appeal, it's pretty nice.
1:52 We also have Flask, Flask is more like ASP.NET MVC
1:56 very lightweight, it doesn't put a lot
1:58 of structure in place for you.
2:01 We also have Pyramid, I built my sites with Pyramid.
2:03 I absolutely love Pyramid, I adore this web framework.
2:06 It's not quite as popular as the other two
2:08 but it is really, really nice.
2:10 It has probably the best templating language out of all
2:12 the frameworks that we'll see, Pyramid is really nice.
2:16 We also have Masonite, Masonite is inspired by Laraval
2:19 and it's a pretty cool framework
2:21 with a lot of command line utilities
2:23 to generate new elements of your web app.
2:25 Starlette is one of the new fancy Asyncio
2:28 very concurrent, friendly type of framework.
2:32 A lot of other frameworks
2:33 are actually based on Starlette, as well.
2:36 We have FastAPI, this is a cool way to build APIs
2:39 and it has it's own API, it's own programming model.
2:43 You have Sanic, which is another one of these
2:44 Async friendly, high speed, high concurrent frameworks.
2:49 You also have Tornado, this is the original
2:51 concurrent framework, it's been around for a long time.
2:54 It's used in a lot of interesting ways, as well.
2:57 This is actually a small sampling
2:59 of the choices you get to pick from.
3:02 Again, spice and variety and life
3:04 and all those amazing things, and yet
3:06 as a newcomer to this ecosystem, I don't think
3:08 this generally comes across as amazing.
3:11 I think it comes across as confusing.
3:13 Alright, well what is the tooling?
3:14 Like if I pick Flask versus FastAPI
3:17 what do I, is there a better IDE to use?
3:20 Is there like a project that I can create
3:22 what libraries are available for?
3:23 All this stuff is, it's quite overwhelming.
3:25 When you compare the two ecosystems, it really comes down to
3:29 with the .NET world you have ASP.NET.
3:31 In the Python ecosystem, you have a ton
3:33 of different open sources options, none of which
3:36 has the major backer of Python itself.
3:39 Like Microsoft or ASP.NET, behind it, right?
3:42 So it's much more of a pick and choose and wild west
3:46 that we're going to talk a little bit
3:47 about how to make some choices here.
3:48 But once you kind of find your way, whatever you pick
3:51 really, there's a lot of good options out there.
3:53 I think you'll be comfortable.