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

Error 500 when accessing release created from annotated tag #515

Closed
DerDackel opened this issue Sep 29, 2014 · 4 comments
Closed

Error 500 when accessing release created from annotated tag #515

DerDackel opened this issue Sep 29, 2014 · 4 comments
Labels
💊 bug Something isn't working

Comments

@DerDackel
Copy link

Trying to access a certain tag in gogs (accessing /user/repo/src/tagname) fails with error code 500 if that tag has been created as an annotated, rather than a lightweight tag (i.e. -a, -s or -m was applied to git tag).

The log shows:

[Macaron] Started GET /root/gogstest/src/withmessage for 127.0.0.1
2014/09/29 13:12:09 [view.go:123 Home()] [E] ListEntries: exit status 128
[Macaron] Completed /root/gogstest/src/withmessage 500 Internal Server Error in 35.711574ms

As far as my printf debugging went, tree.ListEntries tries to operate on an empty subtree (Commit ID 0000...). Haven't yet fully investigated but this seems to stem from annotated tags having distinct commit objects compared to lightweight tags.

Tested in master (commit 3cfa4a5) as well as dev branch (commit cd084da).

Steps to reproduce:

  1. Create git repo
  2. Create annotated tag with git tag failtag -m "This will fail"
  3. Add remote gogs repository and git push --tags
  4. In Gogs, access Releases page for the repo and click on failtag release.
@unknwon unknwon added the 💊 bug Something isn't working label Sep 29, 2014
@unknwon
Copy link
Member

unknwon commented Sep 29, 2014

Thanks your feedback, we're working on it!

unknwon added a commit that referenced this issue Sep 30, 2014
@unknwon
Copy link
Member

unknwon commented Sep 30, 2014

I've pushed fix on dev branch and updated https://try.gogs.io , please test again, thanks!

@DerDackel
Copy link
Author

Seems to work now, thanks!

@unknwon
Copy link
Member

unknwon commented Sep 30, 2014

No problem!

@unknwon unknwon closed this as completed Sep 30, 2014
@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 26, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
💊 bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants