Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion config/clients/js/config.overrides.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"sdkId": "js",
"gitRepoId": "js-sdk",
"packageName": "@openfga/sdk",
"packageVersion": "0.9.0",
"packageVersion": "0.9.2",
"packageDescription": "JavaScript and Node.js SDK for OpenFGA",
"packageDetailedDescription": "This is an autogenerated JavaScript SDK for OpenFGA. It provides a wrapper around the [OpenFGA API definition](https://openfga.dev/api), and includes TS typings.",
"npmRegistry": "https://registry.npmjs.org/",
Expand Down
6 changes: 5 additions & 1 deletion config/clients/js/template/README_installation.mustache
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,8 @@ Using [yarn](https://yarnpkg.com):

```shell
yarn add {{packageName}}
```
```

#### Supported Node.js Versions

For details on the supported Node.js versions and our support policy, see [SUPPORTED_RUNTIMES.md](./SUPPORTED_RUNTIMES.md).
Comment on lines +11 to +15
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Search for SUPPORTED_RUNTIMES template or reference in the JS client config
rg -rn "SUPPORTED_RUNTIMES" config/clients/js/
# Also check if there's a shared template
rg -rn "SUPPORTED_RUNTIMES" config/

Repository: openfga/sdk-generator

Length of output: 356


🏁 Script executed:

#!/bin/bash
# Read the README_installation.mustache file to see the actual content
cat -n config/clients/js/template/README_installation.mustache | head -20

Repository: openfga/sdk-generator

Length of output: 478


🏁 Script executed:

#!/bin/bash
# Search for SUPPORTED_RUNTIMES.md files in the repository
find . -name "*SUPPORTED_RUNTIMES*" -type f
# Also check if there's a template that generates it
find config/ -name "*.mustache" -type f | xargs grep -l "SUPPORTED_RUNTIMES" 2>/dev/null || echo "No other templates reference SUPPORTED_RUNTIMES"

Repository: openfga/sdk-generator

Length of output: 120


🏁 Script executed:

#!/bin/bash
# Check if there's a generator config or manifest that lists files to be generated
find config/clients/js/ -type f | head -30
# Look for any configuration that might generate SUPPORTED_RUNTIMES.md
rg -l "SUPPORTED_RUNTIMES" config/

Repository: openfga/sdk-generator

Length of output: 1403


🏁 Script executed:

#!/bin/bash
# Check the config files to see if SUPPORTED_RUNTIMES.md is listed as a generated file
cat config/clients/js/config.overrides.json | head -100

Repository: openfga/sdk-generator

Length of output: 1141


🏁 Script executed:

#!/bin/bash
# Get the full config.overrides.json file
cat config/clients/js/config.overrides.json | jq '.files | keys' 2>/dev/null || rg "destinationFilename" config/clients/js/config.overrides.json

Repository: openfga/sdk-generator

Length of output: 134


🏁 Script executed:

#!/bin/bash
# Check template-source.json to see how README files are configured
cat config/clients/js/template-source.json

Repository: openfga/sdk-generator

Length of output: 457


🏁 Script executed:

#!/bin/bash
# Search the entire repository for SUPPORTED_RUNTIMES (including documentation and non-config files)
find . -type f \( -name "*.md" -o -name "*.mustache" -o -name "*.json" \) -exec grep -l "SUPPORTED_RUNTIMES" {} \;
# Also check if there are any README template files in parent generator
find . -type f -name "*SUPPORTED*"

Repository: openfga/sdk-generator

Length of output: 179


🏁 Script executed:

#!/bin/bash
# Check if SUPPORTED_RUNTIMES.md exists in the repository root or docs directory
find . -name "SUPPORTED_RUNTIMES.md" -o -name "*SUPPORTED*RUNTIME*"
# Check the root directory for any README or documentation files
ls -la | grep -i readme
# Check if there's a docs directory
find . -maxdepth 3 -type d -name "docs" -o -type d -name "doc"

Repository: openfga/sdk-generator

Length of output: 131


🏁 Script executed:

#!/bin/bash
# Check if there's a generation script or configuration that creates SUPPORTED_RUNTIMES.md
find . -type f \( -name "*.sh" -o -name "Makefile" -o -name "*.yaml" -o -name "*.yml" \) -exec grep -l "SUPPORTED_RUNTIMES" {} \;
# Check the docs directory to see what's there
ls -la docs/ 2>/dev/null || echo "docs directory not accessible"
# Search for any reference to runtime support or similar documentation
rg "Node.js" config/clients/js/ -A 2 -B 2

Repository: openfga/sdk-generator

Length of output: 1272


🏁 Script executed:

#!/bin/bash
# Check if SUPPORTED_RUNTIMES.md should be a static file copied from elsewhere
find . -type f -name "*.md" | xargs grep -l "Node.js" | head -10
# Check the actual JS SDK repository or similar projects to see if they have SUPPORTED_RUNTIMES.md
rg "SUPPORTED_RUNTIMES" . --type md
# Check if there's a template or static file directory
ls -la config/clients/js/ | grep -v template

Repository: openfga/sdk-generator

Length of output: 356


🏁 Script executed:

#!/bin/bash
# Check the .openapi-generator-ignore to see if SUPPORTED_RUNTIMES.md is being ignored
cat config/clients/js/.openapi-generator-ignore
# Look for any static files or additional files that might be copied
find config/clients/js/ -type f ! -path "*/template/*" -name "*.md"

Repository: openfga/sdk-generator

Length of output: 110


🏁 Script executed:

#!/bin/bash
# Check for generation scripts or workflows
find . -type f \( -name "*.sh" -o -name "*.ts" -o -name "*.js" \) -path "*/scripts/*" -o -path "*/.github/workflows/*"
# Look for any mention of file generation or copying
rg "SUPPORTED_RUNTIMES\|copy.*file\|static.*file" . --type json --type yaml --type yml
# Check if there's a static files directory
find config/ -type d -name "static" -o -type d -name "assets"

Repository: openfga/sdk-generator

Length of output: 219


🏁 Script executed:

#!/bin/bash
# Check the common files/assets directory for SUPPORTED_RUNTIMES.md or similar
find config/common/files/ -type f | head -20
ls -la config/common/files/assets/

Repository: openfga/sdk-generator

Length of output: 1038


🏁 Script executed:

#!/bin/bash
# Check if there's a SUPPORTED_RUNTIMES.md template anywhere
find config/ -name "*SUPPORTED_RUNTIMES*"
# Look at the build script to understand how files are generated
cat scripts/build_client.sh | head -50

Repository: openfga/sdk-generator

Length of output: 1927


🏁 Script executed:

#!/bin/bash
# Check if SUPPORTED_RUNTIMES.md is supposed to be a static file in the repository
find . -type f -name "*.md" | xargs grep -l "supported.*runtime\|support.*policy" -i
# Check the OpenAPI Generator default templates to see if they generate such a file
rg "SUPPORTED_RUNTIMES" . --type all

Repository: openfga/sdk-generator

Length of output: 303


Remove or provide the SUPPORTED_RUNTIMES.md file.

The link to ./SUPPORTED_RUNTIMES.md on line 15 references a file that does not exist in the repository and is not generated by the build process. Either create the SUPPORTED_RUNTIMES.md template in config/clients/js/template/ or config/common/files/, or remove this link and replace it with a valid reference.

🤖 Prompt for AI Agents
In `@config/clients/js/template/README_installation.mustache` around lines 11 -
15, The README_installation.mustache references ./SUPPORTED_RUNTIMES.md which
doesn't exist; either add a SUPPORTED_RUNTIMES.md template (containing supported
Node.js versions and policy) into the template set (e.g., create the file under
config/clients/js/template/ or the shared templates folder config/common/files/)
and ensure it is included in generated packages, or remove/replace the link in
README_installation.mustache with a valid existing reference (or inline the
supported runtimes text) so the README no longer points to a missing file.

27 changes: 14 additions & 13 deletions config/clients/js/template/package.mustache
Original file line number Diff line number Diff line change
Expand Up @@ -20,21 +20,22 @@
},
"dependencies": {
"@opentelemetry/api": "^1.9.0",
Copy link
Member

Choose a reason for hiding this comment

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

How come we're still maintaining the package.json file in this repo? Is it just because of the version?

"axios": "^1.12.2",
"jose": "^5.10.0",
"axios": "^1.13.5",
"jose": "5.10.0",
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

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

jose was changed from a semver range to an exact version. Pinning an exact dependency version can prevent consumers from receiving compatible patch/minor updates (including security fixes). Consider reverting to a caret range (or document why this must be pinned).

Suggested change
"jose": "5.10.0",
"jose": "^5.10.0",

Copilot uses AI. Check for mistakes.
"tiny-async-pool": "^2.1.0"
},
"devDependencies": {
"@types/jest": "^29.5.14",
"@types/node": "^24.2.0",
"@types/jest": "30.0.0",
"@types/node": "^25.2.2",
"@types/tiny-async-pool": "^2.0.3",
"@typescript-eslint/eslint-plugin": "^8.39.0",
"@typescript-eslint/parser": "^8.39.0",
"eslint": "^8.57.1",
"jest": "^29.7.0",
"nock": "^14.0.9",
"ts-jest": "^29.4.1",
"typescript": "^5.9.2"
"@typescript-eslint/eslint-plugin": "^8.55.0",
"@typescript-eslint/parser": "^8.55.0",
"eslint": "9.39.2",
"globals": "^17.3.0",
"jest": "30.2.0",
"nock": "^14.0.11",
"ts-jest": "29.4.6",
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

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

jest is bumped to v30 but ts-jest remains on the v29 major line. These typically have peer dependency/compatibility coupling, and this mismatch is likely to break npm test in generated SDKs. Align ts-jest's major version with jest (or keep jest on v29).

Suggested change
"ts-jest": "29.4.6",
"ts-jest": "30.0.0",

Copilot uses AI. Check for mistakes.
"typescript": "^5.9.3"
},
"files": [
"CHANGELOG.md",
Expand All @@ -44,14 +45,14 @@
],
"repository": {
"type": "git",
"url": "git://{{gitHost}}:{{gitUserId}}/{{gitRepoId}}.git"
"url": "git+https://{{gitHost}}/{{gitUserId}}/{{gitRepoId}}.git"
},
"bugs": {
"url": "https://{{gitHost}}/{{gitUserId}}/{{gitRepoId}}/issues"
},
"homepage": "https://{{gitHost}}/{{gitUserId}}/{{gitRepoId}}#readme",
"engines": {
"node": ">=16.15.0"
"node": ">=20.19.0"
},
Comment on lines 54 to 56
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

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

The PR title says support is being dropped for Node 16 and 18, but the generated engines.node is set to >=20.19.0, which additionally excludes earlier Node 20.x releases. If the intent is simply “Node 20+”, consider loosening this to >=20 (or update the PR description/title and docs to explain the stricter minimum).

Copilot uses AI. Check for mistakes.
"publishConfig": {
"access": "public",
Expand Down
Loading