Internal Server Error: profile.firstname / profile.lastname / profile.birthday
-
My Humhub instance is giving me some troubles now that users are using it.
I cannot open the https://domain/admin/user-profile and I get the below error in the logging.
It's also impossible to add users to a space when searching & adding them.How can I access the database?
yii\base\InvalidConfigException: Unable to locate message source for category 'profile.firstname'. in /app/code/protected/vendor/yiisoft/yii2/i18n/I18N.php:201
Stack trace:
#0 /app/code/protected/humhub/components/i18n/I18N.php(172): yii\i18n\I18N->getMessageSource()
#1 /app/code/protected/vendor/yiisoft/yii2/i18n/I18N.php(89): humhub\components\i18n\I18N->getMessageSource()
#2 /app/code/protected/humhub/components/i18n/I18N.php(148): yii\i18n\I18N->translate()
#3 /app/code/protected/vendor/yiisoft/yii2/BaseYii.php(538): humhub\components\i18n\I18N->translate()
#4 /app/code/protected/humhub/modules/user/views/profile/about.php(40): yii\BaseYii::t()
#5 /app/code/protected/vendor/yiisoft/yii2/base/View.php(347): require('...')
#6 /app/code/protected/vendor/yiisoft/yii2/base/View.php(257): yii\base\View->renderPhpFile()
#7 /app/code/protected/vendor/yiisoft/yii2/base/View.php(156): yii\base\View->renderFile()
#8 /app/code/protected/vendor/yiisoft/yii2/base/Controller.php(407): yii\base\View->render()
#9 /app/code/protected/humhub/modules/user/controllers/ProfileController.php(96): yii\base\Controller->render()
#10 [internal function]: humhub\modules\user\controllers\ProfileController->actionAbout()
#11 /app/code/protected/vendor/yiisoft/yii2/base/InlineAction.php(57): call_user_func_array()
#12 /app/code/protected/vendor/yiisoft/yii2/base/Controller.php(178): yii\base\InlineAction->runWithParams()
#13 /app/code/protected/vendor/yiisoft/yii2/base/Module.php(552): yii\base\Controller->runAction()
#14 /app/code/protected/vendor/yiisoft/yii2/web/Application.php(103): yii\base\Module->runAction()
#15 /app/code/protected/vendor/yiisoft/yii2/base/Application.php(384): yii\web\Application->handleRequest()
#16 /app/code/index.php(23): yii\base\Application->run()
#17 {main}×Een onbekende serverfout deed zich voor; neem bij herhaling contact op met een beheerder van deze site.
{
"url": "/s/duinzijde-blok-f/space/membership/members-list",
"status": 500,
"response": {
"error": true,
"message": "Er is een interne serverfout opgetreden."
},
"textStatus": "error",
"xhr": {
"readyState": 4,
"responseText": "{"error":true,"message":"Er is een interne serverfout opgetreden."}",
"responseJSON": {
"error": true,
"message": "Er is een interne serverfout opgetreden."
},
"status": 500,
"statusText": "error"
},
"dataType": "json",
"error": true,
"message": "Er is een interne serverfout opgetreden.",
"errorThrown": "",
"validationError": false
} -
If you open a webterminal into the app, there is a button to inject the mysql client commandline for database access.
For the actual error, can you try to set a displayname for that user in Cloudron with two words "first last" and see if that helps temporarily?
Either way this looks like an upstream bug in humhub itself.
-
Okay, I found out that this is also happening on a fresh install.
I get the exact same error when opening this:
"url": "/s/test/space/membership/members-listPDOException: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'profile.lastname' in 'order clause' in /app/code/protected/vendor/yiisoft/yii2/db/Command.php:1302
Stack trace:
#0 /app/code/protected/vendor/yiisoft/yii2/db/Command.php(1302): PDOStatement->execute()
#1 /app/code/protected/vendor/yiisoft/yii2/db/Command.php(1168): yii\db\Command->internalExecute()
#2 /app/code/protected/vendor/yiisoft/yii2/db/Command.php(410): yii\db\Command->queryInternal()
#3 /app/code/protected/vendor/yiisoft/yii2/db/Query.php(249): yii\db\Command->queryAll()
#4 /app/code/protected/vendor/yiisoft/yii2/db/ActiveQuery.php(133): yii\db\Query->all()
#5 /app/code/protected/humhub/modules/user/widgets/UserListBox.php(72): yii\db\ActiveQuery->all()
#6 /app/code/protected/vendor/yiisoft/yii2/base/Widget.php(146): humhub\modules\user\widgets\UserListBox->run()
#7 /app/code/protected/humhub/modules/space/controllers/MembershipController.php(295): yii\base\Widget::widget()
#8 [internal function]: humhub\modules\space\controllers\MembershipController->actionMembersList()
#9 /app/code/protected/vendor/yiisoft/yii2/base/InlineAction.php(57): call_user_func_array()
#10 /app/code/protected/vendor/yiisoft/yii2/base/Controller.php(178): yii\base\InlineAction->runWithParams()
#11 /app/code/protected/vendor/yiisoft/yii2/base/Module.php(552): yii\base\Controller->runAction()
#12 /app/code/protected/vendor/yiisoft/yii2/web/Application.php(103): yii\base\Module->runAction()
#13 /app/code/protected/vendor/yiisoft/yii2/base/Application.php(384): yii\web\Application->handleRequest()
#14 /app/code/index.php(23): yii\base\Application->run()
#15 {main}Next yii\db\Exception: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'profile.lastname' in 'order clause'
The SQL being executed was: SELECTuser
.* FROMuser
LEFT JOINprofile
ONuser
.id
=profile
.user_id
LEFT JOINspace_membership
ON space_membership.user_id=user.id WHERE (user
.status
=1) AND (space_membership
.status
=3) AND (space_id
=1) AND (user
.status
=1) ORDER BYprofile
.lastname
LIMIT 8 in /app/code/protected/vendor/yiisoft/yii2/db/Schema.php:676
Stack trace:
#0 /app/code/protected/vendor/yiisoft/yii2/db/Command.php(1307): yii\db\Schema->convertException()
#1 /app/code/protected/vendor/yiisoft/yii2/db/Command.php(1168): yii\db\Command->internalExecute()
#2 /app/code/protected/vendor/yiisoft/yii2/db/Command.php(410): yii\db\Command->queryInternal()
#3 /app/code/protected/vendor/yiisoft/yii2/db/Query.php(249): yii\db\Command->queryAll()
#4 /app/code/protected/vendor/yiisoft/yii2/db/ActiveQuery.php(133): yii\db\Query->all()
#5 /app/code/protected/humhub/modules/user/widgets/UserListBox.php(72): yii\db\ActiveQuery->all()
#6 /app/code/protected/vendor/yiisoft/yii2/base/Widget.php(146): humhub\modules\user\widgets\UserListBox->run()
#7 /app/code/protected/humhub/modules/space/controllers/MembershipController.php(295): yii\base\Widget::widget()
#8 [internal function]: humhub\modules\space\controllers\MembershipController->actionMembersList()
#9 /app/code/protected/vendor/yiisoft/yii2/base/InlineAction.php(57): call_user_func_array()
#10 /app/code/protected/vendor/yiisoft/yii2/base/Controller.php(178): yii\base\InlineAction->runWithParams()
#11 /app/code/protected/vendor/yiisoft/yii2/base/Module.php(552): yii\base\Controller->runAction()
#12 /app/code/protected/vendor/yiisoft/yii2/web/Application.php(103): yii\base\Module->runAction()
#13 /app/code/protected/vendor/yiisoft/yii2/base/Application.php(384): yii\web\Application->handleRequest()
#14 /app/code/index.php(23): yii\base\Application->run()
#15 {main}
Additional Information:
Array
(
[0] => 42S22
[1] => 1054
[2] => Unknown column 'profile.lastname' in 'order clause'
) -
Opened upstream: https://github.com/humhub/humhub/issues/6427
-
hm from your support ticket with more logs, it kinda looks like the initial app startup didn't even succeed, as the errors indicate, that basic db columns don't exist.
On a fresh installation, can you ensure that in the app logs you see
echo "==> Setup complete"
at some point? -
Got that line on the root.dev (test humhub)
2023-07-13T14:20:44.000Z ==> Create admin user
2023-07-13T14:20:44.000Z ==> Finish configuration
2023-07-13T14:20:44.000Z ==> Running upgrade
2023-07-13T14:20:44.000Z ==> Setup completeBut I added these tables manually:
ALTER TABLE profile ADD COLUMN lastname VARCHAR(255);
ALTER TABLE profile ADD COLUMN firstname VARCHAR(255);
ALTER TABLE profile ADD COLUMN birthdayVARCHAR(255);And after that I could open the members table. Need to test the rest if that fixes the rest of the problem as well.
Can anyone possibly show their database profiles table?
Mines got firstname, lastname, birthday in it.
But I’m not sure if there’s more or not.EDIT:
Tried to find it in their github repo:
This could possibly all of the colomns?
https://paste.cloudbasis.nl/?e458eab20259eb41#EhytDcgtGdio68qJ7BNLpzqyJEtpLce5BMLimBoDgPJK -
@nebulon I've tested again a new install on a Digital Ocean Droplet (cloudron)
I can reproduce this error, same problem with the missing colomns.When I install it manually without cloudron on a test Digital Ocean vm it works out of the box.
When I install Humhub via a droplet, it also works out of the box.I think there must be something wrong with package humhub inside cloudron?
-
Same issue here, I was surprised that such software was so buggy but hopefully it’s a package bug?
-
I've reproduced it over here:
https://files.cloudbasis.nl/yAhu8/TImiNulo31.gif