### Godot version

4.0.dev (c309de53997feff3286295fb2d71657f112a15db)

### System information

Linux, Nvidia, Vulkan

### Issue description

Editor segfaults when certain conditions are met when using the AnimationPlayer editor.

### Steps to reproduce

1. Create multiple animations, saved into a animation collection
2. Open an existing animation, then make a new empty animation
3. Change from seconds to fps, or add a new property to animate ()
4. Editor crashes

NOTE: It is slightly random and I have not found a perfect repro

### Minimal reproduction project

N/A (TBD?)
if (selected_filter->is_pressed()) {
		_update_tracks(); 
	} else {
		_redraw_tracks();
		_redraw_groups();
	}
}
float AnimationTrackEditor::snap_time(float p_value, bool p_relative) {
	if (is_snap_enabled()) {
		double snap_increment;
		if (timeline->is_using_fps() && step->get_value() > 0) {
			snap_increment = 1.0 / step->get_value();
		} else {
			snap_increment = step->get_value();
		}
		if (Input::get_singleton()->is_key_pressed(Key::SHIFT)) {
			
			snap_increment *= 0.25;
		}
		if (p_relative) {
			double rel = Math::fmod(timeline->get_value(), snap_increment);
			p_value = Math::snapped(p_value + rel, snap_increment) - rel;
		} else {
			p_value = Math::snapped(p_value, snap_increment);
		}
	}
	return p_value;
}
void AnimationTrackEditor::_show_imported_anim_warning() {