Error: InvalidArgumentExpression files_sharing is using the old way to register

Support intro

Sorry to hear you’re facing problems :slightly_frowning_face:

help.nextcloud.com is for home/non-enterprise users. If you’re running a business, paid support can be accessed via portal.nextcloud.com where we can ensure your business keeps running smoothly.

In order to help you as quickly as possible, before clicking Create Topic please provide as much of the below as you can. Feel free to use a pastebin service for logs, otherwise either indent short log examples with four spaces:

example

Or for longer, use three backticks above and below the code snippet:

longer
example
here

Some or all of the below information will be requested if it isn’t supplied; for fastest response please provide as much as you can :heart:

Nextcloud version (eg, 18.0.2): 18.0.4
Operating system and version (eg, Ubuntu 20.04): FreeBSD 11.3-RELEASE-p8 #0 r360490
Apache or nginx version (eg, Apache 2.4.25): apache24-2.4.43
PHP version (eg, 7.1): php73-7.3.18

The issue you are facing: logs hammered with the “old way to register” even if the file sharing plugin is disabled.

Is this the first time you’ve seen this error? (Y/N): N

Steps to replicate it:

  1. Install
  2. Watch logs

The output of your Nextcloud log in Admin > Logging:

[no app in context] Error: InvalidArgumentException: Notifier Federated sharing (id: files_sharing) is not considered because it is using the old way to register. at <<closure>>

0. /usr/local/www/nextcloud/apps/federatedfilesharing/appinfo/app.php line 40
   OC\Notification\Manager->registerNotifier(Closure {}, Closure {})
1. /usr/local/www/nextcloud/lib/private/legacy/app.php line 266
   require_once("/usr/local/www/ ... p")
2. /usr/local/www/nextcloud/lib/private/legacy/app.php line 155
   OC_App::requireAppFile(OCA\FederatedFil ... {})
3. /usr/local/www/nextcloud/lib/private/legacy/app.php line 128
   OC_App::loadApp("federatedfilesharing")
4. /usr/local/www/nextcloud/lib/base.php line 993
   OC_App::loadApps()
5. /usr/local/www/nextcloud/index.php line 38
   OC::handleRequest()

GET /index.php/apps/logreader/poll?lastReqId=1NuyVBwzSplpSyk9aKiB
from 185.106.28.37 by gessel at 2020-06-08T12:47:30+00:00

The output of your config.php file in /path/to/nextcloud (make sure you remove any identifiable information!):

<?php
$CONFIG = array (
  'instanceid' => '',
  'passwordsalt' => '',
  'secret' => '/',
  'trusted_domains' =>
  array (
    0 => 'nas..com',
    1 => '173...144',
    2 => 'inas..com',
  ),
  'datadirectory' => '/usr/local/iNAS',
  'overwrite.cli.url' => 'https://nas..com/nextcloud',
  'dbtype' => 'mysql',
  'version' => '18.0.4.2',
  'dbname' => '',
  'dbhost' => '10.3..:',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'dbuser' => 'nextcloud_admin',
  'dbpassword' => '',
  'installed' => true,
  'memcache.local' => '\\OC\\Memcache\\Redis',
  'memcache.locking' => '\\OC\\Memcache\\Redis',
  'redis' =>
  array (
    'host' => '/tmp/redis.sock',
    'port' => 0,
    'dbindex' => 0,
    'password' => '',
    'timeout' => 1.5,
  ),
  'mail_smtpmode' => 'smtp',
  'mail_smtpauthtype' => 'LOGIN',
  'mail_from_address' => 'nas',
  'mail_domain' => '.com',
  'mail_smtphost' => '10.3.69.135',
  'mail_smtpport' => '25',
  'appcodechecker' => false,
  'maintenance' => false,
  'apps_paths' =>
  array (
    0 =>
    array (
      'path' => '/usr/local/www/nextcloud/apps',
      'url' => '/apps',
      'writable' => true,
    ),
    1 =>
    array (
      'path' => '/usr/local/www/nextcloud/apps-pkg',
      'url' => '/apps-pkg',
      'writable' => false,
    ),
  ),
  'log_type' => 'file',
  'logfile' => '/var/log/nextcloud.log',
  'loglevel' => 4,
  'theme' => '',
  'session_lifetime' => 6220800,
  'ldapIgnoreNamingRules' => false,
  'ldapProviderFactory' => 'OCA\\User_LDAP\\LDAPProviderFactory',
  'app_install_overwrite' =>
  array (
    0 => 'theming_customcss',
    1 => 'metadata',
    2 => 'dashboard',
    3 => 'socialsharing_email',
    4 => 'files_texteditor',
  ),
  'has_rebuilt_cache' => true,
  'mysql.utf8mb4' => true,
);

The output of your Apache/nginx/system log in /var/log/____:

[Mon Jun 08 05:54:58.364688 2020] [proxy_fcgi:error] [pid 77295:tid 35205138944] (70008)Partial results are valid but processing is incomplete: [client 95.170.194.91:21607] AH01075: Error dispatching request to : (reading input brigade)

(different issue, I think, but the only error)

Updated to 19.0.0_1 (up to date)
and php73-7.3.19

changes to config.php:

-  'version' => '18.0.4.2',
+  'version' => '19.0.0.12',


-  'app_install_overwrite' =>
+  'app_install_overwrite' => 
   array (
 0 => 'theming_customcss',
 1 => 'metadata',
 2 => 'dashboard',
 3 => 'socialsharing_email',
 4 => 'files_texteditor',
+    5 => 'fulltextsearch_elasticsearch',
+    6 => 'files_fulltextsearch',
+    7 => 'fulltextsearch',
+    8 => 'passman',
   ),

Errors persist:

[no app in context] Error: InvalidArgumentException: Notifier Federated sharing (id: files_sharing) is not considered because it is using the old way to register. at <<closure>>

0. /usr/local/www/nextcloud/apps/federatedfilesharing/appinfo/app.php line 40
   OC\Notification\Manager->registerNotifier(Closure {}, Closure {})
1. /usr/local/www/nextcloud/lib/private/legacy/OC_App.php line 266
   require_once("/usr/local/www/ ... p")
2. /usr/local/www/nextcloud/lib/private/legacy/OC_App.php line 155
   OC_App::requireAppFile(OCA\FederatedFil ... {})
3. /usr/local/www/nextcloud/lib/private/legacy/OC_App.php line 128
   OC_App::loadApp("federatedfilesharing")
4. /usr/local/www/nextcloud/lib/base.php line 992
   OC_App::loadApps()
5. /usr/local/www/nextcloud/index.php line 37
   OC::handleRequest()

GET /index.php/apps/logreader/get?offset=0&count=50&levels=00011
from 185.106.28.207 by gessel at 2020-06-28T09:56:22+00:00

This appears to be a “frequent” error:

# grep "old way to register" nextcloud.log | wc -l
4044

Federated file sharing is disabled in this install.
(all cloud Federated Cloud Sharing options are disabled in “sharing” and the “Federation” app (v 1.9.0) is disabled in “Apps”

(enabling it does not quiet the errors).