-
Notifications
You must be signed in to change notification settings - Fork 26
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
Add support for Mercurial #6
Comments
Are you using the latest version? Also, be sure to add Thank you! |
It triggers on pull-request but says no changes. TeamCity 8.0.5 |
Did you install a previous version of the plugin, then updated to the new one? |
If it's not the first build on the branch, it might show that there's no change (since the last build) |
The plugin was not updated. |
The thing is that we had that bug in the past, and fixed it with the latest version. What is the version number shown for the plugin on the page : {yourTeamCityServer}/admin/admin.html?item=plugins |
I'm out of ideas here. The plugin works on our TeamCity server and I've had another person that reported the bug you are experiencing, but the last version fixed it and it works fine for him too. Do you have anything relevant in your log files? |
Can you give any tips what to look for? |
I ran into such an issue when my branch spec didn't match what the plugin was passing. Try manually triggering a build, selecting a branch to run build from and then look at what teamcity has in the build history for the branch name. That match what the bitbucket plugin is passing (I think you can see what that is by looking at one of the builds triggered by it) |
Does this plugin support mercurial? As I understand +:refs/heads/* doesn't make much sense for hg. |
Ah that's a good point, the plugin was only tested with git. I'm not sure what's the branch specification for mercurial.. Maybe you can try |
As I understand branch is not created on pull request in mercurial. You need to checkout upstream branch and than do
|
In bitbucket, a branch is not created for git pull requests either. The plugin uses the bitbucket REST API to find the pull requests, not the VCS. |
I've already tried |
Can you try +:* and wait for the next PR to open? |
I have set branch to if I create a pull request within my repository from |
I agent's build log there is comments that patch was applied http://pastebin.com/qHQsS5Vc |
teamcity-activities.log http://pastebin.com/ZUqr3qN8 |
Thank you for those tests. So if I understand, your first PR from a branch to another triggered the build with the correct changes? But the PR from a fork didnt? |
In first case Also in build logs I have such thing
From what I see now branch specification |
The first case is the expected result, as develop contains default + your changes. For forks, I must say that I don't think it's supported. There's no way teamcity knows about the forks, because the VCS root doesn't include them |
But TeamCity labled it as a
Actually it knows, otherwise build would not be triggered on pull request from fork. In any case, can your plugin export parameter with PULL_REQUEST_ID to Ant or do you know a way I can get it in Ant from TeamCity? This will do the job for me. |
The reason it's labeled As for the parameter, I can look on what's possible with TeamCity to pass to the build |
As I understand your in your plugin gets changeset number from api and calls setChangeset(CHANGESET_ID) and then git implicitly changes branch to pull request, because pull requests are stored within same repository in git. But this approach does not work for mercurial. Maybe you can use https://bitbucket.org/aragost/javahg/ to import patch that is provided by bitbucket api to project working copy in build agent? |
Is this issue still relevant? |
Yes it is |
Any idea on when you might work on this? I'm keen to get a pull-request setup on mercurial/bitbucket combo, and there are so little tools supporting this. I had thought my salvation was here, but alas, it doesn't work. I'm not a Java developer, so I did clone the repo, but very quickly got lost in how to map the links that come back from bitbucket using gson. Could even exporting the pull request ID into the TeamCity Env variables be the place to start? Then the first build step can download the patch (PullRequest.links.patch) and apply it? |
Sorry for the delays. We are not using mercurial at the moment so it's hard to tell when we'll implement this feature. If anyone wants to contribute this, pull requests are more than welcome! |
No description provided.
The text was updated successfully, but these errors were encountered: