minecraft-datapack-language 15.4.8__py3-none-any.whl → 15.4.9__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -28,7 +28,7 @@ version_tuple: VERSION_TUPLE
28
28
  commit_id: COMMIT_ID
29
29
  __commit_id__: COMMIT_ID
30
30
 
31
- __version__ = version = '15.4.8'
32
- __version_tuple__ = version_tuple = (15, 4, 8)
31
+ __version__ = version = '15.4.9'
32
+ __version_tuple__ = version_tuple = (15, 4, 9)
33
33
 
34
34
  __commit_id__ = commit_id = None
@@ -13,7 +13,7 @@ from .mdl_parser_js import parse_mdl_js
13
13
  from .expression_processor import ExpressionProcessor
14
14
  from .dir_map import get_dir_map
15
15
  from .pack import Pack, Namespace, Function, Tag, Recipe, Advancement, LootTable, Predicate, ItemModifier, Structure
16
- from .mdl_errors import MDLErrorCollector, create_error, MDLFileError, MDLSyntaxError, MDLParserError, MDLLexerError
16
+ from .mdl_errors import MDLErrorCollector, create_error, MDLBuildError, MDLFileError, MDLCompilationError, MDLSyntaxError, MDLParserError, MDLLexerError
17
17
  from .cli_utils import ensure_dir, write_json, _process_variable_substitutions, _convert_condition_to_minecraft_syntax, _find_mdl_files, _validate_selector, _resolve_selector, _extract_base_variable_name, _slugify
18
18
  from .cli_colors import (
19
19
  print_success, print_warning, print_error, print_info,
@@ -70,7 +70,7 @@ def _merge_mdl_files(files: List[Path], verbose: bool = False, error_collector:
70
70
  except Exception as e:
71
71
  if error_collector:
72
72
  error_collector.add_error(create_error(
73
- MDLSyntaxError,
73
+ MDLCompilationError,
74
74
  f"Failed to parse {files[0]}: {str(e)}",
75
75
  file_path=str(files[0]),
76
76
  suggestion="Check the file syntax and ensure it's a valid MDL file."
@@ -142,12 +142,12 @@ def _merge_mdl_files(files: List[Path], verbose: bool = False, error_collector:
142
142
  return None
143
143
  except Exception as e:
144
144
  if error_collector:
145
- error_collector.add_error(create_error(
146
- MDLSyntaxError,
147
- f"Failed to parse {file_path}: {str(e)}",
148
- file_path=str(file_path),
149
- suggestion="Check the file syntax and ensure it's a valid MDL file."
150
- ))
145
+ error_collector.add_error(create_error(
146
+ MDLCompilationError,
147
+ f"Failed to parse {file_path}: {str(e)}",
148
+ file_path=str(file_path),
149
+ suggestion="Check the file syntax and ensure it's a valid MDL file."
150
+ ))
151
151
  else:
152
152
  raise
153
153
  return None
@@ -1058,7 +1058,7 @@ def build_mdl(input_path: str, output_path: str, verbose: bool = False, pack_for
1058
1058
  error_collector.add_error(e)
1059
1059
  error_collector.print_errors(verbose=True, ignore_warnings=ignore_warnings)
1060
1060
  error_collector.raise_if_errors()
1061
- except MDLFileError as e:
1061
+ except MDLBuildError as e:
1062
1062
  error_collector.add_error(e)
1063
1063
  error_collector.print_errors(verbose=True, ignore_warnings=ignore_warnings)
1064
1064
  error_collector.raise_if_errors()
@@ -1066,13 +1066,13 @@ def build_mdl(input_path: str, output_path: str, verbose: bool = False, pack_for
1066
1066
  error_collector.add_error(e)
1067
1067
  error_collector.print_errors(verbose=True, ignore_warnings=ignore_warnings)
1068
1068
  error_collector.raise_if_errors()
1069
- except MDLSyntaxError as e:
1069
+ except MDLCompilationError as e:
1070
1070
  error_collector.add_error(e)
1071
1071
  error_collector.print_errors(verbose=True, ignore_warnings=ignore_warnings)
1072
1072
  error_collector.raise_if_errors()
1073
1073
  except Exception as e:
1074
1074
  error_collector.add_error(create_error(
1075
- MDLFileError,
1075
+ MDLBuildError,
1076
1076
  f"Unexpected error during build: {str(e)}",
1077
1077
  suggestion="Check the input files and try again. If the problem persists, report this as a bug."
1078
1078
  ))