You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
However, when running the same code in another project, it gives this error:
ubuntu@ip-172-31-43-104:~/myapp/worker$ nodemon --exec ts-node --files src/index.ts
[nodemon] 2.0.20
[nodemon] to restart at any time, enter `rs`
[nodemon] watching path(s): *.*
[nodemon] watching extensions: ts,json
[nodemon] starting `ts-node --files src/index.ts`
/home/ubuntu/myapp/worker/node_modules/ts-node/src/index.ts:859
return new TSError(diagnosticText, diagnosticCodes, diagnostics);
^
TSError: ⨯ Unable to compile TypeScript:
src/utils/logger/devLogger.ts:48:15 - error TS2339: Property 'metadata' does not exist on type 'TransformableInfo'.
48 `${info.metadata.timestamp} ${info.metadata.ms} ${info.metadata.host} pid:${process.pid} ` +
~~~~~~~~
src/utils/logger/devLogger.ts:48:42 - error TS2339: Property 'metadata' does not exist on type 'TransformableInfo'.
48 `${info.metadata.timestamp} ${info.metadata.ms} ${info.metadata.host} pid:${process.pid} ` +
~~~~~~~~
src/utils/logger/devLogger.ts:48:62 - error TS2339: Property 'metadata' does not exist on type 'TransformableInfo'.
48 `${info.metadata.timestamp} ${info.metadata.ms} ${info.metadata.host} pid:${process.pid} ` +
~~~~~~~~
src/utils/logger/devLogger.ts:60:15 - error TS2339: Property 'metadata' does not exist on type 'TransformableInfo'.
60 `${info.metadata.timestamp} ${info.metadata.ms} ${info.metadata.host} pid:${process.pid} ` +
~~~~~~~~
src/utils/logger/devLogger.ts:60:42 - error TS2339: Property 'metadata' does not exist on type 'TransformableInfo'.
60 `${info.metadata.timestamp} ${info.metadata.ms} ${info.metadata.host} pid:${process.pid} ` +
~~~~~~~~
src/utils/logger/devLogger.ts:60:62 - error TS2339: Property 'metadata' does not exist on type 'TransformableInfo'.
60 `${info.metadata.timestamp} ${info.metadata.ms} ${info.metadata.host} pid:${process.pid} ` +
~~~~~~~~
src/utils/logger/devLogger.ts:74:15 - error TS2339: Property 'metadata' does not exist on type 'TransformableInfo'.
74 `${info.metadata.timestamp} ${info.metadata.ms} ${info.metadata.host} pid:${process.pid} ` +
~~~~~~~~
src/utils/logger/devLogger.ts:74:42 - error TS2339: Property 'metadata' does not exist on type 'TransformableInfo'.
74 `${info.metadata.timestamp} ${info.metadata.ms} ${info.metadata.host} pid:${process.pid} ` +
~~~~~~~~
src/utils/logger/devLogger.ts:74:62 - error TS2339: Property 'metadata' does not exist on type 'TransformableInfo'.
74 `${info.metadata.timestamp} ${info.metadata.ms} ${info.metadata.host} pid:${process.pid} ` +
~~~~~~~~
src/utils/logger/devLogger.ts:87:22 - error TS2339: Property 'metadata' does not exist on type 'TransformableInfo'.
87 return `${info.metadata.timestamp} ${moment(parseFloat(info.metadata.timestamp))} `;
~~~~~~~~
src/utils/logger/devLogger.ts:87:67 - error TS2339: Property 'metadata' does not exist on type 'TransformableInfo'.
87 return `${info.metadata.timestamp} ${moment(parseFloat(info.metadata.timestamp))} `;
~~~~~~~~
at createTSError (/home/ubuntu/myapp/worker/node_modules/ts-node/src/index.ts:859:12)
at reportTSError (/home/ubuntu/myapp/worker/node_modules/ts-node/src/index.ts:863:19)
at getOutput (/home/ubuntu/myapp/worker/node_modules/ts-node/src/index.ts:1077:36)
at Object.compile (/home/ubuntu/myapp/worker/node_modules/ts-node/src/index.ts:1433:41)
at Module.m._compile (/home/ubuntu/myapp/worker/node_modules/ts-node/src/index.ts:1617:30)
at Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
at Object.require.extensions.<computed> [as .ts] (/home/ubuntu/myapp/worker/node_modules/ts-node/src/index.ts:1621:12)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at Module.require (node:internal/modules/cjs/loader:1005:19)
at require (node:internal/modules/cjs/helpers:94:18)
at Object.<anonymous> (/home/ubuntu/myapp/worker/src/utils/logger/index.ts:1:1)
at Module._compile (node:internal/modules/cjs/loader:1101:14)
at Module.m._compile (/home/ubuntu/myapp/worker/node_modules/ts-node/src/index.ts:1618:23)
at Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
at Object.require.extensions.<computed> [as .ts] (/home/ubuntu/myapp/worker/node_modules/ts-node/src/index.ts:1621:12) {
diagnosticCodes: [
2339, 2339, 2339,
2339, 2339, 2339,
2339, 2339, 2339,
2339, 2339
]
}
[nodemon] app crashed - waiting for file changes before starting...
What is this?
There is no information about this error on the internet.
Both projects are using node version v16.6.1, and
"winston": "^3.3.3",
"winston-daily-rotate-file": "^4.7.1",
"ts-node": "^10.9.1",
"typescript": "^3.7.2"
Everything is the same, and yet it gives this incredible error.
I have also tried:
"winston": "^3.8.2",
"winston": "^3.7.1",
But no luck at all.
I am pulling my hair so hard. What is this bug?
What version of Winston presents the issue?
v3.3.3
What version of Node are you using?
v16.6.1
If this worked in a previous version of Winston, which was it?
v3.3.3
Minimum Working Example
No response
Additional information
No response
The text was updated successfully, but these errors were encountered:
🔎 Search Terms
TS2339, metadata, does not exist, TransformableInfo,
The problem
The below code works perfectly fine in one project:
However, when running the same code in another project, it gives this error:
What is this?
There is no information about this error on the internet.
Both projects are using node version v16.6.1, and
"winston": "^3.3.3",
"winston-daily-rotate-file": "^4.7.1",
"ts-node": "^10.9.1",
"typescript": "^3.7.2"
Everything is the same, and yet it gives this incredible error.
I have also tried:
"winston": "^3.8.2",
"winston": "^3.7.1",
But no luck at all.
I am pulling my hair so hard. What is this bug?
What version of Winston presents the issue?
v3.3.3
What version of Node are you using?
v16.6.1
If this worked in a previous version of Winston, which was it?
v3.3.3
Minimum Working Example
No response
Additional information
No response
The text was updated successfully, but these errors were encountered: