From b1b625045af79689fab414261bb36e0f2db612c2 Mon Sep 17 00:00:00 2001 From: Abolfazl Date: Mon, 20 Apr 2026 23:15:49 +0330 Subject: [PATCH] Add PyPI mirror installation instructions and enhance troubleshooting section in README and README_FA --- README.md | 8 ++++++++ README_FA.md | 10 +++++++++- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 1e4327e..3e232a5 100644 --- a/README.md +++ b/README.md @@ -42,6 +42,11 @@ cd MasterHttpRelayVPN pip install -r requirements.txt ``` +> **Can't reach PyPI directly?** Use this mirror instead: +> ```bash +> pip install -r requirements.txt -i https://mirror-pypi.runflare.com/simple/ --trusted-host mirror-pypi.runflare.com +> ``` + Or download the ZIP from [GitHub](https://github.com/masterking32/MasterHttpRelayVPN/tree/python_testing) and extract it. ### Step 2: Set Up the Google Relay (Code.gs) @@ -255,9 +260,12 @@ python main.py -c /path/to/config.json # Use a different config file |---------|----------| | "Config not found" | Copy `config.example.json` to `config.json` and fill in your values | | Browser shows certificate errors | Install the CA certificate (see Step 6 above) | +| Telegram works but browser doesn't load sites | Almost certainly the CA certificate is not installed. Follow Step 6 to install `ca/ca.crt`, then **fully close and reopen your browser** (for Chrome/Edge, make sure no Chrome process is running in the background before reopening). | +| Installed the cert but browser still errors | Chrome and Edge cache certificates — you must **completely close** the browser (check Task Manager / system tray) and reopen it for the new cert to take effect. Firefox requires a separate import (see Step 6 Firefox section). | | "unauthorized" error | Make sure `auth_key` in `config.json` matches `AUTH_KEY` in `Code.gs` exactly | | Connection timeout | Try a different `google_ip` or check your internet connection | | Slow browsing | Deploy multiple `Code.gs` copies and use `script_ids` array for load balancing | +| `502 Bad JSON` error | Google returned an unexpected response (HTML instead of JSON). Causes: wrong `script_id`, Apps Script daily quota exhausted, or the deployment wasn't re-created after editing `Code.gs`. Check your `script_id` and create a **new deployment** if you recently changed `Code.gs`. | --- diff --git a/README_FA.md b/README_FA.md index 78419b1..8c3f9f7 100644 --- a/README_FA.md +++ b/README_FA.md @@ -36,6 +36,11 @@ cd MasterHttpRelayVPN pip install -r requirements.txt ``` +> **دسترسی به PyPI ندارید؟** از این mirror استفاده کنید: +> ```bash +> pip install -r requirements.txt -i https://mirror-pypi.runflare.com/simple/ --trusted-host mirror-pypi.runflare.com +> ``` + اگر نخواستید با Git کار کنید، می‌توانید فایل ZIP پروژه را از GitHub دانلود و extract کنید. ### مرحله 2: راه‌اندازی رله Google با `Code.gs` @@ -240,10 +245,13 @@ python main.py -c /path/to/config.json | مشکل | راه‌حل | |------|--------| | `Config not found` | فایل `config.example.json` را به `config.json` کپی کنید | -| خطای certificate در مرورگر | گواهی CA را نصب کنید | +| خطای certificate در مرورگر | گواهی CA را نصب کنید (مرحله ۶) | +| تلگرام کار می‌کند ولی مرورگر سایت‌ها را باز نمی‌کند | تقریباً مطمئناً گواهی CA نصب نشده. مرحله ۶ را دنبال کنید، سپس مرورگر را **کاملاً ببندید و دوباره باز کنید** (برای Chrome/Edge مطمئن شوید هیچ پروسه Chrome در پس‌زمینه باز نیست). | +| گواهی نصب شد ولی مرورگر هنوز خطا می‌دهد | Chrome و Edge گواهی‌ها را cache می‌کنند — باید مرورگر را **کاملاً ببندید** (Task Manager یا system tray را چک کنید) و دوباره باز کنید. Firefox نیاز به import جداگانه دارد (بخش Firefox در مرحله ۶). | | خطای `unauthorized` | مقدار `auth_key` و `AUTH_KEY` باید یکسان باشند | | timeout | IP دیگری برای Google امتحان کنید | | سرعت کم | از چند `script_id` برای load balancing استفاده کنید | +| خطای `502 Bad JSON` | Google به‌جای JSON پاسخ HTML برگردانده (مثلاً صفحه quota یا 404). دلایل: `script_id` اشتباه، تجاوز از سهمیه روزانه Apps Script، یا عدم ایجاد deployment جدید پس از ویرایش `Code.gs`. `script_id` را بررسی کنید و یک **deployment جدید** بسازید. | ---