Saturday, February 25, 2012

Bad Snake Joke

Just between you and me, I'm getting a bit bored of writing Python all the time. It's a good language: I can write code that's functional or OO as the case may be; it has lots of libraries; it has Twisted, which is incredibly useful; it's not too hard to make a big project and keep it clean. It's the least awful programming language that I know of. That said, I'd like to do something different.

I would like to play with something makes static typing rock (like Haskell), or that has what Rich Hickey calls "polymorphism a la carte" (again, like Haskell, or Clojure). I would like to make something that stands a chance of feeling snappy (perhaps PyPy?), a chance to use something with richer debugging and refactoring tools, or to get a feel for doing some serious concurrency work outside of an event loop.

But mainly, I'm just bored of Python.

Also, I increasingly suspect that Python doesn't have legs. The Python 3 language change has increased the split between the core developer community and people writing code in the field. Python continues to be slow, both with start-up time and while running. The only people who seem to care are the PyPy developers, but I doubt I'll ever get to use it for commercial development. It's tricky to write code in Python that takes advantage of multiple cores, and even my phone has multiple cores now.

When I get the chance, I'm going to do more with Haskell and Clojure in my spare time. I'm not sure if there is something less "fringe" that I could recommend for use at Canonical. Go is a possibility, if a slightly disappointing one (interfaces are cool, but why oh why didn't they do typeclasses?).

7 comments:

Tom Berger said...
This comment has been removed by the author.
Tom Berger said...

If you're thinking of revisiting lisp, I urge you to take a look at Racket, the latest incarnation of PLT Scheme. Racket gives you the opportunity to work with pretty much all the best tools and paradigms modern programming languages can offer (dynamic typing, static typing, functional, OO, declarative), it is reasonably performant (optimizing JIT compiler, optional type declarations) and though not as hype as Clojure, it has a small but active and very mature community.

Go is great, but I'm finding it hard to give up the dynamism, especially interaction.

glyph said...

I humbly submit that being bored with the language is kind of a good thing. Maybe you should be looking further up the stack for some excitement? Do something with PyGame, maybe? Or learn something about bioinformatics and mess around with BioPython?

To put it a different way: when I was doing C++, I felt a range of emotions about the language and my tools for dealing with it, but "boredom" was not one of them.

(That said, Twisted really needs to make it easier to utilize multiple cores.)

Daniel Bo said...

Learning new things is great and no one should get themselves in a rut.

Have you tried Vala? GObject introspection in a C3/Java-like language that pre-compiles to C. It hits that start-up time problem you mentioned. Vala also has a sister language called Genie, which is much more Python-like and which uses the same libraries and compiler. You may want to start there.

ddaa said...

That is how I feel about Python at the moment too. As Glyph says, that probably tells something good about the language...

Clojure and Go are the two "next" languages I have in mind too. I will posting something on g+ about a project I have been contemplating for a while.

jml said...

@Tom, I'll take a look at Racket. When I last looked at PLT Scheme, my main take-away was disappointment in its module system.

@glyph, it's kind of a good thing. It's arguably a great thing for the end users of my work. If the way out of Python's boredom is to run through some other language's minefield, then, umm, yeah, no thanks. However, I'm not convinced that every other language will necessarily be more dangerous/frustrating/slippery/difficult.

As for going further up the stack, it's definitely an option, but not one that immediately appeals.

@Daniel, I haven't tried Vala. Does it do much beyond Java / C#?

@ddaa, I'm glad I'm not the only one! That I'm bored after twelve or so years rather than, say, consumed by loathing, is a good sign. I look forward to hearing more about your project.

AmanicA said...

lol. good post :)

Twitter Updates

Blog Archive