Compare commits

..
11 Commits
Author SHA1 Message Date
shmyga e6e7bb50a8 ci(version): 0.10.11
release / release (push) Successful in 3m39s
test / test (push) Successful in 1m11s
2026-11-03 21:43:33 +03:00
shmyga a8cf8ac960 fix(gismeteo): add gismeteo parser precipitation variant 2026-11-03 21:43:21 +03:00
shmyga 3297a66153 ci(version): 0.10.10
release / release (push) Successful in 40s
test / test (push) Successful in 50s
2026-11-03 00:47:38 +03:00
shmyga d55c945dcd ci(action): update deploy action 2026-11-03 00:47:10 +03:00
shmyga 2c10f81008 ci(version): 0.10.9
release / release (push) Successful in 7m25s
test / test (push) Successful in 1m3s
2026-11-03 00:05:31 +03:00
shmyga c513c2a7a7 ci(docker): fix poetry install 2026-11-03 00:05:08 +03:00
shmyga 234d9c33d4 fix(weather): fix gismeteo parser 2026-11-03 00:04:48 +03:00
shmyga 32956af5f0 ci(version): 0.10.8
test / test (push) Successful in 1m6s
release / release (push) Failing after 1m26s
2026-11-02 22:57:56 +03:00
shmyga 57112793e7 fix(weather): fix rp5 and yandexweather parsers 2026-11-02 22:57:23 +03:00
shmyga ecfa9caecc ci(version): 0.10.7
test / test (push) Successful in 42s
release / release (push) Successful in 11m53s
2026-10-13 18:01:05 +03:00
shmyga c0ae3f3be8 fix(gismeteo): add sky parser value variant 2026-10-13 18:00:47 +03:00
10 changed files with 21 additions and 8 deletions
+3 -2
View File
@@ -13,10 +13,11 @@ jobs:
- uses: appleboy/ssh-action@v1 - uses: appleboy/ssh-action@v1
with: with:
host: ${{ secrets.DEPLOY_HOST }} host: ${{ secrets.DEPLOY_HOST }}
port: ${{ secrets.DEPLOY_PORT }}
username: ${{ secrets.DEPLOY_USERNAME }} username: ${{ secrets.DEPLOY_USERNAME }}
key: ${{ secrets.DEPLOY_KEY }} key: ${{ secrets.DEPLOY_KEY }}
passphrase: ${{ secrets.DEPLOY_PASSPHRASE }} passphrase: ${{ secrets.DEPLOY_PASSPHRASE }}
script: | script: |
cd /opt/gallery cd /opt/gallery
docker compose pull /Volume1/@apps/DockerEngine/dockerd/bin/docker-compose pull
docker compose up -d /Volume1/@apps/DockerEngine/dockerd/bin/docker-compose up -d
+1 -1
View File
@@ -4,7 +4,7 @@ ENV PATH="$POETRY_HOME/bin:$PATH"
RUN apt update && \ RUN apt update && \
apt install -y gettext apt install -y gettext
WORKDIR /app WORKDIR /app
RUN curl -sSL https://install.python-poetry.org | python3 - RUN pip install poetry
COPY pyproject.toml poetry.lock README.md ./ COPY pyproject.toml poetry.lock README.md ./
RUN poetry config virtualenvs.in-project true RUN poetry config virtualenvs.in-project true
RUN --mount=type=cache,target=/root/.cache/pypoetry/cache \ RUN --mount=type=cache,target=/root/.cache/pypoetry/cache \
@@ -29,6 +29,7 @@ def cloudness_icon(sky: Sky, date: datetime.datetime, period: str) -> list[str]:
Precipitation.RAIN: "thunderstorm", Precipitation.RAIN: "thunderstorm",
Precipitation.HEAVY_RAIN: "thunderstorm", Precipitation.HEAVY_RAIN: "thunderstorm",
Precipitation.SHOWER: "thunderstorm", Precipitation.SHOWER: "thunderstorm",
Precipitation.SMALL_SNOW: "storm-showers",
Precipitation.SNOW: "storm-showers", Precipitation.SNOW: "storm-showers",
Precipitation.HEAVY_SNOW: "storm-showers", Precipitation.HEAVY_SNOW: "storm-showers",
}[sky.precipitation] }[sky.precipitation]
@@ -47,6 +48,7 @@ def cloudness_icon(sky: Sky, date: datetime.datetime, period: str) -> list[str]:
Precipitation.RAIN: "rain-mix", Precipitation.RAIN: "rain-mix",
Precipitation.HEAVY_RAIN: "rain", Precipitation.HEAVY_RAIN: "rain",
Precipitation.SHOWER: "rain", Precipitation.SHOWER: "rain",
Precipitation.SMALL_SNOW: "snow",
Precipitation.SNOW: "snow", Precipitation.SNOW: "snow",
Precipitation.HEAVY_SNOW: "snow", Precipitation.HEAVY_SNOW: "snow",
Precipitation.HAIL: "hail", Precipitation.HAIL: "hail",
+3
View File
@@ -80,7 +80,10 @@ class SkyParser(TableValueParser[Sky]):
"сильный снег с дождём": Precipitation.HEAVY_SNOW, "сильный снег с дождём": Precipitation.HEAVY_SNOW,
"небольшой снег с дождём": Precipitation.SNOW, "небольшой снег с дождём": Precipitation.SNOW,
"небольшой мокрый снег": Precipitation.SNOW, "небольшой мокрый снег": Precipitation.SNOW,
"снежные зёрна": Precipitation.SNOW,
"град": Precipitation.HAIL, "град": Precipitation.HAIL,
"небольшая морось": Precipitation.SMALL_RAIN,
"морось": Precipitation.SMALL_RAIN,
} }
THUNDER = {"гроза"} THUNDER = {"гроза"}
+4
View File
@@ -86,6 +86,10 @@ class PrecipitationParser(TableValueParser[tuple[Precipitation, float]]):
"Явления погоды отсутствуют": Precipitation.NO, "Явления погоды отсутствуют": Precipitation.NO,
"Cлабый дождь": Precipitation.SMALL_RAIN, "Cлабый дождь": Precipitation.SMALL_RAIN,
"Умеренный дождь": Precipitation.RAIN, "Умеренный дождь": Precipitation.RAIN,
"Cлабый дождь со снегом": Precipitation.SMALL_SNOW,
"Слабый снег с дождём": Precipitation.SMALL_SNOW,
"Cлабый снег": Precipitation.SMALL_SNOW,
"Снег": Precipitation.SNOW,
} }
def extract(self, data: Tag) -> tuple[Precipitation, float]: def extract(self, data: Tag) -> tuple[Precipitation, float]:
+3 -1
View File
@@ -61,7 +61,7 @@ class TemperatureParser(TableValueParser[list[int]]):
model_key = "temperature" model_key = "temperature"
def extract(self, data: Tag) -> list[int]: def extract(self, data: Tag) -> list[int]:
return [int(data.text.strip().rstrip("°"))] return [int(data.text.strip().rstrip("°").replace("−", "-"))]
class SkyParser(TableValueParser[Sky]): class SkyParser(TableValueParser[Sky]):
@@ -79,6 +79,8 @@ class SkyParser(TableValueParser[Sky]):
"небольшой дождь": Precipitation.SMALL_RAIN, "небольшой дождь": Precipitation.SMALL_RAIN,
"дождь": Precipitation.RAIN, "дождь": Precipitation.RAIN,
"ливень": Precipitation.SHOWER, "ливень": Precipitation.SHOWER,
"дождь со снегом": Precipitation.SNOW,
"снег": Precipitation.SNOW,
} }
def extract(self, data: Tag) -> Sky: def extract(self, data: Tag) -> Sky:
+1
View File
@@ -40,6 +40,7 @@ class Precipitation(StrEnum):
RAIN = auto() RAIN = auto()
HEAVY_RAIN = auto() HEAVY_RAIN = auto()
SHOWER = auto() SHOWER = auto()
SMALL_SNOW = auto()
SNOW = auto() SNOW = auto()
HEAVY_SNOW = auto() HEAVY_SNOW = auto()
HAIL = auto() HAIL = auto()
+1 -1
View File
@@ -1,7 +1,7 @@
[project] [project]
name = "gallery" name = "gallery"
description = "" description = ""
version = "0.10.6" version = "0.10.11"
readme = "README.md" readme = "README.md"
authors = [{ name = "shmyga", email = "shmyga.z@gmail.com" }] authors = [{ name = "shmyga", email = "shmyga.z@gmail.com" }]
requires-python = ">=3.14,<4.0" requires-python = ">=3.14,<4.0"
+2 -2
View File
@@ -1,12 +1,12 @@
{ {
"name": "gallery", "name": "gallery",
"version": "0.10.6", "version": "0.10.11",
"lockfileVersion": 3, "lockfileVersion": 3,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "gallery", "name": "gallery",
"version": "0.10.6", "version": "0.10.11",
"license": "ISC", "license": "ISC",
"dependencies": { "dependencies": {
"@popperjs/core": "^2.11.8", "@popperjs/core": "^2.11.8",
+1 -1
View File
@@ -1,6 +1,6 @@
{ {
"name": "gallery", "name": "gallery",
"version": "0.10.6", "version": "0.10.11",
"type": "module", "type": "module",
"scripts": { "scripts": {
"build": "webpack --mode production", "build": "webpack --mode production",