Coverage for src / ezcompiler / shared / exceptions / utils / compiler_exceptions.py: 100.00%

9 statements  

« prev     ^ index     » next       coverage.py v7.13.5, created at 2026-03-27 06:49 +0000

1# /////////////////////////////////////////////////////////////// 

2# COMPILER_EXCEPTIONS - Compiler operation exceptions 

3# Project: ezcompiler 

4# /////////////////////////////////////////////////////////////// 

5 

6""" 

7Compiler exceptions - Specialized exceptions for compiler operations. 

8 

9This module defines exceptions for various compiler-related failures 

10used by CompilerUtils and compiler implementations. 

11""" 

12 

13from __future__ import annotations 

14 

15# /////////////////////////////////////////////////////////////// 

16# IMPORTS 

17# /////////////////////////////////////////////////////////////// 

18from .base import EzCompilerError 

19 

20# /////////////////////////////////////////////////////////////// 

21# EXCEPTIONS 

22# /////////////////////////////////////////////////////////////// 

23 

24 

25class CompilerError(EzCompilerError): 

26 """Base exception for compiler operation errors.""" 

27 

28 

29class CompilerConfigValidationError(CompilerError): 

30 """Raised when compiler configuration validation fails.""" 

31 

32 

33class MainFileNotFoundError(CompilerError): 

34 """Raised when the main file for compilation is not found.""" 

35 

36 

37class OutputDirectoryError(CompilerError): 

38 """Raised when output directory creation or access fails.""" 

39 

40 

41class IncludeFilesFormatError(CompilerError): 

42 """Raised when include files formatting fails.""" 

43 

44 

45class CompilerNotAvailableError(CompilerError): 

46 """Raised when the compiler is not available on the system.""" 

47 

48 

49class CompilationExecutionError(CompilerError): 

50 """Raised when the actual compilation execution fails."""