Skip to content

fix(bboard-cli): resolve config path with fileURLToPath (handles spaces in path)#1473

Open
tomiin wants to merge 1 commit into
midnightntwrk:mainfrom
tomiin:fix-spaces-in-path-config
Open

fix(bboard-cli): resolve config path with fileURLToPath (handles spaces in path)#1473
tomiin wants to merge 1 commit into
midnightntwrk:mainfrom
tomiin:fix-spaces-in-path-config

Conversation

@tomiin

@tomiin tomiin commented Jun 22, 2026

Copy link
Copy Markdown

Problem

bboard-cli/src/config.ts builds currentDir with new URL(import.meta.url).pathname. When the project path contains a space, the space stays percent-encoded as %20 (e.g. /Users/me/Midnight code/... becomes /Users/me/Midnight%20code/...). That path doesn't exist on disk, so the ZK config lookup fails at runtime with ZKConfigurationReadError: Failed to read verifier key.

Fix

Use fileURLToPath(import.meta.url) from node:url, which decodes the file URL to a real filesystem path. One-line change plus the import. Fixes the failure for anyone whose checkout lives under a directory with a space in the name.

@tomiin tomiin requested review from a team as code owners June 22, 2026 13:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant