Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

isArray Deprecation notice #177

Open
Fyb3roptik opened this issue Oct 30, 2024 · 4 comments
Open

isArray Deprecation notice #177

Fyb3roptik opened this issue Oct 30, 2024 · 4 comments

Comments

@Fyb3roptik
Copy link

Getting this on Deploy

DeprecationWarning: The `util.isArray` API is deprecated. Please use `Array.isArray()` instead
@TwitchBronBron
Copy link
Member

What node version are you using? And what command were you using to deploy? (like are you running npx roku-deploy or calling it from the nodejs api?)

@Fyb3roptik
Copy link
Author

Sorry I didnt get notification you replied. I am running gulp deploy which does rokuDeploy.deploy(args)

Node version is v23.2.0

@Fyb3roptik
Copy link
Author

I just upgraded to 3.12.3 and still the same error. Im not seeing util.isArray in your code at all, but wonder if a dependency is still using it?

@TwitchBronBron
Copy link
Member

I spent a little time tracking down this issue.

We used to depend on the request library, but it has been abandoned. Then, we moved to postman-request which is a fork of request but they keep their dependencies up to date. Well, it seems that package has also fallen stale.

The underlying issue comes from https://github.com/postmanlabs/form-data

(node:43448) [DEP0044] DeprecationWarning: The `util.isArray` API is deprecated. Please use `Array.isArray()` instead.
    at FormData.append (C:\projects\roku\sample-projects\standard-with-task\node_modules\@postman\form-data\lib\form_data.js:64:12)
    at Request.init (C:\projects\roku\sample-projects\standard-with-task\node_modules\postman-request\request.js:462:21)
    at new Request (C:\projects\roku\sample-projects\standard-with-task\node_modules\postman-request\request.js:228:8)
    at request (C:\projects\roku\sample-projects\standard-with-task\node_modules\postman-request\index.js:64:10)
    at Function.post (C:\projects\roku\sample-projects\standard-with-task\node_modules\postman-request\index.js:72:12)
    at results (C:\projects\roku\sample-projects\standard-with-task\node_modules\roku-deploy\dist\RokuDeploy.js:632:21)
    at new Promise (<anonymous>)
    at RokuDeploy.doPostRequest (C:\projects\roku\sample-projects\standard-with-task\node_modules\roku-deploy\dist\RokuDeploy.js:631:29)
    at RokuDeploy.deleteInstalledChannel (C:\projects\roku\sample-projects\standard-with-task\node_modules\roku-deploy\dist\RokuDeploy.js:776:21)
    at RokuDeploy.deploy (C:\projects\roku\sample-projects\standard-with-task\node_modules\roku-deploy\dist\RokuDeploy.js:756:28)

Neither postman-request or @postman/form-data have their issues pages available. I could try to open a pull request to fix the issue, but they've also had another pull request open since October 2024.

So as I see it, our options are:

  1. try to get the postman packages upgraded to fix these issues
  2. fork and release our own copies with the fixes
  3. do nothing because it's just a warning.

Thoughts?

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

No branches or pull requests

2 participants