{
  // Use IntelliSense to learn about possible attributes.
  // Hover to view descriptions of existing attributes.
  // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
  "version": "0.2.0",
  "configurations": [
    {
      "type": "node",
      "request": "launch",
      "name": "stacks-blockchain dist-tool",
      "program": "${workspaceFolder}/stacks-blockchain/dist-tool/index.js",
      "skipFiles": ["<node_internals>/**"],
      "env": {
        "STACKS_BLOCKCHAIN_BRANCH": "feature/event-observer-envvar"
      }
    },
    {
      "type": "node",
      "request": "launch",
      "name": "Launch: app",
      "runtimeArgs": ["-r", "ts-node/register/transpile-only", "-r", "tsconfig-paths/register"],
      "args": ["${workspaceFolder}/src/index.ts"],
      "outputCapture": "std",
      "internalConsoleOptions": "openOnSessionStart",
      "preLaunchTask": "generate:schemas",
      "env": {
        "NODE_ENV": "development",
        "TS_NODE_SKIP_IGNORE": "true"
      }
    },
    {
      "type": "node",
      "request": "launch",
      "name": "Launch: mocknet",
      "skipFiles": [
        "<node_internals>/**"
      ],
      "runtimeArgs": ["-r", "ts-node/register/transpile-only", "-r", "tsconfig-paths/register"],
      "args": ["${workspaceFolder}/src/index.ts"],
      "outputCapture": "std",
      "internalConsoleOptions": "openOnSessionStart",
      "preLaunchTask": "stacks-node:deploy-dev",
      "postDebugTask": "stacks-node:stop-dev",
      "env": {
        "STACKS_BLOCKCHAIN_API_DB": "pg",
        "STACKS_CHAIN_ID": "0x80000000",
        "NODE_ENV": "development",
        "TS_NODE_SKIP_IGNORE": "true"
      },
      "killBehavior": "polite",
    },
    {
      "type": "node",
      "request": "launch",
      "name": "Launch: read-only",
      "skipFiles": [
        "<node_internals>/**"
      ],
      "runtimeArgs": [
        "-r",
        "ts-node/register/transpile-only",
        "-r",
        "tsconfig-paths/register"
      ],
      "args": [
        "${workspaceFolder}/src/index.ts"
      ],
      "outputCapture": "std",
      "internalConsoleOptions": "openOnSessionStart",
      "env": {
        "STACKS_BLOCKCHAIN_API_PORT": "3998",
        "STACKS_READ_ONLY_MODE": "true",
        "STACKS_BLOCKCHAIN_API_DB": "pg",
        "STACKS_CHAIN_ID": "0x80000000",
        "NODE_ENV": "development",
        "TS_NODE_SKIP_IGNORE": "true"
      },
      "killBehavior": "polite",
    },
    {
      "type": "node",
      "request": "launch",
      "name": "Launch: follower",
      "runtimeArgs": ["-r", "ts-node/register/transpile-only", "-r", "tsconfig-paths/register"],
      "args": ["${workspaceFolder}/src/index.ts"],
      "outputCapture": "std",
      "internalConsoleOptions": "openOnSessionStart",
      "preLaunchTask": "stacks-node:deploy-follower",
      "postDebugTask": "stacks-node:stop-dev",
      "env": {
        "STACKS_BLOCKCHAIN_API_DB": "pg",
        "STACKS_CHAIN_ID": "0x00000001",
        "NODE_ENV": "development",
        "TS_NODE_SKIP_IGNORE": "true"
      }
    },
    {
      "type": "node",
      "request": "launch",
      "name": "Launch: export-events",
      "runtimeArgs": ["-r", "ts-node/register/transpile-only", "-r", "tsconfig-paths/register"],
      "args": ["${workspaceFolder}/src/index.ts", "export-events", "--file", "/tmp/test-events-export.csv", "--overwrite-file"],
      "outputCapture": "std",
      "internalConsoleOptions": "openOnSessionStart",
      "env": {
        "NODE_ENV": "development",
        "TS_NODE_SKIP_IGNORE": "true"
      }
    },
    {
      "type": "node",
      "request": "launch",
      "name": "Launch: import-events",
      "runtimeArgs": ["-r", "ts-node/register/transpile-only", "-r", "tsconfig-paths/register"],
      "args": ["${workspaceFolder}/src/index.ts", "import-events", "--file", "/tmp/test-events-export.csv", "--wipe-db"],
      "outputCapture": "std",
      "internalConsoleOptions": "openOnSessionStart",
      "env": {
        "NODE_ENV": "development",
        "TS_NODE_SKIP_IGNORE": "true"
      }
    },
    {
      "type": "node",
      "request": "launch",
      "name": "Jest",
      "program": "${workspaceFolder}/node_modules/.bin/jest",
      "args": [
        "--testTimeout=3600000",
        "--runInBand",
        "--no-cache",
        "--config",
        "${workspaceRoot}/jest.config.js"
      ],
      "outputCapture": "std",
      "console": "integratedTerminal",
      "preLaunchTask": "stacks-node:deploy-dev",
      "postDebugTask": "stacks-node:stop-dev"
    },
    {
      "type": "node",
      "request": "launch",
      "name": "Jest: Rosetta",
      "program": "${workspaceFolder}/node_modules/.bin/jest",
      "args": [
        "--testTimeout=3600000",
        "--runInBand",
        "--no-cache",
        "--config",
        "${workspaceRoot}/jest.config.rosetta.js"
      ],
      "outputCapture": "std",
      "console": "integratedTerminal",
      "preLaunchTask": "stacks-node:deploy-dev",
      "postDebugTask": "stacks-node:stop-dev"
    },
    {
      "type": "node",
      "request": "launch",
      "name": "Jest: BNS",
      "program": "${workspaceFolder}/node_modules/.bin/jest",
      "args": [
        "--testTimeout=3600000",
        "--runInBand",
        "--no-cache",
        "--config",
        "${workspaceRoot}/jest.config.bns.js"
      ],
      "outputCapture": "std",
      "console": "integratedTerminal",
      "preLaunchTask": "stacks-node:deploy-dev",
      "postDebugTask": "stacks-node:stop-dev"
    },
    {
      "type": "node",
      "request": "launch",
      "name": "Jest: Tokens",
      "program": "${workspaceFolder}/node_modules/.bin/jest",
      "args": [
        "--testTimeout=3600000",
        "--runInBand",
        "--no-cache",
        "--config",
        "${workspaceRoot}/jest.config.tokens.js"
      ],
      "outputCapture": "std",
      "console": "integratedTerminal",
      "preLaunchTask": "stacks-node:deploy-dev",
      "postDebugTask": "stacks-node:stop-dev"
    },
    {
      "type": "node",
      "request": "launch",
      "name": "client-lib test",
      "runtimeArgs": ["-r", "ts-node/register/transpile-only", "-r", "tsconfig-paths/register"],
      "cwd": "${workspaceFolder}/docs/client",
      "args": ["${workspaceFolder}/docs/client/src/test.ts"],
      "outputCapture": "std",
      "internalConsoleOptions": "openOnSessionStart",
      "env": {
        "NODE_ENV": "development",
        "TS_NODE_SKIP_IGNORE": "true"
      }
    },
    {
      "type": "node",
      "request": "launch",
      "name": "docs: generate-types",
      "runtimeArgs": ["-r", "ts-node/register/transpile-only"],
      "cwd": "${workspaceFolder}/docs",
      "args": ["${workspaceFolder}/docs/scripts/generate-types.ts"]
    },
    {
      "type": "node",
      "request": "launch",
      "name": "utils: chaintip cache-control test",
      "runtimeArgs": ["-r", "ts-node/register/transpile-only"],
      "cwd": "${workspaceFolder}/utils",
      "args": ["${workspaceFolder}/utils/src/chaintip-cache-control-test.ts"]
    }
  ],
  "compounds": [
    {
      "name": "Launch: mocknet reader-writer",
      "configurations": ["Launch: mocknet", "Launch: read-only"]
    }
  ]
}
