[PEAK] Passing user and password to easy_install

Luigi Paioro luigi at lambrate.inaf.it
Mon Apr 12 12:23:44 EDT 2010

>> what I'd like to have is the possibility to avoid asking the user to
>> explicitly refer to a specific repository address (it might be
>> provided with an easy_install configuration file, for example), and in
>> particular I would avoid to put clearly the user name and the password
>> in the command line.
> Then right now, you'll need to put them in the configuration file.

Yes, indeed.

>> Poking around setuptools code, I stumbled on the routine where the
>> actual package downloading is performed, and thus I tried to modify
>> the code in order to introduce something that might meet my needs. In
>> attachment you find a package_index.py patch file with very few lines
>> giving me all I need. It is just a testing code, not really clean,
> Currently, easy_install is not designed to be user-interactive, and a
> "not really clean testing code" is not a suitable way to change that. In
> particular, other programs reuse easy_install's code and are not
> expecting it to prompt for user input. At minimum, there would need to
> be a command-line option used to enable interactivity, and the default
> behavior would need to be to respond to 401 with output telling the user
> that they need to enable interactivity to get a password prompt.

The example code I attached was just to help me explaining what I meant. 
Certainly your solution is more suited and would be a very nice new feature.


More information about the PEAK mailing list