Iterate over sources

async AsyncCogniteClient.hosted_extractors.sources.__call__(
chunk_size: int | None = None,
limit: int | None = None,
) AsyncIterator[Source] | AsyncIterator[SourceList]

Iterate over sources

Fetches sources as they are iterated over, so you keep a limited number of sources in memory.

Parameters:
  • chunk_size (int | None) – Number of sources to return in each chunk. Defaults to yielding one source a time.

  • limit (int | None) – Maximum number of sources to return. Defaults to returning all items.

Yields:

Source | SourceList – yields Source one by one if chunk_size is not specified, else SourceList objects.