Skip to content

Commit aa3ead2

Browse files
authored
Merge pull request #331 from cta-observatory/flake_e231
Update .pre-commit-config.yaml
2 parents a42b8b8 + 02a35e6 commit aa3ead2

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ repos:
1111
- id: black-jupyter
1212
# https://black.readthedocs.io/en/stable/guides/using_black_with_other_tools.html?highlight=other%20tools#flake8
1313
- repo: https://github.com/PyCQA/flake8
14-
rev: 5.0.4
14+
rev: 6.1.0
1515
hooks:
1616
- id: flake8
1717
args: [--max-line-length=88, "--extend-ignore=E203,E712"]

magicctapipe/image/calib.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,11 +68,11 @@ def calibrate(
6868
raise ValueError(
6969
"Check the provided parameters and the telescope type; LST calibration not possible if gamera_geoms not provided"
7070
)
71-
if (not is_lst) and (type(magic_clean[tel_id]) != MAGICClean):
71+
if (not is_lst) and (not isinstance(magic_clean[tel_id], MAGICClean)):
7272
raise ValueError(
7373
"Check the provided magic_clean parameter; MAGIC calibration not possible if magic_clean not a dictionary of MAGICClean objects"
7474
)
75-
if (is_lst) and (type(camera_geoms[tel_id]) != CameraGeometry):
75+
if (is_lst) and (not isinstance(camera_geoms[tel_id], CameraGeometry)):
7676
raise ValueError(
7777
"Check the provided camera_geoms parameter; LST calibration not possible if camera_geoms not a dictionary of CameraGeometry objects"
7878
)

0 commit comments

Comments
 (0)