Closed
Bug 628655
Opened 13 years ago
Closed 13 years ago
Support daily builds in download script
Categories
(Mozilla QA Graveyard :: Mozmill Automation, defect)
Mozilla QA Graveyard
Mozmill Automation
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: whimboo, Assigned: whimboo)
References
Details
Attachments
(1 file, 5 obsolete files)
11.66 KB,
patch
|
whimboo
:
review+
|
Details | Diff | Splinter Review |
With bug 528064 we now have the capability to easily download builds from our staging server and mirrors. But it only implements the download for release and release candidate builds. We have to implement the NightlyScraper class to also support nightly builds.
Assignee | ||
Comment 1•13 years ago
|
||
Heather, would you be ok with when we take parts of your script for out downloader script? It's only missing the nightly build pieces. https://github.com/harthur/mozregression/blob/master/mozregression/runnightly.py
Comment 2•13 years ago
|
||
(In reply to comment #1) > Heather, would you be ok with when we take parts of your script for out > downloader script? It's only missing the nightly build pieces. > > https://github.com/harthur/mozregression/blob/master/mozregression/runnightly.py That's fine, yeah
Assignee | ||
Comment 3•13 years ago
|
||
With the new channels we have to support daily builds for Nightly and Aurora. Both will be covered by my upcoming patch.
Assignee: nobody → hskupin
Status: NEW → ASSIGNED
Summary: Support nightly builds in download script → Support daily builds in download script
Assignee | ||
Comment 4•13 years ago
|
||
Please note that we do not support the old structure on the FTP server yet. It will only work with the structure we have right now. As long as we do not run regression tests with Mozmill there will also be no need for it.
Attachment #542293 -
Flags: review?(jhammel)
Comment 5•13 years ago
|
||
Comment on attachment 542293 [details] [diff] [review] Patch v1 Nit: + parser.add_option('--build', '-b', + dest='build', + default=1, indentation of dest, etc should be one additional space You should also do `type="int"` if you expect an int. Otherwise you'll get a string + self.list_regex = 'nightly/%(YEAR)s/%(MONTH)s/' % { + 'YEAR': self.date.year, + 'MONTH': str(self.date.month).zfill(2) } I find this type of filtering very brittle. I would expect some tests, a docstring, or otherwise documentation on why things are done this way, preferably citing a URL + regex = r'%(DATE)s-(\d+-)+mozilla-%(BRANCH)s%(L10N)s$' % { + 'DATE': self.date.strftime('%Y-%m-%d'), + 'BRANCH': self.branch, + 'L10N': '' if self.locale == 'en-US' else '-l10n'} Likewise + @property + def binary_regex(self): Is there any reason to have this a property vs a function? I really find the filtering stuff more complex and it would be nice to have this live as a utility. I'll grant a review, fixing the type="int" issue, but it is with a grain of salt
Attachment #542293 -
Flags: review?(jhammel) → review+
Assignee | ||
Comment 6•13 years ago
|
||
(In reply to comment #5) > + @property > + def binary_regex(self): > > Is there any reason to have this a property vs a function? Why should that not be a property? From all what I can see it speaks for a getter. Also all other elements on the classes are properties. > I really find the filtering stuff more complex and it would be nice to have > this live as a utility. I'll grant a review, fixing the type="int" issue, > but it is with a grain of salt The parser is already a separate class, which we can put into another module in the future. But all the regular expressions are closely tied to the scraper class and can't be moved out.
Assignee | ||
Comment 7•13 years ago
|
||
Any of the review comments have been addressed and documentation added. I hope it's more understandable now. Also I have found an issue with branch handling. We only supported branches with a 'mozilla-' prefix. Now we support all branches like 'private-browsing', 'ux', and others.
Attachment #542293 -
Attachment is obsolete: true
Attachment #542430 -
Flags: review?(jhammel)
Comment 8•13 years ago
|
||
Comment on attachment 542293 [details] [diff] [review] Patch v1 + def __init__(self, branch='mozilla-central', date=date.today(), So, this will set the default date argument for the function to when the module is first loaded. In other words, it will be wrong after 24-N hours. Probably better to set to None and then do if date is None: date = datetime.date.today()
Updated•13 years ago
|
Attachment #542430 -
Flags: review?(jhammel) → review+
Assignee | ||
Comment 9•13 years ago
|
||
With updated review comments. Thanks for the clarification, that were news to me.
Attachment #542430 -
Attachment is obsolete: true
Attachment #542662 -
Flags: review?(jhammel)
Assignee | ||
Comment 10•13 years ago
|
||
I should not upload broken patches. Here the qrefreshed version of the last patch.
Attachment #542662 -
Attachment is obsolete: true
Attachment #542779 -
Flags: review?(jhammel)
Attachment #542662 -
Flags: review?(jhammel)
Assignee | ||
Comment 11•13 years ago
|
||
Not sure what hg is doing. Even with a hg qrefresh the latest changes weren't included. Seems to be fixed now.
Attachment #542779 -
Attachment is obsolete: true
Attachment #542783 -
Flags: review?(jhammel)
Attachment #542779 -
Flags: review?(jhammel)
Comment 12•13 years ago
|
||
Comment on attachment 542783 [details] [diff] [review] Patch v3.2 +from datetime import date ... + def __init__(self, branch='mozilla-central', date=None, + build=1, *args, **kwargs): MozillaScraper.__init__(self, *args, **kwargs) - raise NotImplementedError("Download of nightly builds hasn't been implemented yet.") + self.branch = branch + self.build = build + self.date = date if date else datetime.date.today() This won't work, as you don't import datetime abict (just from datetime import date). I recommend changing the import r+ if you fix that
Attachment #542783 -
Flags: review?(jhammel) → review+
Assignee | ||
Comment 13•13 years ago
|
||
Thanks for catching that Jeff! What an awkward mistake. Here the updated patch and taking over r+.
Attachment #542783 -
Attachment is obsolete: true
Attachment #542967 -
Flags: review+
Assignee | ||
Comment 14•13 years ago
|
||
Landed as: http://hg.mozilla.org/qa/mozmill-automation/rev/78fcedc41024 Thanks everyone. Support for tinderbox or hourly builds can be added later on another bug.
Status: ASSIGNED → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Updated•10 years ago
|
Product: Mozilla QA → Mozilla QA Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•