On Mon, Nov 19, 2007 at 06:45:52AM -0600, Dan McGee wrote:
The best solution would be to factor print URIs operation out of needing a transaction at all. This may be helped by me actually merging your upgrade patch first.
That patch alone doesn't help much. But if the idea is alright, maybe it could be extended to sync_prepare, after find_replacements and sync_sysupgrade : skip the QUESTIONs when the trans argument is NULL. The questions in sync_prepare are LOCAL_UPTODATE and CONFLICT_PKG. If I'm not mistaken, the first one will never be skipped in case of -Su anyway, and the second one shouldn't come often. So that would not be a problem. But I'm looking at it now, and sync_prepare looks much more dependent on the trans argument than the others. It also uses trans->packages, trans->targets, trans->flags, EVENT(trans,...). So that doesn't seem easy. Using a null trans argument looks quite hackish anyway.. If the current code really doesn't allow to implement features like -Qu and -Sup correctly, then I think these options should be removed, and the problematic code rewritten, so that they can be added properly later.