Make sure every site that catches gclient_utils.Error also catch
subprocess2.CalledProcessError.
BUG=
TEST=
Review URL: http://codereview.chromium.org/6691034
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@80339 0039d316-1c4b-4281-b951-d872f2087c98
Reapply r79006 with fixes for ubuntu 10.4.
The only change is in fix_default_encoding() to trap an exception
locale.getlocale() may throw.
R=dpranke@chromium.org
BUG=none
TEST=unit test
Review URL: http://codereview.chromium.org/6721029
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@79144 0039d316-1c4b-4281-b951-d872f2087c98
It is causing exception for some users on ubuntu 10.4 with:
"category LC_ALL is not supported"
TBR=dpranke
Review URL: http://codereview.chromium.org/6717025
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@79012 0039d316-1c4b-4281-b951-d872f2087c98
With this code in action, I can successfully print arabic and chinese on linux
and cygwin. It fails to print chinese on my Mac but prints arabic. It prints '?'
on Windows console but it *doesn't throw* which is the biggest improvement here.
It was particularly a problem on windows because WindowsError's description text
is in the current ANSI code page so it failed to print if the text was not pure
ASCII, like error message when using Windows' French UI.
R=dpranke@chromium.org
BUG=none
TEST=manual unit test ./tests/fix_encoding_test.py and it shouldn't throw
Review URL: http://codereview.chromium.org/6676090
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@79006 0039d316-1c4b-4281-b951-d872f2087c98
Otherwise the following presubmit checks where never called.
TBR=nsylvain
BUG=
TEST=fixes unit tests
Review URL: http://codereview.chromium.org/5995003
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@69844 0039d316-1c4b-4281-b951-d872f2087c98
Most of them are style issues or variable aliasing.
TEST=Can almost enable pylint warnings
BUG=none
Review URL: http://codereview.chromium.org/4360002
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@64908 0039d316-1c4b-4281-b951-d872f2087c98
Otherwise files containing these characters can be created on the file system,
making it harder to get rid of those files.
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/4127014
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@64782 0039d316-1c4b-4281-b951-d872f2087c98
BUG=None
TEST=Add '*.diff' to 'global-ignores' in your local SVN configuration. Submit a try job using 'gcl try'.
Review URL: http://codereview.chromium.org/4240003
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@64768 0039d316-1c4b-4281-b951-d872f2087c98
Otherwise, git try breaks for some users.
Also, make testUpdateCheckout pass if the path to the temp directory contains a symlink (like on Mac OS X).
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/3620011
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@61786 0039d316-1c4b-4281-b951-d872f2087c98
smarter about finding the most appropriate settings file.
Before this change, I inadvertently did a [gcl try] on a chrome-internal
change (it was a trivial change and not really secret, so no harm done).
After this change, that won't be possible.
Also, change breakpad to not upload the exception that is thrown when
the user fails to provide correct log-on credentials.
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/3390013
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@61738 0039d316-1c4b-4281-b951-d872f2087c98
Change CheckCallError to inherit from Error. This will simplify try/except changes.
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/3324007
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@58695 0039d316-1c4b-4281-b951-d872f2087c98
This way the function is much more similar to subprocess.call(). Further changes
will be done, to be able to convert all the function, to be able to parallelize
output without corrupting it.
Used pylint to verify call graph correctness, causing some other unrelated
changes.
TEST=unit tests
BUG=none
Review URL: http://codereview.chromium.org/3117039
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@57369 0039d316-1c4b-4281-b951-d872f2087c98
BUG=none
TEST=Make change in local sandbox and confirm proper things happen on "git try help", "git try xyzzy", and "git try -b linux."
Review URL: http://codereview.chromium.org/3075009
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@54374 0039d316-1c4b-4281-b951-d872f2087c98
This fixes issues with Chromium OS checkout.
BUG=crosbug:3132.
TEST=none
Review URL: http://codereview.chromium.org/2016006
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@46761 0039d316-1c4b-4281-b951-d872f2087c98
BUG=17948
TEST=submit various try jobs with and without -t option
Review URL: http://codereview.chromium.org/1733026
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@46173 0039d316-1c4b-4281-b951-d872f2087c98
Raise an exception in case an upstream branch can't be found.
Fix an exception that was occuring just before when no upstream is found.
Review URL: http://codereview.chromium.org/1755018
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@46011 0039d316-1c4b-4281-b951-d872f2087c98
It now defaults to origin/master when no branch is tracked.
TEST=git-try on untracked branch now doesn't result in an empty diff
BUG=none
Review URL: http://codereview.chromium.org/1739021
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@45935 0039d316-1c4b-4281-b951-d872f2087c98
svn 1.4 doesn't have --depth parameter support so it cannot easily do a sparse checkout.
To workaround that, use svn import instead. It's also faster.
The main caveat is that the file must have a unique name, it uses a timestamp in file name for uniqueness.
Using a subdirectory (like the user name) doesn't work in the directory already exist.
It could be worked around but that would nullify the performance improvement.
Review URL: http://codereview.chromium.org/1783009
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@45811 0039d316-1c4b-4281-b951-d872f2087c98
We now return the stderr half of the tuple.
This required a clean up of any usage of CheckCall and GIT.Capture.
Patch contributed by Nasser Grainawi <nasser@codeaurora.org>
Review URL: http://codereview.chromium.org/551215
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@37650 0039d316-1c4b-4281-b951-d872f2087c98
It breaks the use case when a dev outside corp wants to send a job's email to someone else.
Review URL: http://codereview.chromium.org/558062
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@37644 0039d316-1c4b-4281-b951-d872f2087c98
trychange.py -R <review_url> is sufficient for try jobs when in a checkout directory.
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/553166
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@37616 0039d316-1c4b-4281-b951-d872f2087c98
By default, filters out 'ChangeLog'. A pain directly coming from Webkit.
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/543012
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@36008 0039d316-1c4b-4281-b951-d872f2087c98
The new try execution should only be triggered when a user just passes the rietveld issue number. Usually, if your branch has a working patchset already defined, it shouldn't think the user passed it. The code has been updated to force patchset to be None (not 0 or any other number) so that specific occurence wont happen again.
TBR=maruel
BUG=None
TEST=git try, git try --issue=123, git try --issue=123 --patchset=0, should all work fine now.
Review URL: http://codereview.chromium.org/542007
git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@35889 0039d316-1c4b-4281-b951-d872f2087c98