atomicshop 3.2.0__py3-none-any.whl → 3.2.1__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.

Potentially problematic release.


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

atomicshop/__init__.py CHANGED
@@ -1,4 +1,4 @@
1
1
  """Atomic Basic functions and classes to make developer life easier"""
2
2
 
3
3
  __author__ = "Den Kras"
4
- __version__ = '3.2.0'
4
+ __version__ = '3.2.1'
@@ -173,6 +173,16 @@ def load_config(config_toml_file_path: str):
173
173
  return result
174
174
 
175
175
 
176
+ # def get_listening_addresses() -> list[str]:
177
+ # """
178
+ # Get the list of listening addresses from the TCPServer configuration.
179
+ # If no_engines_usage_to_listen_addresses_enable is True, return the no_engines_listening_address_list.
180
+ # Otherwise, return an empty list.
181
+ # """
182
+ #
183
+ # return ENGINES_LIST
184
+
185
+
176
186
  # ============ Server Tester Specific ===============
177
187
  CONFIG_INI_TESTER_FILE_NAME: str = 'config_tester.ini'
178
188
 
@@ -159,6 +159,7 @@ def check_configurations() -> int:
159
159
 
160
160
  is_localhost: bool | None = None
161
161
  for engine in config_static.ENGINES_LIST:
162
+ port_list: list[str] = []
162
163
  for domain_port in engine.domain_list:
163
164
  # Check if the domains has port.
164
165
  if ':' not in domain_port:
@@ -170,6 +171,7 @@ def check_configurations() -> int:
170
171
  else:
171
172
  # Split the domain and port.
172
173
  domain, port = domain_port.split(':')
174
+ port_list.append(port)
173
175
  # Check if the port is a number.
174
176
  if not port.isdigit():
175
177
  message = (
@@ -178,6 +180,24 @@ def check_configurations() -> int:
178
180
  print_api(message, color="red")
179
181
  return 1
180
182
 
183
+ # Check if the ports in on_port_connect are unique.
184
+ if engine.on_port_connect:
185
+ ports_on_connect: list[str] = list(engine.on_port_connect.keys())
186
+ # Check if any of the ports in the on_port_connect are not in the domain list.
187
+ ports_in_domain_list: list[str] = []
188
+ for port in ports_on_connect:
189
+ if port in port_list:
190
+ ports_in_domain_list.append(port)
191
+
192
+ if ports_in_domain_list:
193
+ message = (
194
+ f"[*] Ports in [on_port_connect] config in engine_config.toml: {ports_in_domain_list}\n"
195
+ f"are also in the [domains] field.\n"
196
+ f"This is not supported.")
197
+ print_api(message, color="red")
198
+ return 1
199
+
200
+
181
201
  # Check if 'localhost' is set in all the engines, or not.
182
202
  # There can't be mixed engines where local host is set and not set.
183
203
  # It can be all engines will be localhost or none of them.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: atomicshop
3
- Version: 3.2.0
3
+ Version: 3.2.1
4
4
  Summary: Atomic functions and classes to make developer life easier
5
5
  Author: Denis Kras
6
6
  License: MIT License
@@ -1,4 +1,4 @@
1
- atomicshop/__init__.py,sha256=ia_QL-nkKuszLHN2XwNJas4i3cauADZSyyLAKJGWcD0,122
1
+ atomicshop/__init__.py,sha256=0QDVialFRk2pBIU7G-tJb5_vrVqmvG0Grp6n90s_aPg,122
2
2
  atomicshop/_basics_temp.py,sha256=6cu2dd6r2dLrd1BRNcVDKTHlsHs_26Gpw8QS6v32lQ0,3699
3
3
  atomicshop/_create_pdf_demo.py,sha256=Yi-PGZuMg0RKvQmLqVeLIZYadqEZwUm-4A9JxBl_vYA,3713
4
4
  atomicshop/_patch_import.py,sha256=ENp55sKVJ0e6-4lBvZnpz9PQCt3Otbur7F6aXDlyje4,6334
@@ -134,10 +134,10 @@ atomicshop/file_io/tomls.py,sha256=vZ_Wng5alLf8z6HSEZj7PS0XKDA-Iies9ihVWOkTcKo,1
134
134
  atomicshop/file_io/xlsxs.py,sha256=v_dyg9GD4LqgWi6wA1QuWRZ8zG4ZwB6Dz52ytdcmmmI,2184
135
135
  atomicshop/file_io/xmls.py,sha256=zh3SuK-dNaFq2NDNhx6ivcf4GYCfGM8M10PcEwDSpxk,2104
136
136
  atomicshop/mitm/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
137
- atomicshop/mitm/config_static.py,sha256=N3D06C_wUytwm80PQCL90ZGHLMHeQlCcI2XQQU2FZ1I,8145
137
+ atomicshop/mitm/config_static.py,sha256=6vAuksHxZhwejwqL0S66mcI95Fe43I5dsjLYA-wDZ-I,8474
138
138
  atomicshop/mitm/config_toml_editor.py,sha256=2p1CMcktWRR_NW-SmyDwylu63ad5e0-w1QPMa8ZLDBw,1635
139
139
  atomicshop/mitm/connection_thread_worker.py,sha256=E_DNvP4lbbcoeFziiG10Aa7bg7Ka09wdwV_uqaRm5rU,32554
140
- atomicshop/mitm/import_config.py,sha256=gCH1hV-CxBAdwjeFJu1I5ntbm5hqzcB0y0vzRPkzra0,16936
140
+ atomicshop/mitm/import_config.py,sha256=_RJPxoVEEsJQwQY-K_8qPw2PbzsDcV23_sEJEWSKqXY,17831
141
141
  atomicshop/mitm/initialize_engines.py,sha256=N4JVoC7PXN8GxUBXvNCXS-ZA5ag6rXqYXyZ3EyHOcLM,10318
142
142
  atomicshop/mitm/message.py,sha256=CDhhm4BTuZE7oNZCjvIZ4BuPOW4MuIzQLOg91hJaxDI,3065
143
143
  atomicshop/mitm/mitm_main.py,sha256=at9uxnXF_4b273HRXt9UGkERkHantRTOAvRtlYYI68E,30774
@@ -337,8 +337,8 @@ atomicshop/wrappers/socketw/statistics_csv.py,sha256=WcNyaqEZ82S5-f3kzqi1nllNT2N
337
337
  atomicshop/wrappers/winregw/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
338
338
  atomicshop/wrappers/winregw/winreg_installed_software.py,sha256=Qzmyktvob1qp6Tjk2DjLfAqr_yXV0sgWzdMW_9kwNjY,2345
339
339
  atomicshop/wrappers/winregw/winreg_network.py,sha256=ih0BVNwByLvf9F_Lac4EdmDYYJA3PzMvmG0PieDZrsE,9905
340
- atomicshop-3.2.0.dist-info/LICENSE.txt,sha256=lLU7EYycfYcK2NR_1gfnhnRC8b8ccOTElACYplgZN88,1094
341
- atomicshop-3.2.0.dist-info/METADATA,sha256=VKefd8URMpY8zVcDX7iiRnpIcssdPlobeUlqhIyA7HQ,10670
342
- atomicshop-3.2.0.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
343
- atomicshop-3.2.0.dist-info/top_level.txt,sha256=EgKJB-7xcrAPeqTRF2laD_Np2gNGYkJkd4OyXqpJphA,11
344
- atomicshop-3.2.0.dist-info/RECORD,,
340
+ atomicshop-3.2.1.dist-info/LICENSE.txt,sha256=lLU7EYycfYcK2NR_1gfnhnRC8b8ccOTElACYplgZN88,1094
341
+ atomicshop-3.2.1.dist-info/METADATA,sha256=qmcM6sJS_q1IivsuhbARaKxfuqkZ5eYfSxpRCfN_oQ0,10670
342
+ atomicshop-3.2.1.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
343
+ atomicshop-3.2.1.dist-info/top_level.txt,sha256=EgKJB-7xcrAPeqTRF2laD_Np2gNGYkJkd4OyXqpJphA,11
344
+ atomicshop-3.2.1.dist-info/RECORD,,