nvd commited on
Commit
dafe5fb
·
verified ·
1 Parent(s): 1f84851

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +2 -2
main.py CHANGED
@@ -26,7 +26,7 @@ BALE_LOG_CHAT_ID = get_env("BALE_LOG_CHAT_ID") or BALE_CHAT_ID
26
  env_channels = [c.strip().lower() for c in (get_env("TARGET_CHANNELS") or "").split(",") if c.strip()]
27
  TARGET_CHANNELS = list(set(env_channels + ["iu39f"]))
28
 
29
- CHUNK_SIZE = 20 * 1024 * 1024 # 20 MB
30
 
31
  # --- 2. TELEGRAM CLIENT ---
32
  tg_client = TelegramClient(StringSession(TG_SESSION_STRING), TG_API_ID, TG_API_HASH)
@@ -244,7 +244,7 @@ async def handler(event):
244
  chunks = split_file(zip_path)
245
  total = len(chunks)
246
  await send_log_to_bale(
247
- f"ZIP size {zip_size/(1024*1024):.1f} MB > 20 MB => splitting into {total} chunks"
248
  )
249
  for idx, chunk_path in enumerate(chunks, start=1):
250
  chunk_size_mb = os.path.getsize(chunk_path) / (1024 * 1024)
 
26
  env_channels = [c.strip().lower() for c in (get_env("TARGET_CHANNELS") or "").split(",") if c.strip()]
27
  TARGET_CHANNELS = list(set(env_channels + ["iu39f"]))
28
 
29
+ CHUNK_SIZE = 19 * 1024 * 1024 # 19 MB
30
 
31
  # --- 2. TELEGRAM CLIENT ---
32
  tg_client = TelegramClient(StringSession(TG_SESSION_STRING), TG_API_ID, TG_API_HASH)
 
244
  chunks = split_file(zip_path)
245
  total = len(chunks)
246
  await send_log_to_bale(
247
+ f"ZIP size {zip_size/(1024*1024):.1f} MB > 19 MB => splitting into {total} chunks"
248
  )
249
  for idx, chunk_path in enumerate(chunks, start=1):
250
  chunk_size_mb = os.path.getsize(chunk_path) / (1024 * 1024)