Closed HaleyACS closed 4 years ago
Hmmmm. Smells like a conflict with another app. Could you disable all optional apps, then try again? If that works re-enable the now disabled apps step by step and always retry occ
, as soon as it breaks we know the conflicting app.
I had the same issue and just solved it by disabling Suspicious Login via occ. I didn't test to see if it was a specific app conflict, but I know that most optional apps were already disabled at that point.
I also have this issue. Version 3.2 seems to completely break Nextcloud 18. Shown in the log: "Argument 1 passed to "Symfony\Component\EventDispatcher\EventDispatcherInterface::dispatch()" must be an object, string given."
Reverting to version 3.1 fixes it.
Here to report that I also had this issue after the latest update to suspicous_login. @mhbates suggestion to disable it via occ worked.
+1 back online after disabled
Okay, so here's the deal: if nobody helps locate the conflict, we won't be able to fix the bug.
Disabled everything that I can disable - still not working, same issue. Note that I checked the log and nextcloud after each disabled app. I can't play around too much, as this system is in production and classes start today in france. ` var/www/html # ./occ app:list Enabled:
I also had a conflict with the following error-message:
> sudo -u www-data php occ log:tail
PHP Fatal error: Declaration of Symfony\Component\Console\Style\OutputStyle::write($messages, bool $newline = false, int $type = self::OUTPUT_NORMAL) must be compatible with Symfony\Component\Console\Output\OutputInterface::write($messages, $newline = false, $options = 0) in /var/www/nextcloud/apps/suspicious_login/vendor/symfony/console/Style/OutputStyle.php on line 52
I disabled the app via occ for now.
My enabled apps:
I am trying to give a full bug report here. environment
steps to reproduce
occ log:watch
The following error has been loggend 5 times in a row:
Error index Exception: Argument 1 passed to 2020-09-01T11:13:07+00:00
"Symfony\Component\EventDispatcher\EventDispatcherInterface::dispatch()"
must be an object, string given. at
lib/private/AppFramework/Http/Dispatcher.php line 109
0. .../App.php line 125
OC\AppFramework\Http\Dispatcher->dispatch(
OCA\Fil ... {},
"index"
)
1. .../RouteActionHandler.php line 47
OC\AppFramework\App::main(
"OCA\\Files\\Controller ... r",
"index",
OC\AppFramework\Depende ... {},
{_route:"files.view.index"}
)
2. <<closure>>
OC\AppFramework\Routing\RouteActionHandler->__invoke(
{_route:"files.view.ind ... "}
)
3. lib/private/Route/Router.php line 299
call_user_func(
OC\AppFramework\Routing\RouteActio ... {},
{_route:"files.view.index"}
)
4. lib/base.php line 1013
OC\Route\Router->match("\/apps\/files\/")
5. index.php line 38
OC::handleRequest(
)
further information for sudo -u www-data php occ app:list
Enabled:
After occ app:disable suspicious_login
its working again.
Okay thanks. In that case the conflict might be between Nextcloud and the app, which is … a bummer and really hard to fix. Let me see if I can delete the release, drop Nextcloud 18 support, and re-release.
Please downgrade to the previous version. Thanks.
Can we downgrade on the CLI? I don't know how to actually do that.
You can't. Download the tarball, replace everything in the apps dir. Run the upgrade procedure. Done.
Interesting though, a pure installation of Nextcloud 17/18/19/20 with this app installed does not cause any errors. So I think it might be caused by one other app.
@Coffeeri @grimSBZ would you have a few mins to try disable all of your many apps, see if the problem remains and then re-endable them one after the other until your installation breaks?
@Coffeeri @grimSBZ would you have a few mins to try disable all of your many apps, see if the problem remains and then re-endable them one after the other until your installation breaks?
As mentioned these are all default apps (and recommended). But just for fun i did disabled all enabled apps - at least those who can be disabled. I dont get any error page.
occ
- lets say support
- i get a stack trace
$ sudo -u www-data php occ app:enable support
An unhandled exception has been thrown:
TypeError: Argument 1 passed to "Symfony\Component\EventDispatcher\EventDispatcherInterface::dispatch()" must be an object, string given. in /var/www/testcloud2/3rdparty/symfony/event-dispatcher/EventDispatcher.php:63
Stack trace:
#0 /var/www/testcloud2/lib/private/EventDispatcher/SymfonyAdapter.php(70): Symfony\Component\EventDispatcher\EventDispatcher->dispatch('\\OC\\Repair::ste...', Object(Symfony\Component\EventDispatcher\GenericEvent))
#1 /var/www/testcloud2/lib/private/Repair.php(204): OC\EventDispatcher\SymfonyAdapter->dispatch('\\OC\\Repair::ste...', Object(Symfony\Component\EventDispatcher\GenericEvent))
#2 /var/www/testcloud2/lib/private/Repair.php(103): OC\Repair->emit('\\OC\\Repair', 'step', Array)
#3 /var/www/testcloud2/lib/private/legacy/app.php(981): OC\Repair->run()
#4 /var/www/testcloud2/lib/private/Installer.php(160): OC_App::executeRepairSteps('support', Array)
#5 /var/www/testcloud2/core/Command/App/Enable.php(117): OC\Installer->installApp('support', false)
#6 /var/www/testcloud2/core/Command/App/Enable.php(91): OC\Core\Command\App\Enable->enableApp('support', Array, false, Object(Symfony\Component\Console\Output\ConsoleOutput))
#7 /var/www/testcloud2/3rdparty/symfony/console/Command/Command.php(255): OC\Core\Command\App\Enable->execute(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#8 /var/www/testcloud2/3rdparty/symfony/console/Application.php(915): Symfony\Component\Console\Command\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#9 /var/www/testcloud2/3rdparty/symfony/console/Application.php(272): Symfony\Component\Console\Application->doRunCommand(Object(OC\Core\Command\App\Enable), Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#10 /var/www/testcloud2/3rdparty/symfony/console/Application.php(148): Symfony\Component\Console\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#11 /var/www/testcloud2/lib/private/Console/Application.php(214): Symfony\Component\Console\Application->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#12 /var/www/testcloud2/console.php(99): OC\Console\Application->run()
#13 /var/www/testcloud2/occ(11): require_once('/var/www/testcl...')
Got it. So it might the difference between default apps (the ones that are packaged) and shipped apps (the ones that live in https://github.com/nextcloud/server). Thanks for testing!
Landed here because update of this app from 3.1.0 to 3.2.0 broke my nextcloud 18.0.8 installation raising the mentioned error in nextcloud log. Manually downgrading to 3.1.0 through download of tarball fixed it. So there's something obvious: Changes from 3.1.0 to 3.2.0 throws the Symphony execption and therefore breaks nextcloud 18.0.8 in total.
So there's something obvious
How is it obvious?
So there's something obvious
How is it obvious?
When one has a working system (for years) and simply upgrades one (this) app and it does not work, then downgrades to previous version and it works again, this is what I would call "obvious". Don't agree?
Well, if you only check the size of the archives 3.1 vs 3.2 - there is a substantial difference.
smurphy@pandora:~/Downloads$ ls -lh suspicious_login-3.* -rw-rw-r-- 1 smurphy smurphy 1,2M sept. 2 09:51 suspicious_login-3.1.tar.gz -rw-rw-r-- 1 smurphy smurphy 1,8M sept. 2 09:51 suspicious_login-3.2.tar.gz
600K compressed in difference? And - 3.1 did not have the vendor/symfony inside.
Question: Which PHP Version are you folks running? Having PHP 7.3.21 (as provided by the official nextcloud docker image).
And - 3.1 did not have the vendor/symfony inside.
Bingo! There is a new dev dependency that was accidentally added as production dependency. Let me fix that …
See https://github.com/nextcloud/suspicious_login/pull/319. It also contains a test build without this dependency.
See #319. It also contains a test build without this dependency.
This one works fine with me. Also show's as 3.2.0 so is confirmed to be proper installed :)
Question: Which PHP Version are you folks running? Having PHP 7.3.21 (as provided by the official nextcloud docker image).
PHP 7.4.9 working as a charm
@ChristophWurst Let us know when you released the last one in the official app-store :) Thx :)
v3.2.1 released: https://github.com/nextcloud/suspicious_login/releases/tag/v3.2.1
You can update via the apps settings of your Nextcloud, though due to caching of the latest releases you might not see the update immediately there.
Nextcloud system becomes unusable:
A occ -h returns:
cf394fd77aca:/var/www/html$ occ -h -sh: occ: not found cf394fd77aca:/var/www/html$ ./occ -h PHP Fatal error: Declaration of Symfony\Component\Console\Input\ArrayInput::hasParameterOption($values, bool $onlyParams = false) must be compatible with Symfony\Component\Console\Input\InputInterface::hasParameterOption($values, $onlyParams = false) in /var/www/html/custom_apps/suspicious_login/vendor/symfony/console/Input/ArrayInput.php on line 202
Data log shows:{"reqId":"UU9bPOOz4PvChBABRmpU","level":3,"time":"2020-08-31 17:35:21","remoteAddr":"","user":"--","app":"PHP","method":"","url":"--","message":"Declaration of Symfony\\Component\\Console\\Input\\ArrayInput::hasParamet erOption($values, bool $onlyParams = false) must be compatible with Symfony\\Component\\Console\\Input\\InputInterface::hasParameterOption($values, $onlyParams = false) at /var/www/html/custom_apps/suspicious_login/ven dor/symfony/console/Input/ArrayInput.php#202","userAgent":"--","version":"18.0.8.2"}
Going into the docker-session, one can disable the app with:cf394fd77aca:/var/www/html$ ./occ app:disable suspicious_login suspicious_login disabled