Skip to content

feat(legacy-json): make source path configurable - #1111

Open
moshams272 wants to merge 1 commit into
nodejs:mainfrom
moshams272:feat/configurable-source-prefix
Open

moshams272 wants to merge 1 commit into
nodejs:mainfrom
moshams272:feat/configurable-source-prefix

Conversation

@moshams272

Copy link
Copy Markdown
Contributor

Description

This PR makes the source path for legacy JSON generators configurable instead of hardcoded.

Validation

Tested locally.

Related Issues

None.

Check List

  • I have read the Contributing Guidelines and made commit messages that follow the guideline.
  • I have run node --run test and all tests passed.
  • I have check code formatting with node --run format:check & node --run lint.
  • I've covered new added functionality with unit tests if necessary.

@moshams272
moshams272 requested a review from a team as a code owner September 25, 2026 15:18
@vercel

vercel Bot commented Sep 25, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
api-docs-tooling Ready Ready Preview Sep 25, 2026 6:09pm UTC

Request Review

@codecov

codecov Bot commented Sep 25, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 42.85714% with 8 lines in your changes missing coverage. Please review.
✅ Project coverage is 91.37%. Comparing base (6a73fd2) to head (e39e886).

Files with missing lines Patch % Lines
...kages/node-legacy/src/legacy-json-all/generate.mjs 20.00% 4 Missing ⚠️
packages/node-legacy/src/legacy-json/generate.mjs 0.00% 3 Missing ⚠️
...node-legacy/src/legacy-json/utils/buildSection.mjs 75.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1111      +/-   ##
==========================================
- Coverage   91.38%   91.37%   -0.01%     
==========================================
  Files         249      249              
  Lines       23253    23261       +8     
  Branches     2244     2244              
==========================================
+ Hits        21250    21255       +5     
- Misses       1994     1997       +3     
  Partials        9        9              

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

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions

github-actions Bot commented Sep 25, 2026 •

Copy link
Copy Markdown
Contributor

api-links Generator

Output: 1 file differs

apilinks.json
Expected values to be strictly deep-equal:
+ actual - expected
... Skipped lines

  {
    'Agent.defaultMaxSockets': 'https://github.com/{repository}/blob/HEAD/lib/_http_agent.js#L300',
    'Buffer.alloc': 'https://github.com/{repository}/blob/HEAD/lib/buffer.js#L453',
    'Buffer.allocUnsafe': 'https://github.com/{repository}/blob/HEAD/lib/buffer.js#L472',
    'Buffer.allocUnsafeSlow': 'https://github.com/{repository}/blob/HEAD/lib/buffer.js#L495',
...
    'agent.addRequest': 'https://github.com/{repository}/blob/HEAD/lib/_http_agent.js#L365',
+   'agent.createConnection': 'https://github.com/{repository}/blob/HEAD/lib/https.js#L354',
-   'agent.createConnection': 'https://github.com/{repository}/blob/HEAD/lib/_http_agent.js#L304',
    'agent.createSocket': 'https://github.com/{repository}/blob/HEAD/lib/_http_agent.js#L446',
    'agent.destroy': 'https://github.com/{repository}/blob/HEAD/lib/_http_agent.js#L679',
+   'agent.getName': 'https://github.com/{repository}/blob/HEAD/lib/https.js#L537',
+   'agent.keepSocketAlive': 'https://github.com/{repository}/blob/HEAD/lib/https.js#L506',
-   'agent.getName': 'https://github.com/{repository}/blob/HEAD/lib/_http_agent.js#L334',
-   'agent.keepSocketAlive': 'https://github.com/{repository}/blob/HEAD/lib/_http_agent.js#L635',
    'agent.removeSocket': 'https://github.com/{repository}/blob/HEAD/lib/_http_agent.js#L574',
    'agent.reuseSocket': 'https://github.com/{repository}/blob/HEAD/lib/_http_agent.js#L671',
    'assert.assert': 'https://github.com/{repository}/blob/HEAD/lib/assert.js#L185',
    'asyncResource.asyncId': 'https://github.com/{repository}/blob/HEAD/lib/async_hooks.js#L243',
    'asyncResource.bind': 'https://github.com/{repository}/blob/HEAD/lib/async_hooks.js#L275',
...
    'server.address': 'https://github.com/{repository}/blob/HEAD/lib/net.js#L2776',
+   'server.close': 'https://github.com/{repository}/blob/HEAD/lib/net.js#L2909',
+   'server.closeAllConnections': 'https://github.com/{repository}/blob/HEAD/lib/https.js#L125',
+   'server.closeIdleConnections': 'https://github.com/{repository}/blob/HEAD/lib/https.js#L127',
-   'server.close': 'https://github.com/{repository}/blob/HEAD/lib/_http_server.js#L694',
-   'server.closeAllConnections': 'https://github.com/{repository}/blob/HEAD/lib/_http_server.js#L704',
-   'server.closeIdleConnections': 'https://github.com/{repository}/blob/HEAD/lib/_http_server.js#L716',
    'server.getConnections': 'https://github.com/{repository}/blob/HEAD/lib/net.js#L2871',
    'server.listen': 'https://github.com/{repository}/blob/HEAD/lib/net.js#L2566',
    'server.ref': 'https://github.com/{repository}/blob/HEAD/lib/net.js#L3023',
+   'server.setTimeout': 'https://github.com/{repository}/blob/HEAD/lib/https.js#L129',
-   'server.setTimeout': 'https://github.com/{repository}/blob/HEAD/lib/_http_server.js#L732',
    'server.unref': 'https://github.com/{repository}/blob/HEAD/lib/net.js#L3032',
+   'server[SymbolAsyncDispose]': 'https://github.com/{repository}/blob/HEAD/lib/net.js#L2950',
-   'server[SymbolAsyncDispose]': 'https://github.com/{repository}/blob/HEAD/lib/_http_server.js#L700',
    'server[SymbolAsyncIterator]': 'https://github.com/{repository}/blob/HEAD/lib/net.js#L2957',
    'server[kDeserialize]': 'https://github.com/{repository}/blob/HEAD/lib/net.js#L2487',
    'server[kTransferList]': 'https://github.com/{repository}/blob/HEAD/lib/net.js#L2459',
    'server[kTransfer]': 'https://github.com/{repository}/blob/HEAD/lib/net.js#L2464',
+   'server[undefined]': 'https://github.com/{repository}/blob/HEAD/lib/net.js#L2987',
-   'server[undefined]': 'https://github.com/{repository}/blob/HEAD/lib/_http_server.js#L739',
    'serverresponse._finish': 'https://github.com/{repository}/blob/HEAD/lib/_http_server.js#L259',
    'serverresponse._implicitHeader': 'https://github.com/{repository}/blob/HEAD/lib/_http_server.js#L416',
    'serverresponse.assignSocket': 'https://github.com/{repository}/blob/HEAD/lib/_http_server.js#L309',
    'serverresponse.detachSocket': 'https://github.com/{repository}/blob/HEAD/lib/_http_server.js#L320',
    'serverresponse.statusCode': 'https://github.com/{repository}/blob/HEAD/lib/_http_server.js#L282',

Performance estimate (single CI run)

  • Generation time: 4.3% slower (1.41 s → 1.47 s)
  • Peak memory: 14.0% lower (412.92 MB → 355.31 MB)

json Generator

Performance estimate (single CI run)

  • Generation time: 2.2% slower (9.14 s → 9.34 s)
  • Peak memory: 2.4% higher (1.69 GB → 1.73 GB)

legacy-html Generator

Performance estimate (single CI run)

  • Generation time: 2.9% slower (43.22 s → 44.48 s)
  • Peak memory: 3.5% lower (2.44 GB → 2.35 GB)

legacy-json Generator

Performance estimate (single CI run)

  • Generation time: 12.4% faster (8.01 s → 7.02 s)
  • Peak memory: 12.0% lower (1.74 GB → 1.53 GB)

llms-txt Generator

Performance estimate (single CI run)

  • Generation time: 65.8% slower (5.52 s → 9.15 s)
  • Peak memory: 1.7% lower (1.57 GB → 1.54 GB)

orama-db Generator

Output size: 1 file changed · net +126.00 B

File size details
File Main PR Change
orama-db.json 9.50 MB 9.50 MB +126.00 B (+0.0%)

Performance estimate (single CI run)

  • Generation time: 21.4% slower (4.96 s → 6.02 s)
  • Peak memory: 3.6% lower (1.77 GB → 1.70 GB)

web Generator

Performance estimate (single CI run)

  • Generation time: 39.8% slower (45.46 s → 63.55 s)
  • Peak memory: 6.2% higher (3.47 GB → 3.68 GB)

Comment thread packages/node-legacy/src/legacy-json-all/index.mjs Outdated

This branch was successfully deployed

1 active deployment
Preview – api-docs-tooling — e39e8867 Deployed Sep 25, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants