On Thu 17 Apr 2008 at 07:37PM, Danek Duvall wrote:
> http://cr.opensolaris.org/~dduvall/pkg-misc3/
>
> This is intended to fix
>
> 669 Need method to print package licenses before installation
> 1144 "pkg list -as" fails when unable to write to the pkg directory
>
> and ends up fixing part of
>
> 208 pkg info, pkg list display no output for pkgs in the repository and
> not installed
>
> In particular, "pkg info" has grown a --license option (for 669), and a -r
> option (also for 669, but that's part of what 208 wants). But I'm not
> adding "-s <server>" to "pkg info", and I'm not adding a remote version of
> what is now "pkg contents".
>
> I'd like folks' thoughts on the loop I copied from image.py to client.py.
> That should be refactored, but given that it's slightly different in the
The layering/implicit knowledge in client.py that something is
going to be gzipped seems... sketchy IMO.
Test cases needed for each of the failure modes at:
client.py: 686 (info: -l and -r may not be combined)
client.py: 689 (nfo: must request remote info for specific packages)
client.py: I personally really like a couple of lines of vertical
whitespace between functions, esp. in python where there is no column
zero closing brace to signify function end. Oh well.
More "get a list of things" sprawl. Oh well. We need to clean this up
post-May.
Can you post some sample output please?
Didn't totally understand the movement of gunzip stuff from generic to
misc....
client/image.py: Any deeper implications of this change? Would
we want to warn the customer that they're fetching manifests but
they can't be stored locally? For non-priv users, should we have
a stash in /tmp or something? I could see this banging on the
server rather a lot...
client/image.py: I know you didn't write this but "parse" is a really
vague name and it took me some time to work out what this was doing.
Would this code be clearer, shorter and faster as follows?
mfst = self.get_manifest(fmri, filtered = True)
for depend in mfst.gen_actions_by_type("depend"):
required, min_fmri, max_fmri = depend.parse()
if required == False:
self.update_optional_dependency(min_fmri)
I couldn't work out why we needed a list comprehension.
-dp
--
Daniel Price - Solaris Kernel Engineering - [EMAIL PROTECTED] - blogs.sun.com/dp
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss