Invalid literal for float(): 31,9964643287382 cannot concatenate 'str' and 'float' objects

Python uses as decimal point the “.” But the scope is configurated with “,” (comma).
So, in the settings of the scope (go to Windows), regional and language options, customize. In the tab “numbers”, change the decimal symbole “,” by “.”