[Debian-med-packaging] Bug#732945: Debian-Bug#732945: python-csb autopkg test always fails

Andreas Tille andreas at an3as.eu
Tue Dec 24 16:24:03 UTC 2013


Hi Ivan,

On Tue, Dec 24, 2013 at 08:41:38AM +0000, Ivan Kalev wrote:
> Just to make sure that I understood everything correctly:
> 
> - you run the build as root

Well, it is actually fakeroot (so faking to be root but without
permission to write to /usr).

> - then you run the test suite again as root and it passes, right?

No, the testsuite does not pass.  

> - this bug appears only when you install the built package and then run the
> test suite as normal user?

In both cases it does not run.
 
> Is this all correct?
> 
> Here is some background. Our project supports several workflows:
> 
> 1) csb developer: checkout/update from the repo, run all tests, write code,
> run tests, commit, etc. The first time a developer runs the test suite,
> some files get written to csb/test/data and remain there (virtually
> forever). Next time the developer runs the test suite to verify their code,
> these files will be read directly from csb/test/data. This is what I mean
> by future use.
> 
> 2) csb nightly build process: this is pretty much your workflow as well.
> Checkout the repo in an empty directory, run the test suite, build package,
> publish artifacts, wipe the entire checkout directory. The moment the build
> bot runs the test suite, some files get generated in csb/test/data. These
> are needed by some test cases and will get deleted along with everything
> else  once the checkout dir gets wiped at the end of the build.
> 
> 3) csb user: install package, use package. No test suites are necessary and
> no files in csb/test/data need to get generated,  stored or used. If the
> user decided to run the test suite for some reason (e.g. to verify that all
> dependencies are properly installed), csb will attempt to generate the
> missing files in csb/test/data. But as you observed, this is only possible
> if csb/test/data is a writable directory. One workaround is to install csb
> from PyPI with normal privileges and a prefix:
> 
> $ python setup.py install --prefix <alt location>
> 
> Another possibility is to modify our code to write these files in
> csb/test/data, but if that is not possible --- to ~/.csb-test-files or
> something similar.

According to FHS it would be reasonable to write to

   /var/{lib,cache}/csb

I think this would fit your workflow as well, isn't it?

> Many thanks for your help!

Thanks for supporting our packaging by responding very quickly and helpful

    Andreas.

-- 
http://fam-tille.de



More information about the Debian-med-packaging mailing list