levistone 0.7.1__cp312-cp312-win_amd64.whl → 0.9.3__cp312-cp312-win_amd64.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.

Potentially problematic release.


This version of levistone might be problematic. Click here for more details.

endstone/__init__.py CHANGED
@@ -1,14 +1,28 @@
1
- from endstone._internal.endstone_python import ColorFormat, GameMode, Logger, OfflinePlayer, Player, Server, Skin
1
+ from endstone._internal.endstone_python import (
2
+ ColorFormat,
3
+ EnchantmentRegistry,
4
+ GameMode,
5
+ ItemRegistry,
6
+ Logger,
7
+ NamespacedKey,
8
+ OfflinePlayer,
9
+ Player,
10
+ Server,
11
+ Skin,
12
+ )
2
13
  from endstone._internal.version import __version__
3
14
 
4
- __minecraft_version__ = "1.21.70"
15
+ __minecraft_version__ = "1.21.93"
5
16
 
6
17
  __all__ = [
7
18
  "__version__",
8
19
  "__minecraft_version__",
9
20
  "ColorFormat",
21
+ "EnchantmentRegistry",
10
22
  "GameMode",
23
+ "ItemRegistry",
11
24
  "Logger",
25
+ "NamespacedKey",
12
26
  "OfflinePlayer",
13
27
  "Player",
14
28
  "Server",
@@ -1,4 +1,5 @@
1
1
  import errno
2
+ import fnmatch
2
3
  import hashlib
3
4
  import logging
4
5
  import os
@@ -110,12 +111,23 @@ class Bootstrap:
110
111
 
111
112
  self._logger.info(f"Integrity check passed. Extracting to {dst}...")
112
113
  dst.mkdir(parents=True, exist_ok=True)
114
+ override_patterns = [
115
+ self.executable_filename,
116
+ "behavior_packs/*",
117
+ "definitions/*",
118
+ "resource_packs/*",
119
+ "bedrock_server_how_to.html",
120
+ "profanity_filter.wlist",
121
+ "release-notes.txt",
122
+ ]
113
123
  with zipfile.ZipFile(f) as zip_ref:
114
124
  for file in zip_ref.namelist():
115
- if file in ["allowlist.json", "permissions.json", "server.properties"] and (dst / file).exists():
116
- self._logger.info(f"{file} already exists, skipping.")
117
- should_modify_server_properties = False
118
- continue
125
+ dest_path = dst / file
126
+ if dest_path.exists():
127
+ if not any(fnmatch.fnmatch(file, pattern) for pattern in override_patterns):
128
+ should_modify_server_properties = False
129
+ self._logger.info(f"{dest_path} already exists, skipping.")
130
+ continue
119
131
 
120
132
  zip_ref.extract(file, dst)
121
133