wmill 1.339.2__py3-none-any.whl → 1.340.2__py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
wmill/client.py
CHANGED
@@ -440,7 +440,7 @@ class Windmill:
|
|
440
440
|
print(file_reader.read())
|
441
441
|
'''
|
442
442
|
"""
|
443
|
-
reader = S3BufferedReader(f"{self.workspace}", self.client, s3object["s3"], s3_resource_path)
|
443
|
+
reader = S3BufferedReader(f"{self.workspace}", self.client, s3object["s3"], s3_resource_path, s3object["storage"])
|
444
444
|
return reader
|
445
445
|
|
446
446
|
def write_s3_file(
|
@@ -479,6 +479,8 @@ class Windmill:
|
|
479
479
|
query_params["file_key"] = s3object["s3"]
|
480
480
|
if s3_resource_path is not None and s3_resource_path != "":
|
481
481
|
query_params["s3_resource_path"] = s3_resource_path
|
482
|
+
if s3object is not None and s3object["storage"] is not None:
|
483
|
+
query_params["storage"] = s3object["storage"]
|
482
484
|
|
483
485
|
try:
|
484
486
|
# need a vanilla client b/c content-type is not application/json here
|
wmill/s3_reader.py
CHANGED
@@ -5,12 +5,14 @@ import httpx
|
|
5
5
|
|
6
6
|
|
7
7
|
class S3BufferedReader(BufferedReader):
|
8
|
-
def __init__(self, workspace: str, windmill_client: httpx.Client, file_key: str, s3_resource_path: str | None):
|
8
|
+
def __init__(self, workspace: str, windmill_client: httpx.Client, file_key: str, s3_resource_path: str | None, storage: str | None):
|
9
9
|
params = {
|
10
10
|
"file_key": file_key,
|
11
11
|
}
|
12
12
|
if s3_resource_path is not None:
|
13
13
|
params["s3_resource_path"] = s3_resource_path
|
14
|
+
if storage is not None:
|
15
|
+
params["storage"] = storage
|
14
16
|
self._context_manager = windmill_client.stream(
|
15
17
|
"GET",
|
16
18
|
f"/w/{workspace}/job_helpers/download_s3_file",
|
wmill/s3_types.py
CHANGED
@@ -0,0 +1,8 @@
|
|
1
|
+
wmill/__init__.py,sha256=nGZnQPezTdrBnBW1D0JqUtm75Gdf_xi3tAcPGwHRZ5A,46
|
2
|
+
wmill/client.py,sha256=Do4iqhleEqvhT0ZThWVC4hiF8aTNeDBX0I3a_ACU3UA,32281
|
3
|
+
wmill/py.typed,sha256=8PjyZ1aVoQpRVvt71muvuq5qE-jTFZkK-GLHkhdebmc,26
|
4
|
+
wmill/s3_reader.py,sha256=izHlg2Xsg0Sr_LkDDEC35VuEijJcuPBDIm-xj21KsgU,1668
|
5
|
+
wmill/s3_types.py,sha256=XVjPyc5sjWesTy6nnRReojhyPgPsaT0EY3X57mWUaJ4,1173
|
6
|
+
wmill-1.340.2.dist-info/METADATA,sha256=hhEXUXJ0bV1W4wU1DNNfdt6v84Lic-tJIctcQRyvvFI,2699
|
7
|
+
wmill-1.340.2.dist-info/WHEEL,sha256=d2fvjOD7sXsVzChCqf0Ty0JbHKBaLYwDbGQDwQTnJ50,88
|
8
|
+
wmill-1.340.2.dist-info/RECORD,,
|
wmill-1.339.2.dist-info/RECORD
DELETED
@@ -1,8 +0,0 @@
|
|
1
|
-
wmill/__init__.py,sha256=nGZnQPezTdrBnBW1D0JqUtm75Gdf_xi3tAcPGwHRZ5A,46
|
2
|
-
wmill/client.py,sha256=bCr9svlONt82xuS-pL1JezvLvFVfeHuTPJoNEaLNRS4,32133
|
3
|
-
wmill/py.typed,sha256=8PjyZ1aVoQpRVvt71muvuq5qE-jTFZkK-GLHkhdebmc,26
|
4
|
-
wmill/s3_reader.py,sha256=ZznXPIdMkP7S17CJ5scBJAyLDHBKAaqZB-B_l9pRIzA,1575
|
5
|
-
wmill/s3_types.py,sha256=axVibTMtpynBwaCVK0O6bBao56no01qflyIGRaVyV6s,1149
|
6
|
-
wmill-1.339.2.dist-info/METADATA,sha256=ezLdzviG0vv90vglkS8Seyxsew9D2hXv3-m3rK2pN4I,2699
|
7
|
-
wmill-1.339.2.dist-info/WHEEL,sha256=d2fvjOD7sXsVzChCqf0Ty0JbHKBaLYwDbGQDwQTnJ50,88
|
8
|
-
wmill-1.339.2.dist-info/RECORD,,
|
File without changes
|