Dan Price wrote: > On Tue 07 Oct 2008 at 07:27PM, Shawn Walker wrote: >> Because I wanted the caller to choose whether or not it was considered >> an error instead of coding that behaviour into the retrieve function itself. > > Is there any other caller other than this? Otherwise this seems > like coding for some future which might never happen. It just seems > like a pitfall to me-- less error paths are usually better than more.
It was for a future case, but I have no problem changing it. Consider it changed. > Now that I look again, the error handling in > image.py also doesn't jibe with the comment below, it, which says: > > "Manifests should only be marked as processed if the > touch is actually performed since multiple retrievals > may occur during the same operation for different reasons." The comment doesn't mean what you think it means, which is probably because of my slightly opaque wording. "is actually performed" here means "was attempted"; it was a comment intending to explain why we set the manifest as has having been "seen" unless all of the checks for authority, imagestate, etc. pass. I originally had the code setup to mark a manifest as touched if we had seen it all with the assumption that intent was sent. Later on, I changed it so that intent is only sent in certain cases, and so I added that comment to try to clarify why I only did it after calling touch_manifest. I've removed this comment which makes it, ironically, less confusing since it would seem obvious why I've done it there and not somewhere else. Cheers, -- Shawn Walker _______________________________________________ pkg-discuss mailing list [email protected] http://mail.opensolaris.org/mailman/listinfo/pkg-discuss
