diff --git a/qiskit/pulse/instructions/delay.py b/qiskit/pulse/instructions/delay.py index edaa406f4fcb..1b911c350731 100644 --- a/qiskit/pulse/instructions/delay.py +++ b/qiskit/pulse/instructions/delay.py @@ -47,10 +47,7 @@ def __init__( Args: duration: Length of time of the delay in terms of dt. channel: The channel that will have the delay. - name: Name of the delay for display purposes. - - Raises: - PulseError: If `channel` cannot be delayed because it is a classical IO channel. + name: Name of the delay for display purposes.k """ super().__init__(operands=(duration, channel), name=name) diff --git a/qiskit/pulse/instructions/frequency.py b/qiskit/pulse/instructions/frequency.py index dfff24ce9b48..15866e0ae79a 100644 --- a/qiskit/pulse/instructions/frequency.py +++ b/qiskit/pulse/instructions/frequency.py @@ -106,7 +106,7 @@ def __init__( frequency = float(frequency) if not isinstance(channel, PulseChannel): raise PulseError( - "The `channel` argument to `SetFrequency` must be of type `channels.PulseChannel`." + "The `channel` argument to `ShiftFrequency` must be of type `channels.PulseChannel`." ) super().__init__(operands=(frequency, channel), name=name) diff --git a/test/python/pulse/test_transforms.py b/test/python/pulse/test_transforms.py index 1cfb28f55245..e19d024c2b4f 100644 --- a/test/python/pulse/test_transforms.py +++ b/test/python/pulse/test_transforms.py @@ -364,7 +364,13 @@ def test_pad_no_delay_on_classical_io_channels(self): + Delay(delay, SnapshotChannel()) ) - self.assertEqual(transforms.pad(sched, until=15), sched) + ref_sched = ( + Delay(delay, MemorySlot(0)).shift(20) + + Delay(delay, RegisterSlot(0)).shift(10) + + Delay(delay, SnapshotChannel()) + ) + + self.assertEqual(transforms.pad(sched, until=15), ref_sched) def get_pulse_ids(schedules: List[Schedule]) -> Set[int]: