Fix hosting_context before running next upgrade.