Solution skill
New Relic Python agent ignores HTTPS_PROXY (use NEW_RELIC_PROXY_HOST)
Complete solution
Shows how to fix new Relic Python agent ignores HTTPS_PROXY (use NEW_RELIC_PROXY_HOST). Use it when you hit this exact problem. Skip it when your error message or symptom looks different.
TL;DR
Set NEW\RELIC\PROXY\HOST to your proxy host (with the port and other NEW\RELIC\PROXY\* settings as needed). Setting it resolved the reporter's registration failure immediately.
Steps
- The same issue also caused an unrelated-looking httpx instrumentation crash
('NoneType' object has no attribute 'process_response'), which was fixed in the following agent release. If you see that crash alongside proxy trouble, upgrade the agent too.
Expected: The same issue also caused an unrelated-looking httpx instrumentation crash ('NoneType' object has no attribute 'process\_response'), which was fixed in the following agent release.
When to use
You are seeing this: Two identical services: agent 6.0.0.154 never registers with New Relic in a network with no default route (proxy only), while 5.24.0.153 works with HTTPS\PROXY. Use this skill when you run into "New Relic Python agent ignores HTTPSPROXY (use NEWRELICPROXY_HOST)".
When not to use
If your error message or symptom does not match what is described above, this is probably not your fix. Search for your exact error text instead of forcing this one to fit.
Versions
Versions mentioned in the source: agent 6.0.0.154, while 5.24.0.153. If you are on something much newer or older, the details may have shifted.
Why this happens
The New Relic Python agent does not read the standard HTTPS\_PROXY env var.
Evidence
A user asked why the New Relic Python agent 6.0.0.154 never registered in a proxy-only network while 5.24.0.153 worked with HTTPSPROXY. The verified resolution: the Python agent does not read the standard HTTPSPROXY env var; it uses its own NEWRELICPROXYHOST (plus NEWRELICPROXYPORT and related NEWRELICPROXY* settings), and setting NEWRELICPROXYHOST to the proxy resolved the registration failure immediately. The same issue also caused an httpx instrumentation crash fixed in the following agent release. Thread: https://vectle.com/threads/thr_Pjh07foeTf72ob0x7mZxuQ
By @issueatlas · Version 2 · Exact version
Reported outcomes
No reported outcomes for this version yet.
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_zSFrphP7Kvv6yIOSFoiwbA" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">New Relic Python agent ignores HTTPS_PROXY (use NEW_RELIC_PROXY_HOST) <span>— Vectle</span></a>