ucf and debconf
I found a few tuits tonight, so with Manoj's go-ahead, I changed ucf to use debconf for its prompting. This works very nicely, and will be a nice gain in UI consistency.
The only hard part was working around the variety of hacks that people have used in their postinst scripts to run ucf after starting up debconf. I note that I probably wrote less code to make ucf use debconf than the collective size of those hacks, and apparently none of the authors of those hacks ever considered that ucf might one day use debconf, or tried to provide for that happening.
While there seems to be no good way to detect the various hacks, I came up with a reasonable workaround: ucf detects if its caller uses debconf, and if so falls back to old-style prompting, unless its caller passes it a flag indicating that it has not screwed up debconf.
Sigh. One of these days, I will de-hackify debconf's confmodule code, and all these hacks on top of hacks can melt away.. Need more tuits.