Fixes a bunch of issues, mainly related to live (re-)pinning of packages

Fixes some cases of messages about availability too.