PyCharm is a Python IDE with a long list of Django-specific features. Paul and Aleksei join us to discuss how to get the most out of PyCharm with Django and what upcoming features they are most excited about. For the month of April, PyCharm is being offered for 30% off on the official DjangoProject.com website with all proceeds going to benefit the Django Software Foundation.
This podcast is a labor of love and does not have any ads or sponsors. To support the show, please consider recommending a book from LearnDjango.com, signing up for the free weekly Django News newsletter, or learning more about Button, a simpler deployment story for Django.
Carlton Gibson 0:06
Hi, welcome to another episode of Django chats fortnightly podcast on the Django web framework. I'm Carlton Gibson joined by Will Vincent. Hello Will!
Will Vincent 0:13
Carlton Gibson 0:15
Hello Will. We've got Paul and Alexei from JetBrains. Joining us who's gonna talk everything pi charm, and Django and all such things. Hi, guys. Thanks for coming on.
Paul Everitt 0:23
Aleksei Kniazev 0:25
Hey, thanks for having us.
Carlton Gibson 0:27
Um, thanks for coming on. Let's kick off pi charm, right. JetBrains is one of the big, big sponsors of Django Collins and and begin the Django community. Tell us about Python. What is it? And why should we be using it?
Paul Everitt 0:41
First and foremost, we're an ID integrated development environment. We are not necessarily text editor, we try and take all the things that you do and bring them into one consistent user experience. It's all supported by us so that you have one throat to choke. I can't really say that in a podcast.
Carlton Gibson 1:02
So when it goes wrong, we know who to come until Yes,
Paul Everitt 1:04
exactly. Right. Yeah. And it's funny since the beginning of pi charm once was a long time ago, 10 years ago. It was positioned as the Python and Django ID. So the Django support is mature, it's evolved, it stayed current, because people like Alexei, put a lot of time into thinking about it.
Carlton Gibson 1:30
Okay. And before we just dive into the features, can I ask a bit more about JetBrains comm because I go to the JetBrains site, and I see Python is one of the options there. Like
Will Vincent 1:42
what else does JetBrains do beyond Python is what he's trying to say?
Aleksei Kniazev 1:46
Carlton Gibson 2:07
Okay, so is that we also
Paul Everitt 2:08
have back end services, team city, things like that. And the point that Alexi is making is it's all built on top of this ID platform. It's written in Java, but all the integrations are written with the native language participating. And so what that means is when we have killer get support in the platform, everybody gets it.
Carlton Gibson 2:34
Okay, so you don't need to get client as well. So he said literally, everything he said, he said, it's one throat to choke. That's good.
Will Vincent 2:39
Okay. Well, yeah, well, we want to talk about the Django specific features, but maybe you could just fill out the battery batteries included, because I know you have database support. So for example, like I use Visual Studio Code primarily, but I'm also use PI charm. What are the I know, there's a bunch more that pi charm does like just one of the high points of what you know, beyond an ID that it provides, as opposed to Visual Studio code or or ATM,
Paul Everitt 3:03
Will Vincent 3:58
Well, cuz I know, there's academic licenses, because I think three years ago, I visited a local university that was using my book. And I remember asking them, like, how is the setup? Because I know that's challenging for people. And they all said, well, we're using pi charm, so it wasn't an issue. And that was the first time actually, I was like, Oh, I didn't, I didn't realize the full featured nature of it. I was like, wow, yeah. It's a lot simpler than rolling it out yourself.
Paul Everitt 4:23
Indeed. And you mentioned academic, it's also free for open source as well. And we have kind of startup discounts. You know, we're still a human sized company. And so we kind of act, we treat people the way we'd want to be treated.
Will Vincent 4:38
Yeah, well, and we should mention that so Django has done the last couple years. Annual promotion with JetBrains pi charm that's gonna start in April, which is about when this comes out. And that's the that's the biggest corporate donor to the DSF by far.
Paul Everitt 4:56
Yeah, we're proud of that. That started a good number of years ago. I think. I think it might have started, I think five. Yeah, like right when I joined the company five years, the previous pi charm Product Marketing Manager, Dimitri filippov is the one who started that. And it really has raised a good amount of money. And some things fit people's brains. Some people don't fit people's brains. This seems to fit people's brains.
Will Vincent 5:24
Yeah, I mean, just in terms of specifics, it's generally about a quarter of the DSF budget, so Carlton's one of the fellows that's most of the money goes to Carlton and Mario's who's the other fellow. And it's generally around a quarter. So it's anywhere between 30 to 60,000. a year, the last couple years, so very material.
Paul Everitt 5:42
And just cranking up again, what next month?
Will Vincent 5:45
Yeah, so it's gonna start the month of April, we're working with Roberto.
Carlton Gibson 5:49
Jim, what what's the details of the of the offer? It's like what 2550 was the same as before? So
Will Vincent 5:55
it's 30% off with the proceeds going to the DSF? for the month of April, if you go through the link?
Carlton Gibson 6:03
Paul Everitt 6:06
Yeah. And to be to do the kind of full honesty perspective, how in the heck can you pi charm, give away something for free? Well, we're a subscription. And so we hope to see the upsides in the future years if people are happy with the product, but it is true 100% goes to DSF.
Will Vincent 6:28
Yeah, and that's partly why the DSF has done it, it's the only corporate sponsorship of the type that the DSF does, in part because the DSF exists kind of to exist not to make money. So as long as we cover our costs for hosting, and fellows and conferences, that's, that's the goal of the organization. But anyways, enough about the DSF.
Carlton Gibson 6:47
Let's talk about features that were featured. So can I show you my my sort of top favorite ones from pie chart, my absolute favorite one, which is closely related my second favorite my absolute favorite zones, there's little down the left hand side, there's a little structure button. And if you click it, and up comes this sort of class diagram of all your, you know, your nasty model layout. And it's like, that's fantastic. That's what I've been looking for, for years. And you can move around it and you can, and it's even got a mini map. So you know, when you've got far too many models, and they're all joined up in horrible ways, you can click around the mini map to navigate, that's my favorite feature. My second favorite feature is in the gutter. Down by the side of the editor, you've got this little button about and you click it and it shows you all the subclasses and all the super classes of the class you're dealing with. So I don't know you've got my custom HTTP redirect response, nasty thing and you're like, Oh, wait, I need to see what the base information, you just click that. And it's like, here's all the superclasses you like, that's the one I'm after, when you're there. And that so those are my, that's my favorite, and my second favorite feature of Python. But that's just an opportunity, if you didn't have to spin off 20 minutes and test all your favorite bits.
Aleksei Kniazev 7:57
That's, that's really hard to overestimate the importance of being able to easily navigate all over your code base. We are very proud of how it's actually done by charm. And what I really enjoy is that it can be done not only through your just a Python code, but just navigating to your templates, from your view for to the to the view function from the template and to the variables that were passed to your template. That's one of my favorites, right? So
Carlton Gibson 8:32
if I've, if I've got extends base extends, you know, skeleton extends,
Paul Everitt 8:38
yeah, exactly. And these magic strings and config files or route declarations and things like that, essentially, we've taught the magical Django strings and conventions to be symbols as if they were Python. And once that's done all of our ID machinery kicks in.
Carlton Gibson 9:00
So that's where you get the autocomplete for model options and
Paul Everitt 9:03
and refactor rename and navigation and all that stuff. Find usages, okay.
Aleksei Kniazev 9:10
Yeah, autocomplete is actually a whole whole story in itself, because well, part of it you get from just just the Python code, but due to Django is nature that you can't always have this information from simply Biocon. That's that's where Django specific knowledge gets handy. If you if we know your models, if we read your code and understood it, we can give you like autocomplete for foreign keys, for example, that are not in the in the current model, but might be somewhere somewhere else, and in many cases, the opposite of autocomplete, which is squigglies telling you you got it wrong or you change it and change this and
Will Vincent 9:53
yeah, that's the thing. I mean, sorry. Go ahead, Carlson.
Carlton Gibson 9:55
Well, I was going to ask, and so this is something that's come on over the last How to use it within VS code code Well, with the we've got the pylons extension here, which uses the, the pipe pie right type checker. And how are you able to say, Oh, well, you know, we think we're better in this regard, or we think we're better in that regard. Like, how would I compare the autocomplete from the two processes? Because you've got a lot more like if you've got 10 years of building the thing?
Aleksei Kniazev 10:23
Yeah. It's hard. It's hard to say, for sure. I still think that we're somewhat ahead in this regard. And we try to evolve, of course, and having 10 years of Django support in the either ID it. Sometimes it's, it takes some work, to how to say it better well, to make it work with the new features.
Paul Everitt 10:56
Okay. And we, we adapt and evolve. And in fact, the imminent upcoming about this had basic, yeah, had a basically a full time, pi charm person, Lada she worked on, we think we're great at autocomplete in laws, like, actually. And so like total rethinking of the experience for typing a couple of characters and getting a deeply nested import generated for you, which is pretty bad ass because I hate stopping what I'm doing and going and typing my imports just hate that. But just in general, it's fun to see the rise in smart editors, it's fun to see the rise in Python, providing more information to help smart editor's whether it's fun to see machine learning giving suggestions for you is
Carlton Gibson 11:55
I'm gonna get on my own. I know what,
Paul Everitt 11:59
color me a little skeptical on this one. But the ability to not just give you a list of completions, but a short list of correct completions.
Will Vincent 12:10
I mean, this is the challenge with search. I gave a talk at Django con the last one two years ago on search. And the problem is everyone assumes Google is the baseline. And Google's a pretty high bar. So like, it's like, when people complain about search, I'm like, why don't you try building your own search? And then you'll start to see, you know, exactly, as you said, it's like teeing up the right one is is quite challenging.
Paul Everitt 12:32
But But uh, you know what, when you see it right, back in the day I had, when I was doing CMS stuff I was I converted a customer to use Postgres Full Text indexing. And I thought, this is gonna be great. It's transactional. And they're like, nut sucks. It does search. It just doesn't do it. astonishingly,
Will Vincent 12:52
yeah. Can I ask about? So databases, this is something I've been really impressed by Python, the integration there. So I, and specific, specifically Docker, so like, in one of my books, I use Docker because it is challenging to set up Postgres, in particular, on Mac versus windows, and people get that wrong all the time. Can you talk a little bit more about the database integrations in Python specific to Django?
Aleksei Kniazev 13:17
Well, for database integration, we actually bundle data grip, which is our ad that is specific for databases. And yet, so this is bundled in Python professional together with Django support. And once we have the connection to your database, once we know where it is it sexually. So we can provide you suggestions. For example, for your column names we can highlight to SQL queries and stuff like that,
Paul Everitt 13:46
yeah, it's incredibly powerful. It's pretty astonishing you can be you can be typing a sequel string, or as Alexei said, working on a model, you can navigate to the column, you can sit in your Python code and rename your column, and it will go and actually change your database. You can execute a SQL query right in the middle of your Python and it will open up a panel a console with the query results. And maybe we'll your question was, what can it talk to? It's JDBC. So, you know, most of the most anything that has a JDBC driver, which now includes Mongo DB, we can provide this experience with
Carlton Gibson 14:26
a wonder DD I haven't looked into this bit, but what's the the the sort of integration between generating a query set and then you know, being able to map to the the SQL that you're generating and think about that because that's one of the hard bits where people are like, you know, if I annotate this what do I get? I mean, got secret sauce?
Paul Everitt 14:47
I don't know. Do you mean like watching what the arm is generating kit?
Carlton Gibson 14:51
Yeah. Well, I mean, because you can always you can, you can get queryset explained which was new in I don't know three point yeah. It's one of the hard bits to, you know, when you get into advanced queries, it's one of the bits of people struggle, and you have to spend a bit of time you have to spend a bit of thinking about how do I craft my query set? Exactly. To get the SQL that I'm after?
Will Vincent 15:13
Or content? How do you look at it right now? So outside of pi charm, what's your way? Okay, so
Carlton Gibson 15:17
outside of Python, I get I get in a shell and I go query sir, and I start annotating. Then I go, bam, explain. And I see all I go query query, and I get the generated SQL string. And it's fine.
Will Vincent 15:32
Yeah, it works. But it's not. But that's
Carlton Gibson 15:35
it. It's a bit quantum
Paul Everitt 15:38
Let me ask you a question. Do you think that string that's being generated? Is all the information available? statically from static analysis? Or does it require some kind of runtime thing? I'll bet it is available from static analysis.
Carlton Gibson 15:53
Yeah. Because you like the the SQL compiler is, you know, it doesn't actually hit the database, particularly, it's the parameters that you need. But like, you know, once you've got the model defined, once you start filtering, and you add on the columns, or you add the annotation,
Paul Everitt 16:11
the actual compiling, because I know Alexei, came onto this podcast thinking, you know, I'd really like to add a new to do feature. Wouldn't it be cool if you could do alt Enter, and convert a sequel? Or a query to a sequel string?
Aleksei Kniazev 16:31
Yes, sorry, I'm kind of spaced out on thinking how we can implement this.
Carlton Gibson 16:37
podcast is like, okay, because that's one of my bugbears. Right is it's one of the more difficult bits of Django is when you're crafting these complicated ORM operations, and you've got a nested sub query, and then there's a window expression. And exactly, you know, when I if I, if I add in that rank function, then what's what's it going to start producing, it's like to see that live, that would be, you know, that would really change the game, I think, the sort of be able to iteratively build your query set,
Aleksei Kniazev 17:11
calls your that's a pretty good idea.
Paul Everitt 17:13
Okay, that sounds like a hackathon idea.
We have internal hackathon contests,
Will Vincent 17:20
I think what crowds is getting at is, to me, at least I mean, query sets is sort of, really what you do at an intermediate advanced level in Django, that's really kind of where most of the focus is on is figuring out how to optimize them how to craft them. All the kind of the rest of it, I would say, is not as advanced, or I don't know, that's, that's my take, like, model, you know, models or models, views, templates, URLs, it's a little bit of whatever. But like, the query set is kind of where it's all at. Once you get beyond a prototype, I would say, but I like sweeping generalizations. So
Carlton Gibson 17:54
no, I mean, it's true, right?
Paul Everitt 17:57
Well, we're in the business, or I'm an advocate, Developer Advocate. So I'm definitely in the business of sweeping, falsifiable generalization.
Will Vincent 18:05
There you go.
Paul Everitt 18:07
We certainly as a product, need to understand who we are for who we're not for what parts we have covered, what parts we need to be more competitive at.
Carlton Gibson 18:19
I don't think anyone's doing a good job on the SQL for
Paul Everitt 18:22
sure. And so that could be a good space for us, because it torian and people like you, Carlton, where it's like, okay, the easy stuff is easy. How about giving me some help on the hard stuff?
Will Vincent 18:33
Yeah, I mean, it's kind of, right. There's the the beginners for whom if they have access to Python, which I guess they do if they are student, it's solved, so many problems. And then there's that middle ground, and then there's the Carlton's who are like yeah, these advanced features, I suspect those are the two barbells of where you kind of focus, is that accurate? Indeed. And the Python developer survey that came out recently showed that
Paul Everitt 18:57
there's a question about how long have you been using Python? And the answers were like, I don't know, under six months or years.
Will Vincent 19:04
There are a lot of newer people. Yeah.
Paul Everitt 19:06
Yeah. It's like 150% of the people found Python yesterday. Yeah,
Will Vincent 19:10
I was surprised by that. I was I was sort of it almost made me not discount the results, but realize how many new people there are in the data set. Because there's a lot of other questions about your you know, preferences, a professional, it's, you know, it's whatever the third, new people, you know, we actually that that Python survey, Django did our first survey in years last year, really modeled off of that Python survey. We're gonna do it again, this year. And so actually, if you have any suggestions on what we ask for an IDS, let me know. Because we'd love to because we don't track anything really about Django. So the survey is a way for the, you know, fellows and the technical people to kind of know outside of Django cons and message boards, what we should focus on like to,
Paul Everitt 19:56
let's set up a call and get you with our research team. They can talk about the mistakes they've made over the years with the survey what they've had to change to make it statistically sound, and any other tips that they could give?
Will Vincent 20:09
Okay, that'd be great. Yeah, we can do that offline, because we had we had 1000s of responses. And it was literally a Google Doc, I set out. Yeah. So we could do better.
Paul Everitt 20:18
So I'll ask this question back to Alexei. In regards to kind of that bumbling dumbbell thing that Will was just talking about, in looking forward forward to the rest of your year, when it comes to Django? Do you think your activities will be more about beginners or more about advanced?
Aleksei Kniazev 20:43
It's hard to to really pick a side here, because what I'm planning for the Django. Well, art of what I'm planning is actually aimed more towards beginners, and part of it is, well should be useful for both categories equally, I guess. So we plan to do some work, enhancing the possibility to view Django documentation from inside of it. We already have this possibility. And I really like this feature. But it's, it's kind of obscure, because you have to enable it specifically in settings. And we don't promote it much yet, because there is some work to be done. But when it's finished, I think that it's going to be pretty good. Because we have the ability to go to your class hierarchy or to assemble like in your settings file. And check the documentation that comes straight from the Django documentation website,
Carlton Gibson 21:53
from inside the PI charm. And it doesn't matter where you do it, if you do it for your views, or for a string in your settings file, you should be able to build that locally, right? Because and for the particular version of Django in the in the, in the virtual environment. So I'm running, you know, on this particular project, I'm running 2.2 point, whatever, I got it, yes, I can pull the documentation for 2.2 point, whatever. And I can have that demonstrate what I mean. So I use dash, which is, I think, just an awesome thing. And I have, you know, I have it open all the time for documentation. But one thing it doesn't do is allow me to version by project, right, I've got what is always got the latest one, but sometimes I'm not on the latest one, I need to see it until I have Okay, I've got the website and Okay, it's not the end of the world to have to go to the website, but it's not, you know, right there. And then so if you could pull it locally and built run, you know, run Spanx, and
Aleksei Kniazev 22:48
yeah, so the dream is to have it not only adapted to your version, but to the specific element that you're associated with to save you like, at least some seconds of looking through the through the page. Yeah.
Carlton Gibson 23:01
I mean, yeah, if you if you can index properly and pull out all the those annotations that get your I know, I'm looking at HTTP response. Where where's the docs for that? Yeah. So that's the advanced feature, right? Because, you know, beginners, there's too scared to look at the docs. They don't do that.
Will Vincent 23:18
Yeah, that's kind of Well, that's my thing is that docs and tutorials are different things by design. So there's, they go there to be confused. And then they come to my educational. But I think that is valid, right? I mean, because I've thought a lot about this, like, should I? What is the difference between the two and the differences? Doc's are designed for, you know, Carlton has a question, or I have a question. And we go and see, oh, this is how it's defined, as opposed to a tutorial or a book that says, Let me start from the beginning and go through everything. And that's not what you need, if you're, you know, more advanced, and it's also so much work. For me, it's like, hard enough to do my things, let alone that, you know, the Django, Doc's are 1000s and 1000s. of pages. So there's a place for both, I guess, is where I've come out after a number of years of doing this.
Carlton Gibson 24:04
And so legacy, what was the what was the other thing? What does? she do? Definitely.
Aleksei Kniazev 24:09
Carlton Gibson 25:20
that will be kind of auto completed. But for me,
Aleksei Kniazev 25:25
well, the the resource, the actual address of, of your view view, for example, will be indexed and will be available to you across your project, and maybe even across different projects that you have opened in the same frame. So for example, you have two applications that need to talk to each other. We can, since we already tied your, like templates and Python code to each other, why not tie different applications that are meant to talk to each other?
Paul Everitt 25:58
So like microservices, guys,
Carlton Gibson 26:00
or a cloud server example? Yeah.
Will Vincent 26:05
That's I see amazing to see like a video demonstration of that, because I think I know what you're saying, but I'm sure you have stuff in the works to
Paul Everitt 26:12
I'm exactly like you, I kind of bounced off me until I saw a demo. I'm like, Are you kidding me? How do you know that? How do you know how to complete that? Yeah,
Will Vincent 26:20
I mean, I think I know. Just okay. Yeah. Well, actually, that's, that's great. Carl, I
Carlton Gibson 26:27
was gonna say, what's the timeline? Is that sort of this year, you think?
Aleksei Kniazev 26:31
Well, I'm hoping to finish it this year.
Paul Everitt 26:36
In the platform, from the Java side, it's that eat Not only does each ID he need to wire it up, you got to wired up to swagger open API, are you going to wire it up to Django? Or you got to wired up to, you know, some graph qL thing or something? Okay,
Carlton Gibson 26:53
fantastic. Alexei, is
Paul Everitt 26:55
that right? Yeah.
Carlton Gibson 26:57
So can I can I cut cut bands slightly, because I wanted to talk a little bit about. So from the IDQ developer perspective, talk about some of the features of Python, and then their applications Django, particularly typing right, because Django is really dynamic, by its nature. And it's really hard for us to throw in type hints where you're just going to end up having any all over the place. Because at that point, it's not worth the price. You know, if you've got a nice new thing, it's tight, and it's, you know, you know, exactly the types and type into beautiful, but something like Django is much more difficult. Well, you've avec, but yeah, obviously, those give you more static information, which enables you to make the Id better. So, you know, riff off that. How was the ground? And where would you like to see Django go? And what do you think is possible? And?
Aleksei Kniazev 27:49
Well, that's, that's true that for Django, it's harder because there's so much more so much more dynamic stuff going on, there's your arguments, there are attributes that are not really declared, but added later. So it's really hard to express statically, some some, some of it might not even be expressible statically. But we've got a very good type checker that works off of Python, and then it has the ability for us to, to plug in into that with our specific knowledge of Django and say, like, I see you have this function, you have a filtering function here, probably this is related to this model. Let's have autocomplete here. Let's have keyword arguments here. And it's always easier to do for stuff that is statically expressible. But I understand it's not always the case. And we try to do our best for Django. Where we can, there is this project that is Django stops for Django? Yes. Yeah. Which is, which is pretty, pretty great. And I'm hoping to one day, use it for our own analysis to kind of enhance it. But so far, it's been kind of hard because because of the dynamic nature of Django, and because the subsp project is tied directly to my PI and has its own my pipeline again.
Carlton Gibson 29:28
That was a Google Summer of Code project for Django last last yet. Yeah.
Aleksei Kniazev 29:35
So because some of it is still done dynamically, we kind of have to figure out a way around it on our side. Okay, but I'm still hopeful.
Carlton Gibson 29:48
I mean, there's one example you mentioned that summer, I'm sorry, Coco, Coco, you did.
Paul Everitt 29:53
You mentioned that summer code, if I remember correctly, one of the first motivation For the DSF campaign with PI charm, the fundraiser was the money was going to go partly towards fellows and partly towards the static typing. Work.
Carlton Gibson 30:11
Yeah, no, this was years ago, it still comes up, it comes up. And the main reason it didn't you know, didn't JetBrains Didn't they fund? Yeah, welcome. And it's like, yes, but how is it to be done? But it's hard. It's, you know, a, we have this sort of idea that, hey, there is a chunk of money in theory available if we can do this, but it's just not possible. Well, it's not, it's not that it's just not possible. But it's a massive undertaking. And, you know, maybe it's smuggling some bits in the internals where it's more tightly constrained. And then, you know, slowly, do something. But
Paul Everitt 30:44
Carlton Gibson 32:01
Yeah, I think that's true. I mean, you know, there were some big advocates, you know, code in Python code numbers are very big advocates, but equally the people who are very big in the Python world who are quite vocally, against going too far down the road. I think there's one thing from the pets, which is important, which is that type annotations were always meant to be optional, even by convention, sure, even by convention, and there's a danger that we get to the, you know, sometimes we're maintaining Django, there's pressure to put type annotations in, where it's like, but they're meant to be optional. And you're not feeling that as a maintainer. You're feeling like, no, they're compulsory, and you're falling behind the times by not putting them in, hang on. The Pep say they're optional, even by convention. So I don't know, excuse me,
Paul Everitt 32:49
ask the two of you, as you do these podcasts as you go out and talk watch what's happening and the zite. Guys, the world of Django, is what percentage on board with using my pie adding type annotations?
Carlton Gibson 33:06
Maybe 30? I guess, like,
Paul Everitt 33:10
and I don't mean, the core team, I mean, just in the why I think
Carlton Gibson 33:12
people are sprinkling them in. I think using the using the type checker is not as prevalent as it can be. Because if you're not, what's the point of an annotation, if you're not going to use the type checker? Well, the ID gives you better autocomplete. That's why, you know, I like that, I'll
Will Vincent 33:30
just need it, I
Carlton Gibson 33:32
get the thing. I think people aren't using them too much. But again, you get you get these quite because of the way Django is written, you get these kind of horrible annotations, you know, like I was writing some yesterday to see if I could get to complete to work. So I've got the you know, it was in a PI test fixture, and I was returning factory function from the PI test suite front, and I wanted order completely wasn't giving it to me. So I spent, you know, 10 minutes, 15 minutes writing sanitation. I still didn't get autocomplete. And I was like, but it's horrible. So I'm deleting it.
Will Vincent 34:04
And I don't know why like is nodding i think you know, this this problem with making autocomplete? Yeah,
Carlton Gibson 34:11
absolutely. You know, I programming now. And when I program in Swift, where these things aren't optional, and where you've got an ugly annotation, you create an alias, and then you just use the alias, and then it's slightly prettier. And there are things which I do without thinking these other languages, which I'm kind of reluctant to do in Python. I think I need to just get over that. So I don't know about in general, I think it's coming. Python in general is increasing it but I mean, Django is maybe not the right example because it's got we've got this big history. And indeed and this big like the Cordy LRM. You type chart you try type internet, like sure. It will come with
Will Vincent 34:51
I don't see it as you know, with beginners intermediate. I don't obviously see it as much because they don't feel the need for it. I would echo what Carlton said why Talk to professionals. It's pretty split. Some people are really into it, and some people are very wary of it.
Carlton Gibson 35:07
So it does help you reason about your code. If you take the time to think, what's the type? What's the, what's the type that's being returned here? Oh, well, this is a, this is a callable that takes these parameters and returns this. And in fact, it's, it's got a generic variable, because I'm using it different times. And if I genericized it, I can create one version of this instead of four. And all of a sudden, you've refactor your code, because you spent a little bit of time thinking about the types and it's like, that's a weird, I
Will Vincent 35:33
mean, it's a bit of a religion, you sort of need to have the problem, spend the time come to the solution, and then you're proselytizing for it. But yeah, I don't it's hard to say what percentage of Django people that applies to. Well, so I go ahead, Paul.
Paul Everitt 35:49
No, no, I stomped on your segway there. Go ahead. Well, I
Will Vincent 35:54
was gonna ask for the two of you. So there's so many features in Python for Django? How do you think about prioritizing them? And, and when do you readjust? You know, the top three, top five, right? Because I assume you the first question is, well, what kind of programmer? Are you? Are you a student? Are you professional? So I guess, you know, you keep adding features, but you still can only hit someone with like three to five killer features. What is that process like? Because I imagine that's a challenge.
Aleksei Kniazev 36:25
That's, that is actually a big challenge. But for one thing, we have an open issue tracker. So it's always possible for users that have some have a need for some feature to come to us and say, Hey, I would like to have this. And we always look at what our users want. We talk to people at conferences, we'll try to find out what the workflows are. Try to think about how we can actually enhance it not just by because maybe there is a better way that would be that would include this feature in it, but would actually deliver more. So we have a voting system and our issue tracker. So that's, that's basically it. So we we talk to people, we encourage people to talk to us about what they want, and try to stay up to date with what's going on.
Will Vincent 37:24
And how do you take stuff out? Right? Because you don't want to be sorry, you don't want to sorry to interrupt, you don't want to be AWS with 300 config options, right? And that's always the challenge is you keep adding stuff, it's really hard to take something away. But if you don't, then it's a bloated mess for a new person.
Aleksei Kniazev 37:43
That's true. That's, that's been
Will Vincent 37:47
Aleksei Kniazev 37:50
That's that. I agree. It's been a challenge for us. And I would argue that it's still a challenge in some areas, we still have some support for some things that we would probably prefer to take out. And I hope we would in the near future. We usually when we remove stuff from pi charm, we extract it into a separate plug in and open source it if it wasn't already open source. So let people who Yeah, sorry, people who still would prefer to use it can still do it.
Paul Everitt 38:25
And if I can add to that, about how decisions are made about what to do, before each release cycle, there's a two headed planning meeting one a retrospective to look back at the previous release cycle, and then a planning the upcoming release cycle. And they actually do produce a list of top tickets with votes. And that is an important input to deciding what gets done. But one of the things we're learning is that we have a lot of features. Right could probably go and announce a new feature in 20 21.1. This thing we implemented five years ago. Yeah. And people would probably it would probably you probably could get away with that.
Will Vincent 39:15
So that's what you were saying Alexey. There's like so many hidden killer features. But yeah, only front page. A couple two people.
Aleksei Kniazev 39:21
Paul Everitt 39:22
we're going through a big effort in the company to surface functionality to make it so you don't have to know it's there. It presents itself to you in a subtle, non irritating way. at the right moment.
Will Vincent 39:38
Paul Everitt 39:40
You didn't say Clippy.
Will Vincent 39:44
Yeah, well, Carlton, that's I mean, so you know, dealing with deprecations and stuff. That's something you know, Django and you spend a lot of time on trying to get right. Yeah,
Carlton Gibson 39:52
I mean, you can't just break stuff. I mean, you can't, if you're Django con just as much
Will Vincent 39:59
as you want. Right? At night, you're just like, I'd love to kill this thing.
Carlton Gibson 40:02
They're a bit. Yeah, I take like the whole of Django don't call don't nail I just like, you know, control, delete, and that could be gone and find their own solution. But we can't just we can't take that whole of Django as much as I'd like to. So, okay, that leaves when we maintain it, and we keep it and we make a change, there's a deprecation policy in the deprecation period, and all of those things, if you're a mature product, you've you've got to, you know, you've got to maintain that. I mean, you know, so this has come up in the typing conversation to just cut back there is, we could make the types tighter in Django, you know, it's meant to be a string you get here, we could say, yeah, it should be a string and then drop the or any, but we can't do that. Because there are people relying on the fact that, you know, duck typing works and blah, blah. So okay, that won't change. I guess this same for if I was developing an idea, what would I think? I mean, sometimes I still use an editor. Right. So my other thing that I use is BB edit, though. I have it open all the time. I use it for any number of reasons. But one is, it's, it's just an editor. And sometimes you just want an editor. I don't know. How do you? How do you maximize that kind of efficiencies? Where you've got the features? And if but you're not? You're not like flying a 747?
Will Vincent 41:27
I mean, that's like a mental thing, too. Because I use a simple text editor. I mean, it's sort of like a, you know, a five star chef wants to have a cheeseburger sometimes, right, like, you just need to balance it out. But I think that I mean, with Django thinking about extra features, I mean, we have a very robust third party package system. And that whole process of sometimes things can leave jank, what is the code something recently that made your left okay, but contract for left Django
Carlton Gibson 41:52
form tools was taken out, and there was the doc browser, the other data browser thing that was taken out there, you know, there's no reason why you can't extract a package as a plug in that's a great idea, you know, make it is still available. If people want to use it, they can maintain it, they can help maintain it, they can use it, but you're not forcing it on everybody. So perhaps we could make call mail a third party package that is doing the Mr. Burns now.
Will Vincent 42:26
Yeah, ladies that it is that tension, right. You know, for any project, I think having the important thing is almost having the outlets, so having a way to deal with it instead of just saying no all the time or, or bloating out a project. Because certainly Django, Django itself like Carlton you and Marius, and everyone really tries hard to keep it narrow. Yeah, yeah, he's like, one of the ones I get all the time is, why can't templates do more? Or why can't there be a front end thing? And it's a logical question for a beginner, I think. But it's also, it's already big enough.
Carlton Gibson 42:57
Yeah, we call it we call it maintain at that point. So the other thing we do is we say you want a new feature, build a third party package. And if it gets uptake, then maybe we can bring it into core. So you export features to plugins, you also can, you know, say I think I want my own feature. And you're like, no, we're not adding that. Can I write a plugin for Python?
Aleksei Kniazev 43:17
Yeah, of course, of course. And there are lots of plugins for all IDs for by charm as well. Recently, we had a poetry support added by a third party plugin, okay.
Paul Everitt 43:33
In that case, we worked with the person to add a couple of extension points, or to refine our existing extension points so that poetry can be included.
Carlton Gibson 43:44
Will Vincent 43:46
spring culture is pretty hot. Hot right now, like I get I think the biggest personally, the biggest thing for Django beginners is installing Python and setting up a virtual environment. That isn't right, it's just there's so many ways to do it. There's still a lack of universality. You know, Pip m project has an interesting history. You know, I still use it, but I debated
Paul Everitt 44:11
asking Alexei, what he's been working on for the past six months for HR, what
Will Vincent 44:15
have you been working on?
Aleksei Kniazev 44:16
Oh, my God. Well, I've been trying to refine our whole story about around packaging, because we have a way to install packages from inside by charm that is located in settings like yo interpreter, and the thing is not one in our own team used it to install packages in pie chart. So that's that's a sure sign that something's not going right. So yeah, so we really started rethinking this whole this whole story. So we extracted the support for installing packages into a separate thing we call tall windows like the thing you get for forget on for for your terminal. we extracted it there with the possibility to browse the documentation for it. And we plan to do much more to, to tie it to your environ environment description that like for your requirements dot txt file to your project or whatever you're using so that if you install package via pi charm, you can just not care whether it's properly added into your requirements. Environment description,
Will Vincent 45:38
what should Python do, right? The two of you palling Alexei, you know if you could make the PSF. What's the silver bullet to solve virtual environments? If you just had to pick one, what would you tell them to do?
Paul Everitt 45:52
I would I've been told by lukesh longer that I'm wrong. So I will go ahead and suggest the failure approach. There's that Pep push by khushal das about having a Dunder pi packages, Dunder. That's like node modules. Don't even think of a virtual environment. There's no vert there is no concept of that. And in a tweet, he Lucas explained why I'm wrong that edge cases and backwards compatibility and stuff like that, but my gosh, all these as a developer advocate, all I do is tutorials. Yeah. And they all start with the same thing. Like, here's 50 hours of janitorial work that I wish I didn't have to say, yeah.
Will Vincent 46:44
Well, and the problem is they they Google around, and then they have four different versions of Python, because they download it directly. And then they did homebrew, and this and that, and then their path is messed up. And then I have to explain path, you know, and then they're on Linux, even though they're beginner. And
Paul Everitt 46:59
in his head, like, I've just spent six months dealing I, you know,
Will Vincent 47:03
Paul Everitt 47:32
I agree. And if there was going to be a Python four that had a breakage, and there was only one breakage that could be allowed, this was the one I would break. We don't have to support easy install from 2005, you know, some obscure edge case,
Carlton Gibson 47:51
there needs to be one story, right? It did. I don't, you know, ultimately, it doesn't matter if it's this tool or that tool or the other tool, but there needs to be one story. And everyone needs to be using the same story. And all the tutorials need to have the same thing. And the learn Python book needs to say this is the thing you have to learn. And then for node, it's an npm install, although they've got yarn now, so you know, perhaps it's
Will Vincent 48:16
like sort of, I mean, it's basically the same thing. But I think that's just the case is that, I mean, so I have a site install Python three COMM And I actually own install Python four.com, that gets quite a bit of traffic, because a beginner says, I don't care, I want it to work. And so as soon as we start saying the conversation we just had, we've lost them, right? It's like, okay, just get something working. And then you can learn why it's hard. But it's really probably not hard if you're just starting out.
Paul Everitt 48:43
I'm curious, Aleksei's answer to this question. Yeah, it's
Will Vincent 48:47
like a personal project, like a Greenfield, you know, if you wake up a cup of coffee, new Django project, how do you get things installed?
Aleksei Kniazev 48:56
Honestly, I would just use my charm. I would just give it to do this thing for me. Okay, just just
Carlton Gibson 49:04
what is pi charm? Do does it does it use VM? Or does it does it
Aleksei Kniazev 49:08
I it. So you can, you can select an option to create a virtual environment for you or use the one that you created before it and it would actually remember your choice and use it for your future project, it would remember the location of the for example, dot vnv folder that you suggested and use it for a future project. It would detect that one if you're opening your project with the virtual environment. So yeah, of course, lots of thinking is going into into how we can simplify the Project Setup. we've, we've added recently the possibility to install Python from inside the pie chart. If you're opening Python, you don't have a Python installed. You can do this and it would look virtually the same as setting up your invite You can just hit next several times, and boom, you got a pipe on there.
Carlton Gibson 50:04
And is that is that? Good? I can manage multiple pipes.
Will Vincent 50:09
Within within one project, Carlton,
Carlton Gibson 50:11
no, yeah, okay, so this is my, this is my goal, right and I haven't, you know, it's a basic for debate based project, I'll use VMs. And I just use VM. And you know that that's it, you know, and I'm happy with that and pip install would require on its while now, and I don't want any of these other things because they just, they're more trouble than they're worth right. But then I need to test against Python 3.5, I have 3.6, Python 3.7 Production 3.8 revenue and nine, I need to test doing a 111 one 2.0, you know, I need to test all these different combinations. So I use pi m to get the vault, multiple Python versions in source and then I use tox for to define this nice matrix for all the things I just run tox. And that's about as close as as it can be. But not what I haven't found is a kind of way of handling that smoothly in the development environment. So I want to quickly spin up a Python 3.6 Django 3.0, you know, I want to install that one and toxic in have come up with a dev env flag where you can use it to you can say use this environment, create a development environment, it's close. But it's still not perfect. And that will be somewhere where I would expect an IDA to step up and say, Look, I can manage this matrix and I can help you create all the different ones and I can activate this one and I can be 100 you can be 100% clear of which one on the matrix is activated. Now that's where I think an ID you would pay value over a text, you know where the text is not gonna do that because out of bounds, but that's the sort of extra feature that I'm thinking, Oh, this Python do that? Because if it does, then it's you know, really? I mean, I don't know, necessarily. Yeah. But that's what that's my sort of Holy Grail that I haven't found. And, you know, pigpen had different had a dev thing, but it just wasn't enough. It wasn't flexible enough. It was, you know,
Aleksei Kniazev 52:03
yeah. So the thing is, it's, it's hard to both maintain several environments, and have a consistent development environment set up. So for example, if you're there for sure, there's a possibility to have several interpreters set up for your project, you can easily switch between different ones that no problem about that. But what if your requirements pile is not the same as the state of this interpreter? Should we just do install it everywhere? There won't mess up something something in your network? So yeah, it's, it's really hard question. It's the one that we're constantly asking. And I think we've tried to bridge this gap. What you describe is a is a very good case where we're thinking about it. And I think we'll continue to do small steps in that direction. I'm hoping we arrived there. Well, let
Carlton Gibson 53:03
me just give you one more nugget. And then I'll leave it with you to ponder on over the next 686 1218 months. But the the one more thing I want is okay, this is all going great. And I've got my environment set up and all rest. But now I've got a really hard problem to debark. And I want to install various extra debugging tools that I just want to use for now. Right? I don't want them in the virtual environment all the time. But I, you know, I really need to solve this problem now. So pip install this pip install app, store the other fix my debugging problem, but then my virtual environments nuked and I have to rebuild it, and in which version, which, you know, so the ability to layer on a sort of extra layer of debug tools just for the moment, that would be a kind of, like cherry on the top. Anyway, I'll leave that with you to ponder because that's these are the things I end up struggling with.
Aleksei Kniazev 53:49
That's, that's the thing that I'm actually working on at the moment. The one I talked about the whole story around packaging. I'll, I'll add it to the list. Oh, sure.
Paul Everitt 54:00
Now, it's interesting, both of the things, Carl to mention, there's a lot of I don't want to say term, because that would be negative. It's actually positive turn in Pep land, about solving individual parts of the problem. They learn their lesson 10 years ago, when they tried to do some big bang effort, and it got rejected. I don't remember any peps about either one of these two problems.
Carlton Gibson 54:27
it? I think yeah, I mean, there is there is a lot of change now. I mean, so I think pi project.com has just sort of finally been given the, the blessing that's going to be the way forward and a couple of years, it's been like, well, do we need to add this to Django? Is this where it is? I mean, we just had set up config. We moved all the stuff from self to pi config. And now we're going to move it to pi project that Tom will is that going to be permanent or that will be burned. Now,
Paul Everitt 55:00
I hope and like bright cannons doing a lot of work on peps to take really tiny, allegedly non controversial things. Get them encoded into that universe. And then everyone complains. Yeah, no poor Brett.
Will Vincent 55:16
I find, yeah, it's thankless work
Carlton Gibson 55:18
plots in such a nice community. And yet, every, every time the pie ideas and putting ideas in the world, it's really quite brutal. And yeah, I stay clear of it for this reason.
Will Vincent 55:32
So are there any any last points you want to either of you make that we haven't touched upon as we wrap things up? I mean, we were so people listening who say, oh, I've got a great idea. I agree with that, I guess we can put a link to the issue tracker for pi charm is that the best way to, to reach out to either of you?
Aleksei Kniazev 55:49
Yeah, of course, goes by issue tracker creates an issue or a vote on if it already exists, leave us a comment, describe your use case, the more information we have, the more thing we can provide.
Will Vincent 56:03
And there's a jacket, and we'll have a link obviously. Sorry, go ahead.
Carlton Gibson 56:05
I was gonna say there's a generous trial period and whatnot. Because I for ages, I looked at the PI charm website a few times, I was actually I download this, and then I was a bit scared by the form. And then I click the Download button, it was quite easy. And they just booted up wasn't a problem. You know?
Will Vincent 56:22
I mean, it's almost, you know, too easy. Because when I like when I teach people, it's so tempting just be like, well just use PI charm, and all these things are solved. But because not everyone uses it, I have to kind of go the the raw way. But certainly I think that's starting to change. And certainly for students, you know, when I go into universities, it's overwhelmingly Python over anything else, in part because, you know, they can use it for free, but because it does have all these features, and then, you know, sometimes I'm not as familiar with all the power features. So I have to sit there and go, Wow, I didn't know that. Like, that's pretty nice. So it's educational.
Aleksei Kniazev 57:04
I do this all the time. I do this all the time, because we have so many features that we constantly discover new ones.
Paul Everitt 57:13
Yeah. And I manage the help manage the Twitter. And so I see someone pointing a tip out to someone else, and they say pi charm. So it gets in our inbox. And I'm like, Oh, really? I
Will Vincent 57:23
Paul Everitt 57:25
How can I not know that? It's my job.
Will Vincent 57:27
Same thing happens to me with Django. You know, people say, Well, of course, you must know this, because you wrote books on it. But, you know, I just discovered this thing. And like yesterday, what happened? I was like, Well, I didn't know that about Django. You know,
Paul Everitt 57:39
people talk about imposter syndrome. I get paid to like, be an expert for pi charm. And I know, maybe 2% of my charm. And I wake up each day and it changes another 1%. So, talk to me about imposter syndrome. My imposter syndrome can beat up your imposter syndrome.
Will Vincent 57:59
Well, you know, Carlton shouldn't have any. But you know, for me, conquering imposter syndrome is when you get to a point where people ask you questions, and you like, I don't know, and then nobody knows. And so it's just knowing, being comfortable not knowing but having the confidence to say, Well, I could share it out. I think it comes about when you are a beginner and you don't know and you feel like you can't figure it out. So when you've ingrained that process of googling, and you have enough context, to use the Django Doc's completely, I think that's when you overcome it. But when you feel like you hit a roadblock, that's where the imposter syndrome smacks people I think.
Carlton Gibson 58:37
Think You're right. But I think it applies at every level. Because, you know, I'm, you know, I work on Django all day. And you know, I have the codebase, open all day. And, yeah, I'll go to an issue on the issue track, and it'll be some nasty in the depths of the ORM. And there'll be two or three of the major or RAM contributors there. And I'll just be like, Oh, I'm not hanging out in this club. This is too hot.
Will Vincent 59:01
You know, but that's my point. When people start when people start asking you questions, and you're like, I don't know, you know, that's when you're like, well, I guess I'm at the level of an expert, because nobody knows. I'm no.
Carlton Gibson 59:13
I think it's easy to feel intimidated in any any level that you are and that you don't have, you don't have the knowledge that it's like, oh, well, but you know, if push comes to shove, okay, I can get in there and I can get my hands dirty, as well. But that that feeling of doubt still lingers that feeling of like
Will Vincent 59:34
Yeah, well, hopefully that's something we do with the podcast is having people on who are experts, and everyone says the same thing. So people listening know that this is just what it feels like, you know, it's like we just get comfortable with feeling stupid. It almost you know, it's like I almost get bored. Now if I know how to do something. I'm like, shouldn't this be a little harder? You know, because the muscle is so built up. Anyways, well, we'll have links to everything. Obviously Go down, download pi charm in April, check out the Django project site for the free trial that benefits the DSF. And yeah, thank you both for coming on and sharing about Python. Really exciting.
Paul Everitt 1:00:11
Thanks for having us. Thanks.
Will Vincent 1:00:13
All right, we are at chat Django on Twitter and Django chat calm. We'll see everyone next time. Join us next time.