A bug has been found — thanks to Brandon for the info. Chances are, you weren't bitten by this if you've used Surftrackr according to the maker's recommendations. The bug caused duplicate entries to be created in the database where the MIME-type was unknown. But since uploaded logfiles are (a) locked when processing starts, and (b) moved somewhere else when processing is finished, you should find you were unaffected. But please upgrade now - read on for more details on how to avoid a full upgrade.
The bug was caused like this:
This would cause duplicate entries if the same line got processed twice (which probably won't happen in normal usage). Python would create a duplicate even though all the arguments to "get_or_create" were the same, with the exception (presumably) of the None object passed in as the MIME-type. I'm still wrestling with the philosopical implication that all objects with a type of "None" are deemed to be unique, but here's how to fix:
Either download the latest release and re-install, OR ...
Download a modified logfiles.py from the download site. Copy it into your surftrackr/media directory and edit the sys.path.append line to match your Surftrackr installation's location. Download the modified surftrackr-livelog.py as well, and copy it into surftrackr/utils.
Then (most important or it will all come to naught) add a new entry into your database:
mysql surftrackr -u surftrackr -p
INSERT INTO log_mimetype VALUES(0, 'unknown', 'unknown', '');
SELECT id FROM log_mimetype WHERE type='unknown';
This query will show you the id of the item you just entered. Although you told MySQL to use the value '0', it will chnage this because the id field is autonumber. However, it's important that it has the id of 0, so take the number (let's suppose it's 640) and change it to 0:
UPDATE log_mimetype SET id=0 WHERE id=640;
Remember to substitute your id for 640, enter the query, then exit from MySQL.
As ever, if you find any other bugs, please let me know. I would like Surftrackr to become a very high-quality professional tool, and your feedback is essential!
Simon Burns
14 Feb 2008