buildout doesn't tear down loggers

Bug #125729 reported by Philipp von Weitershausen
4
Affects Status Importance Assigned to Milestone
Buildout
Won't Fix
Undecided
Unassigned
zopeproject
Confirmed
Undecided
Unassigned

Bug Description

When you call buildout from the Python API multiple times, buildout's _setup_logging will add a new logging handler each time, causing its output to be multiplied, e.g.:

<<<Calling bootstrap>>>
Creating directory '/Users/philipp/dev/grokproject/Foo/bin'.
Creating directory '/Users/philipp/dev/grokproject/Foo/parts'.
Creating directory '/Users/philipp/dev/grokproject/Foo/develop-eggs'.
Generated script '/Users/philipp/dev/grokproject/Foo/bin/buildout'.
<<<Calling install>>>
Invoking zc.buildout...
Develop: '/Users/philipp/dev/grokproject/Foo/.'
Develop: '/Users/philipp/dev/grokproject/Foo/.'
Installing app.
Installing app.
Generated script '/Users/philipp/dev/grokproject/Foo/parts/app/runzope'.
Generated script '/Users/philipp/dev/grokproject/Foo/parts/app/runzope'.
Generated script '/Users/philipp/dev/grokproject/Foo/parts/app/debugzope'.
Generated script '/Users/philipp/dev/grokproject/Foo/parts/app/debugzope'.
Installing data.
Installing data.
Installing zopectl.
Installing zopectl.
Generated script '/Users/philipp/dev/grokproject/Foo/bin/zopectl'.
Generated script '/Users/philipp/dev/grokproject/Foo/bin/zopectl'.
Installing test.
Installing test.
Generated script '/Users/philipp/dev/grokproject/Foo/bin/test'.
Generated script '/Users/philipp/dev/grokproject/Foo/bin/test'.

Revision history for this message
Jim Fulton (jim-zope) wrote :

Creating buildout objects or calling main from Python code isn't a supported use case. I'm not necessarily opposed to creating an API at this level, but it would be a new feature.

Changed in zc.buildout:
status: New → Won't Fix
Changed in zopeproject:
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.