A while back the question come up why MacPorts sometimes (and sometimes often) takes ages to return control to the user after the requested operations were all completed, and if anything could be done to reduce the duration.
The why question was easy to answer: it does a bit of registry database management. The registry of installed ports is stored in an sqlite3 database and MacPorts does a regular cleanup (VACUUM) on it to remove stale information.
The 2nd question was harder to answer, in part because the registry database requires an extension to be operated on with external tools and there was an explicit lack of willingness among the MP devs to help out with suggestions or instructions. After all, no one else complained so why would they...
I wouldn't be writing this if I did manage to answer the question and yes, the duration of that final limbo situation can be reduced considerably, possibly in a win-win situation with a somewhat smaller file size of the registry db. How much gain there is to be ha