Skip to content

Conversation

@denizyts
Copy link

Signed-off-by: Deniz Yetiş <denizyetis56@gmail.com>

(node:93573) [DEP0047] DeprecationWarning: The util.isDate API is deprecated.

This deprecation message annoys me a lot. I hope in the future versions it will be fixed or my pull request will be merged.

@oracle-contributor-agreement oracle-contributor-agreement bot added the OCA Verified All contributors have signed the Oracle Contributor Agreement. label Jan 20, 2026
@barisaydinayy
Copy link

this deprecation warning annoys me a lot also ++++++++++

@sharadraju
Copy link
Member

sharadraju commented Jan 20, 2026

This deprecation is done only in Node.js 25 and above, I think.
So, it is only a recent change in Node.js as it is.
What is the Node.js version that you are using?

@denizyts
Copy link
Author

This deprecation is done only in Node.js 25 and above, I think. So, it is only a recent change in Node.js as it is. What is the Node.js version that you are using?

v22.12.0

deprecation gone after fix

@sharadraju
Copy link
Member

sharadraju commented Jan 20, 2026

Thanks @denizyts. We will check this internally and make the change in the next release, if required (with due credits given to you :) )

@sharadraju
Copy link
Member

@denizyts The strange thing is, I am not seeing this warning and I am also using Node.js 22.

Can you give me an example, where you are seeing this warning? Are you using node-oracledb as part of any framework?

@sudarshan12s
Copy link
Member

Yes util.types.isDate should be ok but not util.isDate. Can you confirm if warning is from same file, lib/connection.js

@sudarshan12s
Copy link
Member

I think the warning is coming from node-oracledb 5.5
util.types.isDate should also be safe .. Update to latest node-oracledb should resolve the issue.

@sosoba
Copy link

sosoba commented Jan 21, 2026

Try polyfl:

util.isDate ??= util.types.isDate;

@sharadraju
Copy link
Member

@denizyts @barisaydinayy What is the node-oracledb version that you are using?

@denizyts
Copy link
Author

denizyts commented Jan 21, 2026

What is the node-oracledb version that you are using?

This deprecation related to oracledb version missmatch on local somehow, my version is 6.10.0 but the connection.js file still same with release 6.3.0 (probably caused by some conflicts with respect to local changes.) after 6.5.0 "util.types.isDate(value)" is used. So deprecation is gone. But still using "instanceof" is better approach i think.

Thanks to @sharadraju and @sudarshan12s for responding <3

@sharadraju
Copy link
Member

Thanks @denizyts. My guess is that your @types/oracledb version might still be 6.3. You might want to upgrade that as well.

But we will discuss internally and see if we want to go ahead with instanceof in the new version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

OCA Verified All contributors have signed the Oracle Contributor Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants