koush / scrypted

Scrypted is a high performance video integration and automation platform
https://scrypted.app
Other
4.33k stars 255 forks source link

Wyze Plugin Python error #1629

Closed JoshuaSeidel closed 4 weeks ago

JoshuaSeidel commented 1 month ago

Describe the bug When installing the wyze plugin, this error happens

[notice] A new release of pip is available: 24.2 -> 24.3.1
[notice] To update, run: python3 -m pip install --upgrade pip
pip install result 0
/server/volume/plugins/@scrypted/wyze/python3.10-Linux-x86_64-20240317/requests/__init__.py:86: RequestsDependencyWarning: Unable to find acceptable character detection dependency (chardet or charset_normalizer).
  warnings.warn(
plugin start/fork failed
Traceback (most recent call last):
  File "/server/node_modules/@scrypted/server/python/plugin_remote.py", line 628, in loadZip
    return await self.loadZipWrapped(packageJson, getZip, options)
  File "/server/node_modules/@scrypted/server/python/plugin_remote.py", line 1055, in loadZipWrapped
    from main import create_scrypted_plugin  # type: ignore
  File "/server/volume/plugins/@scrypted/wyze/zip/unzipped/main.py", line 28, in <module>
    import wyzecam
  File "/server/volume/plugins/@scrypted/wyze/zip/unzipped/wyzecam/__init__.py", line 36, in <module>
    from wyzecam.api import (
  File "/server/volume/plugins/@scrypted/wyze/zip/unzipped/wyzecam/api.py", line 12, in <module>
    from wyzecam.api_models import WyzeAccount, WyzeCamera, WyzeCredential
  File "/server/volume/plugins/@scrypted/wyze/zip/unzipped/wyzecam/api_models.py", line 6, in <module>
    from pydantic import BaseModel
  File "/server/volume/plugins/@scrypted/wyze/python3.10-Linux-x86_64-20240317/pydantic/__init__.py", line 411, in __getattr__
    module = import_module(module_name, package=package)
  File "/usr/lib/python3.10/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "/server/volume/plugins/@scrypted/wyze/python3.10-Linux-x86_64-20240317/pydantic/main.py", line 28, in <module>
    import pydantic_core
  File "/server/volume/plugins/@scrypted/wyze/python3.10-Linux-x86_64-20240317/pydantic_core/__init__.py", line 6, in <module>
    from ._pydantic_core import (
ImportError: /server/volume/plugins/@scrypted/wyze/python3.10-Linux-x86_64-20240317/pydantic_core/_pydantic_core.cpython-310-x86_64-linux-gnu.so: failed to map segment from shared object

To Reproduce Steps to reproduce the behavior:

  1. Go to Plugins
  2. Search for Wzye
  3. Hit install plugin
  4. check logs

Expected behavior Clean install and working plugin

Server (please complete the following information):

bjia56 commented 1 month ago

https://github.com/pydantic/pydantic-core/issues/1461 Possible permission error in docker mount. Consider deleting plugin and ensuring plugin folder on host is empty, then recreate the container and reinstall the plugin.

JoshuaSeidel commented 1 month ago

https://github.com/pydantic/pydantic-core/issues/1461

Possible permission error in docker mount. Consider deleting plugin and ensuring plugin folder on host is empty, then recreate the container and reinstall the plugin.

I tried this many times, no luck. Every other plugin I've installed is fine

bjia56 commented 4 weeks ago

Per similar issue reported in Discord, it's possible this is due to the filesystem being mounted as noexec. Disable that on the filesystem used as the Scrypted volume mount.