Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(935)

Issue 5154008: Add ability to rev and build a chrome from cbuildbot (Closed)

Created:
10 years, 1 month ago by sosa
Modified:
9 years, 6 months ago
Reviewers:
davidjames, scottz, anush
CC:
chromium-os-reviews_chromium.org, Mandeep Singh Baines, anush, sosa
Visibility:
Public.

Description

This CL adds the ability to Rev and Build Chrome using cros_mark_chrome_as_stable. Other things: Removing commit|clean|push command from cros_mark_chrome because it's unnecessary ... I'm just gonna use the same stabilizing branch as the other stable marker, so I can use the same clean / push from the other script. This makes this change fit in much more nicely to cbuildbot. Other changes: Add ability for cros_mark_chrome_as_stable to communicate to calling script through stdout. Make STABLE_BRANCH in cros_mark_as_stable public for above reason. Removed push_options from cros_mark and accompanying change to cbuildbot as it isn't used anymore. Made it easier to debug with cbuildbot (I ran cbuildbot A LOT of times to test this change so I felt the pain)...this includes: - only build when syncing - allow one to explicitly disable tests - use dryrun is options.debug is set Change-Id: I413a2e81a99cdde2e4d9139561cd518245b9b346 BUG=chromium-os:8693 TEST=Ran cbuildbot with --notest --debug --nosync x86-pre-flight and saw it go through correctly and dryrun push. Ran cbuildbot with same and --chrome_rev=tot. Ran with syncing and running tests too. Committed: http://chrome-svn/viewvc/chromeos?view=rev&revision=c58667b

Patch Set 1 #

Patch Set 2 : Nit #

Patch Set 3 : Stuffs #

Total comments: 27

Patch Set 4 : FOR SCOTT #

Patch Set 5 : Merge issues #

Patch Set 6 : Nit #

Unified diffs Side-by-side diffs Delta from patch set Stats (+111 lines, -64 lines) Patch
M bin/cbuildbot.py View 1 2 3 4 5 9 chunks +74 lines, -27 lines 0 comments Download
M bin/cros_mark_chrome_as_stable.py View 3 4 6 chunks +34 lines, -32 lines 0 comments Download
M cros_mark_as_stable.py View 1 2 3 3 chunks +3 lines, -5 lines 0 comments Download

Messages

Total messages: 6 (0 generated)
sosa
10 years, 1 month ago (2010-11-20 00:20:21 UTC) #1
sosa
Ping
10 years, 1 month ago (2010-11-22 21:31:23 UTC) #2
scottz
http://codereview.chromium.org/5154008/diff/1003/bin/cbuildbot.py File bin/cbuildbot.py (right): http://codereview.chromium.org/5154008/diff/1003/bin/cbuildbot.py#newcode210 bin/cbuildbot.py:210: """Returns the atom for the newly revved chrome ebuild.""" ...
10 years, 1 month ago (2010-11-23 02:44:39 UTC) #3
sosa
PTAL http://codereview.chromium.org/5154008/diff/1003/bin/cbuildbot.py File bin/cbuildbot.py (right): http://codereview.chromium.org/5154008/diff/1003/bin/cbuildbot.py#newcode210 bin/cbuildbot.py:210: """Returns the atom for the newly revved chrome ...
10 years ago (2010-11-23 21:09:19 UTC) #4
scottz
As for the code LGTM. I wouldn't mind continuing the style guide discussion. If you ...
10 years ago (2010-11-24 04:21:53 UTC) #5
sosa
10 years ago (2010-11-24 21:18:01 UTC) #6
http://codereview.chromium.org/5154008/diff/1003/bin/cbuildbot.py
File bin/cbuildbot.py (right):

http://codereview.chromium.org/5154008/diff/1003/bin/cbuildbot.py#newcode210
bin/cbuildbot.py:210: """Returns the atom for the newly revved chrome ebuild."""
I generally agree but there are a few special cases in this scenario.

1)  Ideally I would want to import cros_mark_* modules directly into this code. 
However, the requirement of having both run inside the chroot and this one makes
it impossible (for now).  

2)  I've put a good amount of time documenting those modules and since these are
simple wrappers for other documented python modules, I would rather have devs go
to the caller ... otherwise everytime I change the interface for the simple
wrapper I'll have to change the documentation in two places.  This isn't that
bad, except that every dev would have to do this, and I've already seen places
where this isn't kept up so we just have partially stale documentation i.e. it
is often you have a change to cros_mark_* but not a corresponding change to
cbuildbot (even though if you gave complete documentation you would want to). 
We would catch this easily if this was all one package ... as it is really
intended to be ... but see 1 (chroot's).  If you don't feel the documentation in
the other modules is sufficient, that is a different case and I'd be more than
happy to add more documentation there.



On 2010/11/24 04:21:53, scottz wrote:
> That is entirely up to you, I like to error on the side of more documentation
> but as you stated there is nothing that enforces that. 
> 
> On 2010/11/23 21:09:19, sosa wrote:
> > I don't agree.  According to PEP-8 and our own style guides, private
functions
> > do not need to be fully docstring'd.  After all, this function is just a
> wrapper
> > to a python module that IS documented.  That should be sufficient.  The same
> > goes for other places.
> > 
> > It's a portage atom.  See man emerge - updating doc
> > 
> > On 2010/11/23 02:44:40, scottz wrote:
> > > I know you are going to love me for this.
> > > 
> > > Time to start adding proper Docstrings with args and retruns and raises Oh
> MY.
> > > Please do so on any new function or function you modify. Future devs will
> > thank
> > > you :)
> > > 
> > > Also, what is the 'atom' ? 
> > 
>

http://codereview.chromium.org/5154008/diff/1003/bin/cbuildbot.py#newcode422
bin/cbuildbot.py:422: cmd.append('push')
Yeah there's an issue to fix that :(

On 2010/11/24 04:21:53, scottz wrote:
> Ah right I forgot we are using gflags in cros_mark_as_stable. 
> On 2010/11/23 21:09:19, sosa wrote:
> > I believe gflags will not correctly parse a flag after a arg
> > 
> > On 2010/11/23 02:44:40, scottz wrote:
> > > Is there a reason why push has to come after a potential dryrun? can we
move
> > > this just into the cmd list defined above?
> > 
>

http://codereview.chromium.org/5154008/diff/1003/bin/cbuildbot.py#newcode537
bin/cbuildbot.py:537: help='Don\'t sync before building.')
On 2010/11/24 04:21:53, scottz wrote:
> Where do you see this breaking the style guide? The rule i've seen followed
is:
> "Unless internal quote characters would mess things up, the general rule is
>   that single quotes should be used for short strings, double quotes for
>   triple-quoted multi-line strings and docstrings.  E.g."
> 
> Which is taken from Barry's guide referenced in PEP8. 
> 
> 
> On 2010/11/23 21:09:19, sosa wrote:
> > I believe this breaks style guidelines and will encourage others to use ""'s
> > when they shouldn't
> > 
> > On 2010/11/23 02:44:40, scottz wrote:
> > > use double quotes instead of escaping the apostrophe.  "Don't" 
> > 
> 

Done.

Powered by Google App Engine
This is Rietveld 408576698