energy_data_retrieval.sources.eskom.client#

Discover current Eskom hourly renewable exports without frozen upload URLs.

energy_data_retrieval.sources.eskom.client.parse_generation_csv(content, *, maximum_rows=100000)[source]#

Read hourly reported MW, labelled at hour beginning in South African time.

The product covers Eskom-owned/contracted renewables and excludes embedded generation. No energy integration or more precise sampling claim is made.

Parameters:
  • content (str | bytes)

  • maximum_rows (int)

Return type:

DataFrame

class energy_data_retrieval.sources.eskom.client.EskomClient(http, maximum_rows=100000)[source]#

Bases: object

Public media discovery and a bounded latest-export read.

The provider’s chart page can retain a stale monthly upload URL. The public WordPress media catalogue supplies current exact filenames. Discovery selects only Hourly_Generation exports, never the separate Total_Hourly product.

Parameters:
http: HTTPClient#
maximum_rows: int#
generation(start=None, end=None, *, url=None)[source]#

Fetch latest published file, optionally filter inclusive local dates.

This endpoint does not promise an arbitrary historical archive. Missing requested days remain absent; frame metadata reports the returned range. An explicit URL permits an independently discovered official archive.

Parameters:
  • start (date | None)

  • end (date | None)

  • url (str | None)

Return type:

GenerationResult