Exit status 128 - fatal: not a git repository (or any of the parent directories): .git

Some of my repos are not accessible anymore:
exit status 128 - fatal: not a git repository (or any of the parent directories): .git

If updated my local version to the latest master:
Gitea versie: 1.19.0+dev-183-g36a2d2f91
but the same result

See in the server output:
2022/12/12 15:59:56 [639741ec] router: completed GET /marcelloh/BookMaker for [::1]:50830, 500 Internal Server Error in 20.6ms @ context/repo.go:428(context.RepoAssignment)

Also in the newest pull it is still the same:
Gitea v1.19.0+dev-201-gd6b96627c built with GNU Make 3.81, go1.19.4 : bindata, sqlite, sqlite_unlock_notify

Can you run this command as a quick diagnosis (and maybe fix)? You may need to specify your config with --config and Gitea’s directory with --work-path.

sudo -u git ./gitea doctor --fix --all

If this doesn’t reveal/do anything, can you change/set LEVEL=Debug and STACKTRACE_LEVEL=Error under [log] in your config and then post the logs of the error occurring?

I already fixed it by removing all the repositories with errors and re-pushed them again. I’ve lost the history but at least I can work with it again.