Email Re: New PyLint release

from
Andreas Amoroso <a.amoroso at freenet dot de>
to
Sylvain Thenault <syt at logilab dot fr>
subject
Re: New PyLint release
date
2004/05/15 10:19
Hello Sylvain,

the problem building binary distributions (probably setup.py bdist_rpm 
will also not work) using the default (common) setup is caused by the 
way you carry out post installation tasks. I am not sure why you chose 
to deploy post installation tasks in the first place, but in case that 
should be necessary the only solution to the problem seems to be to use 
the proposed way of supplying a post installation task script that needs 
to be registered with the setup function and named using an  option when 
calling setup (details in the manual, distutils section).  The way you 
do currently fails because in a binary distribution build there is no 
installation directory present when your post-installation script tries 
to create the __init__.py (as nothing gets installed yet and the build 
directory is removed partially before the setup function exits).

You may of course specify additional files calling setup that are not 
located in the module directory, but I suppose you knew that. It all 
boils down to the question why this special setup is required (and, of 
course, if it is worth the trouble to support binary distributions in 
the first place). In case you should be happy with this limitation I 
would consider it to be a good idea to embed the __init__-creation in a 
try/except clause and to let the user know that the file needs to be 
created manually when the binary distribution is used (basically, after 
creating the init manually the last version of PyLint installed from my 
binary distribution worked all right for me, thus nothing really 
important should be missing).

Best regards,
Andreas


Sylvain Thénault schrieb am 14.05.2004 14:57:

>On Thursday 13 May à 21:24, Andreas Amoroso wrote:
>  
>
>>Hello again,
>>    
>>
>
>hello

>  
>
>>nice to see that the new release is out already. I took the opportunity 
>>to find out what the problem was that I had the last time installing 
>>PyLint. I build a binary installer using setup.py bdist_wininst and got:
>>
>>   C:\>setup.py bdist_wininst
>>   running bdist_wininst
>>   running build
>>  
>>   ...
>>  
>>   adding 'PURELIB\logilab\common\ureports\text_writer.py'
>>   adding 'PURELIB\logilab\common\ureports\__init__.py'
>>   creating dist
>>   removing 'build\bdist.win32\wininst' (and everything under it)
>>   Traceback (most recent call last):
>>     File "C:\setup.py", line 179, in ?
>>       install()
>>     File "C:\setup.py", line 163, in install
>>       stream = open(product_init, 'w')
>>   IOError: [Errno 2] No such file or directory: 
>>'build\\bdist.win32\\wininst\\PURELIB\\logilab\\__init__.py'
>>
>>Using setup.py install creates the __init__.py as expected, using the 
>>binary installer does not. Obviously, creating the binary installer on 
>>Win is/shows the problem.  This is not at all important, but using Win 
>>its still nice to install Python modules this way. Maybe it would be 
>>worth fixing it in a future release.  (You are on *nix, right?)
>>    
>>
>
>Yeah, we've no windows machine... I'll try to take a look at this.
>Anyway, I'll have to make a bug fix release soon since there is an
>annoying bug with bad method name.
>
>  
>
>>BTW, IMHO the naming convention for the module-specific PyLint output 
>>file is - well - not what I would have chosen. Don't you think something 
>>like PyPosta.pylint.txt or even (consistent to global file name) 
>>pylint_PyPosta.txt would be nicer than PyPosta,pylint.txt?
>>    
>>
>
>well, I've to say it does'nt really matter for me. I can change this if
>you think it's better.
>
>regards
>  
>


is a reply to
in thread