()
| 173 | // When the parent process refreshes the token (via token file or env var), |
| 174 | // the transport can pick it up on reconnection. |
| 175 | const refreshHeaders = (): Record<string, string> => { |
| 176 | const h: Record<string, string> = getSessionIngressAuthHeaders() |
| 177 | const freshErVersion = process.env.CLAUDE_CODE_ENVIRONMENT_RUNNER_VERSION |
| 178 | if (freshErVersion) { |
| 179 | h['x-environment-runner-version'] = freshErVersion |
| 180 | } |
| 181 | return h |
| 182 | } |
| 183 | |
| 184 | // Get appropriate transport based on URL protocol |
| 185 | this.transport = getTransportForUrl( |
no test coverage detected