Skip to content

chore(eslint): enable JSDoc parameter and type checks - #9566

Merged
BridgeAR merged 8 commits into
masterfrom
BridgeAR/2026-07-28-jsdoc-types
Aug 4, 2026
Merged

chore(eslint): enable JSDoc parameter and type checks#9566
BridgeAR merged 8 commits into
masterfrom
BridgeAR/2026-07-28-jsdoc-types

Conversation

@BridgeAR

@BridgeAR BridgeAR commented Jul 28, 2026

Copy link
Copy Markdown
Member

Summary

Complete missing JSDoc parameter declarations and replace unresolved type names across instrumentation, Test Optimization, tracer, integration, and helper code. Enable jsdoc/require-param and jsdoc/no-undefined-types.

Why

The rules were disabled behind a backlog of violations. Resolving it turns these contracts into a lint gate instead of allowing further drift.

@dd-octo-sts

dd-octo-sts Bot commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

Overall package size

Self size: 7.8 MB
Deduped: 8.46 MB
No deduping: 8.46 MB

Dependency sizes | name | version | self size | total size | |------|---------|-----------|------------| | import-in-the-middle | 3.3.3 | 125.43 kB | 441.68 kB | | opentracing | 0.14.7 | 194.81 kB | 194.81 kB | | dc-polyfill | 0.1.11 | 25.74 kB | 25.74 kB |

🤖 This report was automatically generated by heaviest-objects-in-the-universe

@datadog-official

datadog-official Bot commented Jul 28, 2026

Copy link
Copy Markdown

Tests

🎉 All green!

🧪 All tests passed
❄️ No new flaky tests detected

🎯 Code Coverage (details)
Patch Coverage: 100.00%
Overall Coverage: 98.51% (+0.00%)

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 2c234e4 | Docs | Datadog PR Page | Give us feedback!

@pr-commenter

pr-commenter Bot commented Jul 28, 2026

Copy link
Copy Markdown

Benchmarks

Benchmark execution time: 2026-08-04 12:57:13

Comparing candidate commit 2c234e4 in PR branch BridgeAR/2026-07-28-jsdoc-types with baseline commit 69c5166 in branch master.

📊 Benchmarking dashboard

Found 0 performance improvements and 0 performance regressions! Performance is the same for 2315 metrics, 43 unstable metrics.

Explanation

This is an A/B test comparing a candidate commit's performance against that of a baseline commit. Performance changes are noted in the tables below as:

  • 🟩 = significantly better candidate vs. baseline
  • 🟥 = significantly worse candidate vs. baseline

We compute a confidence interval (CI) over the relative difference of means between metrics from the candidate and baseline commits, considering the baseline as the reference.

If the CI is entirely outside the configured SIGNIFICANT_IMPACT_THRESHOLD (or the deprecated UNCONFIDENCE_THRESHOLD), the change is considered significant.

Feel free to reach out to #apm-benchmarking-platform on Slack if you have any questions.

More details about the CI and significant changes

You can imagine this CI as a range of values that is likely to contain the true difference of means between the candidate and baseline commits.

CIs of the difference of means are often centered around 0%, because often changes are not that big:

---------------------------------(------|---^--------)-------------------------------->
                              -0.6%    0%  0.3%     +1.2%
                                 |          |        |
         lower bound of the CI --'          |        |
sample mean (center of the CI) -------------'        |
         upper bound of the CI ----------------------'

As described above, a change is considered significant if the CI is entirely outside the configured SIGNIFICANT_IMPACT_THRESHOLD (or the deprecated UNCONFIDENCE_THRESHOLD).

For instance, for an execution time metric, this confidence interval indicates a significantly worse performance:

----------------------------------------|---------|---(---------^---------)---------->
                                       0%        1%  1.3%      2.2%      3.1%
                                                  |   |         |         |
       significant impact threshold --------------'   |         |         |
                      lower bound of CI --------------'         |         |
       sample mean (center of the CI) --------------------------'         |
                      upper bound of CI ----------------------------------'

Unstable benchmarks

These benchmarks have a confidence interval too wide to call a change; treat them as noise rather than signal.

scenario:appsec-appsec-enabled-24

  • unstable execution_time [-204.192ms; +201.740ms] or [-7.632%; +7.541%]

scenario:appsec-appsec-enabled-26

  • unstable execution_time [-242.953ms; +238.539ms] or [-9.507%; +9.335%]

scenario:appsec-appsec-enabled-with-attacks-24

  • unstable execution_time [-165.131ms; +162.294ms] or [-5.340%; +5.248%]

scenario:appsec-appsec-enabled-with-attacks-26

  • unstable execution_time [-185.883ms; +194.531ms] or [-6.406%; +6.704%]

scenario:appsec-control-20

  • unstable execution_time [-115.581ms; +131.662ms] or [-7.009%; +7.984%]

scenario:appsec-control-24

  • unstable execution_time [-111472.896µs; +111376.430µs] or [-8.964%; +8.956%]

scenario:appsec-control-26

  • unstable execution_time [-130.416ms; +117.843ms] or [-10.562%; +9.544%]

scenario:appsec-iast-no-vulnerability-control-20

  • unstable execution_time [-7.523ms; +22.625ms] or [-2.918%; +8.776%]

scenario:appsec-iast-no-vulnerability-iast-enabled-default-config-20

  • unstable execution_time [-19.569ms; +10.330ms] or [-7.575%; +3.999%]

scenario:appsec-iast-with-vulnerability-iast-enabled-always-active-20

  • unstable execution_time [-29496.157µs; +29937.623µs] or [-5.279%; +5.358%]

scenario:debugger-line-probe-with-snapshot-default-24

  • unstable cpu_user_time [-2063.872ms; +3258.121ms] or [-24.821%; +39.183%]
  • unstable execution_time [-2240.898ms; +3481.643ms] or [-24.783%; +38.506%]
  • unstable instructions [-17.1G instructions; +27.3G instructions] or [-25.353%; +40.437%]
  • unstable max_rss_usage [-8.376MB; +13.229MB] or [-5.330%; +8.418%]
  • unstable throughput [-889.667op/s; +582.706op/s] or [-24.324%; +15.931%]

scenario:debugger-line-probe-with-snapshot-minimal-24

  • unstable cpu_user_time [-2.748s; +0.379s] or [-30.957%; +4.269%]
  • unstable execution_time [-2.777s; +0.364s] or [-28.858%; +3.787%]
  • unstable instructions [-23.4G instructions; +3.2G instructions] or [-32.277%; +4.343%]
  • unstable throughput [-98.129op/s; +736.450op/s] or [-2.808%; +21.076%]

scenario:debugger-line-probe-without-snapshot-24

  • unstable cpu_user_time [-1774.067ms; +568.099ms] or [-21.398%; +6.852%]
  • unstable execution_time [-1801.450ms; +560.920ms] or [-20.034%; +6.238%]
  • unstable instructions [-15.1G instructions; +4.8G instructions] or [-22.295%; +7.171%]
  • unstable throughput [-147.856op/s; +484.356op/s] or [-4.034%; +13.216%]

scenario:debugger-line-probe-without-snapshot-26

  • unstable cpu_user_time [-2.723s; +5.859s] or [-26.428%; +56.869%]
  • unstable execution_time [-2.844s; +6.019s] or [-25.769%; +54.535%]
  • unstable instructions [-24.1G instructions; +51.8G instructions] or [-27.920%; +59.976%]
  • unstable max_rss_usage [-10.593MB; +19.419MB] or [-6.581%; +12.064%]
  • unstable throughput [-1169.013op/s; +561.249op/s] or [-37.812%; +18.154%]

scenario:dogstatsd-with-tags-20

  • unstable cpu_user_time [-287.820ms; +364.697ms] or [-6.051%; +7.667%]
  • unstable execution_time [-281.925ms; +365.519ms] or [-5.835%; +7.566%]
  • unstable throughput [-131906.118op/s; +97364.790op/s] or [-7.591%; +5.604%]

scenario:plugin-claude-agent-sdk-compact-stream-scan-26

  • unstable cpu_usage_percentage [-6.317%; +4.305%]

scenario:plugin-graphql-long-with-depth-off-26

  • unstable max_rss_usage [-11.362MB; +42.323MB] or [-5.567%; +20.737%]

scenario:plugin-graphql-long-with-depth-on-max-20

  • unstable cpu_user_time [-587.257ms; +605.144ms] or [-5.090%; +5.245%]
  • unstable execution_time [-601.463ms; +617.856ms] or [-5.108%; +5.248%]
  • unstable throughput [-3.601op/s; +3.526op/s] or [-5.270%; +5.160%]

scenario:plugin-memcached-get-24

  • unstable execution_time [-97.320ms; +153.349ms] or [-4.048%; +6.379%]

scenario:plugin-memcached-hashring-24

  • unstable cpu_user_time [-92.717ms; +167.921ms] or [-3.568%; +6.462%]
  • unstable execution_time [-95.306ms; +168.365ms] or [-3.656%; +6.459%]

scenario:plugin-pg-service-26

  • unstable cpu_usage_percentage [-6.994%; +4.428%]
  • unstable execution_time [-63.380ms; +81.877ms] or [-6.981%; +9.019%]
  • unstable throughput [-469036.758op/s; +373147.784op/s] or [-6.992%; +5.563%]

scenario:test-optimization-large-suite-20

  • unstable max_rss_usage [-5256.558KB; +7216.225KB] or [-6.472%; +8.884%]

@codecov

codecov Bot commented Jul 28, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.51%. Comparing base (69c5166) to head (2c234e4).
⚠️ Report is 3 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff            @@
##           master    #9566    +/-   ##
========================================
  Coverage   98.51%   98.51%            
========================================
  Files         957      957            
  Lines      134553   134811   +258     
  Branches    11689    11754    +65     
========================================
+ Hits       132551   132809   +258     
  Misses       2002     2002            
Flag Coverage Δ
aiguard 57.00% <96.42%> (+0.03%) ⬆️
aiguard-integration 55.83% <97.59%> (+0.06%) ⬆️
apm-bucket-0 57.26% <96.22%> (+0.02%) ⬆️
apm-bucket-1 63.36% <96.77%> (+0.02%) ⬆️
apm-bucket-2 62.15% <96.22%> (+0.02%) ⬆️
apm-bucket-3 59.67% <96.22%> (+0.02%) ⬆️
apm-capabilities-tracing 62.64% <99.50%> (+0.07%) ⬆️
apm-integrations-aerospike 56.30% <96.22%> (+0.02%) ⬆️
apm-integrations-confluentinc-kafka-javascript 61.00% <96.36%> (-0.01%) ⬇️
apm-integrations-couchbase 56.72% <96.22%> (+0.02%) ⬆️
apm-integrations-http 62.03% <96.77%> (+0.02%) ⬆️
apm-integrations-kafkajs 61.62% <96.36%> (+0.02%) ⬆️
apm-integrations-next 58.74% <98.11%> (+0.02%) ⬆️
apm-integrations-prisma 58.32% <96.61%> (+0.02%) ⬆️
appsec 72.10% <96.22%> (+<0.01%) ⬆️
appsec-express_fastify_graphql 69.49% <97.01%> (+0.01%) ⬆️
appsec-integration 50.27% <99.11%> (+0.12%) ⬆️
appsec-kafka_ldapjs_lodash 63.38% <96.36%> (+0.01%) ⬆️
appsec-mongodb-core_mongoose_mysql 66.99% <96.77%> (+0.01%) ⬆️
appsec-next 56.59% <98.21%> (+0.02%) ⬆️
appsec-node-serialize_passport_postgres 66.63% <96.87%> (+0.01%) ⬆️
appsec-sourcing_stripe_template 64.99% <98.38%> (+0.02%) ⬆️
debugger 64.26% <96.42%> (+0.01%) ⬆️
instrumentations-bucket-0 51.55% <96.22%> (+0.03%) ⬆️
instrumentations-bucket-1 59.62% <96.77%> (+0.03%) ⬆️
instrumentations-bucket-10 61.42% <96.87%> (+0.02%) ⬆️
instrumentations-bucket-11 51.46% <96.22%> (+0.03%) ⬆️
instrumentations-bucket-12 52.26% <96.77%> (+0.04%) ⬆️
instrumentations-bucket-13 51.57% <96.22%> (+0.03%) ⬆️
instrumentations-bucket-2 53.38% <96.77%> (+0.04%) ⬆️
instrumentations-bucket-3 58.67% <96.77%> (+0.03%) ⬆️
instrumentations-bucket-4 52.10% <96.42%> (+0.03%) ⬆️
instrumentations-bucket-5 57.22% <98.52%> (+0.03%) ⬆️
instrumentations-bucket-6 60.27% <96.22%> (+0.02%) ⬆️
instrumentations-bucket-7 58.03% <96.42%> (+0.03%) ⬆️
instrumentations-bucket-8 59.01% <96.77%> (+0.03%) ⬆️
instrumentations-bucket-9 60.96% <97.36%> (+0.04%) ⬆️
instrumentations-instrumentation-couchbase 50.81% <96.22%> (+0.03%) ⬆️
instrumentations-integration-esbuild 34.01% <99.06%> (+0.21%) ⬆️
llmobs-ai_anthropic_bedrock 62.48% <96.55%> (+0.02%) ⬆️
llmobs-bucket-1 61.36% <98.76%> (+0.09%) ⬆️
llmobs-openai 61.84% <97.53%> (+0.04%) ⬆️
llmobs-openai-agents_vertex-ai 59.80% <97.53%> (+0.05%) ⬆️
llmobs-sdk 66.18% <96.55%> (+0.02%) ⬆️
master-coverage 98.51% <100.00%> (?)
openfeature 55.61% <96.77%> (+0.06%) ⬆️
openfeature-unit 53.13% <96.22%> (+0.03%) ⬆️
platform-core_esbuild_instrumentations-misc 40.57% <99.11%> (+0.15%) ⬆️
platform-integration 60.52% <97.14%> (+0.05%) ⬆️
platform-shimmer_unit-guardrails_webpack 38.81% <99.55%> (+0.16%) ⬆️
plugins-bucket-0 56.82% <96.22%> (+0.02%) ⬆️
plugins-bucket-1 53.90% <96.61%> (+0.04%) ⬆️
plugins-bucket-11 61.85% <96.72%> (+0.02%) ⬆️
plugins-bucket-18 61.42% <96.77%> (+0.02%) ⬆️
plugins-bucket-19 59.59% <96.22%> (+0.02%) ⬆️
plugins-bucket-20 61.61% <96.55%> (+0.02%) ⬆️
plugins-bucket-4 58.17% <96.42%> (+0.02%) ⬆️
plugins-bullmq_cassandra_cookie 61.29% <96.22%> (+0.02%) ⬆️
plugins-cookie-parser_crypto_dd-trace-api 56.35% <96.22%> (+0.02%) ⬆️
plugins-fetch_fs_generic-pool 58.22% <96.77%> (+0.03%) ⬆️
plugins-google-cloud-pubsub_grpc_handlebars 64.13% <96.49%> (+0.02%) ⬆️
plugins-hapi_hono_ioredis 59.77% <98.11%> (+0.02%) ⬆️
plugins-jest_knex_langgraph 55.34% <96.36%> (+0.03%) ⬆️
plugins-ldapjs_light-my-request_limitd-client 58.10% <96.22%> (+0.02%) ⬆️
plugins-lodash_mariadb_memcached 57.68% <96.22%> (+0.02%) ⬆️
plugins-moleculer_mongodb_mongodb-core 61.40% <96.22%> (+0.02%) ⬆️
plugins-mongoose_multer_mysql 58.68% <96.22%> (+0.02%) ⬆️
plugins-mysql2_nats_node-serialize 60.23% <96.22%> (+0.02%) ⬆️
plugins-opensearch_passport-http_pino 59.12% <96.22%> (+0.02%) ⬆️
plugins-postgres_process_pug 58.27% <96.36%> (+0.02%) ⬆️
plugins-redis_router_sequelize 61.46% <96.77%> (+0.02%) ⬆️
plugins-test-and-upstream-rhea_undici_url 61.01% <96.77%> (+0.02%) ⬆️
plugins-valkey_vm_winston 57.63% <96.22%> (+0.02%) ⬆️
plugins-ws 59.15% <96.55%> (+0.02%) ⬆️
profiling 61.48% <96.87%> (+0.02%) ⬆️
serverless-aws-sdk-aws-sdk 54.93% <96.61%> (+0.02%) ⬆️
serverless-aws-sdk-base-inject-field 50.75% <96.22%> (+0.03%) ⬆️
serverless-aws-sdk-bedrockruntime 54.51% <96.22%> (+0.02%) ⬆️
serverless-aws-sdk-client 56.14% <96.22%> (+0.02%) ⬆️
serverless-aws-sdk-dynamodb 55.38% <96.22%> (+0.01%) ⬆️
serverless-aws-sdk-eventbridge 49.37% <97.05%> (+0.04%) ⬆️
serverless-aws-sdk-kinesis 58.94% <96.22%> (+0.02%) ⬆️
serverless-aws-sdk-lambda 57.08% <96.22%> (+0.02%) ⬆️
serverless-aws-sdk-s3 55.48% <96.22%> (+0.02%) ⬆️
serverless-aws-sdk-serverless-peer-service 59.34% <96.22%> (+0.02%) ⬆️
serverless-aws-sdk-sns 59.77% <96.22%> (+0.02%) ⬆️
serverless-aws-sdk-sqs 60.20% <96.22%> (+0.02%) ⬆️
serverless-aws-sdk-stepfunctions 55.31% <96.22%> (+0.02%) ⬆️
serverless-aws-sdk-util 51.30% <96.22%> (+0.03%) ⬆️
serverless-bucket-0 53.98% <96.22%> (+0.05%) ⬆️
serverless-bucket-1 58.85% <96.22%> (+0.02%) ⬆️
test-optimization-cucumber 71.46% <98.01%> (+0.01%) ⬆️
test-optimization-cypress 65.36% <98.11%> (+0.14%) ⬆️
test-optimization-jest 73.08% <99.05%> (+0.05%) ⬆️
test-optimization-mocha 72.65% <98.01%> (+0.08%) ⬆️
test-optimization-playwright-playwright-atr 60.18% <99.24%> (+0.08%) ⬆️
test-optimization-playwright-playwright-efd 60.33% <99.24%> (+0.08%) ⬆️
test-optimization-playwright-playwright-final-status 60.49% <99.24%> (+0.07%) ⬆️
test-optimization-playwright-playwright-impacted-tests 60.02% <99.24%> (+0.23%) ⬆️
test-optimization-playwright-playwright-reporting 61.21% <99.24%> (-0.03%) ⬇️
test-optimization-playwright-playwright-test-management 61.03% <99.24%> (-0.02%) ⬇️
test-optimization-playwright-playwright-test-span 60.23% <99.24%> (-0.14%) ⬇️
test-optimization-selenium 59.49% <99.05%> (-0.09%) ⬇️
test-optimization-testopt 57.85% <99.16%> (+0.15%) ⬆️
test-optimization-vitest 73.76% <99.05%> (+0.07%) ⬆️
test-optimization-vitest-browser 59.07% <98.54%> (+0.07%) ⬆️
test-optimization-webdriverio 64.93% <97.91%> (+0.11%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@BridgeAR
BridgeAR force-pushed the BridgeAR/2026-07-28-jsdoc-types branch from f2a03d6 to 33934bc Compare August 4, 2026 10:33
`jsdoc/no-undefined-types` resolves neither TypeScript's lib globals (`IArguments`,
`ArrayLike`, `PropertyKey`, `PropertyDescriptor`, `Generator`, `ArrayBufferView`,
`ReadonlyArray`) nor the `NodeJS.*` namespace. Types that relied on those names are
spelled structurally or imported from `node:*` instead.
## Summary

Complete parameter declarations and replace unavailable ambient type names in files added after the branch diverged.

## Why

Rebasing enabled the JSDoc checks for newer master code. Without these annotations, the rebased branch cannot pass lint.
@BridgeAR
BridgeAR force-pushed the BridgeAR/2026-07-28-jsdoc-types branch from b40712f to d4f8543 Compare August 4, 2026 11:46
## Summary

Normalize the remaining JSDoc type expressions introduced on master after the branch diverged.

## Why

The enabled JSDoc checks apply to rebased master code as well.
@BridgeAR
BridgeAR force-pushed the BridgeAR/2026-07-28-jsdoc-types branch from 429ad6f to 2c234e4 Compare August 4, 2026 12:46
@BridgeAR BridgeAR changed the title chore(eslint): enable rules that are clean or trivially fixable chore(eslint): enable JSDoc parameter and type checks Aug 4, 2026
@BridgeAR
BridgeAR marked this pull request as ready for review August 4, 2026 14:12
@BridgeAR
BridgeAR requested review from a team as code owners August 4, 2026 14:12
@BridgeAR
BridgeAR requested review from khanayan123 and removed request for a team August 4, 2026 14:12
@BridgeAR
BridgeAR requested review from bojbrook and lym953 and removed request for a team August 4, 2026 14:12

@datadog-official datadog-official Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Datadog Autotest: PASS

More details

The diff contains no executable behavior changes: added lines are JSDoc/type annotations or lint configuration, and realistic router, OpenAI lifecycle, OTel bridge, git, and stacktrace scenarios remain passing.

Was this helpful? React 👍 or 👎

📊 Validated against 4 scenarios · Open Bits AI session

🤖 Datadog Autotest · Commit 2c234e4 · What is Autotest? · @DataDog review to ask questions · Any feedback? Reach out in #autotest

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2c234e45f2

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread eslint.config.mjs
Comment thread eslint.config.mjs
@BridgeAR
BridgeAR merged commit d70e6a0 into master Aug 4, 2026
678 checks passed
@BridgeAR
BridgeAR deleted the BridgeAR/2026-07-28-jsdoc-types branch August 4, 2026 15:30
@dd-octo-sts dd-octo-sts Bot mentioned this pull request Aug 5, 2026
@dd-octo-sts dd-octo-sts Bot mentioned this pull request Aug 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants