code: def set_versions(self):
          
          self.versions = {}
          self.upgrades = {}
          qi = getToolByName(self.context, "portal_quickinstaller")
          for key in qi.keys():
              self.versions[key] = qi.getProductVersion(key)
              info = qi.upgradeInfo(key)
              if info and 'installedVersion' in info:
                  self.upgrades[key] = info['installedVersion']
docs: Configure a list of product versions from portal.quickinstaller