Closed Bug 788971 Opened 12 years ago Closed 12 years ago

Pymake chokes when native commands raise exceptions without a "code" attribute

Categories

(Firefox Build System :: General, defect)

All
Windows 7
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
mozilla18

People

(Reporter: glandium, Assigned: rain1)

Details

Attachments

(1 file)

Bug 784262 caused bug 788954, which is a race condition happening because export-idl and export are trying to do the same thing in the same directory at the same time. It seems to be causing deadlocks on windows builders in bug 788917.
So this is a bug in rules.mk that also manifested as a deadlock in Pymake?
Apparently, yes.
random dead-lock.
Summary: Possible pymake dead-lock caused by makefile race-conditions → Pymake chokes when native commands raise exceptions without a "code" attribute
Attached patch oopsSplinter Review
Assignee: nobody → sagarwal
Status: NEW → ASSIGNED
Attachment #658881 - Flags: review?(ted.mielczarek)
Comment on attachment 658881 [details] [diff] [review]
oops

Review of attachment 658881 [details] [diff] [review]:
-----------------------------------------------------------------

::: pymake/process.py
@@ +264,5 @@
>                  pass # sys.exit(0) is not a failure
>              else:
>                  print >>sys.stderr, e
> +                traceback.print_exc()
> +                return -127

Can we be smarter about this and use getattr(e.code, -127)?
Attachment #658881 - Flags: review?(ted.mielczarek) → review+
I'd rather not -- e.code isn't defined in general. It's also defined for a few other exceptions, e.g. HTTP errors in urllib2, and I don't think we should turn those into something equivalent to process exit codes!
Flags: in-testsuite+
https://hg.mozilla.org/mozilla-central/rev/a111a94df092
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla18
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: