SparkyFitness unusable

I have searched the forum for similar issues

on

This category is for issues regarding specific apps, NOT general issues with YunoHost.

on

This form is written in English but feel free to write in French if you’re more comfortable!

on

What app is this about, and its version

SparkyFitness

What YunoHost version are you running

Latest

What type of hardware are you using

Old laptop or computer

Describe your issue

Hello!
In a fresh installation of SparkyFitness, I receive the below mentioned errors and I cannot either sign up or login. Cannot paste the log since it shows my domain.

> ### Share relevant logs or error messages
>
> Save New Duplicate & Edit Just Text Twitter
> LOGFILE: journalctl
> Oct 10 12:22:10 systemd\[1\]: sparkyfitness.service: Consumed 12.781s CPU time.
> Oct 10 12:22:10 systemd\[1\]: Started sparkyfitness.service - SparkyFitness service.
> Oct 10 12:22:48 systemd\[1\]: sparkyfitness.service: Main process exited, code=exited, status=1/FAILURE
> Oct 10 12:22:48 systemd\[1\]: sparkyfitness.service: Failed with result 'exit-code'.
> Oct 10 12:22:48 systemd\[1\]: sparkyfitness.service: Consumed 10.945s CPU time.
> Oct 10 12:22:53 systemd\[1\]: sparkyfitness.service: Scheduled restart job, restart counter is at 9229.
> Oct 10 12:22:53 systemd\[1\]: Stopped sparkyfitness.service - SparkyFitness service.
> Oct 10 12:22:53 systemd\[1\]: sparkyfitness.service: Consumed 10.945s CPU time.
> Oct 10 12:22:53 systemd\[1\]: Started sparkyfitness.service - SparkyFitness service.
> Oct 10 12:23:30 systemd\[1\]: sparkyfitness.service: Main process exited, code=exited, status=1/FAILURE
> Oct 10 12:23:30 systemd\[1\]: sparkyfitness.service: Failed with result 'exit-code'.
> Oct 10 12:23:30 systemd\[1\]: sparkyfitness.service: Consumed 10.597s CPU time.
> Oct 10 12:23:36 systemd\[1\]: sparkyfitness.service: Scheduled restart job, restart counter is at 9230.
> Oct 10 12:23:36 systemd\[1\]: Stopped sparkyfitness.service - SparkyFitness service.
> Oct 10 12:23:36 systemd\[1\]: sparkyfitness.service: Consumed 10.597s CPU time.
> Oct 10 12:23:36 systemd\[1\]: Started sparkyfitness.service - SparkyFitness service.
> Oct 10 12:24:13 systemd\[1\]: sparkyfitness.service: Main process exited, code=exited, status=1/FAILURE
> Oct 10 12:24:13 systemd\[1\]: sparkyfitness.service: Failed with result 'exit-code'.
> Oct 10 12:24:13 systemd\[1\]: sparkyfitness.service: Consumed 10.553s CPU time.
> Oct 10 12:24:18 systemd\[1\]: sparkyfitness.service: Scheduled restart job, restart counter is at 9231.
> Oct 10 12:24:18 systemd\[1\]: Stopped sparkyfitness.service - SparkyFitness service.
> Oct 10 12:24:18 systemd\[1\]: sparkyfitness.service: Consumed 10.553s CPU time.
> Oct 10 12:24:18 systemd\[1\]: Started sparkyfitness.service - SparkyFitness service.
> Oct 10 12:24:55 systemd\[1\]: sparkyfitness.service: Main process exited, code=exited, status=1/FAILURE
> Oct 10 12:24:55 systemd\[1\]: sparkyfitness.service: Failed with result 'exit-code'.
> Oct 10 12:24:55 systemd\[1\]: sparkyfitness.service: Consumed 10.527s CPU time.
> Oct 10 12:25:01 systemd\[1\]: sparkyfitness.service: Scheduled restart job, restart counter is at 9232.
> Oct 10 12:25:01 systemd\[1\]: Stopped sparkyfitness.service - SparkyFitness service.
> Oct 10 12:25:01 systemd\[1\]: sparkyfitness.service: Consumed 10.527s CPU time.
> Oct 10 12:25:01 systemd\[1\]: Started sparkyfitness.service - SparkyFitness service.
> Oct 10 12:25:38 systemd\[1\]: sparkyfitness.service: Main process exited, code=exited, status=1/FAILURE
> Oct 10 12:25:38 systemd\[1\]: sparkyfitness.service: Failed with result 'exit-code'.
> Oct 10 12:25:38 systemd\[1\]: sparkyfitness.service: Consumed 10.759s CPU time.
> Oct 10 12:25:41 systemd\[1\]: Stopped sparkyfitness.service - SparkyFitness service.
> Oct 10 12:25:41 systemd\[1\]: sparkyfitness.service: Consumed 10.759s CPU time.
> Oct 10 12:25:41 systemd\[1\]: Started sparkyfitness.service - SparkyFitness service.
> Oct 10 12:26:19 systemd\[1\]: sparkyfitness.service: Main process exited, code=exited, status=1/FAILURE
> Oct 10 12:26:19 systemd\[1\]: sparkyfitness.service: Failed with result 'exit-code'.
> Oct 10 12:26:19 systemd\[1\]: sparkyfitness.service: Consumed 10.604s CPU time.
> Oct 10 12:26:24 systemd\[1\]: sparkyfitness.service: Scheduled restart job, restart counter is at 9233.
> Oct 10 12:26:24 systemd\[1\]: Stopped sparkyfitness.service - SparkyFitness service.
> Oct 10 12:26:24 systemd\[1\]: sparkyfitness.service: Consumed 10.604s CPU time.
> Oct 10 12:26:24 systemd\[1\]: Started sparkyfitness.service - SparkyFitness service.
> Oct 10 12:27:01 systemd\[1\]: sparkyfitness.service: Main process exited, code=exited, status=1/FAILURE
> Oct 10 12:27:01 systemd\[1\]: sparkyfitness.service: Failed with result 'exit-code'.
> Oct 10 12:27:01 systemd\[1\]: sparkyfitness.service: Consumed 10.755s CPU time.
> Oct 10 12:27:06 systemd\[1\]: sparkyfitness.service: Scheduled restart job, restart counter is at 9234.
> Oct 10 12:27:06 systemd\[1\]: Stopped sparkyfitness.service - SparkyFitness service.
> Oct 10 12:27:06 systemd\[1\]: sparkyfitness.service: Consumed 10.755s CPU time.
> Oct 10 12:27:06 systemd\[1\]: Started sparkyfitness.service - SparkyFitness service.
>
> LOGFILE: /var/log/sparkyfitness/sparkyfitness.log
> file: 'aclchk.c',
> line: '3793',
> routine: 'aclcheck_error'
> }
> DEBUG: SPARKY_FITNESS_FRONTEND_URL is: https://xxx.xxx
> SparkyFitnessServer UPLOADS_BASE_DIR: /home/yunohost.app/sparkyfitness
> \[2026-10-10T09:26:31.572Z\] \[ERROR\] Error applying migrations: error: must be owner of schema public
> at /var/www/sparkyfitness/backend/node_modules/.pnpm/pg@8.20.0/node_modules/pg/lib/client.js:631:17
> at process.processTicksAndRejections (node:internal/process/task_queues:104:5)
> at async applyMigrations (/var/www/sparkyfitness/backend/utils/dbMigrations.ts:66:9) {
> length: 90,
> severity: 'ERROR',
> code: '42501',
> detail: undefined,
> hint: undefined,
> position: undefined,
> internalPosition: undefined,
> internalQuery: undefined,
> where: undefined,
> schema: undefined,
> table: undefined,
> column: undefined,
> dataType: undefined,
> constraint: undefined,
> file: 'aclchk.c',
> line: '3793',
> routine: 'aclcheck_error'
> }
> Failed to start server: error: must be owner of schema public
> at /var/www/sparkyfitness/backend/node_modules/.pnpm/pg@8.20.0/node_modules/pg/lib/client.js:631:17
> at process.processTicksAndRejections (node:internal/process/task_queues:104:5)
> at async applyMigrations (/var/www/sparkyfitness/backend/utils/dbMigrations.ts:66:9) {
> length: 90,
> severity: 'ERROR',
> code: '42501',
> detail: undefined,
> hint: undefined,
> position: undefined,
> internalPosition: undefined,
> internalQuery: undefined,
> where: undefined,
> schema: undefined,
> table: undefined,
> column: undefined,
> dataType: undefined,
> constraint: undefined,
> file: 'aclchk.c',
> line: '3793',
> routine: 'aclcheck_error'
> }

Seems like the same issue here?

https://github.com/YunoHost-Apps/sparkyfitness_ynh/issues/86

Thanks for the heads up! I’ve just fixed the issue with version 0.16.8~ynh2 (should be available in the catalog in a few hours).

The best is to install the app from scratch.

Thank you. I can confirm that version 0.16.8 solves the issue. I just got a warning of a newer version available.

Indeed, future updates will be unlocked when we upgrade to Trixie

Ok , so coming back to the issue. I am getting again errors, when I added a visitors permissions which I had not when installing the app. I set it to Yunohost users only during the setup.

Apart from the errors ie not being able to log in and also the Android app not being able to connect to the server (via api), the service is down even if I restart it manually. Only if I remove again the visitors permission the service remains up, BUT I still cannot connect to the service. If I read the errors properly I get a 502 bad request.

DEBUG: SPARKY_FITNESS_FRONTEND_URL is: https://xx.xx.xx
SparkyFitnessServer UPLOADS_BASE_DIR: /home/yunohost.app/sparkyfitness
\[2026-10-16T18:40:53.692Z\] \[ERROR\] Error granting permissions: error: permission denied for function pg_stat_statements_reset
at /var/www/sparkyfitness/backend/node_modules/.pnpm/pg@8.20.0/node_modules/pg/lib/client.js:631:17
at process.processTicksAndRejections (node:internal/process/task_queues:104:5)
at async grantPermissions (/var/www/sparkyfitness/backend/db/grantPermissions.ts:35:5)
at async applyMigrations (/var/www/sparkyfitness/backend/utils/dbMigrations.ts:77:5) {
length: 115,
severity: 'ERROR',
code: '42501',
detail: undefined,
hint: undefined,
position: undefined,
internalPosition: undefined,
internalQuery: undefined,
where: undefined,
schema: undefined,
table: undefined,
column: undefined,
dataType: undefined,
constraint: undefined,
file: 'aclchk.c',
line: '3655',
routine: 'aclcheck_error'
}
DEBUG: SPARKY_FITNESS_FRONTEND_URL is: https://xx.xx.xx
SparkyFitnessServer UPLOADS_BASE_DIR: /home/yunohost.app/sparkyfitness
\[2026-10-16T18:41:06.060Z\] \[ERROR\] Error granting permissions: error: permission denied for function pg_stat_statements_reset
at /var/www/sparkyfitness/backend/node_modules/.pnpm/pg@8.20.0/node_modules/pg/lib/client.js:631:17
at process.processTicksAndRejections (node:internal/process/task_queues:104:5)
at async grantPermissions (/var/www/sparkyfitness/backend/db/grantPermissions.ts:35:5)
at async applyMigrations (/var/www/sparkyfitness/backend/utils/dbMigrations.ts:77:5) {
length: 115,
severity: 'ERROR',
code: '42501',
detail: undefined,
hint: undefined,
position: undefined,
internalPosition: undefined,
internalQuery: undefined,
where: undefined,
schema: undefined,
table: undefined,
column: undefined,
dataType: undefined,
constraint: undefined,
file: 'aclchk.c',
line: '3655',
routine: 'aclcheck_error'
}

Adding to the above, I reinstalled it with visitors access from the start. Worked ok, until I changed the disable registration to off and got the same errors and cannot login and access the server from the Android app.