groupfolders icon indicating copy to clipboard operation
groupfolders copied to clipboard

Upgrade from 27.1.6.2: Class OCA\\GroupFolders\\Helper\\LazyFolder contains 2 abstract methods and must therefore be declared abstract or implement the remaining methods (OCP\\Files\\Folder::searchBySystemTag, OCP\\Files\\FileInfo::getMetadata)

Open ChristophWurst opened this issue 1 year ago โ€ข 11 comments

How to use GitHub

  • Please use the ๐Ÿ‘ reaction to show that you are affected by the same issue.
  • Please don't comment if you have no relevant information to add. It's just extra noise for everyone subscribed to this issue.
  • Subscribe to receive notifications on status change and new comments.

Steps to reproduce

  1. Run Nextcloud 27.1.6
  2. Use web updater to go to 28
  3. When the updater is done replacing Nextcloud, I go "Back to Nextcloud" to click the upgrade

Expected behaviour

Nextcloud shows and I can proceed with the upgrade.

Actual behaviour

Blank page. I have to look into the logs to get any information.

{
  "reqId": "OHaWUQE8vQnAq6PKZn2z",
  "level": 3,
  "time": "2024-02-02T11:24:09+00:00",
  "remoteAddr": "abc:123",
  "user": "--",
  "app": "PHP",
  "method": "GET",
  "url": "/",
  "message": "Class OCA\\GroupFolders\\Helper\\LazyFolder contains 2 abstract methods and must therefore be declared abstract or implement the remaining methods (OCP\\Files\\Folder::searchBySystemTag, OCP\\Files\\FileInfo::getMetadata) at /var/www/nextcloud/apps/groupfolders/lib/Helper/LazyFolder.php#32",
  "userAgent": "Mozilla/5.0 (X11; Linux x86_64; rv:120.0) Gecko/20100101 Firefox/120.0",
  "version": "27.1.6.2",
  "data": {
    "app": "PHP"
  }
}

Server configuration

Operating system:

Web server:

Database:

PHP version:

Nextcloud version: 27.1.6.2/28.0.2

Group folders version: groupfolders: 15.3.4

Updated from an older Nextcloud/ownCloud or fresh install:

Where did you install Nextcloud from:

Are you using external storage, if yes which one: local/s3/smb/sftp/...

Are you using encryption: yes/no

Are you using an external user-backend, if yes which one: LDAP/ActiveDirectory/Webdav/Saml/...

Client configuration

Browser:

Operating system:

Logs

Web server error log

Web server error log
Insert your webserver log here

Nextcloud log (data/nextcloud.log)

Nextcloud log
Insert your Nextcloud log here

Browser log

Browser log
Insert your browser log here, this could for example include:

a) The javascript console log
b) The network log
c) ...

ChristophWurst avatar Feb 02 '24 11:02 ChristophWurst

Once groupfolders is disabled, the blank page vanishes and I'm back at the expected upgrade screen

image

ChristophWurst avatar Feb 02 '24 11:02 ChristophWurst

cc @artonge judging from the Exception this compatibility issue should be not too hard to fix (or catch and allow the update process to continue)?

sorbaugh avatar Feb 02 '24 14:02 sorbaugh

From what I understand, this implementation of LazyFolder has been removed in 28: https://github.com/nextcloud/groupfolders/pull/2607 So upgrading groupfolders should fix the issue. Shouldn't groupfolders be automatically upgraded to 28 during the server upgrade ? Or at least disabled if the version for 28 is not available?

artonge avatar Feb 05 '24 10:02 artonge

Edit: the currently (after the update) installed version of Groupfolders is 16.0.3

I just had the same issue. When I manually disabled the plugin via occ I was able to upgrade to 28. No automatic update of the plugin was performed. After the update to 28 was done I had to manually allow an "untested plugin", manually upgrade and manually activate it.

It still doesn't work although it's shown as enabled. I can see my files in the "recent changes" and the config is still the same, no files are lost. But in the files-tab none of the group-folders are shown, although the permissions are set correctly. By directly accessing the file (through "recent"-tab) I can see and open the file, but the group-folders are not visible. Using occ maintenance:repair didn't change anything. Restarts didn't help and reinstalling the plugin didn't help either (in various combinations)

I have attached a few screenshots, showing my view. As you can see in the "all files" tab nothing is shown, grafik in the "recent" tab everything is shown, even the groupfolders grafik and when entering a groupfolder via the "recent" tab, nothing is shown, but the path is correct and exists. grafik

thebootable avatar Feb 06 '24 00:02 thebootable

So upgrading groupfolders should fix the issue. Shouldn't groupfolders be automatically upgraded to 28 during the server upgrade ? Or at least disabled if the version for 28 is not available?

Reconstructed upgrade

  1. Maintenance mode enables
  2. Apps are upgraded while still on 27
    1. {"reqId":"7Lb9oeK8g2qieaCA8Ko9","level":0,"time":"2024-02-01T15:43:15+00:00","remoteAddr":"","user":"--","app":"updater","method":"","url":"--","message":"\\OC\\Updater::checkAppStoreAppBefore: Checking for update of app "groupfolders\" in appstore","userAgent":"--","version":"27.1.6.2","data":{"app":"updater"}}
    2. {"reqId":"7Lb9oeK8g2qieaCA8Ko9","level":0,"time":"2024-02-01T15:43:15+00:00","remoteAddr":"","user":"--","app":"updater","method":"","url":"--","message":"\\OC\\Updater::checkAppStoreApp: Checked for update of app \"groupfolders\" in appstore","userAgent":"--","version":"27.1.6.2","data":{"app":"updater"}}
  3. Repair steps are executed while still on 27 (taken from config.php?)
  4. BROKEN INSTALLATION (LazyFolder contains 2 abstract methods...)
  5. App manually disabled
  6. starting upgrade from 27.1.6.2 to 28.0.2.5
  7. (shipped?) apps are updated
  8. maintenance mode disabled manually
  9. groupfolders app updated manually
  10. groupfolders app enabled manually

So it could be that the pre upgrade app update only goes to the latest app release for 27, not the one for 28 and the upgrade to 28 runs with the incompatible version.

ChristophWurst avatar Feb 06 '24 08:02 ChristophWurst

So the solution would be to implement a 28 interface in the 27 version of groupfolders? Sounds weird, but maybe there is no other way.

artonge avatar Feb 06 '24 10:02 artonge

Yeah. I could imagine other apps fall apart on this, too. Should apps be disabled during the upgrade? Then this would not have happened either.

ChristophWurst avatar Feb 06 '24 10:02 ChristophWurst

the issue with not showing any files seems to be a problem from another plugin (SAML), see https://github.com/nextcloud/user_saml/issues/810 "locally" generated users can see all files as expected, sorry!

Edit: the currently (after the update) installed version of Groupfolders is 16.0.3

I just had the same issue. When I manually disabled the plugin via occ I was able to upgrade to 28. No automatic update of the plugin was performed. After the update to 28 was done I had to manually allow an "untested plugin", manually upgrade and manually activate it.

It still doesn't work although it's shown as enabled. I can see my files in the "recent changes" and the config is still the same, no files are lost. But in the files-tab none of the group-folders are shown, although the permissions are set correctly. By directly accessing the file (through "recent"-tab) I can see and open the file, but the group-folders are not visible. Using occ maintenance:repair didn't change anything. Restarts didn't help and reinstalling the plugin didn't help either (in various combinations)

I have attached a few screenshots [...]

thebootable avatar Feb 10 '24 14:02 thebootable

Same issue. app:disable groupfolders solved the problem.

omitrowski avatar Feb 21 '24 19:02 omitrowski

I was affected by the same problem

Polve avatar Feb 23 '24 16:02 Polve

Running occ upgrade in terminal resolved the issue for me.

dharmann avatar Jul 16 '24 14:07 dharmann

Looks like we got rid of it after 27, so it is no longer relevant and was likely a caching issue on the web server or old files that didn't get deleted by the update.

provokateurin avatar Sep 18 '24 08:09 provokateurin

We had the same issue when upgrading from v27 to v28 via CLI :( Details: https://help.nextcloud.com/t/lazyfolder-contains-3-abstract-declared-abstract-or-implement-the-remaining-methods/177086/9?u=nextclaus

NextClaus avatar Sep 18 '24 15:09 NextClaus

@joshtrichards Why was this issue closed when it's still there? It does not seem to be a Nextcloud issue but an Groupfolder issue. Therefore referencing to https://github.com/nextcloud/server/issues/42754 makes no sense in my eyes...

NextClaus avatar Sep 18 '24 15:09 NextClaus

Can you check if the file at apps/groupfolders/lib/Helper/LazyFolder.php is still present? Also as I said this file no longer exists in 28 so there should not be a problem as the code no longer exists.

provokateurin avatar Sep 18 '24 15:09 provokateurin

@provokateurin I even do not see the folder "Helper": image

NextClaus avatar Sep 18 '24 18:09 NextClaus

But you still see this error message? Please restart your webserver as this has to be a caching issue.

provokateurin avatar Sep 18 '24 18:09 provokateurin

@provokateurin No, we are "save" now. We did the upgrade from v27 to v28 by disabling the Groupfolder app before starting the upgrade. Details: https://help.nextcloud.com/t/lazyfolder-contains-3-abstract-declared-abstract-or-implement-the-remaining-methods/177086/9?u=nextclaus

With my posting I wanted to emphasize that the issue should be fixed. Why? There are for sure many Nextcloud admins who are still on v27 and use this app. When they do the upgrade to v28 they will run into the same issues which others and me had...

NextClaus avatar Sep 18 '24 18:09 NextClaus

Ok, but as I said this issue is not a problem with the app but with the caching of the webserver or left-over files. There is literally nothing I can do to fix this.

provokateurin avatar Sep 18 '24 18:09 provokateurin

Yea, maybe - I'm not a coder and therefore cannot judge about that. If it is not an app issue: Is there anything Nextcloud developers will do about that in future releases?

NextClaus avatar Sep 18 '24 18:09 NextClaus

No there is nothing that can be done, it's a caching problem of the webserver that happens sometimes when the code is updated and it can only be solved by restarting the webserver.

provokateurin avatar Sep 18 '24 21:09 provokateurin