forcedotcom / cli

Salesforce CLI
https://developer.salesforce.com/docs/atlas.en-us.sfdx_cli_reference.meta/sfdx_cli_reference/
BSD 3-Clause "New" or "Revised" License
494 stars 78 forks source link

sf org login command for authentication always comes with a deprecation waring in GitLab pipeline script #3120

Closed shabu74 closed 2 hours ago

shabu74 commented 2 hours ago

Summary

Salesforce CLI command for authentication always comes with a deprecation waring "Closing a FileHandle object on garbage collection is deprecated. Please close FileHandle objects explicitly using FileHandle.prototype.close(). In the future, an error will be thrown if a file descriptor is closed during garbage collection." in GitLab pipeline script

Steps To Reproduce

Execute sf org login sfdx-url command

Expected result

Successful authentication with out any warning

Actual result

Successful authentication, but with a deprecation warning

Additional information

image

System Information

{
  "architecture": "linux-x64",
  "cliVersion": "@salesforce/cli/2.66.7",
  "nodeVersion": "node-v19.9.0",
  "osVersion": "Linux 6.8.0-1017-aws",
  "rootPath": "/usr/local/lib/node_modules/@salesforce/cli",
  "shell": "bash",
  "pluginVersions": [
    "@oclif/plugin-autocomplete 3.2.8 (core)",
    "@oclif/plugin-commands 4.1.7 (core)",
    "@oclif/plugin-help 6.2.16 (core)",
    "@oclif/plugin-not-found 3.2.25 (core)",
    "@oclif/plugin-plugins 5.4.15 (core)",
    "@oclif/plugin-search 1.2.14 (core)",
    "@oclif/plugin-update 4.6.10 (core)",
    "@oclif/plugin-version 2.2.15 (core)",
    "@oclif/plugin-warn-if-update-available 3.1.21 (core)",
    "@oclif/plugin-which 3.2.17 (core)",
    "@salesforce/cli 2.66.7 (core)",
    "apex 3.5.6 (core)",
    "api 1.3.1 (core)",
    "auth 3.6.72 (core)",
    "data 3.11.2 (core)",
    "deploy-retrieve 3.15.8 (core)",
    "info 3.4.17 (core)",
    "limits 3.3.38 (core)",
    "marketplace 1.3.4 (core)",
    "org 5.1.2 (core)",
    "packaging 2.9.0 (core)",
    "schema 3.3.40 (core)",
    "settings 2.4.4 (core)",
    "sobject 1.4.44 (core)",
    "telemetry 3.6.19 (core)",
    "templates [56](https://gitlab.service.nsw.gov.au/salesforce/caresnsw/-/jobs/11932645#L56).3.28 (core)",
    "trust 3.7.39 (core)",
    "user 3.6.2 (core)"
  ]
}
github-actions[bot] commented 2 hours ago

Thank you for filing this issue. We appreciate your feedback and will review the issue as soon as possible. Remember, however, that GitHub isn't a mechanism for receiving support under any agreement or SLA. If you require immediate assistance, contact Salesforce Customer Support.

github-actions[bot] commented 2 hours ago

Hello @shabu74 :wave: Your version of nodeJS (19) is not supported.

We recommend using LTS and we support anything Node says is Current, Active and Maintenance.

See Node's version status.

This issue will be closed. If you're able to reproduce your issue on a supported node version, please open a new issue.

shabu74 commented 1 hour ago

When I used node 19, at least I got only one issue. But after using node 22, I got a heap of other errors too. Please suggest something only if it is working fine.

(node:62) Warning: Closing file descriptor 24 on garbage collection (Use node --trace-warnings ... to show where the warning was created) (node:62) [DEP0137] DeprecationWarning: Closing a FileHandle object on garbage collection is deprecated. Please close FileHandle objects explicitly using FileHandle.prototype.close(). In the future, an error will be thrown if a file descriptor is closed during garbage collection. (node:62) [DEP0040] DeprecationWarning: The punycode module is deprecated. Please use a userland alternative instead. at node:punycode:3:9 at BuiltinModule.compileForInternalLoader (node:internal/bootstrap/realm:399:7) at BuiltinModule.compileForPublicLoader (node:internal/bootstrap/realm:338:10) at loadBuiltinModule (node:internal/modules/helpers:114:7) at Function._load (node:internal/modules/cjs/loader:1100:17) at TracingChannel.traceSync (node:diagnostics_channel:315:14) at wrapModuleLoad (node:internal/modules/cjs/loader:218:24) at Module.require (node:internal/modules/cjs/loader:1340:12) at require (node:internal/modules/helpers:141:16) at Object. (/usr/local/lib/node_modules/@salesforce/cli/node_modules/whatwg-url/lib/url-state-machine.js:2:18) Successfully authorized [MASKED] with org ID 00D5P0000008aZgUAI (node:98) [DEP0040] DeprecationWarning: The punycode module is deprecated. Please use a userland alternative instead. at node:punycode:3:9 at BuiltinModule.compileForInternalLoader (node:internal/bootstrap/realm:399:7) at BuiltinModule.compileForPublicLoader (node:internal/bootstrap/realm:338:10) at loadBuiltinModule (node:internal/modules/helpers:114:7) at Function._load (node:internal/modules/cjs/loader:1100:17) at TracingChannel.traceSync (node:diagnostics_channel:315:14) at wrapModuleLoad (node:internal/modules/cjs/loader:218:24) at Module.require (node:internal/modules/cjs/loader:1340:12) at require (node:internal/modules/helpers:141:16) at Object. (/usr/local/lib/node_modules/@salesforce/cli/node_modules/whatwg-url/lib/url-state-machine.js:2:18) Set Config Name Value Success

target-org MyCIDEVOrg true
(node:123) [DEP0040] DeprecationWarning: The punycode module is deprecated. Please use a userland alternative instead. at node:punycode:3:9 at BuiltinModule.compileForInternalLoader (node:internal/bootstrap/realm:399:7) at BuiltinModule.compileForPublicLoader (node:internal/bootstrap/realm:338:10) at loadBuiltinModule (node:internal/modules/helpers:114:7) at Function._load (node:internal/modules/cjs/loader:1100:17) at TracingChannel.traceSync (node:diagnostics_channel:315:14) at wrapModuleLoad (node:internal/modules/cjs/loader:218:24) at Module.require (node:internal/modules/cjs/loader:1340:12) at require (node:internal/modules/helpers:141:16) at Object. (/usr/local/lib/node_modules/@salesforce/cli/node_modules/whatwg-url/lib/url-state-machine.js:2:18) Set Config Name Value Success

target-dev-hub MyCIDEVOrg true
(node:147) [DEP0040] DeprecationWarning: The punycode module is deprecated. Please use a userland alternative instead. at node:punycode:3:9 at BuiltinModule.compileForInternalLoader (node:internal/bootstrap/realm:399:7) at BuiltinModule.compileForPublicLoader (node:internal/bootstrap/realm:338:10) at loadBuiltinModule (node:internal/modules/helpers:114:7) at Function._load (node:internal/modules/cjs/loader:1100:17) at TracingChannel.traceSync (node:diagnostics_channel:315:14) at wrapModuleLoad (node:internal/modules/cjs/loader:218:24) at Module.require (node:internal/modules/cjs/loader:1340:12) at require (node:internal/modules/helpers:141:16) at Object. (/usr/local/lib/node_modules/@salesforce/cli/node_modules/whatwg-url/lib/url-state-machine.js:2:18)

shabu74 commented 1 hour ago

{ "architecture": "linux-x64", "cliVersion": "@salesforce/cli/2.66.7", "nodeVersion": "node-v22.11.0", "osVersion": "Linux 6.8.0-1017-aws", "rootPath": "/usr/local/lib/node_modules/@salesforce/cli", "shell": "bash", "pluginVersions": [ "@oclif/plugin-autocomplete 3.2.8 (core)", "@oclif/plugin-commands 4.1.7 (core)", "@oclif/plugin-help 6.2.16 (core)", "@oclif/plugin-not-found 3.2.25 (core)", "@oclif/plugin-plugins 5.4.15 (core)", "@oclif/plugin-search 1.2.14 (core)", "@oclif/plugin-update 4.6.10 (core)", "@oclif/plugin-version 2.2.15 (core)", "@oclif/plugin-warn-if-update-available 3.1.21 (core)", "@oclif/plugin-which 3.2.17 (core)", "@salesforce/cli 2.66.7 (core)", "apex 3.5.6 (core)", "api 1.3.1 (core)", "auth 3.6.72 (core)", "data 3.11.2 (core)", "deploy-retrieve 3.15.8 (core)", "info 3.4.17 (core)", "limits 3.3.38 (core)", "marketplace 1.3.4 (core)", "org 5.1.2 (core)", "packaging 2.9.0 (core)", "schema 3.3.40 (core)", "settings 2.4.4 (core)", "sobject 1.4.44 (core)", "telemetry 3.6.19 (core)", "templates 56.3.28 (core)", "trust 3.7.39 (core)", "user 3.6.2 (core)" ] }