1
0
Fork 0
mirror of https://we.phorge.it/source/arcanist.git synced 2025-01-07 21:31:01 +01:00
phorge-arcanist/src/workflow
epriestley 98d71571e4 Fix arc diff --raw with "onto" target properties
Summary:
Currently, `git show | arc diff --raw` and similar doesn't work because we try to figure out what the "Branch: feature (branched from whatever)" value is, which doesn't make sense.

```
$ git show | arc diff --raw --trace
 ARGV  '/Users/epriestley/dev/core/lib/arcanist/bin/../scripts/arcanist.php' 'diff' '--raw' '--trace'
 LOAD  Loaded "phutil" from "/Users/epriestley/dev/core/lib/libphutil/src".
 LOAD  Loaded "arcanist" from "/Users/epriestley/dev/core/lib/arcanist/src".
Config: Reading user configuration file "/Users/epriestley/.arcrc"...
Config: Did not find system configuration at "/etc/arcconfig".
Working Copy: Reading .arcconfig from "/Users/epriestley/dev/core/lib/arcanist/.arcconfig".
Working Copy: Path "/Users/epriestley/dev/core/lib/arcanist" is part of `git` working copy "/Users/epriestley/dev/core/lib/arcanist".
Working Copy: Project root is at "/Users/epriestley/dev/core/lib/arcanist".
Config: Reading local configuration file "/Users/epriestley/dev/core/lib/arcanist/.git/arc/config"...
Loading phutil library from '/Users/epriestley/dev/core/lib/arcanist/src'...
>>> [0] <conduit> conduit.connect() <bytes = 489>
>>> [1] <http> https://secure.phabricator.com/api/conduit.connect
<<< [1] <http> 211,217 us
<<< [0] <conduit> 212,001 us
>>> [2] <event> diff.didCollectChanges <listeners = 0>
<<< [2] <event> 140 us
>>> [3] <event> diff.didBuildMessage <listeners = 0>
<<< [3] <event> 46 us
Reading diff from stdin...
>>> [4] <conduit> differential.creatediff() <bytes = 10,542>
>>> [5] <http> https://secure.phabricator.com/api/differential.creatediff
<<< [5] <http> 120,215 us
<<< [4] <conduit> 120,411 us
>>> [6] <event> diff.wasCreated <listeners = 0>
<<< [6] <event> 41 us
 SKIP STAGING  Raw changes can not be pushed to a staging area.
>>> [7] <conduit> harbormaster.queryautotargets() <bytes = 290>
>>> [8] <http> https://secure.phabricator.com/api/harbormaster.queryautotargets
<<< [8] <http> 217,717 us
<<< [7] <conduit> 217,944 us
>>> [9] <conduit> harbormaster.sendmessage() <bytes = 274>
>>> [10] <http> https://secure.phabricator.com/api/harbormaster.sendmessage
>>> [11] <conduit> harbormaster.sendmessage() <bytes = 274>
>>> [12] <http> https://secure.phabricator.com/api/harbormaster.sendmessage
<<< [10] <http> 123,821 us
<<< [9] <conduit> 134,329 us
<<< [12] <http> 227,580 us
<<< [11] <conduit> 227,787 us

[2016-01-05 10:08:58] EXCEPTION: (Exception) This workflow ('ArcanistDiffWorkflow') requires a Repository API, override requiresRepositoryAPI() to return true. at [<arcanist>/src/workflow/ArcanistWorkflow.php:804]
arcanist(head=master, ref.master=b3e68c9f1793), phutil(head=stable, ref.master=adb8a9c074ba, ref.stable=7b8d38cd2d4e)
  #0 ArcanistWorkflow::getRepositoryAPI() called at [<arcanist>/src/workflow/ArcanistDiffWorkflow.php:2421]
  #1 ArcanistDiffWorkflow::getDiffOntoTargets() called at [<arcanist>/src/workflow/ArcanistDiffWorkflow.php:2411]
  #2 ArcanistDiffWorkflow::updateOntoDiffProperty() called at [<arcanist>/src/workflow/ArcanistDiffWorkflow.php:534]
  #3 ArcanistDiffWorkflow::run() called at [<arcanist>/scripts/arcanist.php:392]
```

Test Plan: Ran `arc diff --raw` in `phabricator/`.

Reviewers: chad

Reviewed By: chad

Differential Revision: https://secure.phabricator.com/D14946
2016-01-05 10:16:39 -08:00
..
exception pht all the things 2015-05-13 21:00:53 +10:00
ArcanistAliasWorkflow.php Tailor CLI feedback about "arc alias" to describe shell command aliases 2015-12-03 18:31:48 -08:00
ArcanistAmendWorkflow.php pht all the things 2015-05-13 21:00:53 +10:00
ArcanistAnoidWorkflow.php Don't explicitly name abstract base classes 2014-07-22 07:49:15 +10:00
ArcanistBackoutWorkflow.php Minor linter fix 2015-08-08 10:18:59 +10:00
ArcanistBookmarkWorkflow.php Minor linter fixes 2015-05-15 07:09:30 +10:00
ArcanistBranchWorkflow.php Minor linter fixes 2015-05-15 07:09:30 +10:00
ArcanistBrowseWorkflow.php pht all the things 2015-05-13 21:00:53 +10:00
ArcanistCallConduitWorkflow.php Use phutil_json_decode instead of json_decode 2015-05-04 22:36:14 +10:00
ArcanistCloseRevisionWorkflow.php pht all the things 2015-05-13 21:00:53 +10:00
ArcanistCloseWorkflow.php Use PhutilInvalidStateException 2015-06-18 22:41:30 +10:00
ArcanistCommitWorkflow.php Various translation improvements 2015-11-02 21:31:04 +11:00
ArcanistCoverWorkflow.php Various translation improvements 2015-11-02 21:31:04 +11:00
ArcanistDiffWorkflow.php Fix arc diff --raw with "onto" target properties 2016-01-05 10:16:39 -08:00
ArcanistDownloadWorkflow.php Fix some format strings 2015-05-25 21:24:40 +10:00
ArcanistExportWorkflow.php Remove call to "arcanist.projectinfo" from arc export 2015-05-25 18:31:09 +10:00
ArcanistFeatureWorkflow.php Improve arc's handling of dirty submodules in Git 2015-09-21 12:40:06 -07:00
ArcanistFlagWorkflow.php Linter fixes 2015-12-07 21:35:34 +11:00
ArcanistGetConfigWorkflow.php pht all the things 2015-05-13 21:00:53 +10:00
ArcanistHelpWorkflow.php phtize a bunch more strings 2015-05-22 17:09:56 +10:00
ArcanistInstallCertificateWorkflow.php Improve error handling in arc install-certificate 2015-11-27 09:05:50 -08:00
ArcanistLandWorkflow.php Clarify that "arc land" means it is merging changes, not branch refences 2015-12-12 10:25:12 -08:00
ArcanistLiberateWorkflow.php Minor linter fixes 2015-05-15 07:09:30 +10:00
ArcanistLintersWorkflow.php Add a table showing all XHPAST linter rules to the output of arc linters xhpast 2015-12-02 06:27:33 +11:00
ArcanistLintWorkflow.php Remove leftover code for "postponed" lint and unit status 2015-08-30 21:56:12 +10:00
ArcanistListWorkflow.php Improve arc's handling of dirty submodules in Git 2015-09-21 12:40:06 -07:00
ArcanistPasteWorkflow.php pht all the things 2015-05-13 21:00:53 +10:00
ArcanistPatchWorkflow.php Use "--whitespace nowarn" in arc patch to respect trailing whitespace 2015-12-17 17:36:26 -08:00
ArcanistPhrequentWorkflow.php Improve arc's handling of dirty submodules in Git 2015-09-21 12:40:06 -07:00
ArcanistRevertWorkflow.php pht all the things 2015-05-13 21:00:53 +10:00
ArcanistSetConfigWorkflow.php pht all the things 2015-05-13 21:00:53 +10:00
ArcanistShellCompleteWorkflow.php Fix arcanist shell completion 2015-06-19 13:15:44 +10:00
ArcanistStartWorkflow.php Minor tidying of ArcanistPhrequentWorkflow classes 2015-02-01 21:49:53 +11:00
ArcanistStopWorkflow.php Minor tidying of ArcanistPhrequentWorkflow classes 2015-02-01 21:49:53 +11:00
ArcanistTasksWorkflow.php Improve arc's handling of dirty submodules in Git 2015-09-21 12:40:06 -07:00
ArcanistTimeWorkflow.php Minor tidying of ArcanistPhrequentWorkflow classes 2015-02-01 21:49:53 +11:00
ArcanistTodoWorkflow.php pht all the things 2015-05-13 21:00:53 +10:00
ArcanistUnitWorkflow.php Remove arguments from unit test engines 2015-11-15 20:04:59 +00:00
ArcanistUpgradeWorkflow.php Improve two error handling behaviors in arc upgrade 2015-10-22 19:55:16 +00:00
ArcanistUploadWorkflow.php Various translation improvements 2015-11-02 21:31:04 +11:00
ArcanistVersionWorkflow.php pht all the things 2015-05-13 21:00:53 +10:00
ArcanistWhichWorkflow.php phtize a bunch more strings 2015-05-22 17:09:56 +10:00
ArcanistWorkflow.php Various translation improvements 2015-11-02 21:31:04 +11:00