Re: Pitfall: mxODBCZopeDA and test runner in 2.9+

"M.-A. Lemburg" <[email protected]>
Newsgroups gmane.comp.web.zope.database
Organization eGenix.com Software GmbH
Message-ID <[email protected]>
Paul Winkler wrote:
> If you have mxODBCZopeDA and are using it with zope 2.9 or higher,
> a word of warning:  
> 
>  You *must* use the -k option to the test runner when running
>  tests in your INSTANCE_HOME.
>  Example:
> 
>   ./bin/zopectl test -k
> 
> If you fail to use -k, the zope test runner will delete bytecode for all
> your products - including mxODBCZopeDA, which has no .py files to fall
> back on.  Ouch. I'll investigate further - there might be a bug to file
> against zope.testing.

Why does the test runner delete .pyc files in directories it
doesn't own ?

.pyc files only change if you upgrade to a new Python version,
so there doesn't seem to be a need for removing them in the first
place. Python is also smart enough to detect updated .py files
and regenerate .pyc files from them automatically (.pyc files have
a timestamp builtin).

-- 
Marc-Andre Lemburg
eGenix.com

Professional Python Services directly from the Source  (#1, Oct 13 2006)
>>> Python/Zope Consulting and Support ...        http://www.egenix.com/
>>> mxODBC.Zope.Database.Adapter ...             http://zope.egenix.com/
>>> mxODBC, mxDateTime, mxTextTools ...        http://python.egenix.com/
________________________________________________________________________

::: Try mxODBC.Zope.DA for Windows,Linux,Solaris,FreeBSD for free ! ::::
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.