orhun/git-cliff

GitLab context data are missing

Aperta

#687 aperta il 10 giu 2024

 (24 commenti) (5 reazioni) (0 assegnatari)Rust (308 fork)auto 404
bughelp wantedquestion

Metriche repository

Star
 (12.040 stelle)
Metriche merge PR
 (Metriche PR in attesa)

Descrizione

Is there an existing issue for this?

  • I have searched the existing issues

Description of the bug

While using a self hosted gitlab instance, the gitlab context of each commit is always empty like in the example bekow:

{ "id": "49bf75934a826c6d182e958405d680938bb474c3", "message": "change all input variables to lower case", "body": "Merge branch 'fix_lower_case_inputs' into 'main'", "footers": [ { "token": "Closes", "separator": " #", "value": "2", "breaking": false }, { "token": "BREAKING CHANGE", "separator": ":", "value": "change all input variables to lower case\n\nSee merge request me-and-only-me/git-cliff-changelog!2", "breaking": true } ], "group": "🐛 Bug Fixes", "breaking_description": "change all input variables to lower case\n\nSee merge request me-and-only-me/git-cliff-changelog!2", "breaking": true, "scope": "inputs", "links": [ { "text": "#2", "href": "/-/issues/2" }, { "text": "!2", "href": "/-/merge_requests/2" } ], "author": { "name": "John Snow", "email": "john.snow@got.com", "timestamp": 1710149612 }, "committer": { "name": "John Snow", "email": "john.snow@got.com", "timestamp": 1710149612 }, "conventional": true, "merge_commit": true, "github": { "username": null, "pr_title": null, "pr_number": null, "pr_labels": [], "is_first_time": false }, "gitlab": { "username": null, "pr_title": null, "pr_number": null, "pr_labels": [], "is_first_time": false }, ... ... },

git-cliff verbose output: TRACE git_cliff_core::repo > Upstream URL: https://my.gitlabinstance.com/me-and-only-me/git-cliff-changelog.git DEBUG git_cliff > No GitHub remote is set, using remote: me-and-only-me/git-cliff-changelog TRACE git_cliff > Arguments: Opt { help: None, version: None, verbose: 4, init: None, config: "/config/git-cliff.toml", workdir: None, repository: None, include_path: None, exclude_path: None, tag_pattern: None, with_commit: None, skip_commit: None, prepend: None, output: None, tag: None, bump: false, bumped_version: false, body: None, latest: false, current: false, unreleased: true, topo_order: false, no_exec: false, context: true, strip: None, sort: Newest, range: None, github_token: None, github_repo: None, gitlab_token: Some( Secret([REDACTED alloc::string::String]), ), gitlab_repo: Some( RemoteValue( Remote { owner: "me-and-only-me", repo: "git-cliff-changelog", token: None, }, ), ), bitbucket_token: None, bitbucket_repo: None, }

Steps To Reproduce

  1. install git-cliff 2.3.0 deb on debian
  2. clone repo from private gitlab instance
  3. change into repo folder
  4. run : GITLAB_API_URL=https://my.gitlabinstance.com/api/v4 git-cliff --gitlab-repo me-and-only-me/git-cliff-changelog --gitlab-token my-awesome-personal-api-token -vvvv -u -x

Expected behavior

any data in context of gitlab

"gitlab": { "username": "John Snow", "pr_title": null, "pr_number": null, "pr_labels": [], "is_first_time": false },

Screenshots / Logs

No response

Software information

  • Operating system: Debian 12 bookworm
  • Project version: git-cliff 2.3.0

Additional context

No response

Guida contributor