Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,15 @@ ci:

repos:
- repo: https://github.com/crate-ci/typos
rev: v1
rev: v1.40.0
hooks:
- id: typos
args: [--force-exclude] # omitting --write-changes

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.12.11
rev: v0.14.7
hooks:
- id: ruff-check
args: [--fix, --unsafe-fixes]
- id: ruff-format

- repo: https://github.com/abravalheri/validate-pyproject
Expand All @@ -23,7 +22,7 @@ repos:
- id: validate-pyproject

- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.17.1
rev: v1.19.0
hooks:
- id: mypy
files: "^src/"
Expand Down
2 changes: 1 addition & 1 deletion src/pymmcore_widgets/hcs/_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def find_circle_center(
B = np.sum(points**2, axis=1).reshape(-1, 1)

# Solve the least squares problem
params, _residuals, rank, s = np.linalg.lstsq(A, B, rcond=None)
params, _residuals, rank, _s = np.linalg.lstsq(A, B, rcond=None)

if rank < 3: # pragma: no cover
raise ValueError("The points are collinear or nearly collinear")
Expand Down
4 changes: 2 additions & 2 deletions src/pymmcore_widgets/hcs/_well_calibration_widget.py
Original file line number Diff line number Diff line change
Expand Up @@ -300,9 +300,9 @@ def _validate_calibration(self) -> None:
try:
# TODO: allow additional sanity checks for min/max radius, width/height
if self.circularWell():
x, y, radius = find_circle_center(points)
x, y, _radius = find_circle_center(points)
else:
x, y, width, height = find_rectangle_center(points)
x, y, _width, _height = find_rectangle_center(points)
except Exception as e: # pragma: no cover
self.setWellCenter(None)
QMessageBox.critical(
Expand Down
2 changes: 1 addition & 1 deletion tests/test_shutter_widget.py
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ def test_shutter_widget_UserWarning(qtbot: QtBot, global_mmcore: CMMCorePlus):
@pytest.mark.xfail(reason="flaky test")
def test_multi_shutter_state_changed(qtbot: QtBot, global_mmcore: CMMCorePlus):
mmc = global_mmcore
shutter, shutter1, multi_shutter = _make_shutters(qtbot)
shutter, _shutter1, multi_shutter = _make_shutters(qtbot)

with (
wait_signal(qtbot, mmc.events.propertyChanged),
Expand Down
Loading