Update app.py
Browse files
app.py
CHANGED
|
@@ -1,18 +1,3 @@
|
|
| 1 |
-
#!/usr/bin/env python3
|
| 2 |
-
"""
|
| 3 |
-
Telegram ↔ Hugging Face Dataset Storage Bot
|
| 4 |
-
-------------------------------------------
|
| 5 |
-
- AES‑SIV deterministic encryption for per‑user folders and filenames.
|
| 6 |
-
- Full support for all media types, albums, message links, instant uploads, CRUD.
|
| 7 |
-
- Real‑time progress updates for Telegram transfers (shows exact size, percentage, speed, ETA).
|
| 8 |
-
- Duplicate detection: checks both filename AND file size; prompts to skip or keep duplicate.
|
| 9 |
-
- Per‑file size limit (45 GB) enforced at upload time.
|
| 10 |
-
- Direct Hugging Face download links (removed from /files listing per request).
|
| 11 |
-
- Optimised download/upload: larger chunk size (1 MB) for Telegram downloads.
|
| 12 |
-
- Automatic disk space guard, keep‑alive pings, and system status reporting (/status).
|
| 13 |
-
- Built on Pyrogram + tgcrypto for maximum speed.
|
| 14 |
-
"""
|
| 15 |
-
|
| 16 |
import os, re, sys, time, base64, hashlib, shutil, logging, secrets, sqlite3, tempfile, threading, asyncio
|
| 17 |
from pathlib import Path
|
| 18 |
from typing import Optional, List, Tuple, Union
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
import os, re, sys, time, base64, hashlib, shutil, logging, secrets, sqlite3, tempfile, threading, asyncio
|
| 2 |
from pathlib import Path
|
| 3 |
from typing import Optional, List, Tuple, Union
|