Skip to content

Commit 68c7637

Browse files
committed
🚀 Bump minor version and update CHANGELOG.md
1 parent 5a82c0f commit 68c7637

File tree

3 files changed

+60
-32
lines changed

3 files changed

+60
-32
lines changed

CHANGELOG.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,33 @@
11
# Changelog
22

3+
## [v2.3.0](https://github.com/azogue/aiopvpc/tree/v2.3.0) - Decrease API refresh rate and try to avoid banning (2021-12-01)
4+
5+
[Full Changelog](https://github.com/azogue/aiopvpc/compare/v2.3.0...v2.2.4)
6+
7+
Quick-Fix Release motivated by the last change in the ESIOS server (on 2021-11-30 😱),
8+
which is now apparently banning HomeAssistant requests,
9+
filtering us out because of the 'User-Agent' headers data 😤,
10+
as the server is returning a 403 status code error for a PUBLIC url 🤷.
11+
12+
**Changes:**
13+
14+
* :zap: **Substantially decrease the number of API requests to ESIOS**,
15+
avoiding unnecesary calls to refresh data for the same electricity prices.
16+
Before, when used from the `pvpc_hourly_pricing` HA Core integration,
17+
the ESIOS API was called 2 times/hour from 0h to 20h, and 4 times/hour in the evening,
18+
from 20h to 0h, retrieving today + tomorrow prices.
19+
This makes a total of ~56 requests/day, which is _not a lot_ 😅,
20+
but it seems the aggregated total for the HA user base (🔥 >30k requests/day just
21+
counting users pushing HA analytics) is being some kind of a problem for ESIOS,
22+
as it looks like they're trying to bane us 🥺😭
23+
Now, the API handler avoids calls to retrieve already available prices,
24+
cutting down the number of requests to just 1-2 requests/day 🤩
25+
26+
* :bug: **Set standard `User-Agent` header info**, to try to avoid server-side banning 🙈,
27+
and _rotate_ it if banning is detected, using common User-Agent browser identifiers.
28+
29+
* :recycle: Minor code refactor to prepare for future library changes, in order to move to authenticated API endpoints in future versions.
30+
331
## [v2.2.4](https://github.com/azogue/aiopvpc/tree/v2.2.4) - Split today / tomorrow price sensor attributes (2021-11-20)
432

533
[Full Changelog](https://github.com/azogue/aiopvpc/compare/v2.2.4...v2.2.2)

poetry.lock

Lines changed: 31 additions & 31 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ markers = [
4040

4141
[tool.poetry]
4242
name = "aiopvpc"
43-
version = "2.2.5rc1"
43+
version = "2.3.0"
4444
description = "Retrieval of Spanish Electricity hourly prices (PVPC)"
4545
authors = ["Eugenio Panadero <[email protected]>"]
4646
license = "MIT"

0 commit comments

Comments
 (0)