Skip to content

bug: incorrect author attribution when base branch is force pushed #133

Closed

Description

@danielleadams

When a changelog is generated, there is an instance when the incorrect author is listed.

Steps for reproduction:

  • commit author opens a pull request against a base branch
  • a second person force pushes to base branch
  • commit author rebases on base branch
  • second person is added as a co-author on the commit
  • when the changelog is generated, the second person that has been added as co-author is listed as the author

Expected result:

When the changelog is generated, the commit author should be listed as the author.

Activity

  1. targos commented on Oct 13, 2022

    @targos
    Member

    Do you have an example PR for which it happened?

  2. RafaelGSS commented on Oct 13, 2022

    @RafaelGSS
    Member

    I think the issue might be on the git node land that included the wrong metadata. Just a guess.

    @targos this one nodejs/node#44256

  3. richardlau commented on Oct 13, 2022

    @richardlau
    Member

    I don't believe changelog-maker even looks at co-authors. commit-stream (which we're using) does parse them (since nodejs/commit-stream#4) but puts them in an authors field (plural) while changelog-maker only reads the author (singular) field:

    s += data.author ? `(${cleanMarkdown(data.author)}) ` : ''

    data.author = (commit.author && commit.author.name) || ''

  4. targos commented on Oct 13, 2022

    @targos
    Member

    I don't think this is related to our tooling. The PR author probably did a mistake when they rebased.

  5. danielleadams commented on Oct 14, 2022

    @danielleadams
    Author

    Okay, I can close then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions