Update of /cvsroot/python/python/dist/src/Lib/distutils In directory usw-pr-cvs1:/tmp/cvs-serv10235 Modified Files: dist.py Log Message: Make the Distribution() constructor forgiving of unknown keyword arguments, triggering a warning instead of raising an exception. (In 1.5.2/2.0, it will print to stderr.) Bugfix candidate for all previous versions. This changes behaviour, but the old behaviour wasn't very useful. If Distutils version X+1 adds a new keyword argument, using the new keyword means your setup.py file won't work with Distutils version X any more. Index: dist.py =================================================================== RCS file: /cvsroot/python/python/dist/src/Lib/distutils/dist.py,v retrieving revision 1.56 retrieving revision 1.57 diff -C2 -d -r1.56 -r1.57 *** dist.py 11 Sep 2002 16:31:52 -0000 1.56 --- dist.py 31 Oct 2002 13:22:41 -0000 1.57 *************** *** 13,16 **** --- 13,22 ---- from types import * from copy import copy + + try: + import warnings + except: + warnings = None + from distutils.errors import * from distutils.fancy_getopt import FancyGetopt, translate_longopt *************** *** 207,212 **** setattr(self, key, val) else: ! raise DistutilsSetupError, \ ! "invalid distribution option '%s'" % key self.finalize_options() --- 213,221 ---- setattr(self, key, val) else: ! msg = "Unknown distribution option: %s" % repr(key) ! if warnings is not None: ! warnings.warn(msg) ! else: ! sys.stderr.write(msg + "\n") self.finalize_options()
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4