tempspace-cli 1.2.4__tar.gz → 1.2.5__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.
- {tempspace_cli-1.2.4 → tempspace_cli-1.2.5}/PKG-INFO +2 -2
- {tempspace_cli-1.2.4 → tempspace_cli-1.2.5}/README.md +1 -1
- {tempspace_cli-1.2.4 → tempspace_cli-1.2.5}/cli/tempspace.py +1 -1
- {tempspace_cli-1.2.4 → tempspace_cli-1.2.5}/pyproject.toml +1 -1
- {tempspace_cli-1.2.4 → tempspace_cli-1.2.5}/tempspace_cli.egg-info/PKG-INFO +2 -2
- {tempspace_cli-1.2.4 → tempspace_cli-1.2.5}/tests/test_main.py +15 -0
- {tempspace_cli-1.2.4 → tempspace_cli-1.2.5}/cli/__init__.py +0 -0
- {tempspace_cli-1.2.4 → tempspace_cli-1.2.5}/setup.cfg +0 -0
- {tempspace_cli-1.2.4 → tempspace_cli-1.2.5}/tempspace_cli.egg-info/SOURCES.txt +0 -0
- {tempspace_cli-1.2.4 → tempspace_cli-1.2.5}/tempspace_cli.egg-info/dependency_links.txt +0 -0
- {tempspace_cli-1.2.4 → tempspace_cli-1.2.5}/tempspace_cli.egg-info/entry_points.txt +0 -0
- {tempspace_cli-1.2.4 → tempspace_cli-1.2.5}/tempspace_cli.egg-info/requires.txt +0 -0
- {tempspace_cli-1.2.4 → tempspace_cli-1.2.5}/tempspace_cli.egg-info/top_level.txt +0 -0
- {tempspace_cli-1.2.4 → tempspace_cli-1.2.5}/tests/test_cli.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: tempspace-cli
|
|
3
|
-
Version: 1.2.
|
|
3
|
+
Version: 1.2.5
|
|
4
4
|
Summary: A command-line tool for uploading files to Tempspace.
|
|
5
5
|
Author-email: Tempspace <mcbplay1@gmail.com>
|
|
6
6
|
License: MIT License
|
|
@@ -17,7 +17,7 @@ Requires-Dist: qrcode==8.2
|
|
|
17
17
|
|
|
18
18
|
Tempspace is a self-hostable, terminal-themed file sharing service. It allows you to quickly upload files and share them via a link, with features like password protection, one-time downloads, and automatic expiration.
|
|
19
19
|
|
|
20
|
-
|
|
20
|
+
|
|
21
21
|
|
|
22
22
|
## ✨ Core Features
|
|
23
23
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Tempspace is a self-hostable, terminal-themed file sharing service. It allows you to quickly upload files and share them via a link, with features like password protection, one-time downloads, and automatic expiration.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
|
|
6
6
|
|
|
7
7
|
## ✨ Core Features
|
|
8
8
|
|
|
@@ -17,7 +17,7 @@ from rich.console import Group
|
|
|
17
17
|
from rich.live import Live
|
|
18
18
|
|
|
19
19
|
# Default configuration
|
|
20
|
-
DEFAULT_SERVER_URL = "https://tempspace.
|
|
20
|
+
DEFAULT_SERVER_URL = "https://tempspace.needrp.net"
|
|
21
21
|
CHUNK_SIZE = 1024 * 1024 # 1MB
|
|
22
22
|
|
|
23
23
|
def parse_time(time_str: str) -> int:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: tempspace-cli
|
|
3
|
-
Version: 1.2.
|
|
3
|
+
Version: 1.2.5
|
|
4
4
|
Summary: A command-line tool for uploading files to Tempspace.
|
|
5
5
|
Author-email: Tempspace <mcbplay1@gmail.com>
|
|
6
6
|
License: MIT License
|
|
@@ -17,7 +17,7 @@ Requires-Dist: qrcode==8.2
|
|
|
17
17
|
|
|
18
18
|
Tempspace is a self-hostable, terminal-themed file sharing service. It allows you to quickly upload files and share them via a link, with features like password protection, one-time downloads, and automatic expiration.
|
|
19
19
|
|
|
20
|
-
|
|
20
|
+
|
|
21
21
|
|
|
22
22
|
## ✨ Core Features
|
|
23
23
|
|
|
@@ -48,6 +48,21 @@ def test_upload_file():
|
|
|
48
48
|
assert "url" in data
|
|
49
49
|
assert "file_id" in data
|
|
50
50
|
|
|
51
|
+
def test_upload_file_with_spaces_in_name():
|
|
52
|
+
"""Test that filenames with spaces are correctly URL-encoded."""
|
|
53
|
+
response = client.post(
|
|
54
|
+
"/upload",
|
|
55
|
+
files={"file": ("test file with spaces.txt", b"hello spaces", "text/plain")},
|
|
56
|
+
data={"hours": "1"},
|
|
57
|
+
)
|
|
58
|
+
assert response.status_code == 200
|
|
59
|
+
data = response.json()
|
|
60
|
+
assert data["success"] is True
|
|
61
|
+
# The returned filename field should be the original, raw filename
|
|
62
|
+
assert data["filename"] == "test file with spaces.txt"
|
|
63
|
+
# The URL should contain the URL-encoded version of the filename
|
|
64
|
+
assert "test%20file%20with%20spaces.txt" in data["url"]
|
|
65
|
+
|
|
51
66
|
def test_upload_with_password():
|
|
52
67
|
"""Test file upload with a password."""
|
|
53
68
|
response = client.post(
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|