Skip to content

Commit

Permalink
Merge remote-tracking branch 'michi42/patch-1' into release/0.72.1
Browse files Browse the repository at this point in the history
  • Loading branch information
szymonlopaciuk committed Dec 16, 2024
2 parents 57d0ad9 + 7b68e7b commit e5321e2
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions xtrack/beam_elements/elements.py
Original file line number Diff line number Diff line change
Expand Up @@ -2447,6 +2447,10 @@ def from_line(cls, line, start, end, twiss_table=None,
A `SecondOrderTaylorMap` object.
'''
if start == end:
# start == end will lead to compute_one_turn_matrix_finite_differences() computing a
# full one-turn response matrix (but here we would rather expect identity)
raise NotImplementedError('end element must be after start element')

if twiss_table is None:
tw = line.twiss(reverse=False)
Expand Down

0 comments on commit e5321e2

Please sign in to comment.