While current Amtrak regulations do not explicitly prohibit bear spray, their prohibited items page lists the following categories of items as prohibited from both carry-on and checked luggage (bolding original):
Canisters, tanks or other devices containing propellants
Corrosive or dangerous chemicals or materials, including but not limited to liquid bleach, tear gas, electronic control devices (stun guns, TASER guns), radioactive and harmful bacteriological materials
Martial-arts and self-defense items, including but not limited to billy clubs, nightsticks, and nunchuks
One could argue that bear spray does not fall exactly into any of these three categories. However, at the top of the page, there is a note that (bolding mine)
The following prohibited items list is not an exhaustive list. Any item that is similar to the prohibited items below, even if not specifically mentioned, is also prohibited. Amtrak personnel may determine if an item not mentioned in this list is prohibited.
So basically, it's up to the Amtrak personnel. If an Amtrak employee learns that you're carrying bear spray, and decides that it falls into one of the above categories (and one could make an argument for each one of them, especially if one wasn't 100% familiar with bear spray), then you might be required to remove it from the train.
That said, what the regulations say and what actually happens can be two different things, as you seem to have found. I'd be curious to know if you actually asked any Amtrak employees about the bear spray, or whether it just flew under their radar.