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

commitgraph throws err 500 when commit message contains a pipe #1189

Closed
2 of 7 tasks
philfry opened this issue Mar 10, 2017 · 0 comments
Closed
2 of 7 tasks

commitgraph throws err 500 when commit message contains a pipe #1189

philfry opened this issue Mar 10, 2017 · 0 comments
Labels
Milestone

Comments

@philfry
Copy link
Contributor

philfry commented Mar 10, 2017

[...uters/repo/commit.go:92 Graph()] [E] GetCommitGraph: Failed parsing grap line:* DATA:||... - Should containt 8 datafields

Description

steps to reproduce:

touch dummyfile
git add dummyfile
git commit -m "this is a testcommit | containing a pipe"
git push
# view commitgraph

In models/graph.go in GetCommitGraph(r *git.Repository) (GraphItems, error) calls a git log and uses a custom format using pipes as field separators. Later in graphItemFromString(s string, r *git.Repository) (GraphItem, error) the lines get split by that delimiter and the resulting array is being checked whether or not it has exactly 8 elements.
The easiest solution would be to check whether or not the array has at least 8 elements and merge the 8th to nth elements together.

@lunny lunny added this to the 1.2.0 milestone Mar 10, 2017
@lunny lunny added the type/bug label Mar 10, 2017
@lunny lunny closed this as completed in e2b2fd6 Mar 11, 2017
ethantkoenig pushed a commit to ethantkoenig/gitea that referenced this issue Apr 29, 2017
@go-gitea go-gitea locked and limited conversation to collaborators Nov 23, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants