Skip to content

Hardcoded year in the price baseline #9

Description

@pailozka

get_averages_year() in src/hpc_eff/utils/energy_price.py scrapes the yearly price baseline from a hardcoded URL:

url = 'https://spotovaelektrina.cz/historicke-ceny/2025/1'

The year 2025 is frozen in the code.

Proposed fix

  1. Build the URL from the current date instead of a constant: fetch /{current_year}/1.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions