Skip to content

TUS support is broken #265

Description

@ewohnlich

Full disclosure, I don't know much about TUS. While researching it and Plone's support I found what appears to be bug.

https://github.com/plone/plone.app.content/blob/master/plone/app/content/browser/file.py#L41 this section checks if the python tus module is installed. I get an error here even though it is installed, because of a different error with tus.

Traceback (most recent call last):
  File "C:\Program Files\JetBrains\PyCharm 2023.2\plugins\python\helpers\pydev\pydevconsole.py", line 364, in runcode
    coro = func()
  File "<input>", line 1, in <module>
  File "C:\Program Files\JetBrains\PyCharm 2023.2\plugins\python\helpers\pydev\_pydev_bundle\pydev_import_hook.py", line 21, in do_import
    module = self._system_import(name, *args, **kwargs)
  File "C:\Users\oolit\PycharmProjects\plone\venv\lib\site-packages\tus\__init__.py", line 4, in <module>
    from StringIO import StringIO
  File "C:\Program Files\JetBrains\PyCharm 2023.2\plugins\python\helpers\pydev\_pydev_bundle\pydev_import_hook.py", line 21, in do_import
    module = self._system_import(name, *args, **kwargs)
ModuleNotFoundError: No module named 'StringIO'

This clearly hasn't been updated to python 3, and it's no surprise because the package hasn't been updated in 10 years. Perhaps support should be dropped, but if not it could use a test. I do not have the experience to help there :(

Original issue https://community.plone.org/t/large-chunked-uploads-and-maybe-tus-support-6-classic/17744/2

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions