Although changes to the variables are picked up when an app using that variable is restarted, if a variable is deleted, a restart of the computer is required.
I can reproduce this.
This happens on 10.10 and newer where a reimplementation of launchd breaks the unsetenv functionality. The corresponding API still exists in the reimplementation, and I assume attempts to emulate the legacy implementation; but evidently it is broken. Interestingly, launchctl unsetenv works because it isn't using the emulated legacy API but the new XPC-based API. To fix we need to reverse-engineer the new API—it is undocumented—and use it instead of relying on the emulation.
On 10.10 and newer use XPC-based API to launchd (fixes #11)
Fix: Can’t unset variables with legacy API (connected to #11)
Regression introduced in 3c4f0fc.