I think you will find that that "spring" is where the speedo outer cable has s-t-r-e-t-c-h-e-d out sooooo far.
And the black plastic couldn't match it, so has pulled away exposing it.
The inner cable is likely to be toast after that too ?
You are up for a new cable, at least...
Check that the threads and nuts at each end of the cable are still good, and the fittings they attach to,
and that it hasn't tugged at the speedo and done any damage.
Sorry to be the bearer of not-so-good news.
Have fun !
P.S. It could be that that spring is a protective shield that goes over the cable, so may or may not be so badly damaged.
Some sunlight on the situation can only help....