0001 """distutils.errors 0002 0003 Provides exceptions used by the Distutils modules. Note that Distutils 0004 modules may raise standard exceptions; in particular, SystemExit is 0005 usually raised for errors that are obviously the end-user's fault 0006 (eg. bad command-line arguments). 0007 0008 This module is safe to use in "from ... import *" mode; it only exports 0009 symbols whose names start with "Distutils" and end with "Error".""" 0010 0011 # This module should be kept compatible with Python 1.5.2. 0012 0013 __revision__ = "$Id: errors.py,v 1.12 2002/11/19 13:12:27 akuchling Exp $" 0014 0015 class DistutilsError (Exception): 0016 """The root of all Distutils evil.""" 0017 pass 0018 0019 class DistutilsModuleError (DistutilsError): 0020 """Unable to load an expected module, or to find an expected class 0021 within some module (in particular, command modules and classes).""" 0022 pass 0023 0024 class DistutilsClassError (DistutilsError): 0025 """Some command class (or possibly distribution class, if anyone 0026 feels a need to subclass Distribution) is found not to be holding 0027 up its end of the bargain, ie. implementing some part of the 0028 "command "interface.""" 0029 pass 0030 0031 class DistutilsGetoptError (DistutilsError): 0032 """The option table provided to 'fancy_getopt()' is bogus.""" 0033 pass 0034 0035 class DistutilsArgError (DistutilsError): 0036 """Raised by fancy_getopt in response to getopt.error -- ie. an 0037 error in the command line usage.""" 0038 pass 0039 0040 class DistutilsFileError (DistutilsError): 0041 """Any problems in the filesystem: expected file not found, etc. 0042 Typically this is for problems that we detect before IOError or 0043 OSError could be raised.""" 0044 pass 0045 0046 class DistutilsOptionError (DistutilsError): 0047 """Syntactic/semantic errors in command options, such as use of 0048 mutually conflicting options, or inconsistent options, 0049 badly-spelled values, etc. No distinction is made between option 0050 values originating in the setup script, the command line, config 0051 files, or what-have-you -- but if we *know* something originated in 0052 the setup script, we'll raise DistutilsSetupError instead.""" 0053 pass 0054 0055 class DistutilsSetupError (DistutilsError): 0056 """For errors that can be definitely blamed on the setup script, 0057 such as invalid keyword arguments to 'setup()'.""" 0058 pass 0059 0060 class DistutilsPlatformError (DistutilsError): 0061 """We don't know how to do something on the current platform (but 0062 we do know how to do it on some platform) -- eg. trying to compile 0063 C files on a platform not supported by a CCompiler subclass.""" 0064 pass 0065 0066 class DistutilsExecError (DistutilsError): 0067 """Any problems executing an external program (such as the C 0068 compiler, when compiling C files).""" 0069 pass 0070 0071 class DistutilsInternalError (DistutilsError): 0072 """Internal inconsistencies or impossibilities (obviously, this 0073 should never be seen if the code is working!).""" 0074 pass 0075 0076 class DistutilsTemplateError (DistutilsError): 0077 """Syntax error in a file list template.""" 0078 0079 0080 # Exception classes used by the CCompiler implementation classes 0081 class CCompilerError (Exception): 0082 """Some compile/link operation failed.""" 0083 0084 class PreprocessError (CCompilerError): 0085 """Failure to preprocess one or more C/C++ files.""" 0086 0087 class CompileError (CCompilerError): 0088 """Failure to compile one or more C/C++ source files.""" 0089 0090 class LibError (CCompilerError): 0091 """Failure to create a static library from one or more C/C++ object 0092 files.""" 0093 0094 class LinkError (CCompilerError): 0095 """Failure to link one or more C/C++ object files into an executable 0096 or shared library file.""" 0097 0098 class UnknownFileError (CCompilerError): 0099 """Attempt to process an unknown file type.""" 0100
Generated by PyXR 0.9.4