Re: [Python-Dev] os.removedirs() vs. shutil.rmtree()
On Sat, Jan 08, 2005 at 02:45:25PM -0600, Skip Montanaro wrote: Is there a reason the standard library needs both os.removedirs and shutil.rmtree? They seem awful similar to me (I can see they aren't really identical). Ditto for os.renames and shutil.move. Presuming they are all really needed, is there some reason they don't all belong in the same module? os.removedirs() only removes directories, it will fail to remove a non-empty directory, for example. It also doesn't have the ignore_errors/onerror arguments [1]. os.renames() is different from shutil.move() in that it also creates intermediate directories (and deletes any left empty). So they're not identical, but I do agree they should be consolidated and moved into one module. I'd say shutil, both because the os module is already awfully crowded, and because these functions are high-level operations on files and collections of files rather than a more portable way of using operating system dependent functionality [...]. Johannes [1] That may actually be a good thing, though. It was a pain to keep those working backwards-compatibly when shutil.rmtree was recently rewritten. ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Website documentation - link to descriptor information
On Thu, Dec 23, 2004 at 09:41:20PM +1000, Nick Coghlan wrote: I just spent 10 minutes hunting through the Python website for this link: http://www.python.org/doc/newstyle.html I knew it was there somewhere, I just couldn't find the darn thing. It turns out the major mistake I made was to start from docs.python.org instead of www.python.org/doc. It's on docs.python.org now. Cheers, Johannes ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Re:[Python-checkins] python/dist/src/Pythonmarshal.c, 1.79, 1.80
On Tue, Dec 21, 2004 at 08:00:22PM +0100, Irmen de Jong wrote: Thanks for those suggestions. Let's see what I can concoct. Never made (or studied in detail) a python regression test case before so now is a good time :) You might be especially interested in 'class urlopen_HttpTests' in test_urllib.py and all the Mock* classes in test_urllib2.py. BTW, don't hesitate to ask for help in the bug/patch. I'm happy to help, though I might be a bit slow to answer. Cheers, Johannes ___ Python-Dev mailing list [EMAIL PROTECTED] http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com