Giter VIP home page Giter VIP logo

Comments (21)

shayki5 avatar shayki5 commented on June 23, 2024

Hi @SrivathsanJ, could you share here the task configuration and also run it with system.debug = true and share the logs?

from azure-devops-create-pr-task.

SrivathsanJ avatar SrivathsanJ commented on June 23, 2024

i have used the basic configurations. Build.SourceBranch as source and master as target.
For some reason $(Build.SourceBranch) is not getting the value. it is not showing the branch value in the logs. could this be the issue ?

from azure-devops-create-pr-task.

shayki5 avatar shayki5 commented on June 23, 2024

I can't know without seeing the configurations and the logs...

from azure-devops-create-pr-task.

SrivathsanJ avatar SrivathsanJ commented on June 23, 2024

PFA the logs you had asked. I have masked Org id and Project ID. Rest all are the same.
Build.SourceBranch and Build.SourceRepo variables are not getting replaced with values. So i added the actual branch name in the task
PR_Task_Log.log

from azure-devops-create-pr-task.

shayki5 avatar shayki5 commented on June 23, 2024

Thank you!
If you enter this url https://My_ORG.visualstudio.com/Project_ID/_apis/git/repositories/Repo_ID/diffs/commits?baseVersion=Release_2&targetVersion=master&api-version=4.1&$top=2 in the browser, do you get results? (replace with your real org/project/repo/ ID)

from azure-devops-create-pr-task.

SrivathsanJ avatar SrivathsanJ commented on June 23, 2024

yes. i get the commit differences

from azure-devops-create-pr-task.

shayki5 avatar shayki5 commented on June 23, 2024

Please see issue #21, it because you use the old URL, can you run it again? (it should work after you logged-in in the browser)

from azure-devops-create-pr-task.

SrivathsanJ avatar SrivathsanJ commented on June 23, 2024

The Old url api call is working when i try locally in my browser. and i have another org with my personal account which is using the same pattern and works fine in the release pipeline.
strange. let me try this now and update.
Thanks

from azure-devops-create-pr-task.

SrivathsanJ avatar SrivathsanJ commented on June 23, 2024

It's creating the pull request now.. However, my self hosted agent is is still using the old url(even on a new release). Hosted agents are able to pickup new url and create PR. But the build.sourcebranch and build.sourcerepo variables are not retuening the values. I had to manually select the repo and branch name. Is there way to get it working..
Thanks

from azure-devops-create-pr-task.

shayki5 avatar shayki5 commented on June 23, 2024

So it works now when you specify the values?
BTW - there is no pre-defined build.sourcerepo variable.

from azure-devops-create-pr-task.

SrivathsanJ avatar SrivathsanJ commented on June 23, 2024

yes. if i manually specify the branch name and select Repo name for "Repository to use" instead of "current repository build".
I was actually referring to "$(Build.Repository.Name)" that's also no retrieving the value

from azure-devops-create-pr-task.

shayki5 avatar shayki5 commented on June 23, 2024

And also $(Build.SourceBranch) not working?

from azure-devops-create-pr-task.

SrivathsanJ avatar SrivathsanJ commented on June 23, 2024

Yes. that is not also not working. I had to manually enter the branch

from azure-devops-create-pr-task.

shayki5 avatar shayki5 commented on June 23, 2024

@SrivathsanJ could you share exactly your configuration? it's in a release pipeline?

from azure-devops-create-pr-task.

PaulIvan avatar PaulIvan commented on June 23, 2024

I've got a similar issue when trying to create PR's from github to azure dev. allowed token and all settings but failing at the same line. any clue?
checkout-from-github.txt
createpr-devops.txt

from azure-devops-create-pr-task.

shayki5 avatar shayki5 commented on June 23, 2024

Hi @PaulIvan, I see in your logs INPUT_REPOTYPE: 'Azure DevOps', but it should be GitHub, can you check?

from azure-devops-create-pr-task.

PaulIvan avatar PaulIvan commented on June 23, 2024

Hi @PaulIvan, I see in your logs INPUT_REPOTYPE: 'Azure DevOps', but it should be GitHub, can you check?

if I select Github, it will try to push the PR on github I don't need that. I want the PR to be published in Devops from Github

from azure-devops-create-pr-task.

shayki5 avatar shayki5 commented on June 23, 2024

@PaulIvan what do you mean "PR to be published in Devops from Github"? where is the repo?

from azure-devops-create-pr-task.

PaulIvan avatar PaulIvan commented on June 23, 2024

The scenario is the following:

  • I have this test repo on my github. https://github.com/PaulIvan/ALAppExtensions/
  • Whenever a PR is made against this github repo a pipeline is triggered in Devops using the azure github connector
  • I want the pipeline task to push the content of the github PR in a duplicate repo in devops (which I already made) as another PR

Is that not something this extension can do?

image

from azure-devops-create-pr-task.

shayki5 avatar shayki5 commented on June 23, 2024

@PaulIvan I'm sorry but not :/
You should clone the repo from GitHub to Azure DevOps and update it there in an automated way (each commit to GitHub will update the repo in Azure DevOps - you can create a build for that), when all the repo will be in Azure DevOps you can use the extension to create the PR in Azure DevOps (not from GitHub, from branch and to branch both in ADO).

from azure-devops-create-pr-task.

shayki5 avatar shayki5 commented on June 23, 2024

Closing because there is no more info from the issue opener.

from azure-devops-create-pr-task.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.