title: Kivy garden mapview deploying error with Buildozer
body: <p>I am using kivy.garden.mapview for my application. Everything works properly, but problems arise when I try to deploy the application to Android with Buildozer. I set "garden_requirements = mapview" in the .spec file, and I always get the same error message: "Command failed: garden install --app mapview". The command fails even when I execute it on its own. The command "buildozer android debug deploy run logcat" produces the following output:</p>
  
  <pre><code>albi@albi-VirtualBox:~/CUCINA$ buildozer android debug deploy run logcat
  # Check configuration tokens
  # Ensure build layout
  # Check configuration tokens
  # Preparing build
  # Check requirements for android
  # Run 'dpkg --version'
  # Cwd None
  Debian 'dpkg' package management program version 1.19.7 (amd64).
  This is free software; see the GNU General Public License version 2 or
  later for copying conditions. There is NO warranty.
  # Search for Git (git)
  #  -&gt; found at /usr/bin/git
  # Search for Cython (cython)
  #  -&gt; found at /home/albi/.local/bin/cython
  # Search for Java compiler (javac)
  #  -&gt; found at /usr/lib/jvm/java-8-openjdk-amd64/bin/javac
  # Search for Java keytool (keytool)
  #  -&gt; found at /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/keytool
  # Install platform
  # Run 'git config --get remote.origin.url'
  # Cwd /home/albi/CUCINA/.buildozer/android/platform/python-for-android
  https://github.com/kivy/python-for-android.git
  # Run 'git branch -vv'
  # Cwd /home/albi/CUCINA/.buildozer/android/platform/python-for-android
  * master 1b3b0e3f [origin/master] Merge pull request #2225 from kivy/release-2020.06.02
  # Run '/usr/bin/python3 -m pip install -q --user \'appdirs\' \'colorama&gt;=0.3.3\' \'jinja2\' \'six\' \'enum34; python_version&lt;"3.4"\' \'sh&gt;=1.10; sys_platform!="nt"\' \'pep517&lt;0.7.0"\' \'toml\''
  # Cwd None
  # Apache ANT found at /home/albi/.buildozer/android/platform/apache-ant-1.9.4
  # Android SDK found at /home/albi/.buildozer/android/platform/android-sdk
  # Recommended android's NDK version by p4a is: 19c
  # Android NDK found at /home/albi/.buildozer/android/platform/android-ndk-r19c
  # Check application requirements
  # Check garden requirements
  # Remove directory and subdirectory /home/albi/CUCINA/.buildozer/libs
  # Run 'bash -c "source venv/bin/activate &amp;&amp; env"'
  # Cwd /home/albi/CUCINA/.buildozer
  SHELL=/bin/bash
  SESSION_MANAGER=local/albi-VirtualBox:@/tmp/.ICE-unix/1718,unix/albi-VirtualBox:/tmp/.ICE-unix/1718
  QT_ACCESSIBILITY=1
  COLORTERM=truecolor
  XDG_CONFIG_DIRS=/etc/xdg/xdg-ubuntu:/etc/xdg
  XDG_MENU_PREFIX=gnome-
  GNOME_DESKTOP_SESSION_ID=this-is-deprecated
  GTK_IM_MODULE=ibus
  QT4_IM_MODULE=ibus
  LC_ADDRESS=it_IT.UTF-8
  GNOME_SHELL_SESSION_MODE=ubuntu
  LC_NAME=it_IT.UTF-8
  SSH_AUTH_SOCK=/run/user/1000/keyring/ssh
  XMODIFIERS=@im=ibus
  DESKTOP_SESSION=ubuntu
  LC_MONETARY=it_IT.UTF-8
  SSH_AGENT_PID=1649
  ANDROIDAPI=27
  GTK_MODULES=gail:atk-bridge
  PWD=/home/albi/CUCINA/.buildozer
  PACKAGES_PATH=/home/albi/.buildozer/android/packages
  XDG_SESSION_DESKTOP=ubuntu
  LOGNAME=albi
  XDG_SESSION_TYPE=x11
  GPG_AGENT_INFO=/run/user/1000/gnupg/S.gpg-agent:0:1
  ANDROIDNDK=/home/albi/.buildozer/android/platform/android-ndk-r19c
  XAUTHORITY=/run/user/1000/gdm/Xauthority
  GJS_DEBUG_TOPICS=JS ERROR;JS LOG
  WINDOWPATH=2
  HOME=/home/albi
  USERNAME=albi
  IM_CONFIG_PHASE=1
  LC_PAPER=it_IT.UTF-8
  LANG=en_US.UTF-8
  LS_COLORS=rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.zst=01;31:*.tzst=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.wim=01;31:*.swm=01;31:*.dwm=01;31:*.esd=01;31:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:
  XDG_CURRENT_DESKTOP=ubuntu:GNOME
  VIRTUAL_ENV=/home/albi/CUCINA/.buildozer/venv
  VTE_VERSION=6001
  GNOME_TERMINAL_SCREEN=/org/gnome/Terminal/screen/66ea9009_ef14_420d_ae9a_ff4590d07de8
  INVOCATION_ID=5f9f2518374145c29f2f6ad18acfb7f8
  MANAGERPID=1473
  CLUTTER_IM_MODULE=ibus
  GJS_DEBUG_OUTPUT=stderr
  LESSCLOSE=/usr/bin/lesspipe %s %s
  XDG_SESSION_CLASS=user
  LC_IDENTIFICATION=it_IT.UTF-8
  TERM=xterm-256color
  LESSOPEN=| /usr/bin/lesspipe %s
  USER=albi
  ANDROIDMINAPI=21
  GNOME_TERMINAL_SERVICE=:1.140
  DISPLAY=:0
  SHLVL=1
  LC_TELEPHONE=it_IT.UTF-8
  QT_IM_MODULE=ibus
  LC_MEASUREMENT=it_IT.UTF-8
  XDG_RUNTIME_DIR=/run/user/1000
  PS1=(venv)
  LC_TIME=it_IT.UTF-8
  ANDROIDSDK=/home/albi/.buildozer/android/platform/android-sdk
  JOURNAL_STREAM=9:32116
  XDG_DATA_DIRS=/usr/share/ubuntu:/usr/local/share/:/usr/share/:/var/lib/snapd/desktop
  PATH=/home/albi/CUCINA/.buildozer/venv/bin:/home/albi/.buildozer/android/platform/apache-ant-1.9.4/bin:/home/albi/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
  GDMSESSION=ubuntu
  DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
  LC_NUMERIC=it_IT.UTF-8
  OLDPWD=/home/albi
  _=/usr/bin/env
  # Run 'pip install Kivy-Garden==0.1.1'
  # Cwd None
  Requirement already satisfied: Kivy-Garden==0.1.1 in ./.buildozer/venv/lib/python3.8/site-packages (0.1.1)
  Requirement already satisfied: requests in ./.buildozer/venv/lib/python3.8/site-packages (from Kivy-Garden==0.1.1) (2.23.0)
  Requirement already satisfied: certifi&gt;=2017.4.17 in ./.buildozer/venv/lib/python3.8/site-packages (from requests-&gt;Kivy-Garden==0.1.1) (2020.4.5.2)
  Requirement already satisfied: idna&lt;3,&gt;=2.5 in ./.buildozer/venv/lib/python3.8/site-packages (from requests-&gt;Kivy-Garden==0.1.1) (2.9)
  Requirement already satisfied: urllib3!=1.25.0,!=1.25.1,&lt;1.26,&gt;=1.21.1 in ./.buildozer/venv/lib/python3.8/site-packages (from requests-&gt;Kivy-Garden==0.1.1) (1.25.9)
  Requirement already satisfied: chardet&lt;4,&gt;=3.0.2 in ./.buildozer/venv/lib/python3.8/site-packages (from requests-&gt;Kivy-Garden==0.1.1) (3.0.4)
  # Create directory /home/albi/CUCINA/.buildozer/libs
  # Install garden package mapview in buildozer_dir
  # Run 'garden install --app mapview'
  # Cwd /home/albi/CUCINA/.buildozer
  Downloading http://github.com/kivy-garden/garden.mapview/archive/master.zip ...
  Traceback (most recent call last):
    File "/home/albi/CUCINA/.buildozer/venv/bin/garden", line 189, in &lt;module&gt;
      GardenTool().main(sys.argv[1:])
    File "/home/albi/CUCINA/.buildozer/venv/bin/garden", line 71, in main
      options.func()
    File "/home/albi/CUCINA/.buildozer/venv/bin/garden", line 109, in cmd_install
      fd = self.download(opts.package)
    File "/home/albi/CUCINA/.buildozer/venv/bin/garden", line 170, in download
      data += buf
  TypeError: can only concatenate str (not "bytes") to str
  # Command failed: garden install --app mapview
  # ENVIRONMENT:
  #     PATH = '/home/albi/CUCINA/.buildozer/venv/bin:/home/albi/.buildozer/android/platform/apache-ant-1.9.4/bin:/home/albi/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin'
  #     PACKAGES_PATH = '/home/albi/.buildozer/android/packages'
  #     ANDROIDSDK = '/home/albi/.buildozer/android/platform/android-sdk'
  #     ANDROIDNDK = '/home/albi/.buildozer/android/platform/android-ndk-r19c'
  #     ANDROIDAPI = '27'
  #     ANDROIDMINAPI = '21'
  #     VIRTUAL_ENV = '/home/albi/CUCINA/.buildozer/venv'
  #     CC = '/bin/false'
  #     CXX = '/bin/false'
  #
  # Buildozer failed to execute the last command
  # The error might be hidden in the log above this error
  # Please read the full log, and search for it before
  # raising an issue with buildozer itself.
  # In case of a bug report, please add a full log with log_level = 2
  albi@albi-VirtualBox:~/CUCINA$
  </code></pre>
  
  <p>I have tried everything I found on Stack Overflow, but nothing worked. Any suggestion?</p>