Closed
Bug 867033
Opened 11 years ago
Closed 11 years ago
ZeroDivisionError: float division by zero
Categories
(Firefox Build System :: General, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
mozilla23
People
(Reporter: ewong, Assigned: ewong)
References
Details
Attachments
(1 file, 1 obsolete file)
1.13 KB,
patch
|
gps
:
review+
|
Details | Diff | Splinter Review |
Our Linux32 builders are encountering this error: checking for application to build... suite checking if app-specific confvars.sh exists... e:/builds/slave/c-cen-t-w32/build/suite/confvars.sh updating cache ./config.cache creating ./config.status *** Fix above errors and then restart with "D:/mozilla-build/python27/python2.7.exe e:/builds/slave/c-cen-t-w32/build/mozilla/build/pymake/pymake/../make.py -f client.mk build" e:\builds\slave\c-cen-t-w32\build\client.mk:305:0: command 'cd objdir && MAKE="D:/mozilla-build/python27/python2.7.exe e:/builds/slave/c-cen-t-w32/build/mozilla/build/pymake/pymake/../make.py" e:/builds/slave/c-cen-t-w32/build/configure \ || ( echo "*** Fix above errors and then restart with\ \"D:/mozilla-build/python27/python2.7.exe e:/builds/slave/c-cen-t-w32/build/mozilla/build/pymake/pymake/../make.py -f client.mk build\"" && exit 1 )' failed, return code 1 e:\builds\slave\c-cen-t-w32\build\client.mk:317:0: command 'D:/mozilla-build/python27/python2.7.exe e:/builds/slave/c-cen-t-w32/build/mozilla/build/pymake/pymake/../make.py -f e:/builds/slave/c-cen-t-w32/build/client.mk configure' failed, return code 2 Reticulating splines... Finished reading 1 moz.build files into 2 descriptors in 0.00s Backend executed in 0.00s 2 total backend files. 2 created; 0 updated; 0 unchanged Traceback (most recent call last): File "./config.status", line 75, in <module> config_status(**args) File "e:\builds\slave\c-cen-t-w32\build\mozilla\build\ConfigStatus.py", line 124, in config_status for line in summary.summaries(): File "e:\builds\slave\c-cen-t-w32\build\mozilla\python\mozbuild\mozbuild\backend\base.py", line 85, in summaries yield self.total_summary File "e:\builds\slave\c-cen-t-w32\build\mozilla\python\mozbuild\mozbuild\backend\base.py", line 75, in total_summary self.wall_time, self.cpu_time, self.cpu_time / self.wall_time) ZeroDivisionError: float division by zero Traceback (most recent call last): File "e:/builds/slave/c-cen-t-w32/build/build/pymake/make.py", line 35, in <module> main(sys.argv[1:]) File "e:/builds/slave/c-cen-t-w32/build/build/pymake/make.py", line 32, in main subprocess.check_call([sys.executable, PYMAKE] + args) File "D:\mozilla-build\python27\lib\subprocess.py", line 511, in check_call raise CalledProcessError(retcode, cmd) subprocess.CalledProcessError: Command '['D:\\mozilla-build\\python27\\python2.7.exe', 'e:\\builds\\slave\\c-cen-t-w32\\build\\mozilla\\build\\pymake\\make.py', '-f', 'client.mk', 'build', 'MOZ_BUILD_DATE=20130429144751']' returned non-zero exit status 2 program finished with exit code 1 elapsedTime=9.782000 ========= Finished compile failed (results: 2, elapsed: 9 secs) (at 2013-04-29 16:49:54.887041) ========== I'm guessing the wall_time == 0 (why? I don't know... Third base..)
Assignee | ||
Comment 1•11 years ago
|
||
http://hg.mozilla.org/mozilla-central/diff/cc1e0568c96a/python/mozbuild/mozbuild/backend/base.py#l1.74 Specifically: @property def total_summary(self): return 'Total wall time: {:.2f}s; CPU time: {:.2f}s; Efficiency: {:.0%}'.format( self.wall_time, self.cpu_time, self.cpu_time / self.wall_time) I'm not familiar with the code, but there's no test for if self.wall_time == 0 (or close to being 0)... should efficiency be set to 100%?
Assignee | ||
Comment 2•11 years ago
|
||
(In reply to Edmund Wong (:ewong) from comment #0) > Our Linux32 builders are encountering this error: s/Linux32//
Comment 3•11 years ago
|
||
The build system is too fast!
Comment 4•11 years ago
|
||
(In reply to Edmund Wong (:ewong) from comment #2) > (In reply to Edmund Wong (:ewong) from comment #0) > > Our Linux32 builders are encountering this error: > > s/Linux32// s/Our/SeaMonkey/
Assignee | ||
Comment 5•11 years ago
|
||
possible patch to avoid divide by zeros.
Attachment #743507 -
Flags: review?(gps)
Assignee | ||
Updated•11 years ago
|
OS: Windows Vista → All
Comment 6•11 years ago
|
||
Comment on attachment 743507 [details] [diff] [review] Check self.wall_time for 0 Review of attachment 743507 [details] [diff] [review]: ----------------------------------------------------------------- ::: python/mozbuild/mozbuild/backend/base.py @@ +74,5 @@ > + efficiencyValue = 0 > + if self.wall_time == 0: > + efficiencyValue = 100 > + else > + efficiencyValue = self.cpu_time / self.wall_time Nit: _ not camelCase You could also write this as: efficiency_value = self.cpu_time / self.wall_time if self.wall_time else 100
Attachment #743507 -
Flags: review?(gps) → review+
Assignee | ||
Comment 8•11 years ago
|
||
Assignee: nobody → ewong
Attachment #743507 -
Attachment is obsolete: true
Status: NEW → ASSIGNED
Attachment #744365 -
Flags: review?(gps)
Updated•11 years ago
|
Attachment #744365 -
Flags: review?(gps) → review+
Assignee | ||
Comment 9•11 years ago
|
||
Pushed to try: https://tbpl.mozilla.org/?tree=Try&rev=fb3f5b152f17
Assignee | ||
Comment 10•11 years ago
|
||
Pushed to mozilla-central: https://hg.mozilla.org/mozilla-central/rev/7f72b029e78e
Assignee | ||
Updated•11 years ago
|
Target Milestone: --- → mozilla25
Assignee | ||
Updated•11 years ago
|
Target Milestone: mozilla25 → mozilla23
Assignee | ||
Updated•11 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Updated•6 years ago
|
Product: Core → Firefox Build System
You need to log in
before you can comment on or make changes to this bug.
Description
•