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

Wrong targetRefName when create azure-repo PullRequestPayload #3348

Open
GreyPlane opened this issue May 7, 2024 · 0 comments
Open

Wrong targetRefName when create azure-repo PullRequestPayload #3348

GreyPlane opened this issue May 7, 2024 · 0 comments

Comments

@GreyPlane
Copy link

GreyPlane commented May 7, 2024

configured repo was like $owner/$repo:develop, other functionality was running fine, but when Steward trying to create a PR, it gets

{
        "$id": "1",
        "errorCode": 0,
        "eventId": 3000,
        "innerException": null,
        "message": "TF401398: The pull request cannot be activated because the source and/or the target branch no longer exists, or the requested refs are not branches",
        "typeKey": "GitPullRequestCannotBeActivated",
        "typeName": "Microsoft.TeamFoundation.Git.Server.GitPullRequestCannotBeActivated, Microsoft.TeamFoundation.Git.Server"
}

after investigation, it seems the targetRefName was develop instead of refs/head/develop, also it appears in both tests and Azure repo API docs, it should be refs/head/develop.

Is this due to something changed in NewPullRequestData.base.name, or AzureRepos changed their API?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant