[Yum] HTTP/FTP Authentication

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jul 30, 2003 at 09:37:39AM -0400, seth vidal wrote:
> > OK, I feel a little silly.  I didn't know that was available at all.
> > I agree.  Probably the cleanest way to do it is to push it in from
> > yummain.  You could do that in two ways:
> > 
> > 1) by importing urlgrabber from within yummain (making yummain depend
> >    on urlgrabber directly is no big deal because it already depends on
> >    it indirectly via clientStuff)
> > 
> >    # <within yummain.py>
> >    import urlgrabber
> >    __version__='2.0'
> >    urlgrabber.set_user_agent('Yum/%s' % __version__)
> 
> Only trick is how to get urlgrabber into the clientStuff namespace then.

It's already there.  If you put the above code into the cvs
yummain.py, it will work right now.  clientStuff needs urlgrabber
directly, so it imports it.

> I was thinking conf.version = __version__ in yummain
> then clientstuff can use version from the conf object.

That is also a very tidy solution.  If you prefer that, I think it's
completely reasonable.  I may actually prefer it myself.  conf is a
global conf object and that seems like a sensible place to stash the
version.

					-Michael

-- 
  Michael Stenner                       Office Phone: 919-660-2513
  Duke University, Dept. of Physics       mstenner@xxxxxxxxxxxx
  Box 90305, Durham N.C. 27708-0305


[Index of Archives]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]

  Powered by Linux