cloud-py-api / mediadc

Nextcloud Media Duplicate Collector application
https://apps.nextcloud.com/apps/mediadc
GNU Affero General Public License v3.0
95 stars 8 forks source link

Internal Server Error with MediaDC #246

Open kanwarplaha opened 4 months ago

kanwarplaha commented 4 months ago

I tried to install MediaDC manually when automated install via app store fails to work. I still see "Internal Server Error".

$ php -f /var/www/html/occ app:enable mediadc
mediadc 0.3.9 enabled

I am running NextCloud AIO v29.0.3. Cloud-API was installed and enabled before running the above.

andrey18106 commented 4 months ago

Hi! @kanwarplaha is there any log error messages after attempt to enable the app?

kanwarplaha commented 4 months ago

Hello @andrey18106 thanks for quick reply. Since I'm running nextcloud aio (all docker containers), which one should I check for logs? is it nextcloud, apache or another one?

andrey18106 commented 4 months ago

The error should be in nextcloud log

kanwarplaha commented 4 months ago

No, there is no error in nextcloud log:

[16-Jul-2024 03:44:01] NOTICE: fpm is running, pid 409
[16-Jul-2024 03:44:01] NOTICE: ready to handle connections
Error: Not a valid JPG - /tmp/0de1366b887e062898f274753d03fb2b.jpg
Error: Not a valid JPG - /tmp/755264b439bc3b10144e840caf9aa992.jpg
Error: Not a valid JPG - /tmp/5289e2f86206cb024af4e1b34b67acec.jpg
Error: Not a valid JPG - /tmp/587ff1abed099c2065a36d18a71c7dbb.jpg

^C

The time right now is 6:51 PM which would be 8:51 AM UTC (as I am not sure what timezone the logs are written in)

andrey18106 commented 4 months ago

Can't confirm locally with AIO and NC 29.0.3. Could you have a look at logs, there should be logreader app installed and corresponding section in admin settings (Logging).

kanwarplaha commented 4 months ago

Thanks @andrey18106 here are the two errors I get in the Log Reader once I enable MediaDC:

Error   no app in context   
Exception
Repair step 'OCA\MediaDC\Migration\AppDataInitializationStep' can't be instantiated: Could not resolve OCA\Cloud_Py_API\Service\UtilsService! Class "OCA\Cloud_Py_API\Service\UtilsService" does not exist
Exception thrown: Exception
---
Error   no app in context   
Exception
Repair step 'OCA\MediaDC\Migration\AppUpdateStep' can't be instantiated: Could not resolve OCA\Cloud_Py_API\Service\UtilsService! Class "OCA\Cloud_Py_API\Service\UtilsService" does not exist
Exception thrown: Exception
---
kanwarplaha commented 4 months ago

Okay, I resolved it by Installing Cloud Python API. I had thought it was installed but apparently not! MediaDC loads now but I get the following PHP error in the logs:

scandir(/mnt/ncdata/appdata_ocikk9f7zjl2/mediadc/binaries/mediadc_musllinux_amd64): Failed to open directory: No such file or directory at /var/www/html/custom_apps/cloud_py_api/lib/Service/UtilsService.php#494

and

scandir(): (errno 0): No error information at /var/www/html/custom_apps/cloud_py_api/lib/Service/UtilsService.php#494

Should I worry about these?

andrey18106 commented 4 months ago

Try to re-enable MediaDC after you've installed CloudPyAPI, the binaries download done during the enabling of the app.