python-noob - which container is appropriate for later exporting into mySql + matplotlib ?
Steven D'Aprano
steve+comp.lang.python at pearwood.info
Sun Apr 14 03:56:21 EDT 2013
On Sat, 13 Apr 2013 10:02:18 -0700, rusi wrote:
> To the OP:
> Steven is welcome to his views about use of databases.
I haven't given any views about databases. I've given my view on
application developers -- specifically, Firefox -- using a not-quite ACID
database in a way that is fragile, can cause data loss, and adds lots
more complexity to the application AND the end-user experience. And for
what? Simple data that would be much better in a simpler format, such as
bookmarks.
> Good to remember
> that everyone does not agree with him. This includes the firefox devs as
> well as python devs.
I don't see what the Python devs have to do with it. They don't use
Sqlite for Python's internals, and the fact that there is a module for
sqlite doesn't mean squat. There's a module for parsing Sun AU audio
files, that doesn't mean the Python devs recommend that they are the best
solution to your audio processing and multimedia needs.
I'm not saying that Sqlite doesn't have it's uses, although I personally
haven't found them yet. And as for the Firefox devs, well, I'll just let
Jamie Zawinski show their l33t des1gn ski11z in context:
http://www.jwz.org/blog/2003/01/more-khtml/
Okay, that's ten years old. What do you think the odds are that Firefox
has a nice, clean design by now? Well, I suppose it's possible, but when
it takes a minimum of NINE files to do the equivalent of "Hello World" in
Firefox, I wouldn't put money on it:
http://kb.mozillazine.org/Getting_started_with_extension_development
I mean, really -- bookmarks, in a single-user application, and they store
it in a database. You can't even have two instances of Firefox running at
the same time.
The consequences of this over-engineered solution is that Firefox is more
complex and fragile than it needs be, and less reliable than it could be.
When your bookmarks database gets corrupt, which is easy, the browser
History and Back button stop working, which then pushes responsibility
for fixing the database corruption back on the user. So the Firefox
developers actually end up paying the costs of a non-lightweight
implementation, but without the benefits. They don't even get to remove
the old bookmarks to HTML code, since they still need it for manual
exports and backups.
Considering the rest of the Firefox architecture (XUL, XUL everywhere!),
using sqlite probably feels like a lightweight solution to the devs.
"The Mork database structure used by Mozilla Firefox v1-2 is unusual to
say the least. It was originally developed by Netscape for their browser
(Netscape v6) and the format was later adopted by Mozilla to be used in
Firefox. It is a plain text format which is not easily human readable
and is not efficient in its storage structures. For example, a single
Unicode character can take many bytes to store. The developers
themselves complained it was extremely difficult to parse correctly and
from Firefox v3, it was replaced by MozStorage which is based on an
SQLite database."
http://wordpress.bladeforensics.com/?p=357
http://en.wikipedia.org/wiki/Mork_%28file_format%29
--
Steven
More information about the Python-list
mailing list