mach configure fails on OpenBSD/i386
Categories
(Firefox Build System :: Mach Core, defect)
Tracking
(firefox-esr91 unaffected, firefox-esr102 fixed, firefox102 wontfix, firefox103 wontfix, firefox104 fixed)
| Tracking | Status | |
|---|---|---|
| firefox-esr91 | --- | unaffected |
| firefox-esr102 | --- | fixed |
| firefox102 | --- | wontfix |
| firefox103 | --- | wontfix |
| firefox104 | --- | fixed |
People
(Reporter: gaston, Assigned: Dexter)
References
(Regression)
Details
(Keywords: regression)
Attachments
(1 external file)
Similar to bug #1774144, but not exactly the same ? This time on i386... i managed to build/install glean-sdk too.
Configure complete!
Be sure to run |mach build| to pick up any changes
Error running mach:
['configure']
The error occurred in code that was called by the mach command. This is either
a bug in the called code itself or in the way that mach is calling it.
You can invoke |./mach busted| to check if this issue is already on file. If it
isn't, please use |./mach busted file configure| to report it. If |./mach busted| is
misbehaving, you can also inspect the dependencies of bug 1543241.
If filing a bug, please include the full output of mach, including this error
message.
The details of the failure are as follows:
SystemError: NULL object passed to Py_BuildValue
File "/build/buildslave-i386/mozilla-central-i386/build/build/mach_initialize.py", line 451, in post_dispatch_handler
_finalize_telemetry_glean(
File "/build/buildslave-i386/mozilla-central-i386/build/build/mach_initialize.py", line 537, in _finalize_telemetry_glean
system_metrics.vscode_running.set(get_vscode_running())
File "/build/buildslave-i386/mozilla-central-i386/build/python/mozbuild/mozbuild/telemetry.py", line 251, in get_vscode_running
for proc in psutil.process_iter():
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/__init__.py", line 1425, in process_iter
a = set(pids())
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/__init__.py", line 1365, in pids
ret = sorted(_psplatform.pids())
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_psbsd.py", line 514, in pids
if OPENBSD and (0 not in ret) and _pid_0_exists():
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_common.py", line 405, in wrapper
ret = cache[key] = fun(*args, **kwargs)
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_psbsd.py", line 502, in _pid_0_exists
Process(0).name()
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_psbsd.py", line 550, in wrapper
return fun(self, *args, **kwargs)
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_psbsd.py", line 617, in name
name = self.oneshot()[kinfo_proc_map['name']]
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_psbsd.py", line 550, in wrapper
return fun(self, *args, **kwargs)
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_common.py", line 450, in wrapper
return fun(self)
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_psbsd.py", line 605, in oneshot
ret = cext.proc_oneshot_info(self.pid)
| Assignee | ||
Comment 1•4 years ago
|
||
Hey Landry!
Thanks for reportin! (once again :-P)
Would you kindly check if returning false here fixes this for you?
| Reporter | ||
Comment 2•4 years ago
|
||
(In reply to Alessio Placitelli [:Dexter] from comment #1)
Hey Landry!
Thanks for reportin! (once again :-P)
Would you kindly check if returning false here fixes this for you?
tried it and no sadly that doesnt help - psutil can be imported without issues on OpenBSD/i386.. but seems process_iter() somehow fails ?
c32# /build/obj/buildslave/mozilla-central/_virtualenvs/build/bin/python
Python 3.9.13 (main, Jun 17 2022, 12:41:31)
[Clang 13.0.0 ] on openbsd7
Type "help", "copyright", "credits" or "license" for more information.
>>> import psutil
>>> psutil.process_iter()
File "<stdin>", line 0
SyntaxError: (unicode error) 'utf-8' codec can't decode byte 0xc3 in position 20: invalid continuation byte
running the same code interactively also fails on OpenBSD/amd64 (but configure succeeds there ?) so i guess smth wrong in my testing.
| Reporter | ||
Comment 3•4 years ago
|
||
ah, it's better with a locale set for python...
c32# LC_ALL=fr_FR.UTF-8 /build/obj/buildslave/mozilla-central/_virtualenvs/build/bin/python
Python 3.9.13 (main, Jun 17 2022, 12:41:31)
[Clang 13.0.0 ] on openbsd7
Type "help", "copyright", "credits" or "license" for more information.
>>> import psutil
>>> psutil.process_iter()
<generator object process_iter at 0x538a3648>
sadly, the same LC_ALL var trick doesnt allow me to run ./mach configure on OpenBSD/i386... puzzling.
| Reporter | ||
Comment 4•4 years ago
|
||
bah, should have tested better.. actually running the generator shows the underlying failure is indeed within psutil:
>>> for f in psutil.process_iter():
... print(f)
...
Traceback (most recent call last):
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_common.py", line 403, in wrapper
return cache[key]
KeyError: ((), frozenset())
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_common.py", line 447, in wrapper
ret = self._cache[fun]
AttributeError: _cache
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/__init__.py", line 1425, in process_iter
a = set(pids())
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/__init__.py", line 1365, in pids
ret = sorted(_psplatform.pids())
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_psbsd.py", line 514, in pids
if OPENBSD and (0 not in ret) and _pid_0_exists():
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_common.py", line 405, in wrapper
ret = cache[key] = fun(*args, **kwargs)
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_psbsd.py", line 502, in _pid_0_exists
Process(0).name()
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_psbsd.py", line 550, in wrapper
return fun(self, *args, **kwargs)
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_psbsd.py", line 617, in name
name = self.oneshot()[kinfo_proc_map['name']]
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_psbsd.py", line 550, in wrapper
return fun(self, *args, **kwargs)
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_common.py", line 450, in wrapper
return fun(self)
File "/build/buildslave/.mozbuild/srcdirs/build-f92f516ac5ed/_virtualenvs/mach/lib/python3.9/site-packages/psutil/_psbsd.py", line 605, in oneshot
ret = cext.proc_oneshot_info(self.pid)
SystemError: NULL object passed to Py_BuildValue
| Assignee | ||
Comment 5•4 years ago
|
||
Got it. Does this mean it's still a build system bug or something that has to do with the underlying OS?
| Reporter | ||
Comment 6•4 years ago
|
||
from my understanding that's a problem within psutil, which badly blows, and the above layers in mach fails to gracefully handle it.
| Assignee | ||
Comment 7•4 years ago
|
||
On OpenBSD/i386, psutils fails in the generator used to enumerate the
active processes, breaking the build.
| Assignee | ||
Comment 8•4 years ago
|
||
Hey :gaston!
Sorry for the noise again. Would you kindly verify if https://phabricator.services.mozilla.com/D150462 fixes it for you?
Thanks!
| Reporter | ||
Comment 9•4 years ago
|
||
Comment on attachment 9283185 [details]
Bug 1776219 - Gracefully handle psutils failures in mach telemetry.
yes, that allows me to run configure on OpenBSD/i386.
Another option would be to return False straight away in get_vscode_running on platforms we know vscode doesnt exist .. eg at least OpenBSD & NetBSD, since FreeBSD has a port.
| Reporter | ||
Comment 10•4 years ago
|
||
i have to admit that detecting if vscode is running by checking if there's a running process named "code" feels a bit fragile :) oh well...
Updated•4 years ago
|
Updated•4 years ago
|
| Assignee | ||
Comment 11•4 years ago
|
||
(In reply to Landry Breuil (:gaston) from comment #9)
Comment on attachment 9283185 [details]
Bug 1776219 - Gracefully handle psutils failures in mach telemetry.yes, that allows me to run configure on OpenBSD/i386.
Nice!
Another option would be to
return Falsestraight away inget_vscode_runningon platforms we know vscode doesnt exist .. eg at least OpenBSD & NetBSD, since FreeBSD has a port.
Yeah, though that would require us to make sure to keep track what platform vscode supports. I'd rather stick to the current approach for now!
| Assignee | ||
Comment 13•4 years ago
|
||
(In reply to Landry Breuil (:gaston) from comment #10)
i have to admit that detecting if vscode is running by checking if there's a running process named "code" feels a bit fragile :) oh well...
Heh, probably :-) I'm not familiar with this part of the codebase, so let's lean on the reviewers to see if that's the right call :)
Updated•4 years ago
|
Comment 14•4 years ago
|
||
Set release status flags based on info from the regressing bug 1717801
Comment 15•4 years ago
|
||
Comment 16•4 years ago
|
||
| bugherder | ||
Updated•4 years ago
|
| Reporter | ||
Comment 17•4 years ago
|
||
thanks :dexter, my i386 buildbot failed building later on ( http://buildbot.rhaalovely.net/nine/#/builders/1/builds/1291) and i'll look at the actual failure, but at least now configure was successful !
| Assignee | ||
Comment 18•4 years ago
|
||
(In reply to Landry Breuil (:gaston) from comment #17)
thanks :dexter, my i386 buildbot failed building later on ( http://buildbot.rhaalovely.net/nine/#/builders/1/builds/1291) and i'll look at the actual failure, but at least now configure was successful !
My pleasure :) please do file another bug if that ends up being a bug in Firefox!
Comment 19•4 years ago
|
||
The patch landed in nightly and beta is affected.
:Dexter, is this bug important enough to require an uplift?
- If yes, please nominate the patch for beta approval.
- If no, please set
status-firefox103towontfix.
For more information, please visit auto_nag documentation.
| Assignee | ||
Updated•4 years ago
|
Updated•4 years ago
|
Comment 20•4 years ago
|
||
| bugherder uplift | ||
Description
•