Legend items move around when updating slider

I have a bokeh plot that has a slider function that changes the date. The graph plots circle glyphs that each represent a country. Each circle is colored a different color based on the continent it’s from. I inserted a legend that shows which colors are associated with which continents. However, when I move around the slider, the continents on the legend switch places and it doesn’t look organized. For example, on the first day of the slider, the order on the legend is 1) South America, 2) Europe, 3) Oceania, 4) North America, 5) Asia. However, when I move the slider to the next day, the order switches to 1) South America, 2) Europe, 3) Asia, 4) Oceania, 5) North America. And the order switches seem pretty random. Is there any way to keep the legend order fixed the entire time, even the slider moves? Thanks so much!