Skip to content

Issue Template Uses Incorrect Path For Ref (Commit Instead Of Branch) #20456

Closed
@Deadmano

Description

@Deadmano

Description

When adding an issue from a template, the icon that links to the ref incorrectly wants to reference a commit instead of the branch, despite the branch existing with that same name. See the attached screenshot.

The template.md file contains:

---

name: "New Bug"
about: "Log a new bug!"
title: "Bug: "
ref: "main"
labels:

- bug

---

Expected path: /user/repo/src/branch/main
Actual path: /user/repo/src/commit/main

The actual path, which points to commit does not exist and thus results in a 404.

My understanding is that the link as per the screenshot will take you to the branch/tag as if you manually selected it when creating an issue and picking a branch/tag and the "ref" portion of the template would do exactly that. The documentation on issue templates was vague and doesn't mention what "ref" actually refers to.

Screenshots

Repo_Issue_5

Gitea Version

1.17.0-rc2

Can you reproduce the bug on the Gitea demo site?

No

Operating System

Windows 10

Browser Version

Firefox 102

Metadata

Metadata

Assignees

No one assigned

    Labels

    topic/uiChange the appearance of the Gitea UItype/bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions