{"action":"created","issue":{"url":"https://api.github.com/repos/pantsbuild/pants/issues/1444","labels_url":"https://api.github.com/repos/pantsbuild/pants/issues/1444/labels{/name}","comments_url":"https://api.github.com/repos/pantsbuild/pants/issues/1444/comments","events_url":"https://api.github.com/repos/pantsbuild/pants/issues/1444/events","html_url":"https://github.com/pantsbuild/pants/issues/1444","id":70186806,"number":1444,"title":"git scm server_url origin check is maybe too loose","user":{"login":"areitz","id":1000135,"avatar_url":"https://avatars.githubusercontent.com/u/1000135?v=3","gravatar_id":"","url":"https://api.github.com/users/areitz","html_url":"https://github.com/areitz","followers_url":"https://api.github.com/users/areitz/followers","following_url":"https://api.github.com/users/areitz/following{/other_user}","gists_url":"https://api.github.com/users/areitz/gists{/gist_id}","starred_url":"https://api.github.com/users/areitz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/areitz/subscriptions","organizations_url":"https://api.github.com/users/areitz/orgs","repos_url":"https://api.github.com/users/areitz/repos","events_url":"https://api.github.com/users/areitz/events{/privacy}","received_events_url":"https://api.github.com/users/areitz/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/pantsbuild/pants/labels/bug","name":"bug","color":"fc2929"},{"url":"https://api.github.com/repos/pantsbuild/pants/labels/in-progress","name":"in-progress","color":"009800"}],"state":"open","locked":false,"assignee":{"login":"jsirois","id":157586,"avatar_url":"https://avatars.githubusercontent.com/u/157586?v=3","gravatar_id":"","url":"https://api.github.com/users/jsirois","html_url":"https://github.com/jsirois","followers_url":"https://api.github.com/users/jsirois/followers","following_url":"https://api.github.com/users/jsirois/following{/other_user}","gists_url":"https://api.github.com/users/jsirois/gists{/gist_id}","starred_url":"https://api.github.com/users/jsirois/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jsirois/subscriptions","organizations_url":"https://api.github.com/users/jsirois/orgs","repos_url":"https://api.github.com/users/jsirois/repos","events_url":"https://api.github.com/users/jsirois/events{/privacy}","received_events_url":"https://api.github.com/users/jsirois/received_events","type":"User","site_admin":false},"milestone":null,"comments":3,"created_at":"2015-04-22T17:26:00Z","updated_at":"2015-06-16T22:28:00Z","closed_at":null,"body":"We're working on setting up an alternate origin for one of our repos at Twitter, and an engineer decided to name the new origin \"`temp_origin`\":\r\n\r\n```\r\n[areitz@XXX]$  git remote -v\r\norigin\thttps://foo.example.com/ro/some_repo (fetch)\r\norigin\thttps://foo.example.com/ro/some_repo (push)\r\ntemp_origin\thttps://foo.example.com/ro/some_repo-ci (fetch)\r\ntemp_origin\thttps://foo.example.com/ro/some_repo-ci (push)\r\n```\r\n\r\nHowever, doing so leads to this error when `scm.server_url()`[1] is invoked (where `scm` is an instance of `Git`:\r\n\r\n```\r\nException message: Unable to find origin remote amongst: origin\thttps://foo.example.com/ro/some_repo (fetch)\r\norigin\thttps://foo.example.com/ro/some_repo (push)\r\ntemp_origin\thttps://foo.example.com/ro/some_repo-ci (fetch)\r\ntemp_origin\thttps://foo.example.com/ro/some_repo-ci (push)\r\n```\r\n\r\nOur current thinking is that the check for `origin` should be more strict -- maybe something like `/\\borigin\\b`. I plan on coming up with a patch for this later today.\r\n\r\n[1] https://github.com/pantsbuild/pants/blob/master/src/python/pants/scm/git.py#L104"},"comment":{"url":"https://api.github.com/repos/pantsbuild/pants/issues/comments/112588918","html_url":"https://github.com/pantsbuild/pants/issues/1444#issuecomment-112588918","issue_url":"https://api.github.com/repos/pantsbuild/pants/issues/1444","id":112588918,"user":{"login":"jsirois","id":157586,"avatar_url":"https://avatars.githubusercontent.com/u/157586?v=3","gravatar_id":"","url":"https://api.github.com/users/jsirois","html_url":"https://github.com/jsirois","followers_url":"https://api.github.com/users/jsirois/followers","following_url":"https://api.github.com/users/jsirois/following{/other_user}","gists_url":"https://api.github.com/users/jsirois/gists{/gist_id}","starred_url":"https://api.github.com/users/jsirois/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jsirois/subscriptions","organizations_url":"https://api.github.com/users/jsirois/orgs","repos_url":"https://api.github.com/users/jsirois/repos","events_url":"https://api.github.com/users/jsirois/events{/privacy}","received_events_url":"https://api.github.com/users/jsirois/received_events","type":"User","site_admin":false},"created_at":"2015-06-16T22:28:00Z","updated_at":"2015-06-16T22:28:00Z","body":"The immediate issue with `Git.server_url` is being worked in #1699 / https://rbcommons.com/s/twitter/r/2379/"}}