[02:03:20] ** bitmonk has joined us [02:41:19] ** bitmonk has left IRC () [03:02:36] ** coderanger has left IRC () [03:08:09] ** coderanger has joined us [03:11:37] ** thinkeryzu has left IRC ("Leaving.") [03:12:57] ** thinkeryzu has joined us [05:08:14] ** apoirier has joined us [05:59:12] [connected at Thu Mar 6 05:59:12 2008] [05:59:12] <> *** Looking up your hostname... [05:59:13] <> *** Checking ident [05:59:13] <> *** No identd (auth) response [05:59:13] <> *** Found your hostname [05:59:13] <> *** Your host is clarke.freenode.net[clarke.freenode.net/6667], running version hyperion-1.0.2b [05:59:15] [I have joined #peak] [05:59:15] ** clarke.freenode.net set the topic to does anyone remember the real topic ? - not really ... [06:41:01] ** mike8 has joined us [07:34:29] zookobedtime is now known as zooko [09:45:43] Good morning! (Mountain Time, North America [09:45:44] ) [09:46:19] Folks: yesterday I made a setuptools plugin to make "./setup.py flakes" run pyflakes: [09:46:20] http://pypi.python.org/pypi/setuptools_pyflakes [09:46:35] (This was accomplished mostly by copying Ian Bicking's code to do the same thing from his buildutils project.) [09:46:53] Today I want a setuptools plugin to make "./setup.py figleaf-test" run the normal "./setup.py test" tests, but under figleaf. [09:47:10] How do I "hook in" to start figleaf before the test command runs and to stop figleaf after the test command finishes? [10:01:58] zooko is now known as zookovolunteerin [11:37:00] ** mike8 has left IRC ("Leaving") [12:04:05] ** pje has joined us [12:12:50] ** apoirier has left IRC ("KVIrc 3.2.6 Anomalies http://www.kvirc.net/") [12:33:30] zookovolunteerin is now known as zooko [12:50:14] ** bitmonk has joined us [13:13:38] pje: I'm trying to figure out the best way to integrate figleaf into my development tools, and other people's. [13:13:51] what's figleaf? [13:13:54] I earlier thought I wanted a setuptools plugin that added a command named "test-figleaf" [13:14:05] http://darcs.idyll.org/~t/projects/figleaf/doc/ [13:14:29] http://allmydata.org has an extensive farm of buildslaves, and one thing that they do on every check-in of a patch [13:14:39] is run the unit tests with figleaf turned on, to generate code coverage statistics. [13:14:47] http://allmydata.org/buildbot/ [13:15:10] Here are the resulting code coverage annotations: http://allmydata.org/tahoe-figleaf/current/ [13:15:31] And here is the graph of number of lines of code not covered by the unit tests: [13:15:31] http://allmydata.org/tahoe-figleaf-graph/hanford.allmydata.com-tahoe_figleaf2.html [13:15:53] So now what I think I want is for "./setup.py test" to take a "--figleaf" option. [13:16:09] What package or source code is responsible for providing the "test" command? [13:16:38] setuptools.command.test [13:17:00] Is there a clean way for a setuptools plugin to add an option to the test command, and hook into it? [13:17:08] per http://darcs.idyll.org/~t/projects/figleaf/doc/ , what is needed is to [13:17:14] Nope. All you can do is replace it. [13:17:19] call figleaf.start() before running the tests, and figleaf.stop() afterward. [13:17:35] Hm. Can I replace it with a command which invokes the setuptools.command.test command? [13:17:43] However, you *can* specify a "test runner", which will be responsible for turning your test_suite string into a unittest suite. [13:17:50] Sure. [13:18:10] Heck, you can just make your command subclass it. [13:18:36] What would you recommend -- making a plugin which has a figleafytest that subclasses the setuptools.command.test and adds a figleaf option? [13:18:43] ** TachyonXV has joined us [13:18:48] ** TachyonXV has left us [13:18:49] Or adding a test runner -- I don't know how to plug that in. [13:18:59] Or patching setuptools itself to add a --figleaf option? [13:19:41] By the way, I recently heard from my brother about a conversation he had with a successful programmer who was enthusiastic about Ruby. [13:19:57] One of his best points was that almost all Ruby software is gemified, but little Python software is eggified. [13:20:13] So he ends up re-using code more in Ruby, even if more libraries and code exists in Python. [13:20:35] This reinforces my already pressing belief that setuptools/easy_install/eggs would bring a lot more value to the world by wider adoption. [13:26:46] Er, easy_install-able != eggified [13:26:58] You can easy_install quite a lot of the cheeseshop [13:27:14] Oh, I know that. [13:27:23] wrt to how best to add your code, I would recommend you subclass the test command. [13:27:44] Okay, and publish a setuptools plugin that replaces the "test" command with a new one that is just the same as the old one except with a --figleaf option? [13:28:06] Named setuptools_figleaf, and, once the new classifier is added, having the new "Framework :: Setuptools Plugin" classifier? [13:28:35] or see this: http://peak.telecommunity.com/DevCenter/setuptools#test-loader [13:29:11] Hm. Thanks. I also want setuptools integration for twisted trial... [13:30:02] That might Just Work if I specify trial as the test_loader... [13:30:07] bbiab [13:30:10] zooko is now known as zookomakingcoffe [13:37:49] zookomakingcoffe is now known as zooko [15:11:54] ** thinkeryz1 has joined us [15:22:23] ** thinkeryzu has left IRC (Read error: 104 (Connection reset by peer)) [16:02:19] pje is now known as pje_afk [16:26:56] zooko is now known as zookonap [16:54:30] zookonap is now known as zooko [17:12:30] pje_afk is now known as pje [18:08:26] ** tav has joined us [18:53:19] zooko is now known as zookoafk [19:08:04] zookoafk is now known as zooko [19:31:59] zooko is now known as zookofamilytime [20:45:44] ** pje has left IRC ("Client exiting") [20:58:50] ** bitmonk has left IRC (Read error: 104 (Connection reset by peer)) [21:51:34] zookofamilytime is now known as zooko [22:04:42] ** bitmonk has joined us [22:20:32] ** thinkeryz1 has left IRC ("Leaving.") [22:20:52] ** thinkeryzu has joined us