Polycrate API 0.11.2
Polycrate API 0.11.2
Release-Datum: 9. Januar 2026
Typ: Patch Release
Highlights
- Hostname-Validierung Fix - Behebung eines Python 3.12+ Syntax-Fehlers durch ungültige Escape-Sequenz
Artefakte
Docker Images
docker pull cargo.ayedo.cloud/polycrate/polycrate-api:0.11.2
Installation & Update
# Block-Konfiguration aktualisieren
polycrate run polycrate-api install
Änderungen
Fix: Invalid Escape Sequence in Hostname-Validierung
Die Funktion is_valid_hostname() in src/polycrate_api/utils.py verwendete einen regulären Ausdruck ohne Raw-String-Prefix.
Problem:
- \d in einem normalen String wird als Escape-Sequenz interpretiert
- Python 3.11: DeprecationWarning
- Python 3.12+: SyntaxError
Lösung:
# Vorher
allowed = re.compile("(?!-)[A-Z\d-]{1,63}(?<!-)$", re.IGNORECASE)
# Nachher
allowed = re.compile(r"(?!-)[A-Z\d-]{1,63}(?<!-)$", re.IGNORECASE)
Das r Prefix macht den String zu einem Raw-String, sodass \d korrekt als Regex-Metazeichen (Ziffern 0-9) interpretiert wird.
Migration
Keine Migration erforderlich. Das Update kann ohne Datenbankänderungen durchgeführt werden.