Error when running post-render script of extension with space in path
@cderv đang làm issue này rồi.
Từ ngày 5/12/2025.
Đánh giá
Issue này chưa được đánh giá.
Mô tả
I have:
- searched the issue tracker for similar issues
- installed the latest version of Quarto CLI
- formatted my issue following the Bug Reports guide
Bug description
Hi,
my project resides in a folder that has a space in its folder path (some people have that).
I have an extension and the extension has defined:
title: MWE
author: Maarten Becker
version: 0.0.5
quarto-required: ">=1.8.0"
contributes:
project:
project:
type: book
metadata:
project:
post-render:
- scripts/echo.sh
I get an error when the script execution should happen.
Steps to reproduce
I created a ZIP with all ingedrients. After decompressing the folder with space in the folder name is present.
Within the folder execute quarto render
Actual behavior
When running I get the error:
ERROR: Error executing '/Users/becker/Entwicklung/MWE': Failed to spawn '/Users/becker/Entwicklung/MWE': No such file or directory (os error 2)
Stack trace:
at execProcess (file:///Users/becker/quarto-dev/quarto-cli/src/core/process.ts:203:11)
at runScripts (file:///Users/becker/quarto-dev/quarto-cli/src/command/render/project.ts:976:28)
at eventLoopTick (ext:core/01_core.js:179:7)
at async runPostRender (file:///Users/becker/quarto-dev/quarto-cli/src/command/render/project.ts:924:3)
at async renderProject (file:///Users/becker/quarto-dev/quarto-cli/src/command/render/project.ts:853:7)
at async Command.actionHandler (file:///Users/becker/quarto-dev/quarto-cli/src/command/render/cmd.ts:251:26)
at async Command.execute (https://deno.land/x/cliffy@v1.0.0-rc.3/command/command.ts:1948:7)
at async Command.parseCommand (https://deno.land/x/cliffy@v1.0.0-rc.3/command/command.ts:1780:14)
at async quarto (file:///Users/becker/quarto-dev/quarto-cli/src/quarto.ts:193:5)
at async file:///Users/becker/quarto-dev/quarto-cli/src/quarto.ts:225:5
The reason for this is that the absolute path created from the relative path in the extension folder is scrambled in function
https://github.com/quarto-dev/quarto-cli/blob/3b905a23928ddcd582edcc9ace978a9294f15558/src/core/run/shell.ts#L8
where script and arguments are separated simply by splitting at spaces.
With debug statements I see before this function /Users/becker/Entwicklung/MWE WithSpace/_extensions/MWE/scripts/echo.sh as path and after {"0":"/Users/becker/Entwicklung/MWE","1":"WithSpace/_extensions/MWE/scripts/echo.sh"}. The first element is then used as executable and the next as argument.
Expected behavior
Well, no error and script execution...
Your environment
- IDE: bash, vim
- OS: Mac OS Sequoia 15.7.2
Quarto check output
I used a fresh v1.9 local build to debug:
Quarto 99.9.9
[✓] Checking environment information...
Quarto cache location: /Users/becker/Library/Caches/quarto
[✓] Checking versions of quarto binary dependencies...
Pandoc version 3.6.3: OK
Dart Sass version 1.87.0: OK
NOTE: Deno version 2.4.5 does not strictly match 2.3.1 and strict checking is enabled. Please use 2.3.1.
Typst version 0.13.0: OK
[✓] Checking versions of quarto dependencies......OK
[✓] Checking Quarto installation......OK
Version: 99.9.9
commit: 25bdae61f21f106468b001525ea3a490ba8e0cf3
Path: /Users/becker/quarto-dev/quarto-cli/package/dist/bin
[✓] Checking tools....................OK
TinyTeX: v2025.12
Chromium: (not installed)
[✓] Checking LaTeX....................OK
Using: TinyTex
Path: /Users/becker/Library/TinyTeX/bin/universal-darwin
Version: 2025
[✓] Checking Chrome Headless....................OK
Chrome: (not detected)
[✓] Checking basic markdown render....OK
[✓] Checking Python 3 installation....OK
Version: 3.14.0
Path: /opt/homebrew/opt/python@3.14/bin/python3.14
Jupyter: (None)
Jupyter is not available in this Python installation.
Install with python3 -m pip install jupyter
[✓] Checking R installation...........OK
Version: 4.5.2
Path: /opt/homebrew/Cellar/r/4.5.2/lib/R
LibPaths:
- /opt/homebrew/Cellar/r/4.5.2/lib/R/library
knitr: 1.50
rmarkdown: (None)
The rmarkdown package is not available in this R installation.
Install with install.packages("rmarkdown")
- Ngôn ngữ chính
- JavaScript
- Star
- 6k
- Fork
- 458
- Merge trung bình
- 1 ngày 9 giờ
- Pull request đã merge (30 ngày)
- 41
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của quarto-dev/quarto-cli
-
binder bug
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 92/100
quarto-dev/quarto-cli#14907 · 3 bình luận ·
-
brand bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
quarto-dev/quarto-cli#14891 ·
-
brand bug html revealjs
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
quarto-dev/quarto-cli#14882 ·
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
quarto-dev/quarto-cli#14875 ·
-
Percent scripts: accept raw-string (r""") and '''-delimited markdown cells, as jupytext writes them Đang mởengines-jupyter enhancement
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
quarto-dev/quarto-cli#14850 · 2 bình luận ·
Tất cả issue của quarto-dev/quarto-cli
Issue tương tự
-
code-quality refactoring
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
github/gh-aw-firewall#8816 ·
-
integration:quickjs org:external priority:backlog topic:code-interpreter topic:middleware type:feature
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 74/100
langchain-ai/deepagents#6450 ·
-
optimization optimization:agents-md-curator
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
githubnext/gh-aw-cao#13143 ·
-
status: needs triage
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100