Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Internal server error trying to access an existing issue #10384

Closed
strk opened this issue Feb 20, 2020 · 14 comments · Fixed by #10608
Closed

Internal server error trying to access an existing issue #10384

strk opened this issue Feb 20, 2020 · 14 comments · Fixed by #10608
Labels
Milestone

Comments

@strk
Copy link
Member

strk commented Feb 20, 2020

See what happens here: https://try.gitea.io/cezar97/Gitea_Issue_Logout/issues/4
Gitea version (or commit ref): 1.12.0+dev-345-gefbd7ca39

@guillep2k
Copy link
Member

I can access the issue no problem. 🤔

@lunny
Copy link
Member

lunny commented Feb 21, 2020

It maybe a random problem.

@strk
Copy link
Member Author

strk commented Feb 21, 2020

I can access it from an anonymous window, not when I'm logged in.
Can you access it when logged in ?
Do you have access to logs to spot what's going on ? I think log access should be available to all maintainers or at least owners of the project, to make the try service more useful.

@guillep2k
Copy link
Member

I can access both logged in and anonymous.

Regarding the access to logs, AFAIU they're kept strictly private.

@strk
Copy link
Member Author

strk commented Feb 21, 2020 via email

@guillep2k
Copy link
Member

There was one user that had problems today because of their cached js content. Can you try again with a clean cache, just in case?

@mcmillen
Copy link

I am seeing this issue as well:

https://git.semicolin.games/semicolin/sneak/issues/4

Gets a 500 error for me every time, logged in or no. I've tried clearing cache, using an incognito window, etc.

There's a useful error line in the logs from trying to load this issue:

2020/02/25 22:06:32 ...outers/repo/issue.go:882:ViewIssue() [E] LoadDepIssueDetails: issue does not exist [id: 25, repo_id: 0, index: 0]

A rough guess based on this error message: maybe there's a false dependency between my issue 4 and an issue 25 that doesn't exist? (My repo only has 23 issues.)

@zeripath
Copy link
Contributor

The log is giving you the issue id not the index of the issue. That log is suggesting that somehow your issue indexed 4 has gained a dependency on issue with id 25 in your db. If I had to guess that would be an issue in a deleted repo?

@mcmillen
Copy link

mcmillen commented Feb 26, 2020

Could be! I have deleted one repo; I don't think it had any Issues associated with it, but I could be wrong. I'm not sure how to check for sure.

In the mean time I have worked around the issue by closing it via a commit comment ("fixes #4"), so that at least the broken issue doesn't show up in my list of open issues.

@lunny lunny added the type/bug label Feb 26, 2020
@lunny
Copy link
Member

lunny commented Feb 26, 2020

@mcmillen what's version of your gitea instance?

@mcmillen
Copy link

Gitea 1.11.1.

I verified that the issue also reproduces on 1.11.0.

@lunny
Copy link
Member

lunny commented Mar 5, 2020

This hasn't been resolved totally. I also need to allow deleted dependencies issues.

@lunny lunny reopened this Mar 5, 2020
@lunny
Copy link
Member

lunny commented Mar 5, 2020

Since we cannot add migration to v1.11, we can add a migration on v1.12 and a command line subcommand to fix it.

@guillep2k
Copy link
Member

Users that need a fix for this while still running 1.11 and can't upgrade to 1.12 (not released at this moment), can run the following in their databases:

DELETE FROM issue_dependency WHERE issue_id NOT IN (SELECT id FROM issue);
DELETE FROM issue_dependency WHERE dependency_id NOT IN (SELECT id FROM issue);

@lunny lunny closed this as completed Mar 5, 2020
@go-gitea go-gitea locked and limited conversation to collaborators Nov 24, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants