Re: Last Import patch
- From: "Thomas Van Machelen" <thomas vanmachelen gmail com>
- To: "Bengt Thuree" <bengt thuree com>
- Cc: f-spot-list gnome org
- Subject: Re: Last Import patch
- Date: Fri, 19 May 2006 13:44:09 +0200
Hi Bengt,
Although i think it would be nice to have an import history, i have
some comments on your patch.
2006/5/19, Bengt Thuree <bengt thuree com>:
Hi Guys
I played around abit with Gunnar's "Last Import" patch, and added a bit
here and there...
The current version tracks the last 6 imports with the following tag
structure.
Last Imports
__0
__1
__2
__3
__4
__5
The reason for the __0 etc is that the tags has to be unique, and wanted
to minimize the risk that the user had already created a tag like this.
IMHO using tags to mark the last 6 imports is not a very good way to
implement some kind of "import history".
First of all, i think we should avoid using tags with a special status
(like the hidden tag). The first version of the duplicates patch also
used a special tag, but votes were quite anonymous that we should
avoid this. See next comments for more reasons.
1) Ensure that no new tags can be created that contains the above tag names.
2) Ensure that the above tag names do not show up in the "Attach tag
during import" list.
As you can see in your own comments, using tags is not the best way.
Because you use special tags, you have to implement some kind of
"exception logic" for them: they cannot be added during import by the
user, and you have to create them if they do not exist yet. Next to
that you have to shift older import tags to higher numbers if you do a
new import (0 becomes 1, 1 becomes 2,...). Imagine what this would do
to performance if your last 5 imports, imported 1000 each. Things
would probably become even worse when you have xmp tagging enabled:
that would cause 5000 photos to be changed on disk. I fear this might
take quite a while.
Any comments?
Is it overkill with tracking 6 imports?
I do think only have the last is not enough though.
While i do think that 5-6 imports is a nice default, i can easily
imagine that people want to track _all_ their imports, or only the
last one. Either your implementation is too simple, or it is too
complicated.
A better approach would be too add 1 or 2 tables to the database. For
example one table that keeps track of the imports performed, and
another one that ties photos to a certain import.
If you do so, you will not have to use any special tags, performing
new imports will not suffer too much from previous imports and
querying imports can be come more flexible (for example: give me an
overview of the last 5 imports, give me an overview of the imports
performed in the last week or the ones performed in march, ...).
Also, you wil not have to cope with incrementing the numbers of
previous imports.
That's it! I hope to have given a good overview of why i think this
can be done better. Give it some dedication, and i think this can
become very useful.
What are other people's comments on this? Unfortunately my opinion
still is only an opinion ;-)
Best Regards,
Thomas
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]