Older blog entries for davidw (starting at number 402)

Kindle thoughts

I went ahead and got myself a Kindle for my birthday.  Thanks to everyone for their comments in the last post.  Here are my thoughts on it, in no particular order:


I like it a lot.  I was worried that I would not actually enjoy reading with it, or that it would be significantly inferior to real books.  However, I do enjoy reading with it, and I think they have achieved their aim of making it so that it 'just disappears' like a good book does.  It's a very small and light device, even with the leather cover I got for it (always best with a small child in the house), so it's in no way heavy or uncomfortable.  It's relatively more expensive and fragile than a copy of The Economist or a paperback, so I don't sling it around quite so casually, and do try and remember to keep it out of reach of said small child, which makes it a little less worry-free than an actual book.  On the other hand, it's much cheaper than an ipad or samsung galaxy or something like that, so it's not the end of the world if something happens to it, although it would be unfortunate to be without reading material for the time it took to replace it!


The selection of material available for it is ok, but I'm just a bit disappointed - I thought offhand there were more books than there are.  I regularly bump into things I might consider getting if they were available for it, but are not.  On the other hand, there are quite a few books available for it for *free* because they're old and out of copyright.  Stuff you might get for 99 cents at a used book store as a paperback, but it's pretty cool to be able to just zip it right to the device, for nothing at all.

I am not convinced that the economics of it all has settled down yet.  It's pretty absurd, for instance, that The Intelligent Investor costs nearly twice as much for the Kindle version as for the paperback!  Especially since I can never resell it.

I think a lot of the value I get from the device is derived from my situation: living abroad here in Italy, it's expensive and slow to get English language books, and now I can get them *instantly*, which is absolutely wonderful, and will significantly increase my reading.  Also, should we ever move back to the US or elsewhere, it means a few less books to lug along or go through the sorrow of parting with.  Were I in the US in a place with a decent used book store, and sure about staying in the same place for a while, I am not sure I would have bothered.

I find it somehow a bit monotonous to read everything in the same form factor and with the same fonts.  It takes something away from the character of a book, especially a well-done hardback.  Of course, what counts is the content, but the presentation counts for something too, I think.

I really do like the size and shape of the Kindle, and could see the 'smaller tablet' size catching on.  Speaking of which, I'm curious to see how reading devices and tables will intersect.  Clearly, a generic device that can also read books is going to be a lot more popular, but for now e-ink still has a few advantages: it's better for reading - I can stare at it much longer than I can at an LCD screen; also the battery life is much better, meaning I don't have to worry about/fiddle with charging it every day.  Also, in some ways, it's nice not to have the siren-call of the web just a click away...  I think though that at some point, generic devices will likely overtake dedicated readers.  Who knows when, though.


Yes, it does have a browser, however, the screen refresh is so slow that I'd only really consider using it for reading web pages - wikipedia, say, rather than doing much with it.  Still, I think it's nice to have and hope they continue the experiment.


Coming back to the comparison with 'real' books, I don't like the fact that I can no longer finish a book and then hand it to my wife if it's good.  We could get her a Kindle too, but I'm still not sure they have the sharing thing worked out that well.  2 weeks - and then what?  One way to do it might be that you can share it with anyone who you trust with one-click purchases.  That'd limit it to family members or really trustworthy friends.  Although... even there, I regularly loan books to friends, and would like to continue to be able to do so.

Also, like I mentioned in the previous article, I'm leary of a future where my daughter doesn't have a multitude of books to peruse on our bookshelves.  Bookshelves are a great way of making serendipitous discoveries that recommendation engines (those I've used at least) don't really account for.

All in all, I'm very pleased with the Kindle, though, and look forward to seeing what the future holds.

Syndicated 2010-11-26 11:13:32 (Updated 2010-11-26 11:45:19) from David's Computer Stuff Journal

The Future of Programming Languages: Economics

Someone on Hacker News asks about the future of programming languages, and I realized that it's a pretty interesting topic. Here's my take on it:

Programming languages are about people, and the compromises they may or may not make in order to communicate their intentions to computers.  The technology in question may change, but there will likely always be people involved, and as long as that's true, looking at the problem through the lense of economics provides useful results.

Therefore, looking at programming languages pretty much requires that you look at the economics of them:

  • Network effects are important, but obviously don't squeeze out smaller languages entirely.  I.e. it's good to be able to get libraries, find people to hire, books to read, friends to chat with about problems, etc...  This means that future languages will have to seek out a critical mass of users.
  • Since the times of Fortran, languages have been getting more efficient in terms of programmer time, because programmer time stays the same or gets more expensive, while computer time keeps getting cheaper, and language implementors keep getting better at making things fast under the hood.  This means that languages of the future are likely to let you do more with less, all else being the same.
  • Learning a programming language will continue to be a fairly involved process for most people, meaning that for many, it's more efficient to learn a few languages well and use them for as much as possible, rather than to try and find the 'perfect' language for each problem.  This rewards general-purpose languages, compared to niche languages.  This also rewards flexible languages that can be used in many different environments.
  • Computers are only going to become more and more important, meaning that more people are going to want to develop the skills to work with them.  Not all of them will be experts, and many may not know much, but have a vision for how a program could solve a particular problem in a field they are knowledgeable about.  This means a low barrier to entry is important, because those novices will pick easier languages, become progressively more competent in them, and thus (network effects) contribute to their diffusion.  Case in point: PHP.  Future languages should be capable of solving hard problems, but should also make it easy to get started solving simple problems too.
  • Working on languages is lots of fun, so even though there aren't necessarily monetary rewards, people will continue to play with and explore new ideas.  I don't see there being a limited supply of new languages in the future.
  • The costs of switching from established languages will continue to be high, so future languages will still need to interact with "legacy" languages like Cobol, Fortran, C, Java, and so on, that are so widely established in industry that systems written in them will be with us for a long time yet.


I wrote this in a hurry.  Have I missed anything?  How do these factors apply to languages you see emerging?

Syndicated 2010-11-10 15:45:20 (Updated 2010-11-10 16:05:19) from David's Computer Stuff Journal

Kindle?

I'm thinking about getting a Kindle, and I thought I'd write down some thoughts, even if they're a bit jumbled, and invite commentary.

Good:

One thing I really like, living here in Italy, is that I would be able to get English language books instantaniously, and not pay shipping or import duties on them.  Whatever disadvantages there may be, that is a huge advantage.

Closely tied to that: if we ever move back to the US, shipping all our books will be very expensive.  Having some of them in an electronic format would lighten that load considerably.

It's fairly cheap.  At $180, it's not something I'd want to treat carelessly, but it's significantly less expensive than various existing tables.

Long battery life means it's not something you have to worry much about.

E-ink looks like it's easier on the eyes than LCD screens.  I'm not sure, but also its slow update speed might be a "feature not a bug" in the sense that you're not so easily distracted by the internet being just one click away.

Bad:

I love having real, physical books in my house.  I grew up in a house full of books, and I want the same thing for my daughter.  I like being able ot look through them, pick one up, and read about something. 

Real books are very convenient, as long as you're not lugging around hundreds of them.  I like not having to worry too much about dropping them, about getting a bit of water on one or that sort of thing.  You can cart them around in a backpack with little worry, take them to the beach, and so on.

As far as I can tell, Knuth's books are not available for, nor would appear like they do on paper.  That's the golden standard for me: once "The Art of Computer Programming" looks good on an e-reader, it will be really and truly ready.  We're not there yet.

It's not general purpose.  Like I said above, maybe this is good for reading, but there are also times when it'd be nice to have a general purpose device, with email, maps, applications, and so on.

A while back, Amazon announced some sort of beta program for a kindle SDK.  I haven't heard much of anything since.  So it looks like it's not really possible to code for it, which is a bit disappointing. I like to have that option available, even if I don't always exercise it.

Unknown:

The pricing: sometimes Kindle versions are cheaper (especially, in my case, considering shipping, and, potentially, import duties), but sometimes they aren't, which seems a bit unfair, given that you cannot sell the book if you don't like it.  I'm not sure how it would work out for me in the aggregate.

Digital Rights Management, or DRM, means you can't, say, sell someone a "used" ebook.  This is, in some ways, understandeable, because it's not like an e-book degrades with time as a physical one might.  Were it possible to sell on your old books, that might radically change the market.  I could see that having both good consequences (cheaper books), but also negative ones for authors (less money).  I suppose this topic merits a post or two, or even an entire book of its own, because it's a complicated subject without, in my opinion, "easy" answers.  Suffice it to say, though, that there are some drawbacks, but I suppose it's also nice that Amazon "knows" which books I have, so even if I switch to a different reader, I still have my books.  And it's good that authors can get paid to work on a book.

Not having actually bought it yet, I have no idea how it actually 'feels' to read a book with one.  I love curling up with a good book, something I certainly can't do with my laptop.  The Kindle looks light and small enough that it could work, but maybe it's just too high tech and sleek to provide that same comfortable coziness.  Or maybe I'm just a luddite where books are concerned?


Do you have one? Do you use it?  For all kinds of books or just certain kinds (technical books, cheap 'fun' reads, whatever...)?  What's the experience like?

Syndicated 2010-10-26 13:47:27 (Updated 2010-10-26 15:04:17) from David's Computer Stuff Journal

17 Oct 2010 (updated 17 Oct 2010 at 15:11 UTC) »

When sunny gets blue, I get traffic

This is definitely a "captain obvious" observation, but it's interesting to see just how much bad weather here in the Veneto is correlated with traffic to my real-time weather site, http://www.meteo-veneto.net

The precipitation and insolation numbers for the month of September - as well as the radar images for the site itself - come from http://www.arpa.veneto.it/

The numbers are all normalized so as to make them easy to compare.  The cloudy/dark numbers are the inverse of the insolation for the month, and could probably be fiddled with to be a bit more accurate - it's obvious that the number increases as the month goes on, with less sunlight.

Syndicated 2010-10-17 06:47:47 (Updated 2010-10-17 14:33:10) from David's Computer Stuff Journal

Moving data around your code - different approaches

I was thinking about this the other day, and I realized I can't particularly think of a label to attach to this concept.  Anyone out there got a name for this?  This could be due to my lack of formal computer science training, so I thought I'd ask, at the risk of looking stupid (I'm having an off day, so that's a very real possibility).

If you have a series of functions, say: a(x), which in turn calls b(x), which calls c(x), and so on, and you end up with a faily long call chain, out to say m(x), and you subsequently decide that m(x) needs an additional piece of information that is contained in a local variable in the body of the a(x) function - how do you get it to m(x) ?

  • You could simply make it a global variable!  That's easy and generally a pretty bad idea.
  • You could modify every function signature between a(x) and m(x) to look like b(x, y), c(x, y).  That's a lot of work though.  And what happens if something *else* needs to get passed around?
  • In an object oriented language, you could make x an object, and attach y to it, so that you mostly pass it around just as before.
  • Along the same lines, you could make x a hash table, so that you can look arguments up by their name, to have some idea what they are.
  • You could just make x a list, and remember what position everything is in.  That's not so nice though if you have to revisit the code and you didn't document where everything is, and why it's there.
  • Other things?  You could make a(x)'s scope visible to m(x), I suppose, although that sounds like it's a fairly involved, and potentially hairy answer.

It seems the answers are basically either 1) add the parameter to all the functions and everything that calls them, or 2) use some kind of composite type to stash the one or more values in.


It seems that this is a reasonable common thing to have to do, so it must have a name.  How well does your language handle that kind of refactoring?

Syndicated 2010-08-20 14:30:15 (Updated 2010-08-20 14:44:24) from David's Computer Stuff Journal

Geek Dad: "Skywalker Story"

I don't usually talk about personal stuff here, but I'll make an exception:

I got tired of telling our two year old daughter the same old stories about children lost in forests, bears, witches, evil stepmothers and so on, so I turned to some other material I know fairly well.  I started recounting simplified bits and pieces of the first Star Wars movie over the course of a week.  She thought it was great fun, what with wookies and robots and a princess and lots of adventures, and now, every evening, asks for "Skywalker story!".   I'm quite proud, although my wife rolls her eyes a bit.

Syndicated 2010-08-06 07:05:41 (Updated 2010-08-06 07:11:18) from David's Computer Stuff Journal

Rails I18n translate with empty string - bug?

Normally, it's pretty easy in Rails to take advantage of the simple i18n tools provided.  You just write I18n.t("some_key") and it'll translate that into whichever language.

Today, however, I discovered what seems like a problem.  If you do I18n.t(""), it returns a hash of all possible translations!  And if you give it a nil, it returns an error because that's not a key in the DB.

The first behavior doesn't sound correct at all, and the second seems dubious as well.  I'm thinking about fixing it like so:
 

  def translate(key, options = {})
    return nil if key.nil?
    return "" if key == ""
    locale = options.delete(:locale) || I18n.locale
    backend.translate(locale, key, options)
  rescue I18n::ArgumentError => e
    raise e if options[:raise]
    send(@@exception_handler, e, locale, key, options)
  end

Is there any reason not to do this?

Syndicated 2010-07-23 13:17:23 (Updated 2010-07-23 13:50:31) from David's Computer Stuff Journal

1 Jul 2010 (updated 1 Jul 2010 at 15:06 UTC) »

On the block: squeezedbooks.com

In keeping with the idea that I want to focus on things where I sell something directly to people, rather than just advertising, I am putting http://www.squeezedbooks.com up for auction on flippa.com.  The auction is here:

http://flippa.com/auctions/99073/Business-Book-Summary-Site

Here's what I wrote about it:

I like to read business books, but many of them contain a nugget of valuable information, and lots of fluff, because you can't sell a 10 page book.  Some of them are pure fluff!  Occasionally, one of them has profound implications.

I created this site several years ago in order to have a place to summarize a series of books I'd read, with the aim of creating a community interested in summarizing and, most of all, discussing business books.  To be honest, that community hasn't really materialized, although there are a number of registered users (585 at last count).  Most other business book summary sites are for-pay - you pay $X dollars a month and receive Y summaries.  I wanted to create an open site, in order to foster discussion and communication between people reading summaries.

In any case, one baby later and in a different country, my heart isn't really in it any more, so I've decided to put the site up for sale.  I still think the idea is a good one, and that in the right hands, the site could take off.


It was a fun site to work on, and really do think that in the right hands, it, or something derived from it, could be successful.  I could conceivably hang on to it and keep trying different things with it, but I've decided I really need to impose this limitation of "make something to sell directly" on myself in order to avoid wandering off into "cool, but no idea how to make money" projects.

Edit:

One thing that I'd like to state explicitly and publicly is that I'm not giving up on open source, just that I think I need to draw a really clear line between "I hope to make some money with this" and "this is a cool project I want to share with the world".  In other words, I think I'd rather avoid the middle ground where stuff is sort of openish, and go either for projects that pay directly, or stuff that's pure open source under an Apache or BSD license.  Hopefully, if I ever hit on a project that takes off, I'll be able to dedicate some time/resources to open sourcing some of the infrastructure, as I think that's currently one of the better models for producing open source software.

Syndicated 2010-07-01 13:40:37 (Updated 2010-07-01 14:20:35) from David's Computer Stuff Journal

Ovi Lays an Egg

In the local dialect here in Padova, Italy, "ovi" means "eggs".  For those who aren't native English speakers, "to lay an egg" means to fail at something or do it poorly.  The connection is very appropriate.


To see what it was about, and if it was worth pursuing, I decided to submit a couple of simple applications to Nokia's OVI store.  Nothing fancy, or that I'd spent much time developing, and they were actually little things I'd done for myself before the ovi.com store came out, but I had hoped to see about making a bit of money out of the time invested nonetheless.


So I went ahead and started adding them, with a quick glance the publisher guidelines.  Too quick, as it turns out.  A month after submitting my application, their "QA" process lets me know my application is not going to be accepted because it's not signed.  Uh... yeah?  Couldn't you have simply run a script on the file I uploaded to tell me the same damn thing?  It's not exactly as if you have to have a human look at the file with a hex editor to determine whether it's signed or not.  My phone can tell, of course - presumably Nokia ought to be able to figure it out programmatically and let me know?  Sure, I should have read their big, long document prior to starting, but come on, it would have saved everyone time if their software had simply informed me that my application, being unsigned, was not ok.

Now, when it comes to signing, Java ME is pretty much the worst in the business, although Apple is giving them a run for their money.  At least Apple does it to make the applications good for their users (for their definition of good).

  • Java ME:  Ovi suggests using http://javaverified.com/ - where it costs $200 to sign up, and then something like at least 75 euros to run an application through *their* whole process.  For each version.   The hell with that!
  • Android: you have to pay $25 to get access to the marketplace, but can self-sign applications.  For free.  Put that in your pipe and smoke it, Nokia & Larry.
  • BlackBerry: I was sure this one was going to be expensive and painful given that BB is mostly aimed at big companies that could certainly spare the money.   It's not: $20 gets you a certificate that you can sign everything you want with, and it's pretty quick and painless to get it.  This is how Nokia ought to be doing things in terms of signing applications.
  • Apple: $100 gets you the dev kit and then you can submit your apps to the somewhat bureaucratic and slow apple approval process.  Plus you have to own a mac to develop on, if you don't already have one.  But still, only $100 a year, and you can do as many apps as you want.

So there you have it, Java ME involves more fees than the other ones, and is probably as slow and bureaucratic to boot. I'm not going to find out, though, this pretty much concludes my experiment with ovi.com - there's no way I'm going to spend all that money on a little fun application that I'd only sell for a few euros.  Being a fan of open source and openness in general, my next phone will certainly be Android based.

I think someone at Nokia probably realizes things are broken: they appear to be working on a way to make it not cost anything to sign Symbian apps.  But I don't have a Symbian app, so that's pretty useless for me.

Oh, and while I'm bitching about their whole process, their publisher interface was down all of last weekend in order to "add a new set of metadata which will improve the Ovi Store user experience".  It took a whole weekend of downtime to add that?

Furthermore, I signed up for Ovi as soon as it came out - I was going to push Hecl to it (but didn't bother at the time) but now it appears they want 50 euros from you just to sign up.  Here's a hint: save your money.

Syndicated 2010-06-23 14:45:39 (Updated 2010-06-23 15:38:54) from David's Computer Stuff Journal

Ok, first one on the block: leenooks.com

The problem with selling off these sites is that I am a bit attached to them emotionally.  Leenooks.com is a cool domain, I think - it's how Linus pronounces Linux, supposedly.  It's also one of the first sites I put together: the original version was done in Perl with CGI back in ... '97?  The current incarnation runs on DedaWiki a wiki I put together that is built with Ruby on Rails.


The idea behind the site was that, rather than keep track of all the hardware out there that works well with Linux, let's focus on the stuff you really want to avoid as that is a smaller set of things, and hopefully one that, one day, will be empty!

It seems to have been fairly popular over the years, and has helped pay for the server it runs on.  However, "popular" doesn't necessarily translate into "oodles of money", and especially now that I have a daughter who is a lot of fun to play with, I need to cut back on my "spare time" projects.  So this one is the first one up on the auction block.

I fervently hope that whoever acquires it can dedicate a bit more time and energy to making it do what it does, only better.

Syndicated 2010-06-10 21:12:25 (Updated 2010-06-10 21:20:06) from David's Computer Stuff Journal

393 older entries...

New Advogato Features

New HTML Parser: The long-awaited libxml2 based HTML parser code is live. It needs further work but already handles most markup better than the original parser.

Keep up with the latest Advogato features by reading the Advogato status blog.

If you're a C programmer with some spare time, take a look at the mod_virgule project page and help us with one of the tasks on the ToDo list!