Skip to content

Commit df15e04

Browse files
barnumbirrclaude
andcommitted
v0.8.5: registration lock, pre-commit yamllint
- Extension registration guard now uses threading.Lock for correctness. - Pre-commit hook now runs yamllint on workflow files. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 3533f28 commit df15e04

4 files changed

Lines changed: 14 additions & 4 deletions

File tree

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/).
77

8+
## [0.8.5] - 2026-04-09
9+
10+
### Changed
11+
- Extension registration guard now uses `threading.Lock` for correctness.
12+
- Pre-commit hook now runs `yamllint` on workflow files.
13+
814
## [0.8.4] - 2026-04-08
915

1016
### Added

octorules_google/_policy_settings.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
"""
1111

1212
import logging
13+
import threading
1314
from dataclasses import dataclass, field
1415

1516
log = logging.getLogger(__name__)
@@ -420,14 +421,16 @@ def format_report(self, plans: list, zone_has_drift: bool, phases_data: list[dic
420421
# Registration
421422
# ---------------------------------------------------------------------------
422423
_registered = False
424+
_register_lock = threading.Lock()
423425

424426

425427
def register_policy_settings() -> None:
426428
"""Register all policy settings hooks with the core extension system."""
427429
global _registered
428-
if _registered:
429-
return
430-
_registered = True
430+
with _register_lock:
431+
if _registered:
432+
return
433+
_registered = True
431434

432435
from octorules.extensions import (
433436
register_apply_extension,

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
44

55
[project]
66
name = "octorules-google"
7-
version = "0.8.4"
7+
version = "0.8.5"
88
description = "Google Cloud Armor provider for octorules"
99
license = "Apache-2.0"
1010
requires-python = ">=3.10"

scripts/hooks/pre-commit

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,4 @@ set -euo pipefail
88
.venv/bin/pip install -e ".[dev]" -q
99
.venv/bin/ruff check octorules_google/ tests/
1010
.venv/bin/ruff format --check octorules_google/ tests/
11+
.venv/bin/yamllint --no-warnings .github/workflows/*.yaml

0 commit comments

Comments
 (0)