Marketplace refresh only keeps a stale local copy on failure when the remote is genuinely unreachable, not on every pull failure
When Claude Code refreshes a plugin marketplace, it now classifies the result of checking the remote as current, unreachable, or stale using a new helper. The CLAUDE_CODE_PLUGIN_KEEP_MARKETPLACE_ON_FAILURE environment variable, which keeps the existing local copy instead of failing, is now only consulted in the unreachable case, and only if the existing local clone still validates as a real marketplace. Previously it applied to any pull failure.
This narrows the keep-on-failure fallback to cases where the remote is actually unreachable, rather than masking other kinds of pull failures by silently keeping a possibly outdated local marketplace copy.