Closed Bug 914925 Opened 8 years ago Closed 7 years ago
mach reftest --debugger doesn't work
Same as bug 913173, but for reftest. master irk:/z/moz/central $ ./mach reftest --debugger=gdb 0:00.20 /usr/bin/make -C . -j8 -s -w reftest make: Entering directory `/z/moz/central/obj-mac-dbg' REFTEST INFO | runreftest.py | Running tests: start. INFO | automation.py | Launching: /usr/bin/gdb -q --args /z/moz/central/obj-mac-dbg/dist/NightlyDebug.app/Contents/MacOS/firefox-bin -foreground -no-remote -profile /var/folders/04/rtvfhstx5c1_y4sv_179m40c0000gn/T/tmpFHBM2J.mozrunner/ -reftest /z/moz/central/layout/reftests/reftest.list INFO | automation.py | Application pid: 20356 TEST-INFO: Not logging stdout or stderr due to debugger connection Reading symbols for shared libraries ......... done (gdb) r Starting program: /z/moz/central/obj-mac-dbg/dist/NightlyDebug.app/Contents/MacOS/firefox-bin -foreground -no-remote -profile /var/folders/04/rtvfhstx5c1_y4sv_179m40c0000gn/T/tmpFHBM2J.mozrunner/ -reftest /z/moz/central/layout/reftests/reftest.list ... Program exited with code 06. (gdb)
I tried sticking in something like bug 913173 comment 11 in runreftest.py's buildBrowserEnv but this didn't have any effect.
I got motivated and did a Mac build and could reproduce the problem (in both reftest and mochitest). This patch fixes the problem.
Attachment #803185 - Flags: review?(jmaher)
Comment on attachment 803185 [details] [diff] [review] fix --debugger for reftest/mochitest on OS X Review of attachment 803185 [details] [diff] [review]: ----------------------------------------------------------------- ::: layout/tools/reftest/runreftest.py @@ +107,5 @@ > ) > self.copyExtraFilesToProfile(options, profile) > return profile > > + def buildBrowserEnv(self, options, profileDir, debugger): why are you not setting this to a default value of False as you do in the mochitest runner?
Attachment #803185 - Flags: review?(jmaher) → review+
I didn't think it was necessary since this was the only caller, but I forgot that runtestsremote calls this as well. I'll fix that, thanks!
Oh, actually, I guess nothing does call the reftest version, but I'll fix it just for sanity.
Attachment #803185 - Attachment is obsolete: true
Backed out for remote test bustage. https://hg.mozilla.org/integration/fx-team/rev/a23d608fb893
This patch doesn't seem to fix the problem for me, still can't debug reftests.
You need to apply the patch then rebuild the build/ directory to get automation.py updated. I tested on my Mac and it worked, so I suspect it's just horrible preprocessed Python nonsense.
The patch seems to have rotted, and the naïve manual application of the reject files doesn't seem to produce a viable environment.
Rebased to work on top of the Mochitest refactor.
Attachment #803816 - Attachment is obsolete: true
I still need to manually apply this patch to basically every repo I work in, FWIW.
At the summit, Ted promised to land something to make mochitests work with a debugger again.
This patch only touches Mochitest. This should be simpler to land.
Attachment #809201 - Attachment is obsolete: true
*sigh*, that still broke Android tests: https://tbpl.mozilla.org/?tree=Try&rev=2cd6ba574f2e
Can we get some traction here? Manually shuffling this patch around in local trees is a pain (especially because it borks android try pushes), but more importantly, this is mysteriously breaks the experience of any newcomer dev who doesn't know about the workaround.
I'm looking into fixing android
Assignee: ted → Ms2ger
Comment on attachment 8334493 [details] [diff] [review] Patch v2 Review of attachment 8334493 [details] [diff] [review]: ----------------------------------------------------------------- this looks to be the right patch.
Attachment #8334493 - Flags: review?(jmaher) → review+
Ms2ger, thank you!
Ms2ger, you are a hero.
Thanks for that, I owe you one.
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla28
You need to log in before you can comment on or make changes to this bug.