On 12/06/09 10:26, Padraig O'Briain wrote:
Shawn Walker wrote:
Padraig O'Briain wrote:
The webrev, http://cr.opensolaris.org/~padraig/ips-9519-v1/ , fixes
9519 Package Manager and Update Manager should not call
misc.get_inventory_list
This webrev contains the following changes:
Package Manager uses the new API get_pkg_list() to get the packages
for a publisher instead of misc.get_inventory_list().
...
Update Manager uses get_pkg_list() to determine which packages to
list instead of misc_get_inventory_list(). It now lists the
currently installed version and not the latest version of a package
but the latest version can be seen in the details tab for the package.
So I applied v2 of your webrev to my workspace. PM is extremely
snappy now and scrolling through the list of packages is quite
satisfying.
On my system, it takes PM about 4s real time (roughly) to process the
package list at startup, which is pretty good. It takes the CLI
about 2.7s real on my system, but you have a lot more overhead with
Gtk, so I think we've finally hit a very good performance point.
I did notice that you are mapping package states to your own set of
enumerations at startup. It might be faster if you just used the
packageinfo constants as is instead. Have you considered that?
For example, if you made your enumerations equal to the same value as
the constants, you wouldn't have to map the state info. You could
just use it as is.
Any thoughts on that?
This is a good idea.I have logged 13104 as I do not think I want to do
this before landing this webrev.
Also, I did see this traceback on the command line:
Traceback (most recent call last):
File "/usr/lib/python2.6/threading.py", line 525, in __bootstrap_inner
self.run()
File "/usr/lib/python2.6/threading.py", line 477, in run
self.__target(*self.__args, **self.__kwargs)
File
"/export/home/swalker/devel/pkg-tip/proto/root_i386/usr/lib/python2.6/vendor-packages/pkg/gui/cache.py",
line 72, in __load_search_completion_info
return gtk.ListStore(str)
NameError: global name 'gtk' is not defined
This was caused by my over-enthusiastic removal of code from cache.py.
It should be fixed in the latest webrev,
http://cr.opensolaris.org/~padraig/ips-9519-v3/.
Padraig
I have respun the webrev,
http://cr.opensolaris.org/~padraig/ips-9519-v5/, to make some cosmetic
changes to Update Manager and fix some coding issues, create
__get_pkg_stem and add tr/execpt around call to get_pkg_list in
packagemanager.py, raised by John in off line conversation.
Padraig
Cheers,
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss