<br><tt><font size=2>Dan Williams wrote on 11/13/2006 03:26:58 PM:<br>
<br>
&gt; On Sun, 2006-11-05 at 23:48 -0500, Joe Todaro wrote:<br>
&gt; &gt; <br>
&gt; &gt; ---- PROBLEM # 1 ---- &nbsp;Depsolve step keeps crashing due
to a typo in<br>
&gt; &gt; the script: &nbsp;<br>
&gt; &gt; <br>
&gt; &gt; 364 (fuse-sshfs): Starting depsolve for arches: ['x86_64', 'i386'].
<br>
&gt; &gt; Exception in thread PackageJob: 364/fuse-sshfs: <br>
&gt; &gt; [...snip...] <br>
&gt; &gt; &gt; &nbsp; File &quot;/usr/share/plague/server/PackageJob.py&quot;,
line 513, in <br>
&gt; &gt; &gt; _arch_deps_solved <br>
&gt; &gt; &gt; &nbsp; &nbsp; base.log = logger.Logger(threshold=threshold,<br>
&gt; &gt; file_object=sys.stdout) <br>
&gt; &gt; &gt; NameError: global name 'logger' is not defined &nbsp;<br>
&gt; <br>
&gt; Fixed, thanks!</font></tt>
<br>
<br><tt><font size=2>My pleasure - glad to help.</font></tt>
<br><tt><font size=2><br>
&gt; <br>
&gt; &gt; <br>
&gt; &gt; ---- PROBLEM # 2 ---- Unable to kill any job that fails due to
a<br>
&gt; &gt; missing package/s in the yum repos: <br>
&gt; &gt; <br>
&gt; &gt; &gt; &nbsp; File &quot;/usr/share/plague/server/PackageJob.py&quot;,
line 548, in<br>
&gt; &gt; _arch_deps_solved <br>
&gt; &gt; &gt; &nbsp; &nbsp;pkg = base.returnPackageByDep(dep) <br>
&gt; &gt; &gt; &nbsp; File &quot;__init__.py&quot;, line 1342, in returnPackageByDep
<br>
&gt; &gt; &gt; YumBaseError: No Package found for fuse-devel &nbsp;<br>
&gt; <br>
&gt; What version of yum do you have on this machine? &nbsp;</font></tt>
<br>
<br><tt><font size=2>yum-2.4.2-2</font></tt>
<br>
<br><tt><font size=2>&gt; The versions of the<br>
&gt; yum python libraries are a bit confusing here; and that's probably
where<br>
&gt; the error is coming from. &nbsp;It appears that an unexpected error
is<br>
&gt; getting thrown, and we need to catch that error. &nbsp;However, I'm
not sure<br>
&gt; where exactly it's coming from to catch it. &nbsp;Can you try to get
this<br>
&gt; error again and then paste in about 10 lines of code from around the<br>
&gt; Line # in PackageJob.py that this backtrace comes from? (ie, line
548<br>
&gt; here), and mark the line numbers too?</font></tt>
<br>
<br><tt><font size=2>&nbsp; &nbsp; 537 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; try:</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 538 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; base.doSackSetup(archlist)</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 539 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; except yum.Errors.RepoError, exc:</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 540 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; raise DepError(str(exc))</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 541</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 542 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; for dep in srpm.requiresList():</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 543 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; if dep.startswith(&quot;rpmlib(&quot;):</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 544 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; continue</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 545 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; if use_repomd:</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 546 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; try:</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 547 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; pkg = base.returnPackageByDep(dep)</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 548 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; except repomd.mdErrors.PackageSackError,
exc:</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 549 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; raise DepError(str(exc))</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 550 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; else:</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 551 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; try:</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 552 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; pkg = base.returnPackageByDep(dep)</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 553 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; except yum.Errors.PackageSackError,
exc:</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 554 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; raise DepError(str(exc))</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 555 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; except yum.Errors.YumBaseError, exc:</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 556 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; raise DepError(str(exc))</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 557 &nbsp; &nbsp; &nbsp; &nbsp; except
DepError, exc:</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 558 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; self._last_depsolve_error = str(exc)</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 559 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; print &quot;%s (%s/%s): Depsolve Error: %s&quot; % (self.uid, self.package,
arch, str(exc))</font></tt>
<br><tt><font size=2>&nbsp; &nbsp; 560 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; success = False</font></tt>
<br><tt><font size=2><br>
&gt; <br>
&gt; The fix you posted for this hunk isn't the &quot;correct&quot; fix;
</font></tt>
<br>
<br><tt><font size=2>Actually, it wasn't intended to &quot;fix&quot; the
(YumBaseError) problem </font></tt>
<br><tt><font size=2>itself -- rather it was just intended to provide us
with a means by </font></tt>
<br><tt><font size=2>which we'd be able to &quot;recover* from the negative
effects of the </font></tt>
<br><tt><font size=2>problem, which was a plague-server that wouldn't allow
us to *kill* </font></tt>
<br><tt><font size=2>the associated buildjob because the buildjob wasn't
in &quot;waiting&quot; </font></tt>
<br><tt><font size=2>state -- it was in &quot;depsolve&quot; which is where
it got stuck. Anyway, </font></tt>
<br><tt><font size=2>recycling the plague-server did not help -- it just
kept restarting </font></tt>
<br><tt><font size=2>the buildjob which just kept failing in the same place
even after we</font></tt>
<br><tt><font size=2>downloaded the missing package (fuse-devel) to the
yum repo and ran</font></tt>
<br><tt><font size=2>the createrepo command in-between plague-server restarts.
</font></tt>
<br>
<br><tt><font size=2>&gt; that would be<br>
&gt; to catch the exception and to re-throw it as a DepSolveError as is
done<br>
&gt; for the other 'execpt' blocks around there.<br>
&gt; <br>
&gt; Cheers,<br>
&gt; Dan<br>
&gt; <br>
&gt; &gt; <br>
&gt; &gt; ---- PATCH ---- &nbsp; &nbsp;<br>
&gt; &gt; <br>
&gt; &gt; Here's the patch that resolved the above 2 problems for us: &nbsp;<br>
&gt; &gt; &nbsp; <br>
&gt; &gt; <br>
&gt; &gt; <br>
&gt; &gt; ----- REQUEST ---- <br>
&gt; &gt; <br>
&gt; &gt; Can someone please review it... especially the fix to PROBLEM
# 2,<br>
&gt; &gt; that could potentially be masking a bigger problem.. &nbsp; <br>
&gt; &gt; <br>
&gt; &gt; Here's the code for your convenience (...these are the updates
we made<br>
&gt; &gt; to the _latest_ version of PackageJob.py): <br>
&gt; &gt; <br>
&gt; &gt; $ cd /usr/share/plague/server <br>
&gt; &gt; $ diff PackageJob.py PackageJob.py.working <br>
&gt; &gt; 513c513 <br>
&gt; &gt; &lt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
base.log = logger.Logger(threshold=threshold,<br>
&gt; &gt; file_object=sys.stdout) <br>
&gt; &gt; --- <br>
&gt; &gt; &gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
base.log = Logger(threshold=threshold,<br>
&gt; &gt; file_object=sys.stdout) <br>
&gt; &gt; 698c698 <br>
&gt; &gt; &lt; &nbsp; &nbsp; &nbsp; &nbsp; if self._curstage == 'waiting':
<br>
&gt; &gt; --- <br>
&gt; &gt; &gt; &nbsp; &nbsp; &nbsp; &nbsp; if self._curstage in ['waiting',
'depsolve']: <br>
&gt; &gt; <br>
&gt; &gt; <br>
&gt; &gt; Thanks, <br>
&gt; &gt; &nbsp; Joe<br>
&gt; &gt; --<br>
&gt; &gt; Fedora-buildsys-list mailing list<br>
&gt; &gt; Fedora-buildsys-list@redhat.com<br>
&gt; &gt; https://www.redhat.com/mailman/listinfo/fedora-buildsys-list<br>
&gt; <br>
&gt; --<br>
&gt; Fedora-buildsys-list mailing list<br>
&gt; Fedora-buildsys-list@redhat.com<br>
&gt; https://www.redhat.com/mailman/listinfo/fedora-buildsys-list<br>
</font></tt>