diff --git a/.python-version b/.python-version index 3e388a4..86f8c02 100644 --- a/.python-version +++ b/.python-version @@ -1 +1 @@ -3.13.2 +3.13.5 diff --git a/CHANGELOG.md b/CHANGELOG.md index 76bcccb..75c26ec 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,13 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [unreleased] + +- remove unused 32-bit architectures +- Babel don't build new po file if only the pot creation-date was changed +- Improve Makefile +- Update dependency pytest-asyncio to v1 + ## [0.14.1] - 2025-05-31 - handle missing MQTT addon [#438](https://github.com/s-allius/tsun-gen3-proxy/issues/438) diff --git a/Makefile b/Makefile index 5964e6e..394ac69 100644 --- a/Makefile +++ b/Makefile @@ -1,27 +1,37 @@ -.PHONY: build babel clean addon-dev addon-debug addon-rc addon-rel debug dev preview rc rel check-docker-compose install +.PHONY: help build babel clean addon-dev addon-debug addon-rc addon-rel debug dev preview rc rel check-docker-compose install -babel: +help: ## show help message + @awk 'BEGIN {FS = ":.*##"; printf "\nUsage:\n make \033[36m\033[0m\n"} /^[$$()% a-zA-Z0-9_-]+:.*?##/ { printf " \033[36m%-15s\033[0m %s\n", $$1, $$2 } /^##@/ { printf "\n\033[1m%s\033[0m\n", substr($$0, 5) } ' $(MAKEFILE_LIST) + +babel: ## build language files $(MAKE) -C app $@ build: $(MAKE) -C ha_addons $@ -clean: +clean: ## delete all built files $(MAKE) -C app $@ $(MAKE) -C ha_addons $@ -debug dev preview rc rel: +debug dev preview rc rel: ## build docker container in version $(MAKE) -C app babel $(MAKE) -C app $@ -addon-dev addon-debug addon-rc addon-rel: +addon-dev addon-debug addon-rc addon-rel: ## build HA add-on in version $(MAKE) -C app babel $(MAKE) -C ha_addons $(patsubst addon-%,%,$@) -check-docker-compose: +check-docker-compose: ## check the docker-compose file docker-compose config -q -install: - python3 -m pip install --upgrade pip - python3 -m pip install -r requirements.txt - python3 -m pip install -r requirements-test.txt \ No newline at end of file +PY_VER := $(shell cat .python-version) + +install: ## install requirements into the pyenv and switch to proper venv + @pyenv local $(PY_VER) || { pyenv install $(PY_VER) && pyenv local $(PY_VER) || exit 1; } + @pyenv exec pip install --upgrade pip + @pyenv exec pip install -r requirements.txt + @pyenv exec pip install -r requirements-test.txt + pyenv exec python --version + +run: ## run proxy locally out of the actual venv + pyenv exec python app/src/server.py -c /app/src/cnf \ No newline at end of file diff --git a/app/.version b/app/.version index c39e9c5..7092c7c 100644 --- a/app/.version +++ b/app/.version @@ -1 +1 @@ -0.14.1 \ No newline at end of file +0.15.0 \ No newline at end of file diff --git a/app/Makefile b/app/Makefile index 29be248..c192556 100644 --- a/app/Makefile +++ b/app/Makefile @@ -55,7 +55,7 @@ $(BABEL_TRANSLATIONS)/%.pot : $(SRC)/.babel.cfg $(BABEL_INPUT) $(BABEL_TRANSLATIONS)/%/LC_MESSAGES/messages.po : $(BABEL_TRANSLATIONS)/messages.pot @mkdir -p $(@D) - @pybabel update --init-missing -i $< -d $(BABEL_TRANSLATIONS) -l $* + @pybabel update --init-missing --ignore-pot-creation-date -i $< -d $(BABEL_TRANSLATIONS) -l $* $(BABEL_TRANSLATIONS)/%/LC_MESSAGES/messages.mo : $(BABEL_TRANSLATIONS)/%/LC_MESSAGES/messages.po @pybabel compile -d $(BABEL_TRANSLATIONS) -l $* diff --git a/app/docker-bake.hcl b/app/docker-bake.hcl index ba9d92b..324a68e 100644 --- a/app/docker-bake.hcl +++ b/app/docker-bake.hcl @@ -53,7 +53,7 @@ target "_common" { ] no-cache = false - platforms = ["linux/amd64", "linux/arm64", "linux/arm/v7"] + platforms = ["linux/amd64", "linux/arm64"] } target "_debug" { diff --git a/app/requirements-test.txt b/app/requirements-test.txt index 4f3a0b0..add2d3c 100644 --- a/app/requirements-test.txt +++ b/app/requirements-test.txt @@ -1,8 +1,8 @@ - flake8==7.2.0 - pytest==8.3.5 - pytest-asyncio==0.26.0 - pytest-cov==6.1.1 + flake8==7.3.0 + pytest==8.4.1 + pytest-asyncio==1.0.0 + pytest-cov==6.2.1 python-dotenv==1.1.0 mock==5.2.0 - coverage==7.8.2 + coverage==7.9.1 jinja2-cli==0.8.2 \ No newline at end of file diff --git a/app/translations/de/LC_MESSAGES/messages.po b/app/translations/de/LC_MESSAGES/messages.po index da4c5b2..85c6c76 100644 --- a/app/translations/de/LC_MESSAGES/messages.po +++ b/app/translations/de/LC_MESSAGES/messages.po @@ -120,6 +120,7 @@ msgid "TSUN Proxy - Log Files" msgstr "TSUN Proxy - Log Dateien" #: src/web/templates/page_logging.html.j2:10 +#, python-format msgid "Do you really want to delete the log file:
%(file)s ?" msgstr "Soll die Datei:
%(file)s
wirklich gelöscht werden?" diff --git a/ha_addons/docker-bake.hcl b/ha_addons/docker-bake.hcl index 32cbf6c..4317a70 100644 --- a/ha_addons/docker-bake.hcl +++ b/ha_addons/docker-bake.hcl @@ -59,7 +59,7 @@ target "_common" { ] no-cache = false - platforms = ["linux/amd64", "linux/arm64", "linux/arm/v7"] + platforms = ["linux/amd64", "linux/arm64"] } target "_debug" {