Skip to content

[Bug]: SecretStoreError: Failed to read secret server-signing-key (username should be redacted) #1887

@benjaminforras

Description

@benjaminforras

Before submitting

  • I searched existing issues and did not find a duplicate.
  • I included enough detail to reproduce or investigate the problem.

Area

Not sure

Steps to reproduce

  1. Run npx t3 version 0.0.16 using Node v24.11.0 and npm 11.6.1 on macOS
  2. Let all migrations complete
  3. Observe the error after migrations

Note: The logs below have the username removed for privacy.

Expected behavior

Migrations and secret loading should succeed without error.

Actual behavior

The following error appears:

[19:33:34.860] INFO (#1): Running all migrations...
[19:33:34.862] INFO (#1): Migrations ran successfully
  migrations: []
(node:56737) ExperimentalWarning: SQLite is an experimental feature and might change at any time
(Use `node --trace-warnings ...` to show where the warning was created)
[19:33:34.866] ERROR (#1): SecretStoreError: Failed to read secret server-signing-key.
    at file:///Users/[USERNAME REDACTED]/.npm/_npx/5ca66e5ae19a7ff4/node_modules/t3/dist/bin.mjs:23202:214
    at file:///Users/[USERNAME REDACTED]/.npm/_npx/5ca66e5ae19a7ff4/node_modules/t3/node_modules/effect/dist/internal/effect.js:1220:96
    at file:///Users/[USERNAME REDACTED]/.npm/_npx/5ca66e5ae19a7ff4/node_modules/t3/node_modules/effect/dist/internal/effect.js:1217:76
    at ~effect/Utils/internal (file:///Users/[USERNAME REDACTED]/.npm/_npx/5ca66e5ae19a7ff4/node_modules/t3/node_modules/effect/dist/Utils.js:69:12) {
  [cause]: PlatformError: NotFound: FileSystem.readFile (/Users/[USERNAME REDACTED]/.t3/userdata/secrets/server-signing-key.bin)
      at Module.systemError (file:///Users/[USERNAME REDACTED]/.npm/_npx/5ca66e5ae19a7ff4/node_modules/effect/dist/PlatformError.js:59:39)
      at file:///Users/[USERNAME REDACTED]/.npm/_npx/5ca66e5ae19a7ff4/node_modules/@effect/platform-node-shared/dist/internal/utils.js:28:24
      at ReadFileContext.callback (file:///Users/[USERNAME REDACTED]/.npm/_npx/5ca66e5ae19a7ff4/node_modules/@effect/platform-node-shared/dist/NodeFileSystem.js:261:74)
      at FSReqCallback.readFileAfterOpen [as oncomplete] (node:fs:297:13) {
    [cause]: Error: ENOENT: no such file or directory, open '/Users/[USERNAME REDACTED]/.t3/userdata/secrets/server-signing-key.bin'
  }
}

Impact

Major degradation or frequent failure

Version or commit

npx t3 v0.0.16

Environment

macOS, Node v24.11.0, npm 11.6.1

Logs or stack traces

[19:33:34.860] INFO (#1): Running all migrations...
[19:33:34.862] INFO (#1): Migrations ran successfully
  migrations: []
(node:56737) ExperimentalWarning: SQLite is an experimental feature and might change at any time
(Use `node --trace-warnings ...` to show where the warning was created)
[19:33:34.866] ERROR (#1): SecretStoreError: Failed to read secret server-signing-key.
    at file:///Users/[USERNAME REDACTED]/.npm/_npx/5ca66e5ae19a7ff4/node_modules/t3/dist/bin.mjs:23202:214
    at file:///Users/[USERNAME REDACTED]/.npm/_npx/5ca66e5ae19a7ff4/node_modules/t3/node_modules/effect/dist/internal/effect.js:1220:96
    at file:///Users/[USERNAME REDACTED]/.npm/_npx/5ca66e5ae19a7ff4/node_modules/t3/node_modules/effect/dist/internal/effect.js:1217:76
    at ~effect/Utils/internal (file:///Users/[USERNAME REDACTED]/.npm/_npx/5ca66e5ae19a7ff4/node_modules/t3/node_modules/effect/dist/Utils.js:69:12) {
  [cause]: PlatformError: NotFound: FileSystem.readFile (/Users/[USERNAME REDACTED]/.t3/userdata/secrets/server-signing-key.bin)
      at Module.systemError (file:///Users/[USERNAME REDACTED]/.npm/_npx/5ca66e5ae19a7ff4/node_modules/effect/dist/PlatformError.js:59:39)
      at file:///Users/[USERNAME REDACTED]/.npm/_npx/5ca66e5ae19a7ff4/node_modules/@effect/platform-node-shared/dist/internal/utils.js:28:24
      at ReadFileContext.callback (file:///Users/[USERNAME REDACTED]/.npm/_npx/5ca66e5ae19a7ff4/node_modules/@effect/platform-node-shared/dist/NodeFileSystem.js:261:74)
      at FSReqCallback.readFileAfterOpen [as oncomplete] (node:fs:297:13) {
    [cause]: Error: ENOENT: no such file or directory, open '/Users/[USERNAME REDACTED]/.t3/userdata/secrets/server-signing-key.bin'
  }
}

Screenshots, recordings, or supporting files

No response

Workaround

No workaround found-unable to proceed past this error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething is broken or behaving incorrectly.needs-triageIssue needs maintainer review and initial categorization.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions