react-doctor 0.5.8-dev.7a673d2 → 0.5.8-dev.9f28454

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE CHANGED
@@ -1,4 +1,4 @@
1
- MIT License
1
+ MIT License (with Additional Restrictions)
2
2
 
3
3
  Copyright (c) 2026 Million Software, Inc.
4
4
 
@@ -12,6 +12,13 @@ furnished to do so, subject to the following conditions:
12
12
  The above copyright notice and this permission notice shall be included in all
13
13
  copies or substantial portions of the Software.
14
14
 
15
+ The Software, its source code, and any derivative works thereof may not be
16
+ used, in whole or in part, as training data, fine-tuning data, evaluation
17
+ data, or as input to any automated pipeline for the purpose of training or
18
+ improving any machine learning model or AI system, without prior written
19
+ permission from the copyright holder. To request permission, contact
20
+ founders@million.dev.
21
+
15
22
  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
23
  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
24
  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
package/dist/cli.js CHANGED
@@ -1,5 +1,5 @@
1
1
 
2
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="0b6893a8-f482-50d5-ad21-45ebd17e98a0")}catch(e){}}();
2
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="34e4ad65-2650-5e3e-afd8-191931eb2a47")}catch(e){}}();
3
3
  import { createRequire } from "node:module";
4
4
  import * as NodeChildProcess from "node:child_process";
5
5
  import { execFile, execFileSync, spawn, spawnSync } from "node:child_process";
@@ -44702,7 +44702,25 @@ const CI_PROVIDER_BY_ENVIRONMENT_VARIABLE = [
44702
44702
  ["TEAMCITY_VERSION", "teamcity"],
44703
44703
  ["BITBUCKET_BUILD_NUMBER", "bitbucket"],
44704
44704
  ["TRAVIS", "travis"],
44705
- ["DRONE", "drone"]
44705
+ ["DRONE", "drone"],
44706
+ ["SEMAPHORE", "semaphore"],
44707
+ ["APPVEYOR", "appveyor"],
44708
+ ["HARNESS_BUILD_ID", "harness"],
44709
+ ["BUDDY", "buddy"],
44710
+ ["CF_BUILD_ID", "codefresh"],
44711
+ ["NETLIFY", "netlify"],
44712
+ ["RAILWAY_SERVICE_ID", "railway"],
44713
+ ["VERCEL", "vercel"],
44714
+ ["CM_BUILD_ID", "codemagic"],
44715
+ ["PROW_JOB_ID", "prow"],
44716
+ ["AGOLA_GIT_REF", "agola"],
44717
+ ["CIRRUS_CI", "cirrus-ci"],
44718
+ ["BLACKSMITH_STICKYDISK_TOKEN", "blacksmith"],
44719
+ ["WARPBUILD_RUNNER_VERIFICATION_TOKEN", "warpbuild"],
44720
+ ["NSC_CACHE_PATH", "namespace"],
44721
+ ["UBICLOUD_CACHE_URL", "ubicloud"],
44722
+ ["RENDER", "render"],
44723
+ ["FLY_APP_NAME", "fly-io"]
44706
44724
  ];
44707
44725
  const GITHUB_ACTION_MARKER_ENVIRONMENT_VARIABLE = "REACT_DOCTOR_GITHUB_ACTION";
44708
44726
  const ACTION_INPUT_ENVIRONMENT_VARIABLES = {
@@ -44720,7 +44738,10 @@ const CODING_AGENT_BY_ENVIRONMENT_VARIABLE = [
44720
44738
  ["CODEX_SANDBOX_NETWORK_DISABLED", "codex"],
44721
44739
  ["OPENCODE", "opencode"],
44722
44740
  ["GOOSE_TERMINAL", "goose"],
44723
- ["AMP_THREAD_ID", "amp"]
44741
+ ["AMP_THREAD_ID", "amp"],
44742
+ ["CLINE_ACTIVE", "cline"],
44743
+ ["AUGMENT_AGENT", "augment"],
44744
+ ["TRAE_AI_SHELL_ID", "trae-ai"]
44724
44745
  ];
44725
44746
  const GENERIC_CODING_AGENT_ENVIRONMENT_VARIABLES = ["AGENT_SESSION_ID", "AGENT_THREAD_ID"];
44726
44747
  const CODING_AGENT_ENVIRONMENT_VALUE_VARIABLES = ["AGENT"];
@@ -44911,7 +44932,7 @@ const makeNoopConsole = () => ({
44911
44932
  });
44912
44933
  //#endregion
44913
44934
  //#region src/cli/utils/version.ts
44914
- const VERSION = "0.5.8-dev.7a673d2";
44935
+ const VERSION = "0.5.8-dev.9f28454";
44915
44936
  //#endregion
44916
44937
  //#region src/cli/utils/json-mode.ts
44917
44938
  let context = null;
@@ -45275,13 +45296,13 @@ const isDevVersion = (version) => version === "0.0.0" || version.includes("-");
45275
45296
  * uploads source-map artifacts under, so stack frames symbolicate. Honors the
45276
45297
  * standard `SENTRY_RELEASE` override.
45277
45298
  */
45278
- const resolveSentryRelease = () => process.env.SENTRY_RELEASE || `react-doctor@0.5.8-dev.7a673d2`;
45299
+ const resolveSentryRelease = () => process.env.SENTRY_RELEASE || `react-doctor@0.5.8-dev.9f28454`;
45279
45300
  /**
45280
45301
  * Deployment environment shown in Sentry's environment filter. Defaults to
45281
45302
  * `production` for tagged releases and `development` for dev/unbuilt versions,
45282
45303
  * overridable via the standard `SENTRY_ENVIRONMENT` env var.
45283
45304
  */
45284
- const resolveSentryEnvironment = () => process.env.SENTRY_ENVIRONMENT || (isDevVersion("0.5.8-dev.7a673d2") ? "development" : "production");
45305
+ const resolveSentryEnvironment = () => process.env.SENTRY_ENVIRONMENT || (isDevVersion("0.5.8-dev.9f28454") ? "development" : "production");
45285
45306
  /**
45286
45307
  * Performance-tracing sample rate in `[0, 1]`. Reads `SENTRY_TRACES_SAMPLE_RATE`
45287
45308
  * (set to `0` to disable tracing) and falls back to
@@ -53980,6 +54001,69 @@ const warnDeprecatedFailOn = (flags, userConfig) => {
53980
54001
  cliLogger.warn(`${source} is deprecated; rename it to ${replacement}.`);
53981
54002
  };
53982
54003
  //#endregion
54004
+ //#region src/cli/utils/detect-ai-training-environment.ts
54005
+ const AI_TRAINING_ENV_VARS = [
54006
+ ["HF_DATASETS_CACHE", "huggingface"],
54007
+ ["HF_HOME", "huggingface"],
54008
+ ["HUGGINGFACE_HUB_CACHE", "huggingface"],
54009
+ ["CUDA_VISIBLE_DEVICES", "cuda"],
54010
+ ["NVIDIA_VISIBLE_DEVICES", "nvidia"],
54011
+ ["WANDB_RUN_ID", "wandb"],
54012
+ ["MLFLOW_RUN_ID", "mlflow"],
54013
+ ["MLFLOW_TRACKING_URI", "mlflow"],
54014
+ ["COMET_EXPERIMENT_KEY", "comet"],
54015
+ ["NEPTUNE_RUN_ID", "neptune"],
54016
+ ["RAY_WORKER_PROCESS", "ray"],
54017
+ ["RAY_ADDRESS", "ray"],
54018
+ ["MUJOCO_GL", "mujoco"],
54019
+ ["MUJOCO_PATH", "mujoco"],
54020
+ ["GYM_DISABLE_ENV_CHECKER", "gymnasium"],
54021
+ ["SAGEMAKER_BASE_DIR", "sagemaker"],
54022
+ ["AZURE_ML_MODEL_DIR", "azure-ml"],
54023
+ ["VERTEX_AI_LOG_LEVEL", "vertex-ai"],
54024
+ ["DAYTONA_WS_ID", "daytona"],
54025
+ ["DAYTONA_WS_NAME", "daytona"],
54026
+ ["E2B_SANDBOX_ID", "e2b"],
54027
+ ["MODAL_FUNCTION_ID", "modal"],
54028
+ ["MODAL_TASK_ID", "modal"],
54029
+ ["RUNPOD_POD_ID", "runpod"],
54030
+ ["HARBOR_URL", "harbor"],
54031
+ ["HARBOR_HOSTNAME", "harbor"],
54032
+ ["SWE_BENCH_TASK", "swe-bench"],
54033
+ ["SWEBENCH_TASK", "swe-bench"],
54034
+ ["SWE_AGENT_MODEL", "swe-agent"],
54035
+ ["KAGGLE_KERNEL_RUN_TYPE", "kaggle"],
54036
+ ["COLAB_BACKEND_VERSION", "google-colab"],
54037
+ ["DATABRICKS_RUNTIME_VERSION", "databricks"],
54038
+ ["SM_TRAINING_ENV", "sagemaker"],
54039
+ ["TRAINING_JOB_ARN", "sagemaker"],
54040
+ ["AZUREML_RUN_ID", "azure-ml"],
54041
+ ["CLOUD_ML_PROJECT_ID", "vertex-ai"],
54042
+ ["WANDB_SWEEP_ID", "wandb"],
54043
+ ["DVC_STAGE", "dvc"],
54044
+ ["CLEARML_TASK_ID", "clearml"],
54045
+ ["FLYTE_INTERNAL_EXECUTION_ID", "flyte"],
54046
+ ["DET_MASTER", "determined-ai"],
54047
+ ["LIGHTNING_USER_ID", "lightning-ai"],
54048
+ ["ARGO_WORKFLOW_NAME", "argo-workflows"],
54049
+ ["KFP_POD_NAME", "kubeflow-pipelines"],
54050
+ ["SPACE_ID", "huggingface-spaces"],
54051
+ ["REPLICATE_USERNAME", "replicate"],
54052
+ ["VAST_CONTAINERLABEL", "vast-ai"],
54053
+ ["TPU_NAME", "google-tpu"],
54054
+ ["ROCR_VISIBLE_DEVICES", "rocm"]
54055
+ ];
54056
+ const detectAiTrainingEnvironment = () => {
54057
+ for (const [envVar, label] of AI_TRAINING_ENV_VARS) if (process.env[envVar] !== void 0) return label;
54058
+ return null;
54059
+ };
54060
+ //#endregion
54061
+ //#region src/cli/utils/warn-ai-training-environment.ts
54062
+ const warnIfAiTrainingEnvironment = () => {
54063
+ if (detectAiTrainingEnvironment() === null) return;
54064
+ cliLogger.warn("react-doctor detected use in an AI or ML pipeline. This use requires written permission under the react-doctor license — contact founders@million.dev to request access.");
54065
+ };
54066
+ //#endregion
53983
54067
  //#region src/cli/utils/validate-mode-flags.ts
53984
54068
  const usedDiffAlias = (flags) => flags.diff !== void 0 && flags.diff !== false && flags.diff !== "false" && flags.diff !== "";
53985
54069
  const usedScope = (flags) => typeof flags.scope === "string" && flags.scope.length > 0;
@@ -54080,6 +54164,7 @@ const inspectAction = async (directory, flags) => {
54080
54164
  setJsonReportDirectory(resolvedDirectory);
54081
54165
  warnDeprecatedFailOn(flags, userConfig);
54082
54166
  warnDeprecatedDiff(flags, userConfig);
54167
+ warnIfAiTrainingEnvironment();
54083
54168
  if (scanTarget.didRedirectViaRootDir && !isQuiet) {
54084
54169
  cliLogger.dim(`Redirected to ${highlighter.info(toRelativePath(resolvedDirectory, requestedDirectory))} via react-doctor config "rootDir".`);
54085
54170
  cliLogger.break();
@@ -55374,4 +55459,4 @@ Promise.resolve().then(() => assertNoRemovedFlags(process.argv)).then(() => prog
55374
55459
  export {};
55375
55460
 
55376
55461
  //# sourceMappingURL=cli.js.map
55377
- //# debugId=0b6893a8-f482-50d5-ad21-45ebd17e98a0
55462
+ //# debugId=34e4ad65-2650-5e3e-afd8-191931eb2a47
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
 
2
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="33508ee6-c977-5b5f-8585-9939928ce74d")}catch(e){}}();
2
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="1ef7f287-5a83-55e9-a20b-41145ffdda43")}catch(e){}}();
3
3
  import { r as __toESM$1, t as __commonJSMin$1 } from "./chunk-N93fKeF6.js";
4
4
  import { createRequire } from "node:module";
5
5
  import * as NFS from "node:fs";
@@ -41342,6 +41342,64 @@ const mergeReactDoctorConfigs = (baseConfig, overrideConfig) => {
41342
41342
  };
41343
41343
  //#endregion
41344
41344
  //#region ../api/dist/index.js
41345
+ const AI_TRAINING_ENV_VARS = [
41346
+ "HF_DATASETS_CACHE",
41347
+ "HF_HOME",
41348
+ "HUGGINGFACE_HUB_CACHE",
41349
+ "CUDA_VISIBLE_DEVICES",
41350
+ "NVIDIA_VISIBLE_DEVICES",
41351
+ "WANDB_RUN_ID",
41352
+ "WANDB_SWEEP_ID",
41353
+ "MLFLOW_RUN_ID",
41354
+ "MLFLOW_TRACKING_URI",
41355
+ "COMET_EXPERIMENT_KEY",
41356
+ "NEPTUNE_RUN_ID",
41357
+ "CLEARML_TASK_ID",
41358
+ "RAY_WORKER_PROCESS",
41359
+ "RAY_ADDRESS",
41360
+ "MUJOCO_GL",
41361
+ "MUJOCO_PATH",
41362
+ "GYM_DISABLE_ENV_CHECKER",
41363
+ "SM_TRAINING_ENV",
41364
+ "TRAINING_JOB_ARN",
41365
+ "SAGEMAKER_BASE_DIR",
41366
+ "AZUREML_RUN_ID",
41367
+ "AZURE_ML_MODEL_DIR",
41368
+ "CLOUD_ML_PROJECT_ID",
41369
+ "VERTEX_AI_LOG_LEVEL",
41370
+ "KAGGLE_KERNEL_RUN_TYPE",
41371
+ "COLAB_BACKEND_VERSION",
41372
+ "DATABRICKS_RUNTIME_VERSION",
41373
+ "FLYTE_INTERNAL_EXECUTION_ID",
41374
+ "DET_MASTER",
41375
+ "LIGHTNING_USER_ID",
41376
+ "ARGO_WORKFLOW_NAME",
41377
+ "KFP_POD_NAME",
41378
+ "DVC_STAGE",
41379
+ "DAYTONA_WS_ID",
41380
+ "DAYTONA_WS_NAME",
41381
+ "E2B_SANDBOX_ID",
41382
+ "MODAL_FUNCTION_ID",
41383
+ "MODAL_TASK_ID",
41384
+ "RUNPOD_POD_ID",
41385
+ "SPACE_ID",
41386
+ "REPLICATE_USERNAME",
41387
+ "VAST_CONTAINERLABEL",
41388
+ "TPU_NAME",
41389
+ "ROCR_VISIBLE_DEVICES",
41390
+ "HARBOR_URL",
41391
+ "HARBOR_HOSTNAME",
41392
+ "SWE_BENCH_TASK",
41393
+ "SWEBENCH_TASK",
41394
+ "SWE_AGENT_MODEL"
41395
+ ];
41396
+ let didWarnAiTraining = false;
41397
+ const warnIfAiTrainingEnvironment = () => {
41398
+ if (didWarnAiTraining) return;
41399
+ if (AI_TRAINING_ENV_VARS.find((envVar) => process.env[envVar] !== void 0) === void 0) return;
41400
+ didWarnAiTraining = true;
41401
+ console.warn("[react-doctor] Use in an AI or ML pipeline requires written permission under the react-doctor license. Contact founders@million.dev to request access.");
41402
+ };
41345
41403
  const buildDiagnoseLayer = (config, configOverrideTarget) => {
41346
41404
  const configLayer = configOverrideTarget === void 0 ? Config.layerNode : Config.layerOf({
41347
41405
  config,
@@ -41379,6 +41437,7 @@ const outputToDiagnoseResult = (output, elapsedMilliseconds) => {
41379
41437
  };
41380
41438
  };
41381
41439
  const diagnoseDirectory = async (directory, options) => {
41440
+ warnIfAiTrainingEnvironment();
41382
41441
  const startTime = globalThis.performance.now();
41383
41442
  const scanTarget = await resolveScanTarget(directory);
41384
41443
  return outputToDiagnoseResult(await runPromise(restoreLegacyThrow(buildInspectProgram(scanTarget, options).pipe(provide(buildDiagnoseLayer(scanTarget.userConfig)), provide(layerOtlp)))), globalThis.performance.now() - startTime);
@@ -41425,6 +41484,7 @@ const diagnoseProject = async (projectDefinition, baseOptions, batchConfig) => {
41425
41484
  }
41426
41485
  };
41427
41486
  const diagnoseProjectBatch = async (input) => {
41487
+ warnIfAiTrainingEnvironment();
41428
41488
  const startTime = globalThis.performance.now();
41429
41489
  const { projects, concurrency, config: batchConfig, ...baseOptions } = input;
41430
41490
  const projectResults = await mapWithConcurrency(projects, concurrency ?? 4, (projectDefinition) => diagnoseProject(projectDefinition, baseOptions, batchConfig));
@@ -41469,4 +41529,4 @@ const toJsonReport = (result, options) => buildJsonReport({
41469
41529
  export { AmbiguousProjectError, NoReactDependencyError, NotADirectoryError, PackageJsonNotFoundError, ProjectNotFoundError, ReactDoctorError, buildJsonReport, buildJsonReportError, clearCaches, defineConfig, diagnose, filterSourceFiles, getDiffInfo, isProjectDiscoveryError, isReactDoctorError, summarizeDiagnostics, toJsonReport };
41470
41530
 
41471
41531
  //# sourceMappingURL=index.js.map
41472
- //# debugId=33508ee6-c977-5b5f-8585-9939928ce74d
41532
+ //# debugId=1ef7f287-5a83-55e9-a20b-41145ffdda43
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-doctor",
3
- "version": "0.5.8-dev.7a673d2",
3
+ "version": "0.5.8-dev.9f28454",
4
4
  "description": "Your agent writes bad React. This catches it",
5
5
  "keywords": [
6
6
  "accessibility",
@@ -20,7 +20,7 @@
20
20
  "bugs": {
21
21
  "url": "https://github.com/millionco/react-doctor/issues"
22
22
  },
23
- "license": "MIT",
23
+ "license": "SEE LICENSE IN LICENSE",
24
24
  "author": "Million Software, Inc",
25
25
  "repository": {
26
26
  "type": "git",
@@ -63,8 +63,8 @@
63
63
  "vscode-languageserver": "^9.0.1",
64
64
  "vscode-languageserver-textdocument": "^1.0.12",
65
65
  "vscode-uri": "^3.1.0",
66
- "deslop-js": "0.5.8",
67
- "oxlint-plugin-react-doctor": "0.5.8-dev.7a673d2"
66
+ "oxlint-plugin-react-doctor": "0.5.8-dev.9f28454",
67
+ "deslop-js": "0.5.8"
68
68
  },
69
69
  "devDependencies": {
70
70
  "@types/babel__code-frame": "^7.27.0",
@@ -72,8 +72,8 @@
72
72
  "@xterm/headless": "^6.0.0",
73
73
  "commander": "^14.0.3",
74
74
  "ora": "^9.4.0",
75
- "@react-doctor/core": "0.5.8",
76
75
  "@react-doctor/api": "0.5.8",
76
+ "@react-doctor/core": "0.5.8",
77
77
  "@react-doctor/language-server": "0.5.8"
78
78
  },
79
79
  "engines": {