diffusion.uri.edit fails if uri is specified before repository:
$ echo '{ "transactions": [ { "type": "uri", "value": "http://home.place/some/uri.git" }, { "type": "repository", "value": "PHID-REPO-7n64jo2jw3uivhysrxgr" }, { "type": "disable", "value": true } ] }' | arc call-conduit diffusion.uri.edit
Attempting to access attached data on PhabricatorRepositoryURI (via getRepository()), but the data is not actually attached
But works fine if uri happens after repository:
$ echo '{ "transactions": [ { "type": "repository", "value": "PHID-REPO-7n64jo2jw3uivhysrxgr" }, { "type": "uri", "value": "http://home.place/some/uri.git" }, { "type": "disable", "value": true } ] }' | arc call-conduit diffusion.uri.edit
{ "object": { "id": 457, "phid": "PHID-RURI-x7ildq64yt3nry2fbe2t" }, ...
stacktrace:
PhabricatorLiskDAO::assertAttached called at [<phabricator>/src/applications/repository/storage/PhabricatorRepositoryURI.php:84] PhabricatorRepositoryURI::getRepository called at [<phabricator>/src/applications/repository/storage/PhabricatorRepositoryURI.php:310] PhabricatorRepositoryURI::getForcedProtocol called at [<phabricator>/src/applications/repository/storage/PhabricatorRepositoryURI.php:272] PhabricatorRepositoryURI::getURIObject called at [<phabricator>/src/applications/repository/storage/PhabricatorRepositoryURI.php:219] PhabricatorRepositoryURI::getEffectiveURI called at [<phabricator>/src/applications/diffusion/editor/DiffusionURIEditor.php:104] DiffusionURIEditor::applyCustomInternalTransaction called at [<phabricator>/src/applications/transactions/editor/PhabricatorApplicationTransactionEditor.php:549] PhabricatorApplicationTransactionEditor::applyInternalEffects called at [<phabricator>/src/applications/transactions/editor/PhabricatorApplicationTransactionEditor.php:936] PhabricatorApplicationTransactionEditor::applyTransactions called at [<phabricator>/src/applications/transactions/editengine/PhabricatorEditEngine.php:1806] PhabricatorEditEngine::buildConduitResponse called at [<phabricator>/src/applications/transactions/editengine/PhabricatorEditEngineAPIMethod.php:40] PhabricatorEditEngineAPIMethod::execute called at [<phabricator>/src/applications/conduit/method/ConduitAPIMethod.php:122] ConduitAPIMethod::executeMethod called at [<phabricator>/src/applications/conduit/call/ConduitCall.php:131] ConduitCall::executeMethod called at [<phabricator>/src/applications/conduit/call/ConduitCall.php:81] ConduitCall::execute called at [<phabricator>/src/applications/conduit/controller/PhabricatorConduitAPIController.php:81] phlog called at [<phabricator>/src/applications/conduit/controller/PhabricatorConduitAPIController.php:101] PhabricatorConduitAPIController::handleRequest called at [<phabricator>/src/aphront/configuration/AphrontApplicationConfiguration.php:237] AphrontApplicationConfiguration::processRequest called at [<phabricator>/src/aphront/configuration/AphrontApplicationConfiguration.php:149] AphrontApplicationConfiguration::runHTTPRequest called at [<phabricator>/webroot/index.php:17]
(From darien via irc)