kleinkram 0.34.3.dev20241029161032__tar.gz → 0.34.3.dev20241029200002__tar.gz
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 kleinkram might be problematic. Click here for more details.
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/PKG-INFO +1 -1
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/pyproject.toml +1 -1
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/requirements.txt +1 -1
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/mission/mission.py +13 -22
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/.gitignore +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/LICENSE +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/README.md +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/deploy.sh +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/dev.sh +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/klein.py +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/__init__.py +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/api_client.py +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/auth/auth.py +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/consts.py +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/endpoint/endpoint.py +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/error_handling.py +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/file/file.py +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/helper.py +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/main.py +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/project/project.py +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/queue/queue.py +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/tag/tag.py +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/topic/topic.py +0 -0
- {kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/user/user.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: kleinkram
|
|
3
|
-
Version: 0.34.3.
|
|
3
|
+
Version: 0.34.3.dev20241029200002
|
|
4
4
|
Summary: A CLI for the ETH project kleinkram
|
|
5
5
|
Project-URL: Homepage, https://github.com/leggedrobotics/kleinkram
|
|
6
6
|
Project-URL: Issues, https://github.com/leggedrobotics/kleinkram/issues
|
|
@@ -258,7 +258,7 @@ def upload(
|
|
|
258
258
|
List[str],
|
|
259
259
|
typer.Option(prompt=True, help="Path to files to upload, Regex supported"),
|
|
260
260
|
],
|
|
261
|
-
|
|
261
|
+
mission_uuid: Annotated[
|
|
262
262
|
str, typer.Option(prompt=True, help="UUID of Mission to create")
|
|
263
263
|
],
|
|
264
264
|
):
|
|
@@ -269,7 +269,7 @@ def upload(
|
|
|
269
269
|
Multiple paths can be given by using the option multiple times.\n
|
|
270
270
|
\n
|
|
271
271
|
Examples:\n
|
|
272
|
-
- 'klein upload --path "~/data/**/*.bag" --
|
|
272
|
+
- 'klein upload --path "~/data/**/*.bag" --mission-uuid "2518cfc2-07f2-41a5-b74c-fdedb1b97f88" '\n
|
|
273
273
|
|
|
274
274
|
"""
|
|
275
275
|
files = []
|
|
@@ -281,7 +281,7 @@ def upload(
|
|
|
281
281
|
if not filenames:
|
|
282
282
|
raise ValueError("No files found matching the given path.")
|
|
283
283
|
|
|
284
|
-
print(f"Uploading the following files to mission '{
|
|
284
|
+
print(f"Uploading the following files to mission '{mission_uuid}':")
|
|
285
285
|
filepaths = {}
|
|
286
286
|
for path in files:
|
|
287
287
|
if not os.path.isdir(path):
|
|
@@ -290,29 +290,20 @@ def upload(
|
|
|
290
290
|
|
|
291
291
|
try:
|
|
292
292
|
client = AuthenticatedClient()
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
293
|
+
get_temporary_credentials = "/file/temporaryAccess"
|
|
294
|
+
response = client.post(
|
|
295
|
+
get_temporary_credentials,
|
|
296
|
+
json={"filenames": filenames, "missionUUID": mission_uuid},
|
|
296
297
|
)
|
|
297
|
-
if
|
|
298
|
+
if response.status_code >= 400:
|
|
298
299
|
raise ValueError(
|
|
299
|
-
"Failed to
|
|
300
|
-
+ str(
|
|
301
|
-
+ "
|
|
302
|
-
+
|
|
300
|
+
"Failed to upload data. Status Code: "
|
|
301
|
+
+ str(response.status_code)
|
|
302
|
+
+ "\n"
|
|
303
|
+
+ response.json()["message"][0]
|
|
303
304
|
)
|
|
304
305
|
|
|
305
|
-
|
|
306
|
-
credential = temp_credentials["credentials"]
|
|
307
|
-
confirmed_files = temp_credentials["files"]
|
|
308
|
-
for _file in filenames:
|
|
309
|
-
if not _file in confirmed_files.keys():
|
|
310
|
-
raise Exception(
|
|
311
|
-
"Could not upload File '" + _file + "'. Is the filename unique? "
|
|
312
|
-
)
|
|
313
|
-
confirmed_files[_file]["filepath"] = filepaths[_file]
|
|
314
|
-
if len(confirmed_files.keys()) > 0:
|
|
315
|
-
uploadFiles(confirmed_files, credential, 4)
|
|
306
|
+
uploadFiles(response.json(), filepaths, 4)
|
|
316
307
|
except Exception as e:
|
|
317
308
|
print(e)
|
|
318
309
|
print("Failed to upload files")
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/auth/auth.py
RENAMED
|
File without changes
|
{kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/consts.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/file/file.py
RENAMED
|
File without changes
|
{kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/helper.py
RENAMED
|
File without changes
|
{kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/main.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/tag/tag.py
RENAMED
|
File without changes
|
|
File without changes
|
{kleinkram-0.34.3.dev20241029161032 → kleinkram-0.34.3.dev20241029200002}/src/kleinkram/user/user.py
RENAMED
|
File without changes
|