[x]
):Hi,
I seems that a DELETE request to https://try.gitea.io/api/v1/repos/camdarley/api-test/issues/1/times/769 leads to a 500 error with this trace:
runtime error: invalid memory address or nil pointer dereference
/usr/local/go/src/runtime/panic.go:199 (0x44c4db)
/usr/local/go/src/runtime/signal_unix.go:394 (0x44c318)
/go/src/code.gitea.io/gitea/models/issue_tracked_time.go:282 (0xee64b0)
/go/src/code.gitea.io/gitea/routers/api/v1/repo/issue_tracked_time.go:302 (0x1725f60)
...
GET https://try.gitea.io/api/v1/repos/camdarley/api-test/issues/1/times list a time entry with ID 769, but when I send a DELETE to https://try.gitea.io/api/v1/repos/camdarley/api-test/issues/1/times/769 it fails with above error.
I tested first on my own Gitea instance, which is 1.11.4 with same issue.
@6543 have we already fixed this in 1.12?
I'll have a look at it asap
While looking at the code I noticed this: #11319
but didn't looked at the delete jet
@6543 I noticed #11319 too, and not found happen often when one mistakenly use issue ID and not index.
But I can confirm this issue is not a related to a "Not Found".
can confirm - I'm on it
ok this is a simple bug: DeleteTime like to create a CommentTypeDeleteTimeManual but Repo of the trackedtime related issue is not loaded ... pull income