
Security News
GitHub Actions Adds cache-mode to Limit Cache Poisoning Risk
GitHub Actions now supports cache-mode, a least-privilege control on the Actions cache aimed at the cache poisoning technique behind recent compromises.
@percy/cli-doctor
Advanced tools
> Percy CLI sub-command that diagnoses network, authentication, configuration, and CI readiness for running Percy builds.
Percy CLI sub-command that diagnoses network, authentication, configuration, and CI readiness for running Percy builds.
@percy/cli-doctor is bundled with @percy/cli. If you use the Percy CLI you already have it:
npx percy doctor
To install standalone:
npm install --save-dev @percy/cli-doctor
# or
yarn add --dev @percy/cli-doctor
percy doctor [options]
Options:
--proxy-server <url> Proxy server to test alongside direct connectivity
e.g. http://proxy.corp.example.com:8080
--url <url> URL to open in Chrome for network activity analysis
(default: https://percy.io)
--timeout <ms> Per-request timeout in milliseconds
(default: 10000, max: 300000)
--quick Run only connectivity, SSL, and token auth checks
(~4 seconds instead of a full diagnostic run)
--output-json <path> Write the full diagnostic report to a JSON file
-v, --verbose Show detailed debug output
-h, --help Show help
Detects and validates Percy configuration files (.percy.yml, .percy.yaml, percy.config.js, etc.) via cosmiconfig:
version field (recommends version 2)fullPage used with a web token)| Category | Meaning |
|---|---|
config_not_found | No Percy config file detected |
config_found | Config file located and loaded |
config_parse_error | Config file has YAML/JSON syntax errors |
config_version_invalid | version field is missing or non-numeric |
config_version_outdated | Config uses an outdated version (< 2) |
config_key_automate_only | Config contains Automate-only keys but token is not Automate |
config_key_web_only | Config contains Web-only keys but token is not a Web token |
Detects your CI provider and validates CI-related settings:
PERCY_PARALLEL_TOTAL + PERCY_PARALLEL_NONCE)| Category | Meaning |
|---|---|
ci_not_detected | Not running in a CI environment |
ci_detected | CI system identified |
ci_commit_missing | Commit SHA could not be detected |
ci_commit_found | Commit SHA available |
ci_branch_missing | Branch name could not be detected |
ci_parallel_nonce_missing | PERCY_PARALLEL_TOTAL set without PERCY_PARALLEL_NONCE |
ci_parallel_config_valid | Both parallel env vars are set correctly |
ci_git_available | Git repository detected |
ci_git_check_skipped | Git check suppressed via PERCY_SKIP_GIT_CHECK=true |
ci_git_unavailable | Git not installed or not in a git repository |
Inventories all Percy-specific environment variables:
PERCY_* vars (names only — values are never exposed)PERCY_PARALLEL_TOTAL is a positive integerPERCY_COMMIT, PERCY_BRANCH, PERCY_PULL_REQUEST)NODE_TLS_REJECT_UNAUTHORIZED=0 disables SSL validation| Category | Meaning |
|---|---|
env_system_info | OS, Node version, CPU, and RAM summary |
env_no_percy_vars | No PERCY_* environment variables detected |
env_vars_listed | Lists names of all set PERCY_* variables |
env_parallel_total_invalid | PERCY_PARALLEL_TOTAL is not a valid positive integer |
env_manual_overrides | Manual override vars active (e.g. PERCY_COMMIT, PERCY_BRANCH) |
env_tls_disabled | NODE_TLS_REJECT_UNAUTHORIZED=0 — SSL validation globally disabled |
Probes each required Percy / BrowserStack domain:
| Domain | Purpose |
|---|---|
https://percy.io | Percy API |
https://www.browserstack.com | BrowserStack API |
https://hub.browserstack.com | BrowserStack Automate |
Failure modes are classified as:
HTTPS_PROXY| Scenario | Outcome |
|---|---|
NODE_TLS_REJECT_UNAUTHORIZED=0 is set | Warning – SSL verification is disabled globally |
| SSL certificate error connecting to percy.io | Fail – likely a MITM proxy/VPN; suggests remediation |
| SSL handshake succeeds | Pass |
When a certificate error is detected, the command prints actionable suggestions
(contact network admin, add proxy cert to trust store, set NODE_EXTRA_CA_CERTS).
Detects proxy configuration from (in priority order):
HTTPS_PROXY, HTTP_PROXY, ALL_PROXY, NO_PROXYscutil --proxy, networksetup -getautoproxyurlgsettings org.gnome.system.proxy/etc/environmentHKCU\Software\Microsoft\Windows\CurrentVersion\Internet SettingsEach discovered proxy is validated by attempting connections to percy.io and browserstack.com through it.
Detects PAC file URLs from:
| Source | Detection method |
|---|---|
| macOS system | networksetup -getautoproxyurl <interface> |
| macOS plist | /Library/Preferences/SystemConfiguration/preferences.plist |
| Linux GNOME | gsettings org.gnome.system.proxy autoconfig-url |
| Windows | HKCU\…\Internet Settings\AutoConfigURL |
| Chrome / Chromium | Default/Preferences JSON (macOS, Linux, Windows) |
| Firefox | ~/.mozilla/firefox/*/prefs.js (network.proxy.autoconfig_url) |
The PAC script is fetched and evaluated in a sandboxed Node.js vm context
using shims for all standard PAC helper functions. The result of
FindProxyForURL("https://percy.io/", "percy.io") is reported.
If a PAC file routes percy.io through a proxy the command surfaces the exact
HTTPS_PROXY=… export statement to add to your CI environment.
Validates the PERCY_TOKEN environment variable:
web_, auto_, app_, ss_, vmw_, res_) and suggests the correct CLI commandpercy.io/api/v1/tokens to verify the token is valid (uses proxy if one was discovered in earlier checks)Token values are never included in output — only the project type and pass/fail status.
| Category | Meaning |
|---|---|
token_missing | PERCY_TOKEN is not set or is blank |
token_type_info | Token prefix decoded — project type and suggested CLI command |
token_auth_pass | Token authenticated successfully; role shown |
token_auth_fail | Token rejected (HTTP 401 or 403) |
token_auth_unexpected_status | Percy API returned an unexpected HTTP status |
token_auth_network_error | Could not reach Percy API to validate token |
check_skipped | Token validation skipped because percy.io is unreachable |
Launches headless Chrome to test end-to-end network connectivity through the browser process, including proxy and PAC resolution as Chrome would see it.
Use --quick to run only the essential checks (connectivity, SSL, and token auth) in ~4 seconds:
npx percy doctor --quick
This is useful for fast triage in CI pipelines or when you just want to verify your token and network are working.
Set PERCY_AUTO_DOCTOR=true to automatically run diagnostics when a Percy build fails:
export PERCY_AUTO_DOCTOR=true
npx percy exec -- your-test-command
When enabled, a build failure triggers a diagnostic run and prints actionable findings inline. This is opt-in and has no effect on successful builds.
Percy Doctor — diagnostic check
── Configuration
ℹ Configuration file detected: /project/.percy.yml
✔ Config version: 2 (current)
── CI Environment
ℹ CI system detected: GitHub Actions
✔ Git is available for commit detection.
── Environment Variables
ℹ Percy environment variables set: PERCY_TOKEN, PERCY_PARALLEL_TOTAL
── SSL / TLS
✔ SSL handshake with percy.io succeeded (47ms).
── Network Connectivity
✔ Percy API is reachable directly (HTTP 200, 51ms).
✔ BrowserStack API is reachable directly (HTTP 200, 72ms).
✔ BrowserStack Automate is reachable directly (HTTP 200, 89ms).
── Proxy Configuration
ℹ No proxy configuration detected in environment or system settings.
── PAC / Auto-Proxy Configuration
ℹ No PAC (Proxy Auto-Configuration) file detected.
── Token Authentication
ℹ Token detected (project type: web). Use `percy exec` to run snapshots.
✔ Token authentication successful.
── Browser Network
✔ Chrome loaded percy.io successfully.
✔ 8 passed · 0 warnings · 0 failures (4.2s)
MIT
FAQs
> Percy CLI sub-command that diagnoses network, authentication, configuration, and CI readiness for running Percy builds.
The npm package @percy/cli-doctor receives a total of 210,552 weekly downloads. As such, @percy/cli-doctor popularity was classified as popular.
We found that @percy/cli-doctor demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.

Security News
GitHub Actions now supports cache-mode, a least-privilege control on the Actions cache aimed at the cache poisoning technique behind recent compromises.

Company News
Allow myself to introduce... myself.

Research
/Security News
A Twitch browser extension on Chrome and Firefox forwards users’ live OAuth session tokens through proxies controlled by a Russian bot service.