code: def wait_for_providers(self):
          
          if self._providers_registered:
              _log.debug('waiting for providers to unregister %s', self)
              self._last_provider_unregistered.wait()
              _log.debug('all providers unregistered %s', self)
docs: Wait for any providers registered with the collector to have
          unregistered.
  
          Returns immediately if no providers were ever registered.