<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>Debugging on 魔都水滴</title>
		<link>https://blog.margrop.net/tag/debugging/</link>
		<description>Recent content in Debugging on 魔都水滴</description>
		<generator>Hugo</generator>
		<language>zh-CN</language>
		
		
		
		
			<lastBuildDate>Sat, 30 May 2026 16:00:00 +0800</lastBuildDate>
		
			<atom:link href="https://blog.margrop.net/tag/debugging/index.xml" rel="self" type="application/rss+xml" />
			<item>
				<title>诡异！Tmux 新 session 里凭空多出一个 http_proxy 环境变量</title>
				<link>https://blog.margrop.net/post/tmux-zsh-http-proxy-mystery/</link>
				<pubDate>Sat, 30 May 2026 16:00:00 +0800</pubDate>
				<guid>https://blog.margrop.net/post/tmux-zsh-http-proxy-mystery/</guid>
				<description>&lt;h1 id=&#34;前言&#34;&gt;前言&lt;/h1&gt;&#xA;&lt;p&gt;今天遇到一个非常诡异的问题：新创建的 tmux session 里，&lt;code&gt;echo $http_proxy&lt;/code&gt; 竟然显示了一个有效的代理地址。但我明明记得自己在 &lt;code&gt;.zshrc&lt;/code&gt; 里只定义了两个 alias：&lt;code&gt;proxy_on&lt;/code&gt; 和 &lt;code&gt;proxy_off&lt;/code&gt;，它们都是手动触发的，不会自动执行。&lt;/p&gt;&#xA;&lt;p&gt;诡异的是，我的主 shell 里 &lt;code&gt;http_proxy&lt;/code&gt;明明是空的，但一进 tmux 就有了。这个问题排查了将近一个小时才找到根因，特此记录。&lt;/p&gt;</description>
			</item>
			<item>
				<title>macOS LaunchAgent 里的 Python 程序连不上外网？一文搞懂 httpx 代理陷阱的完整排查与修复</title>
				<link>https://blog.margrop.net/post/macos-launchagent-python-httpx-proxy-no-route-to-host/</link>
				<pubDate>Sat, 30 May 2026 09:00:00 +0800</pubDate>
				<guid>https://blog.margrop.net/post/macos-launchagent-python-httpx-proxy-no-route-to-host/</guid>
				<description>&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;先说结论：&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;p&gt;macOS 的 LaunchAgent 环境下，Python httpx 库会自动读取系统代理设置（&lt;code&gt;scutil --proxy&lt;/code&gt;），但 LaunchAgent 进程可能根本无法访问该代理服务器——于是请求静默失败，报错 &lt;code&gt;All connection attempts failed&lt;/code&gt; 或 &lt;code&gt;No route to host&lt;/code&gt;。&lt;/p&gt;&#xA;&lt;p&gt;解决方案只需要一行：在 LaunchAgent 的 plist 文件中添加 &lt;code&gt;NO_PROXY=*&lt;/code&gt;。&lt;/p&gt;&#xA;&lt;p&gt;这篇文章记录了我从发现 AI Agent 企业微信消息不回复、到逐步排查代理问题、最终定位到 macOS 系统代理与 LaunchAgent 网络隔离的完整过程。涉及 Python httpx 源码分析、macOS 代理机制深度解析、以及 LaunchAgent 运行环境的诸多坑点。&lt;/p&gt;&#xA;&lt;/blockquote&gt;</description>
			</item>
	</channel>
</rss>
