Skip to content

Commit 8cb8fc8

Browse files
authored
Merge branch 'dev' into feat/remove-eth-dhcp
2 parents 82856db + eea8cc0 commit 8cb8fc8

File tree

2 files changed

+18
-16
lines changed

2 files changed

+18
-16
lines changed

BlocksScreen/lib/panels/widgets/probeHelperPage.py

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -524,14 +524,18 @@ def on_manual_probe_update(self, update: dict) -> None:
524524

525525
# if update.get("z_position_lower"):
526526
# f"{update.get('z_position_lower'):.4f} mm"
527-
if update.get("is_active"):
528-
if not self.isVisible():
529-
self.request_page_view.emit()
530-
531-
self.helper_initialize = False
532-
self.helper_start = True
527+
is_active = update.get("is_active", False)
528+
if is_active and not self.isVisible():
529+
self.request_page_view.emit()
530+
# Shared state updates
531+
self.helper_initialize = False
532+
self.helper_start = is_active
533+
# UI updates
534+
self._toggle_tool_buttons(is_active)
535+
if is_active:
533536
self._hide_option_cards()
534-
self._toggle_tool_buttons(True)
537+
else:
538+
self._show_option_cards()
535539

536540
if update.get("z_position_upper"):
537541
self.old_offset_info.setText(f"{update.get('z_position_upper'):.4f} mm")

Makefile

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -78,11 +78,11 @@ rcc-all: ## Force recompile all .qrc files
7878
# ─────────────────────────────────────────────────────────────────────────────
7979

8080
lint: ## Run pylint
81-
$(PYTHON) -m pylint $(SRC)
81+
$(PYTHON) -m pylint -j$(shell nproc) --recursive=y $(SRC)/
8282

83-
format-check: ## Verify formatting without modifying files (ruff-based)
84-
$(PYTHON) -m ruff format --check $(SRC) $(TESTS)
85-
$(PYTHON) -m ruff check $(SRC) $(TESTS)
83+
format-check: ## Verify formatting without modifying files (matches CI exactly)
84+
$(PYTHON) -m ruff check --target-version=py311 --config=pyproject.toml
85+
$(PYTHON) -m ruff format --diff --target-version=py311 --config=pyproject.toml
8686

8787
security: ## Run bandit security scan
8888
$(PYTHON) -m bandit -c pyproject.toml -r $(SRC)
@@ -145,11 +145,9 @@ docstrcov: ## Check docstring coverage (fail-under=80%, matches CI)
145145
# ─────────────────────────────────────────────────────────────────────────────
146146

147147
clean: ## Remove build artefacts, caches, and coverage data
148-
rm -rf dist/ build/ *.egg-info src/*.egg-info site/ htmlcov .coverage
149-
find . -depth \
150-
\( -type f -name '*.py[co]' \
151-
-o -type d -name __pycache__ \
152-
-o -type d -name .pytest_cache \) -exec rm -rf {} +
148+
rm -rf dist/ build/ *.egg-info src/*.egg-info site/ htmlcov/ .coverage .ruff_cache .mypy_cache
149+
find . -type d \( -name __pycache__ -o -name .pytest_cache \) -exec rm -rf {} + 2>/dev/null || true
150+
find . -type f -name '*.py[co]' -delete 2>/dev/null || true
153151

154152
clean-venv: ## Remove the virtual environment (destructive!)
155153
@echo "Removing $(VENV)..."

0 commit comments

Comments
 (0)