dbmc - urllib3 error

  • hi

    i am using dbmc (dropbox addon) on libreelec krypton build. after the last addon update i receive an error, that dbmc needs urllib3:

    22:08:37 481.109039 T:140116060272384 ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
    - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
    Error Type: <type 'exceptions.ImportError'>
    Error Contents: Dropbox python client requires urllib3.

    urllib3 is installed as addon under
    /.kodi/addons/script.module.requests/lib/requests/packages/urllib3/

    is there anything further to do to be recognized by python? the owner of the addon said, that on his pc urllib3 can be found under /usr/lib/python2.7/dist-packages/urllib3/
    but on libreelec it's not there.
    any help is appreciated.


  • can you post the output of the following command?

    Code
    python -c "import sys; print(sys.path)"

    here's the output:

    # python -c "import sys; print(sys.path)"
    ['', '/usr/lib/python27.zip', '/usr/lib/python2.7', '/usr/lib/python2.7/plat-linux2', '/usr/lib/python2.7/lib-tk', '/usr/lib/python2.7/lib-old', '/usr/lib/python2.7/lib-dynload', '/usr/lib/python2.7/site-packages', '/usr/lib/python2.7/site-packages/gtk-2.0']


  • I just installed dbmc from the kodi repo and it works fine for me.

    A quick look and it seems like only urllib2 is needed?


    that's true for the repo version, but it fails to sync due to some changes concerning certificates. pls have a look at the kodi forum: Dropbox addon

    josetaza made a new version 0.9.5 for testing, it's not in the official repo yet -> download under Dbmc - Browse Files at SourceForge.net . this one works for him but fails on libreelec - at least on my pc. can you check this one too pls!?

  • So in "/storage/.kodi/addons/http://plugin.dbmc/resources/lib/dropbox/rest.py" change the line that says

    Code
    import urllib3


    to

    Code
    import requests.packages.urllib3 as urllib3

    Then it should work after restarting.
    This add-on should also depend on scripts.module.requests

    so in the addon.xml in the <requires> section it should have

    Code
    <import addon="script.module.requests" version="2.9.1" />


    this doesn't matter if you have script.module.requests installed already though.

    You might want to ping the author so he knows this

    also, he could do this

    Code
    try:
       import urllib3
    except ImportError:
       try:
          import requests.packages.urllib3 as urllib3
       except ImportError:
          raise ImportError('Dropbox python client requires urllib3.')


    or a similar solution

  • great, thanks a lot! i will try it when i am back home!

    EDIT: Thanks you, it's working again!

    Edited once, last by marv_el (August 6, 2016 at 7:43 PM).

  • Sorry for the silly question but how do i access it. Tried SSh ans Samba. Ihave no clue how to find storage. Thnx