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

Handle base commit not found error #63

Closed
ChaitanyaPramod opened this issue Aug 11, 2015 · 5 comments
Closed

Handle base commit not found error #63

ChaitanyaPramod opened this issue Aug 11, 2015 · 5 comments
Assignees
Labels

Comments

@ChaitanyaPramod
Copy link
Contributor

Sometimes, diffs are made against commits which haven't been pushed up to remote yet. The build fails in this case, but no notification of result is made to Harbormaster.

[workspace] $ /var/lib/arc/arcanist/bin/arc call-conduit differential.querydiffs ********
Applying patch for differential
[workspace] $ git reset --hard 1a9049ef170d7351ca18ba164bfe8e73bcf4fdcd
fatal: Could not parse object '1a9049ef170d7351ca18ba164bfe8e73bcf4fdcd'.
Got non-zero exit code resetting to base commit 1a9049ef170d7351ca18ba164bfe8e73bcf4fdcd: 128
[workspace] $ git clean -fd -f
[workspace] $ git submodule update --init --recursive
[workspace] $ /var/lib/arc/arcanist/bin/arc patch --nobranch --diff 3955 --nocommit ********


    This diff is against commit 1a9049ef170d7351ca18ba164bfe8e73bcf4fdcd, but
    the commit is nowhere in the working copy. Try to apply it against the
    current working copy state? (cabbdf90274bcef598ae45a47c1ceb0c7ba2b1ec)
    [Y/n] Exception
The program is attempting to read user input, but stdin is being piped from some other source (not a TTY).
(Run with `--trace` for a full exception trace.)
49[arcanist] Error applying arc patch; got non-zero exit code 1

The plugin should handle this case and either

  • report build failure on Phabricator (Harbormaster)
  • allow applying the patch on some git reference (like master branch) through a configuration
@ascandella
Copy link
Contributor

Yes, this is definitely a bug. I will look at this after getting #60 merged, since there's some pretty heavy refactoring going on.

@ascandella
Copy link
Contributor

As soon as the associated PR is merged I will cut a new release.

ascandella added a commit to jenkinsci/phabricator-plugin that referenced this issue Aug 12, 2015
@ascandella
Copy link
Contributor

This is now released in 1.7 of the plugin. Note that conduit credentials have moved into the "Credentials" plugin so you'll need to follow the instructions at https://github.com/uber/phabricator-jenkins-plugin#configuration

@mindheist
Copy link

So, what should we expect after this change ? Should I see a notification on Phabricator about the build failure ?

@ascandella
Copy link
Contributor

It should set the build status to failed, just like if the tests failed.

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

No branches or pull requests

3 participants