docker use gitea/gitea:latest
visit /api/v1/users/haytoo/heatmap
error message:
{"message":"Error 1305: FUNCTION gitea.strftime does not exist","url":"https://godoc.org/github.com/go-gitea/go-sdk/gitea"}
Hmm... Could you check whether this still happens?
驴which database engine are you using? if I use postgresql my error is this one:
"message":"pq: function strftime(unknown, bigint, unknown) does not exist","url":"https://godoc.org/github.com/go-gitea/go-sdk/gitea"
and my docker log:
[SQL] SELECT strftime('%s', strftime('%Y-%m-%d', created_unix, 'unixepoch')) AS timestamp, count(user_id) as contributions FROM "action" WHERE (user_id = $1) AND (created_unix > $2) GROUP BY timestamp ORDER BY timestamp []interface {}{1, 1513899654} => that's sqlite code, not psql. Tomorrow I'll try with a new install using sqlite
rebuilt with latest docker image, now it seems to be fixed
@mnieto156 - I think your problem was Gitea was speaking sqlite dialect to postgres - not sure why. It might have been a configuration issue or an issue with the way it was built.
@haytoo1 's problem seems to imply that the strftime function hadn't been compiled into the embedded sqlite - which is probably an issue with the build - so a simple redownload the image and retry might solve the issue and if it's still there after a redownload when Gitea was supposed to have been rebuilt - then it says that there is a consistent problem with the docker build process rather than an intermittent one that might have had something to do with the change of go version that also affected drone's continuous build earlier last week.
Yeah, thanks, probably my issue was in my config, i've tried a fresh install + docker restart and now it works as expected
Hi,
I have the same problem. I use MySQL instead of sqlite. No bugs in sqlite installation.
@jnlin have you restarted gitea?
After restart gitea, it works! Thank you @lunny
Ah. @lunny - is it that you can change the database backend but the dialect won't change with it until a restart?
If you changed custom/app.ini, you have to restart the docker. @zeripath I don't think there is any options to change the database settings on UI after installation UI finished.