Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unrecognized format error #11

Closed
BarryJohnson01 opened this issue Jan 18, 2022 · 1 comment
Closed

Unrecognized format error #11

BarryJohnson01 opened this issue Jan 18, 2022 · 1 comment

Comments

@BarryJohnson01
Copy link

I have installed and configured the fcm-push module. I use firebase on a number of websites with the same credentials.
What I notice is that the browser doesn't asks for permissions, which it does for the other websites. So I assume the module is not working. I checked the log and found the following error.
By the way... it would be nice to see some kind of test result, or a test button to check the API connection.

Error message in HumHub log:
yii\base\InvalidParamException: Unrecognized format '' in /var/www/vhosts/lostboysworld.org/protected/vendor/yiisoft/yii2-httpclient/src/Client.php:178
Stack trace:
#0 /var/www/vhosts/lostboysworld.org/protected/vendor/yiisoft/yii2-httpclient/src/Response.php(199): yii\httpclient\Client->getParser(NULL)
#1 /var/www/vhosts/lostboysworld.org/protected/vendor/yiisoft/yii2-httpclient/src/Response.php(33): yii\httpclient\Response->getParser()
#2 /var/www/vhosts/lostboysworld.org/protected/vendor/yiisoft/yii2/base/Component.php(140): yii\httpclient\Response->getData()
#3 /var/www/vhosts/lostboysworld.org/protected/modules/fcm-push/components/FcmApi.php(69): yii\base\Component->__get('data')
#4 /var/www/vhosts/lostboysworld.org/protected/modules/fcm-push/components/NotificationTargetProvider.php(32): humhub\modules\fcmPush\components\FcmApi->sendNotification(Object(humhub\modules\user\notifications\Followed), Object(humhub\modules\user\models\User))
#5 /var/www/vhosts/lostboysworld.org/protected/humhub/modules/notification/targets/MobileTarget.php(56): humhub\modules\fcmPush\components\NotificationTargetProvider->handle(Object(humhub\modules\user\notifications\Followed), Object(humhub\modules\user\models\User))
#6 /var/www/vhosts/lostboysworld.org/protected/humhub/modules/notification/targets/BaseTarget.php(161): humhub\modules\notification\targets\MobileTarget->handle(Object(humhub\modules\user\notifications\Followed), Object(humhub\modules\user\models\User))
#7 /var/www/vhosts/lostboysworld.org/protected/humhub/modules/notification/components/NotificationManager.php(89): humhub\modules\notification\targets\BaseTarget->send(Object(humhub\modules\user\notifications\Followed), Object(humhub\modules\user\models\User))
#8 /var/www/vhosts/lostboysworld.org/protected/humhub/modules/notification/components/NotificationManager.php(108): humhub\modules\notification\components\NotificationManager->sendBulk(Object(humhub\modules\user\notifications\Followed), Object(humhub\modules\user\components\ActiveQueryUser))
#9 /var/www/vhosts/lostboysworld.org/protected/humhub/modules/notification/jobs/SendNotification.php(41): humhub\modules\notification\components\NotificationManager->send(Object(humhub\modules\user\notifications\Followed), Object(humhub\modules\user\models\User))
#10 /var/www/vhosts/lostboysworld.org/protected/humhub/modules/queue/ActiveJob.php(33): humhub\modules\notification\jobs\SendNotification->run()
#11 /var/www/vhosts/lostboysworld.org/protected/vendor/yiisoft/yii2-queue/src/Queue.php(246): humhub\modules\queue\ActiveJob->execute(Object(humhub\modules\queue\driver\MySQL))
#12 /var/www/vhosts/lostboysworld.org/protected/vendor/yiisoft/yii2-queue/src/cli/Queue.php(162): yii\queue\Queue->handleMessage('473', 'O:49:"humhub\mo...', '300', '1')
#13 /var/www/vhosts/lostboysworld.org/protected/vendor/yiisoft/yii2-queue/src/cli/Command.php(146): yii\queue\cli\Queue->execute('473', 'O:49:"humhub\mo...', '300', '1', '36931')
#14 [internal function]: yii\queue\cli\Command->actionExec('473', '300', '1', '36931')
#15 /var/www/vhosts/lostboysworld.org/protected/vendor/yiisoft/yii2/base/InlineAction.php(57): call_user_func_array(Array, Array)
#16 /var/www/vhosts/lostboysworld.org/protected/vendor/yiisoft/yii2/base/Controller.php(181): yii\base\InlineAction->runWithParams(Array)
#17 /var/www/vhosts/lostboysworld.org/protected/vendor/yiisoft/yii2/console/Controller.php(184): yii\base\Controller->runAction('exec', Array)
#18 /var/www/vhosts/lostboysworld.org/protected/vendor/yiisoft/yii2/base/Module.php(534): yii\console\Controller->runAction('exec', Array)
#19 /var/www/vhosts/lostboysworld.org/protected/vendor/yiisoft/yii2/console/Application.php(181): yii\base\Module->runAction('queue/exec', Array)
#20 /var/www/vhosts/lostboysworld.org/protected/vendor/yiisoft/yii2/console/Application.php(148): yii\console\Application->runAction('queue/exec', Array)
#21 /var/www/vhosts/lostboysworld.org/protected/vendor/yiisoft/yii2/base/Application.php(392): yii\console\Application->handleRequest(Object(yii\console\Request))
#22 /var/www/vhosts/lostboysworld.org/protected/yii(29): yii\base\Application->run()
#23 {main}

@marc-farre
Copy link
Contributor

marc-farre commented Oct 3, 2022

It means that your Server Key is not correct.
I should start with AAAA as you can see on this screenshot (on the bottom right, the token column):
image

@luke- luke- closed this as completed Mar 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants