abhinavsingh / proxy.py

💫 Ngrok FRP Alternative • ⚡ Fast • 🪶 Lightweight • 0️⃣ Dependency • 🔌 Pluggable • 😈 TLS interception • 🔒 DNS-over-HTTPS • 🔥 Poor Man's VPN • ⏪ Reverse & ⏩ Forward • 👮🏿 "Proxy Server" framework • 🌐 "Web Server" framework • ➵ ➶ ➷ ➠ "PubSub" framework • 👷 "Work" acceptor & executor framework
https://abhinavsingh.com/proxy-py-a-lightweight-single-file-http-proxy-server-in-python/
BSD 3-Clause "New" or "Revised" License
2.91k stars 568 forks source link

High memory usage over time when using pypy (~1MB per request) #1309

Open andywill222 opened 1 year ago

andywill222 commented 1 year ago

Hello everyone,

I'm running the Proxy.py with pypy3 and observing that for every proxy request made through the service, around 1MB of memory is being added to the overall usage and it continues to increase over time.

When running the script using the python3 interpreter, the memory usage remains stable.

btw, it happen even when running the proxy service like this without any plugins or logics within.

with proxy.Proxy(
    enable_web_server=False,
    port=8081,
) as _:
    proxy.sleep_loop()

Has anyone else encountered this issue before and have any suggestions for resolving it? thanks you.