cloud_py_api icon indicating copy to clipboard operation
cloud_py_api copied to clipboard

Seems like database not initialized properly. Try to re-enable the app

Open deimjons opened this issue 2 years ago • 11 comments
trafficstars

Describe the bug Hi. I used nextcloud in docker container. db - postgress, nextcloud from stable-fpm-alpine with ffmpeg, imagemagick, procps, samba-client, supervisor. I can't find cloud_py_api in nextcloud UI so I installed that manualy. NC version 25.0.6

To Reproduce Steps to reproduce the behavior:

  1. Go to '...'
  2. Perform some actions '...'
  3. See error

Expected behavior App just not working. with media DC the same

Screenshots Снимок экрана 2023-05-02 в 12 48 29

Desktop (please complete the following information):

  • OS [e.g. docker from stable-fpm-alpine]
  • CPU [architecture x86]
  • Nextcloud version [e.g. 25.0.6]
  • Database configuration (postgres:9-alpine)
  • app version, that using cloud_py_api
  • cloud_py_api version [e.g. 0.1.7]
  • cloud_py_api config and admin settings (can be obtained in bug report admin settings section)

deimjons avatar May 02 '23 11:05 deimjons

@deimjons Do you have viewer and serverinfo apps installed and enabled? Did you installed and enabled cloud_py_api first, then mediadc?

andrey18106 avatar May 02 '23 12:05 andrey18106

Thanks for the ideas on what I need to check. Now it is working well for me. Looks like serverinfo was disabled. Please add some information to cloud_py_api documentation/description that serverinfo and viewer required.

Information for the people who will have similar problem:

You need to check that these two default apps are enabled. https://github.com/nextcloud/serverinfo https://github.com/nextcloud/viewer

In my case, I didn't see these apps in nextcloud UI. Not in enabled, not in disabled. Maybe they have a different name in UI - I don't know. I just enable both with OSS command app:enable. In my case, serverinfo was disabled.

  1. I uninstalled mediaDC and cloud_py_api.
  2. Then enable serverinfo via OSS command app:enable serverinfo . (same with viewer)
  3. After that I installed cloud_py_api. It started to work.
  4. And the last step, I installed mediadc (installation take some time).

deimjons avatar May 14 '23 14:05 deimjons

I'm experiencing the same thing, except I already have the serverinfo and viewer apps enabled.

I see the following error in the logs:

Exception: Repair step 'OCA\Cloud_Py_API\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

Some info: OS [Docker nextcloud aio official image] CPU [architecture x86] Nextcloud version [26.0.2 RC1] Database configuration (default aio config) app version, that using cloud_py_api: N/A cloud_py_api version [0.1.7] cloud_py_api config and admin settings (can be obtained in bug report admin settings section)

TheSimpleZ avatar Jun 02 '23 13:06 TheSimpleZ

I'm experiencing the same thing, except I already have the serverinfo and viewer apps enabled.

I see the following error in the logs:

Exception: Repair step 'OCA\Cloud_Py_API\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

Some info: OS [Docker nextcloud aio official image] CPU [architecture x86] Nextcloud version [26.0.2 RC1] Database configuration (default aio config) app version, that using cloud_py_api: N/A cloud_py_api version [0.1.7] cloud_py_api config and admin settings (can be obtained in bug report admin settings section)

i am getting the exact same problem. (i was on the latest aio version, then updated to beta, still same results)

Arbel-arad avatar Jun 23 '23 07:06 Arbel-arad

i figured out the solution. there was a folder left from when i first tried to install mediaDC /mnt/ncdata/appdata_oc5bwmghpu5h/mediadc after deleting that and installing cloud python api again the settings page shows up!

Arbel-arad avatar Jun 24 '23 17:06 Arbel-arad

I also got it working. I did not fiddle with any folders. Simply update to the latest version (0.1.8)

TheSimpleZ avatar Jun 26 '23 12:06 TheSimpleZ

it doesn't seem like the update works with the brokenfolder still in place. anyway it's good that you got it working.

Arbel-arad avatar Jun 26 '23 13:06 Arbel-arad

I also had an issue with installing cloud_py_api and mediadc and resolved it by deleting false entries in my database due to what i think was a migration error on one of the last updates. I explained the steps i took in detail here.

rumexcrisp avatar Jul 05 '23 17:07 rumexcrisp

I also had this problem on nextcloud 27.0.0

I followed along with another post trying to fix it by delete some config of MediaDC, but don't do this ------WARNING!!! DON'T DO THIS BELOW----- I Wrongly deleted the database oc_mediadc_photos, oc_mediadc_settings, oc_mediadc_tasks, oc_mediadc_tasks_details, oc_mediadc_videos table in database, and cloud_py_api in oc_appconfig table in database It will bring you and error OC\DB\Exceptions\DbalException: An exception occurred while executing a query: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'weasam_ncloud2.oc_mediadc_tasks' doesn't exist ------WARNING!!! DON'T DO THIS ABOVE-----

install cloud_py_api first then install MediaDC Fortunately I copy the table from another newly installed nextcloud instance, keep in mind to backup your database first

weasam avatar Jul 20 '23 05:07 weasam

I get the following Exception when installing cloud-py: Exception: Repair step 'OCA\Cloud_Py_API\Migration\AppUpdateStep' can't be instantiated: Could not resolve OCA\ServerInfo\DatabaseStatistics! Class "OCA\ServerInfo\DatabaseStatistics" does not exist

(serverinfo app enabled)

cuthulino avatar Aug 05 '23 19:08 cuthulino

I have new instance installed, MediaDC installation issue come up again. After I enable some php function in php.ini, it install successfully, because my HestiaCP panel disable some php function by default

php.ini

....
; http://php.net/disable-functions
disable_functions = pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,passthru,popen
;;;;;;;;;;;;;;;;;;;;;; Custom Enabled begin ;;;;;;;;;;;;;;;;;;;;;;;;
; Enabled by Weasam moved from disable_function
; required by nextcloud: pcntl_signal,pcntl_signal_dispatch,shell_exec,exec,system,proc_open,
;;;;;;;;;;;;;;;;;;;;;; Custom Enabled end ;;;;;;;;;;;;;;;;;;;;;;;;
......

weasam avatar Dec 11 '23 01:12 weasam