Keynote: Guido Van Rossum

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments

I would like to see Guido (and other community leaders for that matter) cheerlead more for Python 3. When Guido talked about Py3, he said things like,

  • "Python 3 is doing fine"
  • "light at the end of the tunnel",
  • use Python 2.6 as a stepping stone, and
  • "it is actually fairly reasonable to consider writing code in Python 2.6 that will also work in Python 3.3"

I think what would get the community as a whole moving much more quickly to Python 3 would be: every time the topic comes up, talk up all the great improvements to Python 3 over Python 2.

👍︎︎ 3 👤︎︎ u/gradations 📅︎︎ Mar 21 2012 🗫︎ replies

The most interesting thing about this talk was the mention of Python on Android. Apparently, there are no technical barriers to adding a Python wrapper around the NDK (Native Development Kit).

👍︎︎ 6 👤︎︎ u/timClicks 📅︎︎ Mar 21 2012 🗫︎ replies
Captions
not gonna announce me or anything and now the inimitable and now the enroll fantastic super power laiden guido van rossum Thank You Jessie well it seems you don't hate these events as much as I do I'm also very very flattered that everybody actually turned their clock forward so they would be able to attend now let's see how we control this computer thank you Python Software Foundation oh my gosh did I have some kind of automatic okay we're going to have to debug this does anyone know how that works there you go I was using arrow keys okay don't hit play well I don't know which button is play but apparently it's the spacebar Wow okay well thank you everyone for helping me out with this great technical difficulty I wanted to show a picture that that just sort of touched my heart there's this woman in Japan her name is Yuko Honda and she's a bit of a geek and a bit of a geek fan and a bit of an artist and she somehow decided that he wanted to give back to open source by drawing open source logos in her lattes and he even sent me a little video that I'm not sure I can share I have to ask with her ask her first how she makes them she draws with like stirs and a tiny sticks whether they called in the latte until it is like an exact copy of the logo so she did a PSF logo at some point and I liked that so much that I thought to show it to everyone and her her wonderful artwork and as sort of to give me the opportunity to thank the PSF for once again being sort of the force behind this amazing conference okay let's see what happens if I hit an arrow key because I actually did prepare some kind of topic I'd like to talk about and here we don't we don't see this so much everybody here comes up to me and they say I love Python Python is so great I love metaclasses oh I'm so glad that Python 3 is coming out but if you go back out there in the real world you might encounter some people who have less friendly things to say about Python and without too much generalization a a fair number of those I consider trolls so what exactly is a troll you've encountered trolls before a troll is a question that is not really meant as a question but it's just sort of trying to make you uncomfortable or start a flame war without a way out troll is also a person who asks questions like that and when I see a troll I usually just turn around and ignore them but that you don't always have the opportunity when someone shakes my hand and then starts trolling then I'll have to give an answer so I've thought about sort of a number of questions that trolls have asked and things that trolls have said about Python over the years and I'm just going to use those as one one way to to sort of speak out what I think is important in Python and at some point I'll probably forget about the trolls because it's really just a sort of an umbrella topic so it used to be that one of the most common trolls you heard about Python was oh you can't be serious with the white space by the white space for indentation is such a stupid thing I don't actually hear that very much anymore the thing is when when people complain divide the white space we sort of after a while as a community we developed a standard answer which was you must not have tried it yet there aren't too many people left left who haven't tried it yet so I think that's why that troll has has gone away or at least people who still haven't tried it know people who have tried it and so they they realize wonderful modern technology well at least I still remember my password so let's let's talk about some some other trolls that we hear Python sucks in general my language is better than Python it could be because it has static typing or because it has an event loop I think that is mostly old we do the same thing we go oh python is so much cleaner than Ruby or Perl if you really think about it if you look at it from 10 kilometers above Python and Ruby and Perl are exactly the same language the language is that certif are fundamentally different our languages like Java which comes from a completely different tradition has a completely different philosophy and a completely different way of running its community too by the way because also if you look at the Ruby community or the Perl community they're organized in a similar way as we are they should be our friends C++ is another language that is really different from Python Lisp on the other hand is a language that is not all that different from Python even though you may not notice it because it looks so different but it actually does very many of the same things so don't get cooled into language comparisons and sort of be proud of your language but don't diss another language and don't worry that this other language which suddenly all your friends are talking about everybody is learning Ruby on Rails well in in the world as a whole there's room for all of them and it's not actually the case that Ruby is Ruby is kicking pythons butt in any particular place so don't worry be happy' look at how many people there are here who will come back next year I don't know what we're going to do with the newbies next year because this pace won't be big enough but don't get pulled into it Python 3 so people ask when will you admit Python three was a mistake when will we finally get see a pie from 2.8 release why don't we just add all the features that we deleted from Python 3 back so that we can write code that works in both code bases well I want to take a pragmatic point of view there because we we did actually add one feature back if you saw Benjamin Peterson's lightning talk yesterday about why Python fleet of three is going to be awesome we put unicode literals back into Python Python 3 purely as a backwards compatibility hack they have no meaning they mean this is the exact same thing as regular strings but it means that a certain style of working with code that has a single code base that works in both cases here we go again really apologize I should have used a real presentation tool instead of Google Docs and preview it was very quick to produce but it sort of the presentation mechanics are horrible - three is doing fine I hear buzz from people everywhere who are seriously thinking about moving to Python 3 I was talking on the exhibit floor - an engineer of a company that has a lot of Python not only do they use Python on their servers but they also ship an entire Python distribution to their clients and you are all clients of that company by the way probably they are considering Python 3 as just a logical next step after Python - 7 and they can do it and they will do it numpy is being ported to Python 3 more and more projects see the advantages of maintaining Python 3 port and more and more knowledge becomes available about what is the best strategy or how to use each of the possible strategies for porting Python from Python 2 to Python 3 of course using Python 2 6 or 2 7 as a stepping-stone is a very good strategy but sort of when we started the Python 3 adventure three and a half years ago I thought that the intersection between the two the two versions of the languages would be too small to work with a single codebase people have proved me wrong with libraries like 6 and a few tweaks like the Unicode literals it is actually fairly reasonable to consider writing code in Python to 6 that will also work in Python 3 3 make so we knew it was going to take a long time we knew it was going to be painful but there is light at the end of the tunnel and as as I said at some point foolishly during a panel in the web meeting before the conference at some point we'll look back to these days and we'll will realize do you remember when we had to keep our code backwards compatibility with Python - that was that was tough I think I said that was help from from from where you are now it may look like hell but from what from five years in the future it will look like ok we dealt with that we did that we got out of it we got over it and now we can all use use Python 3 happily ever after that will happen don't worry it will happen and sort of better tools and techniques are being made available and more ports of more dependencies in everybody's dependency graph will be available so the excuse I'm waiting for package X to be ported will be less and less valid sort of it is a game of chicken but somebody is going to jump ok let's see what's next bye-bye another very leading question given that pi PI is so much faster than C Python when will pi PI become the reference implementation why are you still putting all this effort in C Python well how many of you are using pi PI in production do I see hands somewhere how many are using cpython in production no hands okay well that's that's so there's still hope by pi is a great project they move from milestone to milestone their next milestone is Python 3 compatibility other milestones they are working on have to do with better support for extensions but it's really difficult to break into an ecosystem where not everybody is writing pure Python code but where people are also writing Python extensions depending on those extensions wanting those extensions to run really fast and sort of linking all kinds of crazy things together and see python as as they easily actually yesterday morning also argued see python is a great glue system that links all those diverse pieces together if you've written something in Fortran you can link to it from Python using a shared library and an extension if you have a large numerical library for which for some reason you only have a binary you can still link it with with C Python those are sort of features that are not so much features of the language but features of the implementation that we're very carefully built into the implementation type I is working on making it situation better and I should let them speak for themselves but people asked my opinion and my observation is that they still have a long way to go and speed is not everything yes if you if you have a sort of a clean simple program that you run all the time and you can make that program tenth times faster just by switching Python interpreters great but in the real world a system is incredibly complex and that little piece of code that will now run ten times faster is surrounded by lots of code that does i/o it talks to databases it's waiting for web services and those things don't suddenly move faster because they're always already waiting for other things to happen at the speed as that they happen and so in a large system you won't actually see that much of a speed-up it's only some sort of some smaller parts where you see the speed-up that the pie pie shows in its benchmark I mean that's why they're benchmarks to show off that there is a speed-up so it's it's sort of it's a tough job to to compete with with the existing 800-pound gorilla in the field which which still is cpython I don't know what what to recommend I don't know what to say I think 5pi needs to be tinkered with like David was was recommending I think pi PI can can improve and it will improve and the people working on it are incredibly smart and they are they're working hard on many different things that that sort of will resolve all these issues and so at some point somebody will find an actual real use for a pi PI application where it really matters and it could be that if if you are shipping a currently a Python installation to your clients to do some particular thing in the background of their their computer that switching to pi PI once it once it is possible actually helps you tremendously and makes makes your system faster it could also mean that it makes your system smaller if you don't have to to ship source code and byte code but just the compiled binaries that come out of pipe I I see I see many exciting possibilities there but they also see years and years and years of Phi Phi and cpython living together as alternate python implementations that support the same language but that sort of live in different ecosystems in different contexts and the choice of pi PI versus C Python is not just based on do I need speed or not but on a much more complex set of of requirements where sometimes pi PI wins and sometimes C Python wins and in the meantime I'm going to to sort of encourage the Python dev community the core Python developers to make C Python better and to keep C Python sort of as the reference implementation upon which other implementations may want to improve in terms of quality of implementation or speed or whatever but C Python will still be around for everybody's use in enjoyment oops did the play thing again dynamic typing a lot of people and I some people here probably but here I died nobody really has brought this up much to me but a lot of people who don't want to use Python bring up the argument that a dynamically typed language is just not safe and they bring up things like well the compiler doesn't detect the simplest errors so I have no I have no guarantee that if my program compiles that and if it starts to run that it won't run into some crazy name error or attribute error or type error much later during some critical run to which my answer is I am I am just a clumsiest keynote speaker you got you guys you've not invited me back can someone help me with it I missed with it sorry all right well let's try that again now I forgot my password okay there we are again the type checking in in compilers is actually very weak yes it can tell you that you shouldn't be putting an integer into a string field or something like that but does it tell you that you're mixing inches and feet or inches and centimeters does it check you tell you that it's possible that a certain variable could be known that you should bet you check for that before just using it know if you trust your compiler to find all the bugs in your program you have not been doing software development for very long so yes there are certain errors that will only be found out at run time that is a part of software it is just as possible that the error is in some other piece of code that you interact with programmers are human we we all make mistakes and the mistakes are sometimes trivial like miss typing the name of a variable and sometimes very deep like not understanding the physics involved in a certain process or the mathematics involved in a certain operation so the only way to come up with software that isn't going to fail after running for four hours seemingly fully is to test it and test it again and think about it and audit it and hire smart people and hire people who know that they're not as smart as they could be so they're not too cocky because if you hire someone who thinks they're incredibly smart they may believe that they don't need to test so work with a team with different capabilities work together help each other look look at your code think about your code how can I make this better and don't get focused on this this very narrow set of of things that a type-checking compiler can find and instead look look at sort of errors in your code as a much wider problem that collectively nobody in software engineering has solved no matter what they tell you the people who do formal proof of correctness know that there also were not actually proving anything relevant to practical software development I know my operating system kernel will never be proven correct so I really don't understand why people are so hung up about that one thing of dynamic typing it is incredibly important and useful in many ways another observation is that in a large program written in a statically typed language at some point they invent a sub language or a sub system that is effectively dynamically typed where they have some class that has a bunch of properties and there are ways of sub classing that class or defining other instances or classes and it's all done through string manipulation in the language and so now the the compiler that does the type checking sees that your well you're passing a string here and you're getting a string back and that's really all you're doing you have these coupled very generic methods and a whole bunch of objects and underneath you've built a whole interpreted language that is custom customized for some particular problem where a dynamic language was actually a better solution so why not write the thing in using an actual dynamic language in the first place so you don't have to put so many string quotes around your identifiers so anyway I'm not saying that there is no room for static typing I am saying that dynamic typing is not something that certif is inherently inferior to static typing one one of the interesting developments recently is actually that you'll see you'll see people from the static typing camp try to design languages that sort of meet the dynamic typing population halfway statically typed languages that start growing little corners of the language where they're not so statically typed invoke dynamic in the JVM the dynamic type in c-sharp optional typing in the dart language that was developed by a bunch of Googlers I find it an interesting development that dynamic type languages have apparently become so mature and popular that the static statically typed language proponents are feeling a little uncomfortable and are designing new languages just to reel all you in and sort of see if you can become customers of their their new languages because that they're now also offering dynamic dynamic features so watch out for that use the original okay speed yep this this is something like everybody seems to have a different opinion some people still reject Phi from outright because it is too slow and they seem to have some proof of that that I'm not aware of because every time I try to write something in Python it's fast enough and I know a lot of you have that experience too and many other languages where execution is not too slow development is too slow so that's one reason why you all use dynamic languages mercurial all written in Python blindingly fast distributed version control system my favorite nobody would consider rewriting that in other language because it's not fast enough because it is absolutely fast enough I've heard of Java programs being replaced by Python programs nobody cared that the Java was supposedly to run so much faster if you don't do it right it won't actually make a difference another question I get a lot from newbie circles is Python is so slow but couldn't you just write a compiler that compiles it instead of interpreting it and then the compiler the compiled code would automatically be faster well that is an interesting research project that some very smart people are still working at turns out it's not so easy to write a compiler that maintains that all the nice dynamic typing properties and also maintain semantic correctness of your program so that it actually does the same thing no matter what kind of weirdness you do somewhere under under the covers and actually runs any faster I expected at some point when computers are faster global type analysis globe Global static analysis of Python programs will be realistic one way that's that that we might see that is that you could put an annotation at the top of your module that says there are certain insanely dynamic crazy semantics that Python makes possible that I promise I will not you try to use inside this module then here we go again then a static type in our analyzer can sort of make a bunch of assumptions and do a much better job at analyzing that code and maybe optimizing it or translating it to a more aesthetically typed language our Python folks the sort of the pipeline folks with there are Python language are doing some of that except they're not really declaring that that that the static analysis is possible they're just sort of doing it and if it fails they say that wasn't our Python I think that's a better approach for for real-world regular regular Python programs would be do a static analysis with some assumptions that certain crazy things like modifying the addictive Global's behind your back or modifying the dick of a class or an instance behind your back with those assumptions and maybe knowing what is in other modules you may you may you have to pretty much know all the modules that are part of the program before you can do a decent job of analysis such analysis currently takes a long time not something you would want to wait for if you're just running a script so it's it's not very practical yet the only time it might be practical is if you if you sort of want to compile a large Python program and then ship it off to a whole bunch of servers where it's going to run we're not quite there yet where we have technology like that but I think technology like that is possible without great compromises or changes to the Python language maybe we'll have to sort of be able to make assumptions like nobody is going to redefine the built-in functions to mean the opposite of what what they currently mean where the code says true and the compiler can tell that it's not a global but two built in true we know that true is true and not false little assumptions like that I think will help static analysis quite a bit so I'm hoping that there are some people with some extra brain cells that are feeling kind of antsy who think that static analysis is an interesting project and I hope that maybe next year we'll see presentations about this and I would I will always entertain small changes to the language too if if it's really clear that one particular feature gets in the way of static analysis then we might want to have a weight of of turning that feature off selectively in cases where you care about static analysis and in other cases where you're happy with the dynamic language where you're using it more sort of exploratory or experimentally or as a scripting language you can still go carry out all the crazy hacks that you like but we all know that too many crazy hacks in one program leads to a maintainable code ok another favorite object of attackers is the jail the jail has been assertive it has become everybody's scary beast it seems and and and parents warned our children don't use Python because of the gill eye I recently answered a question from a user who was fetching the contents of two different URLs in two different threads and he was worried that those two URL fetches wouldn't overlap because of the jail the jail said one threat at the time could run so he thought that only one thread at a time could be engaged in IO across the internet that that sort of that made me so sad that the jail has become this completely out of proportion caricature of what it really is which is a little hack to make the common case of interaction between Python code and C code much faster and cleaner and safer and well because of this some people say we don't have real threads which I would thoroughly disagree with Python has totally real threads and if you use them for what threads were originally meant for os-level threads are meant for doing parallel i/o not for doing parallel computation it's just sort of easier to not make that distinction to to complete and allow some parallel computation but traditionally parallel computation meant that the computation with the CPU would just sort of do a bunch of work for this thread and a bunch of work for that thread never again but that certif if you really want to to run something on lots of CPUs you're going to have to have a different architecture there are people who are running Python on machines with 64,000 CPUs ironically their problem is not that the jail because of course they don't have the jail because it's a separate process on each each core their problem is some locking in their file system because these these happen to be diskless computers so they have a distributed file system and the distributed file system then didn't deal well with the default module lookup approach in Python the bug was in their file system not in Python so I I think that Python is a totally fine language for a multi-core computer there are a number of very simple strategies for for dealing with that message passing between multiple processes for example using the multi processing module or some other approach of sharding sharding request handling between multiple CPUs is just fine and don't don't don't get so hung up on this gel and don't believe it when people say oh but Dave Beasley found the counter-argument he thought he found the counter example where only two threads and only only writing a thousand bytes it was a million times slower yes that but you have to be David Beasley to to be able to come up with that counter example so what else related topic asynchronous i/o concurrency stackless event loop G event all kinds of very interesting alternate primitives for dealing with concurrency I love the problem the problem I don't have a good solution I'm going to say well that if a troll texts me over this I have is I have a specific answer for each of the questions but I don't have a real answer for what what is your strategy going forward about asynchronous events I unfortunately for the asynchronous events I live in this bubble where I don't have to deal with them in the way that many of you try are trying to deal with them it seems to me that G events and things based on G event are very interesting and useful tools I am hesitant to add them to the standard library at this point because they're probably better off being maintained by a third party stackless again is something that would have to be part of the language definition which i think would make the implementers of some other versions of Python like JSON and ironpython and possibly pipe I although I don't know what their position would be but it would make other implementations of Python much more complicated or even impossible an event loop depending on what what your daily job is or what what what your code is doing an event loop may or may not be useful I mean some people come to me and say everything I do involves an event loop why is there no standard event loop in Python well because not everything that everybody does involves any Loup they're sort of you can make an event loop the primary mechanism for synchronization in your language and you can probably get away with that but it it is sort of it is a point of philosophy in language design is not just something that you you add on and and then then all your problems are solved you sort of you can do things with an event loop in certain ways that are sometimes advantageous and sometimes make no sense I'm personally not a fan of anything that requires me to write a called callback function whenever I see a callback I know that I'm going to get it wrong so I like other approaches so in that sense I would probably prefer the the library packages that are built on top of G's and if I understand the architecture correctly that lets you write synchronous looking code that under the hood does something asynchronously without invoking operating system threads but I think that there are different approaches to this and I think it's too soon to to sort of pick a winner and say we're going to put that in the standard library we're going to integrate that in the language and this is how everybody is going to have to do it from now on because I know there are many different approaches and I think sort of advanced synchronization primitives like channels or mesh and message passing or actors keep being brought up all those things are interesting and deserve more attention and again if you have some spare cycles look into them learn about them see if you can integrate them in Python see if you can design a variant of Python that integrates those things but sir we'll have to have a whole bunch of draft designs like that and be able to compare them before we'll actually have a good idea of what what we should really do with Python for say we we might want to make Python for the the new target language for that that solves that concurrent programming synchronization problem so think about it that's it's it's definitely an interesting problem I don't don't have a solution myself at the moment oh yeah here's here's an old question why don't you put Python in the browser it would be so much better than JavaScript yes and you couldn't get anyone to use it unless until all browsers supported it and the browser's won't support it because there's nobody asking for it because nobody would want to use it introducing a new language to replace JavaScript is just such an incredibly hard political problem the biggest browser vendors in the world have not been able to solve that they've sort of all listened to me and and said sorry we're going to stick with JavaScript because that's the only thing that that has a chance of moving forward so don't ask me to to lean on any browser vendors I might know it's similar for mobile why aren't we all programming our phones in Android as in Python or at least the Android phones well I wish I I could I if it was possible I would probably write some Android programs occasionally which so far have not tried to do I did at some point get involved with some other Googlers who were trying to make just as possible and we were told that it was strategically not important and we were not we were asked not to work on it anymore what I learned then was that there is absolutely nothing technologically stopping anyone else from doing this there are enough tools that given just the public documentation for how Android work works and how to interface to it and things like there is a native development kit that game developers like to use so that they can write their games in C++ or whatever they use machine language for all I care that lets you run arbitrary programs and so you can just link a Python binary in with your application and then the trick becomes taking taking some kind of formal description of the entire API and compiling it into a set of Python classes that interface to the real API and I'm sure it can be done and I hope someone else will do it because I'm not going to be able to do it oh yeah functional programming I love functional programming languages I don't think that Python is a functional programming language despite having lambda and map and filter that doesn't make a language of functional programming language it's it's an old argument I really don't want to get into the reduce thing that that was answered years ago but it still comes up that every once in a while I get an email in my inbox from some random Python user who is very upset that I killed killed reduce or sort of passive-aggressive comments in a G+ plus post about Python where someone just out of the blue says we want to reduce back it seems so miss misguided Python is not a functional language for a very good reason Python is very pragmatic it lets you mess around with state it lets you fiddle with the operating system there are all kinds of things that you can very easily do in Python that somehow are incredibly hard in in a beautiful language like Haskell Haskell is great when you cert if you you follow all the examples you you see all these incredibly beautiful little diamonds of code that functionally translate one piece of data into another piece of data but when you try to actually accomplish something like copy a file system or a writer web server all the messy code becomes much Messier and there isn't an easy sort of clean functional part in there that that's where the functional language helps you so much what you can do is learn a functional language get excited about some of the functional features some of the functional ideas and when you're writing Python when you see an opportunity for writing something in a functional style use a functional style don't get hung up about doing everything in a functional style are doing everything with higher-order functions or emulating you could go overboard and add a whole bunch of new built-ins or new utility functions that emulate all the haskell utility functions and then write lambdas and glue it all together and you can say wow I can write Haskell in Python and it will probably run incredibly slow because it's not actually a functional language and it's still interpreted in the way that Python does it on the other hand if you have a thunk if you have a problem and some of some part of the problem involves taking a bunch of data and doing something with it it can sometimes be very useful to to think about that oh yeah how would I do this in Haskell oh yeah I can I can sort of create the same program structure in Python and so you can use some functional conventions in some part of your program just fine and then when it comes to actually writing the data to the file system or copying the directory tree or invoking a compiler or anything like that you don't have to to worry about oh but how do we do that in a functional style because that's not a particularly functional operation and so you just use it in an imperative or an object-oriented style so I like functional programming as a challenge and as sort of a fresh idea and I think it will will inform some future features of some future languages I don't expect that 30 years from now we'll all be writing purely functional code all the time it's just it's not just the only solution we need ok the standard library there is there are still people who believe that there a killer clever bit of code has not had sufficient respect until it's being included in the standard library as a standard module don't do that don't worry about that you you're much better off not being in the standard library once you're in the standard library you have you are stuck with the release schedule if you made a mistake in your API design you can never fix it you're stuck with a broken API forever for backwards compatibility reasons essentially forever if you have a cool idea for a new feature you'll have to wait a year and a half or two years before you can put it in the next Python version and of course then you have to convince all your users to upgrade to that next Python version before they can benefit from the new feature on the other hand if you use if you develop your clever bit of code as a third party package and you distributed through pi PI there's nothing stopping you from releasing a new version every day or every week or you can you can be more systematic about it and have sort of a development team and release us and you can do new releases every few months and you can do alphas and betas in between but you can adjust your development schedule to sort of the speed of the world around you if you're hacking on something new you probably are going to throw all of it away after sort of writing the first prototype and playing with it for a day or a week if you've got an established project maybe Django you're going to be very conservative in deleting old features except when it comes to security I hope but you're going to still aggressively add new functionality and if you own your own release cycle you can add new functionality every time you do a new release every month if you want to as long as you have active users and insertive active developers it's unlikely that your users will want to sort of stick with the same functionality for two years and every new feature idea will just go in the tracker and yeah we can add that in the next release which is in 2014 there are very few situations where where that sort of is an acceptable development approach now so what what are good things to put in a standard library it's things that enable everything else decorators with statements well okay they've got their language features but there are things in the standard library that sort of support everything if we had a new context manager that would sort of help you solve a certain problem that context manager sounds like a context manager that's sort of not the context manager that that sort of deals with web requests and the SSL security or whatever that would be something that was third-party by the web if you had a context manager that solved some problem where if I have two classes that want to cooperate I want them to interact in a certain way that's the kind of thing that goes in the standard library we have things go in the standard library one example is an IP address parsing and manipulation library that was actually pretty contentious API design but in the end once we settled on agreement on a particular API the format of an IP address is not going to change again after ipv6 so as long as you support ipv4 and ipv6 that's a good module to have in the standard library because it's write-once and then the functionality is there and it's it's usable for everyone there's no point in different people having to reinvent that that wheel over and over but they're assertive there are many many areas where if you if you look at how often new features make sense and sort of are suggested you really don't want to tie yourself to the development cycle of the standard library let's see I have no idea where we are timewise okay well garbage collection I believe that there is nothing wrong in principle with reference counting Python has gotten a long way with reference counting we also have some other garbage collector so python actually does have garbage collection although many people don't realize that still yes there are better ways of doing this and a pie pie is probably the place to experiment with that our memory allocators I am personally quite happy with how fast by from the C pythons the memory allocator works so I would really think that this is not a very interesting topic and my computer seems to disagree but it does come up and just sort of remember that Python does have garbage collection and that first of all reference counting is garbage collection is it it is a legitimate algorithm for garbage collection and second of all Python doesn't have pure reference County but it also has a garbage collector that resolves cycles and there's all sorts of clever things what else is there yeah this is more sort of a note on you can't please everyone because all the people on my left are asking me to please stop changing the language because it's already perfect Paul Everett famously said that about Python 1/5 - hi Paul and on my right are all the people who still have a favorite language feature that they want added now the scary thing is that it's actually often the same people who walk from left to the right and back because they don't want the language to change except for their one pet peeve so this this this is never going to be resolved completely satisfactorily for everyone my idea is that as your user base grows you become more conservative in changes and so there are still way more Java users than Python users and so indeed the Java process for getting new changes into the language and into the standard API is it's more heavyweight and pythons process they take even longer to to make changes at that level the ultimate slow-moving language is probably C++ which has the most users and so nobody wants it to change but there are still people who wanted to change so they they can do a new version of the language every decade rounded up to a little more than that Python is not quite there yet but we do have to be very careful and not change too much at a time and we we already went through a pretty dramatic change with Python 3 of course so let's let's all set our expectations low about new features landing into the language and if you if you watch Benjamin's presentation last night there are some interesting new things and if we give some times if we can do something really clever by permuting a couple of existing keywords we can do that but otherwise even if you have an incredibly important use case for a new statement or expression the hopes of getting that accepted into the language are not very high and I know that some people sort of accept this and they define their own super set or subset of Python and they write their own parser and maybe they have a transformational engine that takes a program in their language which resembles Python and then translates it into standard Python and then runs it and there are a couple of nice advantages to that approach so I won't want to sort of give you that idea for consideration if you really have a desperate need for certain extensions to the language that you cannot do by just importing more modules and adding more classes or functions or methods or constants if you really want something more than that you think you have to change the language define your own your own transformation there are clever things called import hooks that will actually let you do the transformation more or less transparently there are downsides too and you sort of you paint yourself into a corner where nobody else is compatible with your language so you have to sort of have a well-defined community of users who can can all use your tool but it is possible to experiment with those kind of things and I'm looking forward to seeing some of those things happen okay well I don't know how much time is being scheduled for audience questions but there are two mics and until the Athey people or Jessi tell me to stop I'll take questions Jessi gave me five minutes anyone okay well that's fine I see I've scared you all thank you
Info
Channel: Next Day Video
Views: 115,678
Rating: 4.8600001 out of 5
Keywords: psf, python pycon pycon2012, pycon_2012
Id: EBRMq2Ioxsc
Channel Id: undefined
Length: 59min 56sec (3596 seconds)
Published: Thu Mar 15 2012
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.