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

[Bug][Gitlab] Deployable.Commit.Message can be bigger than 255 #6455

Closed
2 of 3 tasks
antoniomuso opened this issue Nov 14, 2023 · 7 comments · Fixed by #6588
Closed
2 of 3 tasks

[Bug][Gitlab] Deployable.Commit.Message can be bigger than 255 #6455

antoniomuso opened this issue Nov 14, 2023 · 7 comments · Fixed by #6588
Assignees
Labels
type/bug This issue is a bug
Milestone

Comments

@antoniomuso
Copy link
Contributor

Search before asking

  • I had searched in the issues and found no similar issues.

What happened

Pipeline crash when Deployable.Commit.Message is bigger than 255:

DeployableCommitMessage: r.Deployable.Commit.Message,

What do you expect to happen

Pipeline is executed without crash.

How to reproduce

You can reproduce by adding into GitLab a commit message bigger than 255.

Anything else

No response

Version

v0.20.0-beta1

Are you willing to submit PR?

  • Yes I am willing to submit a PR!

Code of Conduct

@antoniomuso antoniomuso added the type/bug This issue is a bug label Nov 14, 2023
@Startrekzky
Copy link
Contributor

Hi @antoniomuso , do you mean that you have a commit message longer than 255? How did that happen?

@antoniomuso
Copy link
Contributor Author

I don't know, but I have it. Maybe the commit message includes the commit body.

@Startrekzky
Copy link
Contributor

@antoniomuso May I know why the commit message included the commit body? I asked because IDEs like vscode will limit the length of the commit message. I'm trying to figure out the root reason for this and evaluate how common this problem is.

@antoniomuso
Copy link
Contributor Author

antoniomuso commented Nov 15, 2023

@Startrekzky If you see in the GitLab API, you can see that deployable.commit.message includes the commit title and the commit body. For this reason, it can be longer than 255.

// This example is taken from Gitlab API documentation
{
    "created_at": "2016-08-11T11:32:35.444Z",
    "updated_at": "2016-08-11T11:34:01.123Z",
    "status": "created",
    "deployable": {
      "commit": {
        "author_email": "[email protected]",
        "author_name": "Administrator",
        "created_at": "2016-08-11T13:28:26.000+02:00",
        "id": "a91957a858320c0e17f3a0eca7cfacbff50ea29a",
>        "message": "Merge branch 'rename-readme' into 'main'\r\n\r\nRename README\r\n\r\n\r\n\r\nSee merge request !2",
        "short_id": "a91957a8",
        "title": "Merge branch 'rename-readme' into 'main'\r"
      },
 ...
 }

@moritz-deissner-turbinekreuzberg

i our case renovate bot is the talkative culprit

@abeizn
Copy link
Contributor

abeizn commented Dec 7, 2023

This issue is the precursor to #6521. I will fix it later.

@abeizn
Copy link
Contributor

abeizn commented Dec 7, 2023

@antoniomuso It will take effect in v0.20.0-beta4: https://github.com/apache/incubator-devlake/releases/tag/v0.20.0-beta4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/bug This issue is a bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants