Hi Jim - it looks buggy… Use MatchSrf, Position, ‘Match by closest points’ , to tune up the sweep edge to the input curve.
Poking at this a bit more, I see that one segment of the rail curve, the pooched out part - is an arc - that is, the curve has a weighted control point (rational). If I rebuild that segment of the rail, the sweep hits the rail nicely. I’ll look into it, it looks like the refitting of the rail needs a tune up for rational curves…