Skip to content

Improve error messages when render target discovery encounters permissions issues #14960

Description

@xtimbeau

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

A _quarto.yml file placed somehow high in the hierarchy of folder (/users/me/_quarto.yml) would crach a lot of quarto commands whith a difficult to interpret error message.

Steps to reproduce

On MacOS at least, put a _quarto.yml in /users/{you}/_quarto.yml with the following content

project:
  type: website
format:
  html: default

then run quarto check from the terminal anywhere under /users/{you}/. You should get the error message: (user folder has been changed)

me ~ % quarto check
ERROR: PermissionDenied: Operation not permitted (os error 1): readdir '/Users/me/Pictures/Photos Library.photoslibrary'

Stack trace:
    at async Object.[Symbol.asyncIterator] (ext:deno_fs/30_fs.js:222:19)
    at async walk (file:///Applications/quarto/bin/quarto.js:2884:20)
    at async walk (file:///Applications/quarto/bin/quarto.js:2917:7)
    at async walk (file:///Applications/quarto/bin/quarto.js:2917:7)
    at async addDir (file:///Applications/quarto/bin/quarto.js:92493:22)
    at async projectInputFilesInternal (file:///Applications/quarto/bin/quarto.js:92536:18)
    at async projectContext (file:///Applications/quarto/bin/quarto.js:92106:36)
    at async initializeProjectContextAndEngines (file:///Applications/quarto/bin/quarto.js:144407:19)
    at async _Command.actionHandler (file:///Applications/quarto/bin/quarto.js:164506:3)
    at async _Command.execute (file:///Applications/quarto/bin/quarto.js:102189:7)
    at async _Command.parseCommand (file:///Applications/quarto/bin/quarto.js:102066:14)
    at async quarto4 (file:///Applications/quarto/bin/quarto.js:188195:5)
    at async file:///Applications/quarto/bin/quarto.js:188224:5
    at async file:///Applications/quarto/bin/quarto.js:188078:14
    at async mainRunner (file:///Applications/quarto/bin/quarto.js:188080:5)
    at async file:///Applications/quarto/bin/quarto.js:188217:3
me ~ % 

Actual behavior

the error message

Expected behavior

a normal quarto diagnosis

Your environment

macos 26.6.2

Quarto check output

See above

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions