atomicshop 2.11.48__py3-none-any.whl → 2.11.49__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 +1 -1
- atomicshop/filesystem.py +8 -12
- {atomicshop-2.11.48.dist-info → atomicshop-2.11.49.dist-info}/METADATA +1 -1
- {atomicshop-2.11.48.dist-info → atomicshop-2.11.49.dist-info}/RECORD +7 -7
- {atomicshop-2.11.48.dist-info → atomicshop-2.11.49.dist-info}/LICENSE.txt +0 -0
- {atomicshop-2.11.48.dist-info → atomicshop-2.11.49.dist-info}/WHEEL +0 -0
- {atomicshop-2.11.48.dist-info → atomicshop-2.11.49.dist-info}/top_level.txt +0 -0
atomicshop/__init__.py
CHANGED
atomicshop/filesystem.py
CHANGED
|
@@ -1205,14 +1205,12 @@ def list_open_files_in_directory(directory):
|
|
|
1205
1205
|
return open_files
|
|
1206
1206
|
|
|
1207
1207
|
|
|
1208
|
-
def
|
|
1208
|
+
def is_any_file_in_directory_opened_by_process(directory_path: str) -> bool:
|
|
1209
1209
|
"""
|
|
1210
|
-
The function checks if any file in the directory is
|
|
1211
|
-
it will be locked for reading). Basically it opens a handle for read and write and if it fails, then the file is
|
|
1212
|
-
locked.
|
|
1210
|
+
The function checks if any file in the directory is opened in any process using psutil.
|
|
1213
1211
|
|
|
1214
1212
|
:param directory_path: string, full path to directory.
|
|
1215
|
-
:return: boolean, if 'True', then at least one file in the directory is
|
|
1213
|
+
:return: boolean, if 'True', then at least one file in the directory is opened by a process.
|
|
1216
1214
|
"""
|
|
1217
1215
|
|
|
1218
1216
|
# for filename in os.listdir(directory_path):
|
|
@@ -1236,25 +1234,23 @@ def is_any_file_in_directory_locked(directory_path: str) -> bool:
|
|
|
1236
1234
|
return False
|
|
1237
1235
|
|
|
1238
1236
|
|
|
1239
|
-
def
|
|
1237
|
+
def is_any_file_in_list_open_by_process(file_paths_list: list[str]) -> bool:
|
|
1240
1238
|
"""
|
|
1241
|
-
The function checks if any file in the list is
|
|
1242
|
-
for reading). Basically it opens a handle for read and write and if it fails, then the file is locked.
|
|
1239
|
+
The function checks if any file in the list is opened by any running process.
|
|
1243
1240
|
|
|
1244
1241
|
:param file_paths_list: list of strings, full paths to files.
|
|
1245
1242
|
:return: boolean, if 'True', then at least one file in the list is locked.
|
|
1246
1243
|
"""
|
|
1247
1244
|
|
|
1248
1245
|
for file_path in file_paths_list:
|
|
1249
|
-
if
|
|
1246
|
+
if is_file_open_by_process(file_path):
|
|
1250
1247
|
return True
|
|
1251
1248
|
return False
|
|
1252
1249
|
|
|
1253
1250
|
|
|
1254
|
-
def
|
|
1251
|
+
def is_file_open_by_process(file_path: str) -> bool:
|
|
1255
1252
|
"""
|
|
1256
|
-
The function checks if the file is
|
|
1257
|
-
Basically it opens a handle for read and write and if it fails, then the file is locked.
|
|
1253
|
+
The function checks if the file is opened in any of the running processes.
|
|
1258
1254
|
|
|
1259
1255
|
:param file_path: string, full path to file.
|
|
1260
1256
|
:return: boolean, if 'True', then the file is locked.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
atomicshop/__init__.py,sha256=
|
|
1
|
+
atomicshop/__init__.py,sha256=qgi85ZKKeYx9w0YfZF0iWyjf6YkZavOGGnHhYdTgoP4,124
|
|
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
|
|
@@ -14,7 +14,7 @@ atomicshop/dns.py,sha256=bNZOo5jVPzq7OT2qCPukXoK3zb1oOsyaelUwQEyK1SA,2500
|
|
|
14
14
|
atomicshop/domains.py,sha256=Rxu6JhhMqFZRcoFs69IoEd1PtYca0lMCG6F1AomP7z4,3197
|
|
15
15
|
atomicshop/emails.py,sha256=I0KyODQpIMEsNRi9YWSOL8EUPBiWyon3HRdIuSj3AEU,1410
|
|
16
16
|
atomicshop/file_types.py,sha256=-0jzQMRlmU1AP9DARjk-HJm1tVE22E6ngP2mRblyEjY,763
|
|
17
|
-
atomicshop/filesystem.py,sha256=
|
|
17
|
+
atomicshop/filesystem.py,sha256=M4x2jTPMOyvwxJD9hJzgJ6BgF2Z9SIDf2Ye4ImXvXtY,47268
|
|
18
18
|
atomicshop/functions.py,sha256=pK8hoCE9z61PtWCxQJsda7YAphrLH1wxU5x-1QJP-sY,499
|
|
19
19
|
atomicshop/hashing.py,sha256=Le8qGFyt3_wX-zGTeQShz7L2HL_b6nVv9PnawjglyHo,3474
|
|
20
20
|
atomicshop/http_parse.py,sha256=nrf2rZcprLqtW8HVrV7TCZ1iTBcWRRy-mXIlAOzcaJs,9703
|
|
@@ -244,8 +244,8 @@ atomicshop/wrappers/socketw/socket_server_tester.py,sha256=AhpurHJmP2kgzHaUbq5ey
|
|
|
244
244
|
atomicshop/wrappers/socketw/socket_wrapper.py,sha256=aXBwlEIJhFT0-c4i8iNlFx2It9VpCEpsv--5Oqcpxao,11624
|
|
245
245
|
atomicshop/wrappers/socketw/ssl_base.py,sha256=k4V3gwkbq10MvOH4btU4onLX2GNOsSfUAdcHmL1rpVE,2274
|
|
246
246
|
atomicshop/wrappers/socketw/statistics_csv.py,sha256=t3dtDEfN47CfYVi0CW6Kc2QHTEeZVyYhc57IYYh5nmA,826
|
|
247
|
-
atomicshop-2.11.
|
|
248
|
-
atomicshop-2.11.
|
|
249
|
-
atomicshop-2.11.
|
|
250
|
-
atomicshop-2.11.
|
|
251
|
-
atomicshop-2.11.
|
|
247
|
+
atomicshop-2.11.49.dist-info/LICENSE.txt,sha256=lLU7EYycfYcK2NR_1gfnhnRC8b8ccOTElACYplgZN88,1094
|
|
248
|
+
atomicshop-2.11.49.dist-info/METADATA,sha256=2Q8mFvwf5Wx4Hyhu2Ngv8Hr2U4hfvkBFGiNpaVdSkg4,10448
|
|
249
|
+
atomicshop-2.11.49.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
|
|
250
|
+
atomicshop-2.11.49.dist-info/top_level.txt,sha256=EgKJB-7xcrAPeqTRF2laD_Np2gNGYkJkd4OyXqpJphA,11
|
|
251
|
+
atomicshop-2.11.49.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|