<tt><font size=2>Hi, sorry for the delay</font></tt>
<br><tt><font size=2><br>
> The GUI tools don't actually run yum or the plugin code, that's done<br>
> by the packagekitd daemon.<br>
<br>
> What version PackageKit and yum are you using? Could you upload your<br>
> yum plugin somewhere public also please.<br>
</font></tt>
<br><tt><font size=2>I am using F13:</font></tt>
<br><tt><font size=2>yum-3.2.28-4.fc13.noarch</font></tt>
<br><tt><font size=2>gnome-packagekit-2.30.3-1.fc13.x86_64</font></tt>
<br><tt><font size=2>PackageKit-gtk-module-0.6.6-2.fc13.i686</font></tt>
<br><tt><font size=2>PackageKit-gtk-module-0.6.6-2.fc13.x86_64</font></tt>
<br><tt><font size=2>PackageKit-0.6.6-2.fc13.x86_64</font></tt>
<br><tt><font size=2>PackageKit-device-rebind-0.6.6-2.fc13.x86_64</font></tt>
<br><tt><font size=2>PackageKit-glib-0.6.6-2.fc13.x86_64</font></tt>
<br><tt><font size=2>PackageKit-command-not-found-0.6.6-2.fc13.x86_64</font></tt>
<br><tt><font size=2>PackageKit-yum-plugin-0.6.6-2.fc13.x86_64</font></tt>
<br><tt><font size=2>PackageKit-yum-0.6.6-2.fc13.x86_64</font></tt>
<br><tt><font size=2>PackageKit-gstreamer-plugin-0.6.6-2.fc13.x86_64<br>
</font></tt>
<br><tt><font size=2>I uploaded an example of the codes here:</font></tt>
<br><tt><font size=2> * triggers INIT hook error: </font></tt><a href=http://pastebin.com/Ht9JR8DX><tt><font size=2>http://pastebin.com/Ht9JR8DX</font></tt></a>
<br><tt><font size=2> * triggers PRE or POST error: </font></tt><a href=http://pastebin.com/NuhPbzFh><tt><font size=2>http://pastebin.com/NuhPbzFh</font></tt></a>
<br>
<br><tt><font size=2>You can use them and run the gpk-application or the
gpk-update-viewer to check the errors.</font></tt>
<br>
<br>
<br><tt><font size=2>> It depends on how your plugin works. PackageKit
does some things a<br>
> little bit different to yum.<br>
<br>
> No. PackageKit is doing different things with the data, and is<br>
> exporting it in a different way to using the bare yum api.<br>
<br>
> What's your use case for adding and removing repos like you're suggesting?</font></tt>
<br>
<br><font size=2 face="sans-serif">We have to hide some repositories and
make them available on the fly when specific users run yum or any front-end
application to it .<br>
We get the repos from a webservice and add them dynamically.</font>
<br>
<br>
<br><font size=2 face="sans-serif">Regards</font>
<br><font size=2 face="sans-serif"><br>
Rodrigo Trujillo<br>
</font>
<br>
<br>
<table width=100%>
<tr valign=top>
<td><font size=1 color=#5f5f5f face="sans-serif">From:</font>
<td><font size=1 face="sans-serif">Richard Hughes <hughsient@gmail.com></font>
<tr valign=top>
<td><font size=1 color=#5f5f5f face="sans-serif">To:</font>
<td><font size=1 face="sans-serif">PackageKit users and developers list
<packagekit@lists.freedesktop.org></font>
<tr valign=top>
<td><font size=1 color=#5f5f5f face="sans-serif">Date:</font>
<td><font size=1 face="sans-serif">09/21/2010 08:16 AM</font>
<tr valign=top>
<td><font size=1 color=#5f5f5f face="sans-serif">Subject:</font>
<td><font size=1 face="sans-serif">Re: [packagekit] Problems with GPK and
Yum Plugins</font>
<tr valign=top>
<td><font size=1 color=#5f5f5f face="sans-serif">Sent by:</font>
<td><font size=1 face="sans-serif">packagekit-bounces+rotru=br.ibm.com@lists.freedesktop.org</font></table>
<br>
<hr noshade>
<br>
<br>
<br><tt><font size=2>On 21 September 2010 12:06, <rotru@br.ibm.com>
wrote:<br>
> I have an Yum Plugin that adds some repositories dynamically to yum
every<br>
> time it runs.<br>
> In the command line Yum works perfectly, and the same result was seen
in<br>
> gnome-packagekit apps.<br>
> But recently gpk-application and gpk-update-viewer are not working
anymore<br>
> with the plugin.<br>
<br>
The GUI tools don't actually run yum or the plugin code, that's done<br>
by the packagekitd daemon.<br>
<br>
> 1- I used to add the repositories in the "init hook", but,
in latest GPK<br>
> versions for F13 I started to get this error:<br>
><br>
> Traceback (most recent call last):<br>
> File "/usr/share/PackageKit/helpers/yum/yumBackend.py",
line 3270, in<br>
> __init__<br>
> self.repos.confirm_func = self._repo_gpg_confirm<br>
> File "/usr/lib/python2.6/site-packages/yum/__init__.py",
line 814, in<br>
> <lambda><br>
> repos = property(fget=lambda self: self._getRepos(),<br>
> File "/usr/lib/python2.6/site-packages/yum/__init__.py",
line 542, in<br>
> _getRepos<br>
> prerepoconf = self.prerepoconf<br>
> AttributeError: 'PackageKitYumBase' object has no attribute 'prerepoconf'<br>
<br>
<br>
What version PackageKit and yum are you using? Could you upload your<br>
yum plugin somewhere public also please.<br>
<br>
> 2- Using prereposetup or postreposetup the error above disappears
and<br>
> gpk-update-viewer, in a first step, finds the repos and the updates<br>
> available<br>
> from them. BUT, when I try to update, it returns an error saying the<br>
> repository was not found !!!<br>
<br>
It depends on how your plugin works. PackageKit does some things a<br>
little bit different to yum.<br>
<br>
> - What is GPK doing with the yum-plugins ? Should not it have the
same<br>
> behavior that YUM in command line ?<br>
<br>
No. PackageKit is doing different things with the data, and is<br>
exporting it in a different way to using the bare yum api.<br>
<br>
> - How can I add dynamic repositories to Yum and use them with GPK
?<br>
> - Is this a potential bug, as I get the behavior desired in the command<br>
> line?<br>
<br>
What's your use case for adding and removing repos like you're suggesting?<br>
<br>
Richard.<br>
_______________________________________________<br>
PackageKit mailing list<br>
PackageKit@lists.freedesktop.org<br>
</font></tt><a href=http://lists.freedesktop.org/mailman/listinfo/packagekit><tt><font size=2>http://lists.freedesktop.org/mailman/listinfo/packagekit</font></tt></a><tt><font size=2><br>
</font></tt>
<br>