This is not a problem with kivy package. It's the bytesstring to string conversion which python3 doesn't like. The code is dyning post the download and fixing it to the string using decode may not be an option.
the data is initialized as data = '' which is a string. r represts the binary content and should be treated as bytes and not string s
for buf in r.iter_content(1024):
index += 1
data += buf <== dying here
count += len(buf)
print('Progression', count, animation[index % len(animation)], '\r')
sys.stdout.flush()
print('Download done ({} downloaded)'.format(count))
potential fix to the problem
change your garden python script to
data = b'' # initialize as a byte buffer
for buf in r.iter_content(1024):
index += 1
data += buf # the error would go away
count += len(buf)
print('Progression', count, animation[index % len(animation)], '\r')
sys.stdout.flush()
print('Download done ({} downloaded)'.format(count))
return BytesIO(data) change string io to BytesIO
this would require import at the top of the script
from io import BytesIO