Skip to content

Commit

Permalink
respond to feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
stan-dot committed Sep 24, 2024
1 parent b986e4b commit 0fdd395
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 17 deletions.
5 changes: 1 addition & 4 deletions src/dodal/aliases.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
from collections.abc import Callable
from typing import TypeAlias

try:
from typing import TypeAlias
except ImportError:
from typing import TypeAlias
from ophyd.device import Device as OphydV1Device
from ophyd_async.core import Device as OphydV2Device

Expand Down
2 changes: 1 addition & 1 deletion src/dodal/beamlines/i22.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ def dcm() -> DoubleCrystalMonochromator:
usage="Bragg",
type="silicon",
reflection=(3, 1, 1),
# todo update
# todo update d_spacing values to match the reflection maths
d_spacing=(3.13475, "nm"),
)

Expand Down
18 changes: 9 additions & 9 deletions src/dodal/beamlines/p38.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,15 +109,15 @@ def i0(
#


# def slits_1(
# wait_for_connection: bool = True,
# fake_with_ophyd_sim: bool = True,
# ) -> Slits:
# return numbered_slits(
# 1,
# wait_for_connection,
# fake_with_ophyd_sim,
# )
def slits_1(
wait_for_connection: bool = True,
fake_with_ophyd_sim: bool = True,
) -> Slits:
return numbered_slits(
1,
wait_for_connection,
fake_with_ophyd_sim,
)


def slits_2(
Expand Down
3 changes: 0 additions & 3 deletions tests/common/beamlines/test_device_instantiation.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,10 @@ def test_devices_are_identical(RE, module_and_devices_for_beamline):
Ensures that for every beamline all device functions are singletons to prevent duplicate instantiation.
"""
bl_mod, devices_a = module_and_devices_for_beamline
# if bl_mod.BL == "i22":
# pytest.skip("i22 uses the new setup")
devices_b, _ = make_all_devices(
bl_mod,
include_skipped=True,
fake_with_ophyd_sim=True,
)
print(devices_b)
for device_name in devices_a.keys():
assert devices_a[device_name] is devices_b[device_name]

0 comments on commit 0fdd395

Please sign in to comment.