Skip to content

Path to source code files is being printed wrongly in stack-traces #352

@msmilkshake

Description

@msmilkshake

Hey guys, I am getting these types of stack-traces for the source code:

Error sending event: Error: Test Error
    at EventHubService.sendEvent (C:\Users\EX145358\3ktech\xbid_nest\src\common\event-hub\file:\C:\Users\EX145358\3ktech\xbid_nest\src\common\event-hub\event-hub.service.ts:19:11)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at EventHubTestController.sendEvent (C:\Users\EX145358\3ktech\xbid_nest\src\common\event-hub\file:\C:\Users\EX145358\3ktech\xbid_nest\src\common\event-hub\event-hub-test.controller.ts:11:7)

Notice the duplicated file path along with a file: prefix

I am using this command to run:
ts-node-dev --inspect --respawn --transpile-only -- src/main.ts

and here's my current tsconfig.json:

{
  "compilerOptions": {
    "module": "commonjs",
    "declaration": true,
    "removeComments": true,
    "emitDecoratorMetadata": true,
    "experimentalDecorators": true,
    "allowSyntheticDefaultImports": true,
    "esModuleInterop": true,
    "target": "es2017",
    "sourceMap": true,
    "outDir": "./dist",
    "baseUrl": "./",
    "incremental": true,
    "skipLibCheck": true,
    "strictNullChecks": false,
    "noImplicitAny": false,
    "noImplicitReturns": true,
    "noImplicitThis":true,
    "strictBindCallApply": false,
    "forceConsistentCasingInFileNames": true,
    "noFallthroughCasesInSwitch": true,
    "allowJs": true,
    "noEmitOnError": true,
    "moduleResolution":"Node",
  }
}

Running on Node 16.16.0 (Project requirement)
ts-node-dev v2.0.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions