Skip to content

Add Quarto troubleshooting section#199

Open
Copilot wants to merge 14 commits into
mainfrom
copilot/summarize-quarto-troubleshooting
Open

Add Quarto troubleshooting section#199
Copilot wants to merge 14 commits into
mainfrom
copilot/summarize-quarto-troubleshooting

Conversation

Copilot AI commented Jan 30, 2026

Copy link
Copy Markdown
Contributor

Adds troubleshooting guidance to the Quarto chapter with summary of diagnostic tools and link to official guide.

Changes

  • quarto/troubleshooting.qmd: New section covering quarto check, debug logging, stack traces, log file locations, and memory allocation options with cross-platform syntax for both Unix-like systems (macOS, Linux) and Windows PowerShell
  • quarto.qmd: Include troubleshooting section between Advanced Features and Additional Resources

The section provides comprehensive troubleshooting guidance including:

  • Checking Your Setup: Details about what quarto check verifies (Quarto version, dependencies, LaTeX, Python/Jupyter, R/knitr, library paths)
  • Diagnostic Tools: Commands for verbose logging (QUARTO_LOG_LEVEL=DEBUG), stack traces (QUARTO_PRINT_STACK), and log file locations (all platforms)
  • Common Issues: Out-of-memory errors, PDF rendering problems (with TinyTeX installation), and environment conflicts
  • Advanced Troubleshooting: Links to specialized topics (Jupyter debugging, Lua filter tracing, Julia-specific issues)

All content is based on the official guide at https://quarto.org/docs/troubleshooting/ and provides accurate, actionable guidance while maintaining a concise summary format.

Troubleshooting section screenshot

Original prompt

This section details on the original issue you should resolve

<issue_title>summarize and link to quarto troubleshooting guide</issue_title>
<issue_description>https://quarto.org/docs/troubleshooting/</issue_description>

Comments on the Issue (you are @copilot in this section)


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Co-authored-by: d-morrison <2474437+d-morrison@users.noreply.github.com>
Copilot AI changed the title [WIP] Summarize and link to Quarto troubleshooting guide Add Quarto troubleshooting section Jan 30, 2026
Copilot AI requested a review from d-morrison January 30, 2026 09:04
@d-morrison

Copy link
Copy Markdown
Member

@copilot I unblocked https://quarto.org/docs/troubleshooting/; try again

Co-authored-by: d-morrison <2474437+d-morrison@users.noreply.github.com>

Copilot AI commented Jan 30, 2026

Copy link
Copy Markdown
Contributor Author

@copilot I unblocked https://quarto.org/docs/troubleshooting/; try again

I've enhanced the troubleshooting section with content from the official guide in commit 3654a3f. The updated section now includes:

  • More comprehensive details about quarto check
  • Proper export syntax for environment variables on Unix systems
  • Command-line flag alternatives (e.g., --log-level debug)
  • New "Common Issues" section covering PDF rendering, memory errors, and environment conflicts
  • New "Advanced Troubleshooting" section linking to Jupyter, Lua filter, and Julia-specific topics

Screenshot of updated troubleshooting section

Copilot AI and others added 2 commits January 30, 2026 09:31
Co-authored-by: d-morrison <2474437+d-morrison@users.noreply.github.com>
Co-authored-by: d-morrison <2474437+d-morrison@users.noreply.github.com>
Copilot AI requested a review from d-morrison January 30, 2026 09:36
@d-morrison d-morrison marked this pull request as ready for review January 30, 2026 19:13
@github-actions

github-actions Bot commented Jan 30, 2026

Copy link
Copy Markdown
Contributor
PR Preview Action v1.8.1-2-g6ad689f

QR code for preview link

🚀 View preview at
https://UCD-SERG.github.io/lab-manual/pr-preview/pr-199/

Built to branch gh-pages at 2026-06-17 17:27 UTC.
Preview will be ready when the GitHub Pages deployment is complete.

Copilot AI review requested due to automatic review settings May 7, 2026 23:19

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new Troubleshooting section to the Quarto chapter, summarizing key diagnostic commands and pointers to official Quarto troubleshooting guidance to help readers debug rendering and environment issues.

Changes:

  • Added a new quarto/troubleshooting.qmd section covering quarto check, debug logging/stack traces, log locations, and common remediation steps.
  • Updated quarto.qmd to include the Troubleshooting section in the chapter structure.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.

File Description
quarto/troubleshooting.qmd New troubleshooting guidance section (checks, diagnostics, common issues, links).
quarto.qmd Adds the Troubleshooting include into the Quarto chapter outline.

Comment thread quarto.qmd Outdated
Comment thread quarto.qmd Outdated
Comment thread quarto/troubleshooting.qmd Outdated
Comment thread quarto/troubleshooting.qmd Outdated
@d-morrison

Copy link
Copy Markdown
Member

@claude apply changes based on the comments in this thread

@claude

claude Bot commented May 19, 2026

Copy link
Copy Markdown
Contributor

Claude finished @d-morrison's task in 1m 6s —— View job


Applied review changes

  • Read quarto.qmd and quarto/troubleshooting.qmd
  • Move Troubleshooting section to between Mermaid Diagrams and Additional Resources (fixes placement discrepancy noted in review)
  • Add blank line after troubleshooting include in quarto.qmd for consistent spacing
  • Reflow long sentence at line 2 in quarto/troubleshooting.qmd (break after link)
  • Reflow long sentence at line 101 in quarto/troubleshooting.qmd (break after "diagnostic document" and after inline code)
  • Commit and push changes

All 4 review comments from the copilot-pull-request-reviewer thread have been addressed in commit d64a540.
|

- Move Troubleshooting section to between Mermaid Diagrams and Additional Resources
- Add blank line after troubleshooting include in quarto.qmd
- Reflow long line at top of troubleshooting.qmd using semantic line breaks
- Reflow long line in Environment Conflicts paragraph using semantic line breaks

Co-authored-by: Douglas Ezra Morrison <d-morrison@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 19, 2026 05:40
Copilot AI removed the request for review from Copilot May 19, 2026 05:40
@d-morrison

Copy link
Copy Markdown
Member

@claude fix failing workflows, review, and revise

@claude

claude Bot commented May 19, 2026

Copy link
Copy Markdown
Contributor

Claude finished @d-morrison's task in 4m 54s —— View job


Workflow analysis, review, and revisions

  • Read CLAUDE.md — not present
  • Check CI status and analyze all 3 failing workflows
  • Review quarto/troubleshooting.qmd and quarto.qmd
  • Fix check-bibliography-dois.R argument parsing bug
  • Minor revision: add trailing newline to quarto/troubleshooting.qmd
  • Commit and push (086339a)

Workflow failures

All 3 failures are pre-existing issues not introduced by this PR. The PR's changed files (quarto.qmd, quarto/troubleshooting.qmd) pass both the character check and DOI check cleanly.

Workflow Status Root cause
Check Non-Standard Characters Pre-existing ❌ 24 files across the repo contain em dashes / curly quotes; none are this PR's files
Check Bibliography DOIs Pre-existing ❌ (fixed) Bug in .github/scripts/check-bibliography-dois.R — see below
Claude Code Review CI tooling ❌ Runner-side failure, not a code issue

DOI script bug fixed — The workflow passes all .bib file paths as a single space-separated string via "$BIB_FILES" (quoted), so R's commandArgs() receives them as one argument. The script then tried to open the entire concatenated string as a single filename and failed with Error: File ... does not exist. Fixed by splitting on whitespace after collecting args.

Note: After the argument parsing fix, the check-bibliography-dois workflow may still fail because several @book entries in book.bib (e.g., xie2015, wickham2023r4ds, wickham2023rpkgs, etc.) lack doi fields. That is a separate pre-existing gap that needs to be addressed in a follow-up — either by adding the missing DOIs or by adjusting the check's policy for online-first books.


Content review

quarto/troubleshooting.qmd is accurate and well-organized. It correctly summarizes the official guide with:

  • quarto check coverage (version, dependencies, LaTeX, Python/Jupyter, R/knitr, library paths)
  • Cross-platform verbose logging and stack trace syntax (Unix + PowerShell)
  • Log file locations for all three platforms
  • Common issues (OOM, PDF rendering, environment conflicts)
  • Links to advanced topics in the official guide

quarto.qmd placement (between Mermaid Diagrams and Additional Resources) matches the previous review request. Spacing is consistent with surrounding includes.

Only minor revision applied: added a trailing newline to quarto/troubleshooting.qmd (no content changes).

Fix check-bibliography-dois.R to handle the case where all .bib file
paths are passed as a single space-separated argument (from "$BIB_FILES"
in the workflow), rather than as individual arguments. Previously the
script would crash with "file does not exist" on the concatenated string.

Also add trailing newline to quarto/troubleshooting.qmd.

Co-authored-by: Douglas Ezra Morrison <d-morrison@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 19, 2026 05:54
Copilot AI removed the request for review from Copilot May 19, 2026 05:54
@d-morrison

Copy link
Copy Markdown
Member

@claude review

@claude

claude Bot commented May 19, 2026

Copy link
Copy Markdown
Contributor

Claude finished @d-morrison's task in 1m 13s —— View job


Code Review

  • Read changed files and diff
  • Review quarto/troubleshooting.qmd
  • Review quarto.qmd
  • Review .github/scripts/check-bibliography-dois.R
  • Post final review

Summary

This PR is in good shape and ready to merge. All four previous copilot-pull-request-reviewer comments have been addressed. Content is accurate, well-organized, and follows the repo's semantic-line-break style.


quarto/troubleshooting.qmd (new file)

Content accuracy: Correct. All environment variable names (QUARTO_LOG_LEVEL, QUARTO_PRINT_STACK, QUARTO_DENO_V8_OPTIONS) and log file paths match the official guide. The quarto check bullet list is an accurate summary of what the command verifies.

Structure: Good. The four ### sub-sections (Checking Your Setup → Diagnostic Tools → Common Issues → Advanced Troubleshooting) follow a logical progression from basic checks to advanced topics.

Minor nits (non-blocking):

  1. Inconsistent quoting on QUARTO_PRINT_STACK (line 51 vs 58): The Unix version uses export QUARTO_PRINT_STACK=true (unquoted) while the PowerShell version uses $env:QUARTO_PRINT_STACK="true" (quoted). Neither is wrong, but quoting the Unix value (="true") would be more consistent with the QUARTO_LOG_LEVEL example above it. Fix this →

  2. "All platforms" bash fence (lines 40–44): The --log-level debug example uses a bash code fence with a comment saying "all platforms", but the bash language hint implies Unix. A neutral fence (plain ```) would be more accurate for a cross-platform command. Very minor. Fix this →

  3. sessionInfo() hint is vague (lines 101–104): The Environment Conflicts paragraph says "render a diagnostic document with sessionInfo()" but doesn't show what that looks like. Given the document's concise summary style this is fine — just noting it if a future pass wants to add a small code block.


quarto.qmd

Placement is correct — Troubleshooting is between Mermaid Diagrams and Additional Resources (lines 27–31). Blank lines before and after the include are consistent with the surrounding sections. No issues.


.github/scripts/check-bibliography-dois.R

The fix is correct. The original bug: "$BIB_FILES" in the workflow passed all paths as a single space-separated string, so commandArgs() returned it as one element and the script tried to open "file1.bib file2.bib" as a filename.

The fix (lines 332–336):

files_raw <- args[!grepl("^--", args)]
files <- unlist(strsplit(paste(files_raw, collapse = " "), "\\s+"))
files <- files[nchar(trimws(files)) > 0]

This correctly handles both cases (already-split args and single space-separated arg). One theoretical edge case: file paths with spaces would be split incorrectly, but .bib file paths in this repo won't have spaces, so this is an acceptable trade-off. The explanatory comment is helpful.

Note: As flagged in the previous Claude session, after this fix the workflow may still report failures for @book entries lacking doi fields (xie2015, wickham2023r4ds, etc.) — that's a pre-existing gap separate from this PR.


Verdict

Looks good to merge. The content is accurate, all prior review comments are addressed, and the DOI script fix is sound.

- Quote QUARTO_PRINT_STACK="true" for consistency with QUARTO_LOG_LEVEL
- Use plain code fence for cross-platform --log-level debug example

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings May 19, 2026 07:39

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

Comment on lines +332 to +336
files_raw <- args[!grepl("^--", args)]
# Handle the case where all file paths are passed as a single space-separated
# argument (e.g., via "$BIB_FILES" in a shell script)
files <- unlist(strsplit(paste(files_raw, collapse = " "), "\\s+"))
files <- files[nchar(trimws(files)) > 0]
Comment thread quarto/troubleshooting.qmd Outdated

Or pass at command line (all platforms):

```
@d-morrison

Copy link
Copy Markdown
Member

@claude address unresolved commetns

@claude

claude Bot commented May 25, 2026

Copy link
Copy Markdown
Contributor

Claude finished @d-morrison's task in 55s —— View job


Addressing unresolved review comments

  • Read files and analyze unresolved comments
  • Fix missing bash language specifier on code fence at quarto/troubleshooting.qmd:42
  • Address out-of-scope concern for check-bibliography-dois.R
  • Commit and push changes (0c66342)

Changes made

quarto/troubleshooting.qmd:42 — Added bash language specifier to the plain code fence. The block now reads ```bash for consistency with the surrounding fenced blocks.

.github/scripts/check-bibliography-dois.R — Not changed. The copilot reviewer's concern is valid from a separation-of-concerns perspective, but reverting the fix would leave CI in a broken state: before the fix, the check-bibliography-dois workflow always errored on startup (the script tried to open a space-separated list of paths as a single filename). Since the fix is small (4 lines), non-destructive, and needed for CI to pass at all, I've left it in place. If the maintainer prefers to split it out, the fix can be cherry-picked to a separate PR.

Co-authored-by: Douglas Ezra Morrison <d-morrison@users.noreply.github.com>
@d-morrison

Copy link
Copy Markdown
Member

Claude Code CLI (local session) is working on this — paws off until I'm done.

Copilot AI review requested due to automatic review settings June 17, 2026 17:23

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

Comment on lines +14 to +20
This command checks for:

- Quarto version and binary dependencies (Pandoc, Dart Sass, Deno, Typst)
- LaTeX installation (TinyTeX or system TeX)
- Python, Jupyter, and available kernels
- R, knitr, and rmarkdown versions
- Library paths and installed packages
Comment on lines +351 to +355
files_raw <- args[!grepl("^--", args)]
# Handle the case where all file paths are passed as a single space-separated
# argument (e.g., via "$BIB_FILES" in a shell script)
files <- unlist(strsplit(paste(files_raw, collapse = " "), "\\s+"))
files <- files[nchar(trimws(files)) > 0]
@d-morrison

Copy link
Copy Markdown
Member

@claude review

@claude

claude Bot commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

Claude finished @d-morrison's task in 1m 20s —— View job


Code Review

  • Read changed files and diff
  • Review quarto/troubleshooting.qmd
  • Review quarto.qmd
  • Review .github/scripts/check-bibliography-dois.R

Summary

The PR is very close to merge-ready. Two unresolved comments from the 2026-06-17 Copilot review need attention before merging; all earlier review comments have been addressed.


quarto/troubleshooting.qmd

Unresolved: attribution for the quarto check bullet list (lines 14–20)

The introduction already links to the official guide, which is good, but the bullet list at lines 16–20 enumerates specific binary names (Dart Sass, Deno, Typst, etc.) without signaling these come from the upstream source. This could become stale if Quarto changes its dependencies. A one-line note after the list would address the reviewer's concern:

See `quarto check` output and the
[official guide](https://quarto.org/docs/troubleshooting/) for the complete list.

Fix this →

Everything else looks good: structure, cross-platform syntax, log file paths, and QUARTO_PRINT_STACK="true" quoting are all correct. The bash fence on the "all platforms" --log-level debug block (line 42) was added in the previous round; it's a mild inconsistency (described as cross-platform, tagged as bash) but non-blocking.


quarto.qmd

No issues. Placement between Mermaid Diagrams and Additional Resources is correct and consistent with the rest of the file's spacing.


.github/scripts/check-bibliography-dois.R

Unresolved: space-split breaks file paths containing spaces (lines 351–355)

The current fix unconditionally splits every raw arg on whitespace:

files <- unlist(strsplit(paste(files_raw, collapse = " "), "\\s+"))

If someone passes check-bibliography-dois.R "my refs/book.bib" (a valid quoted path with a space), it will be split into "my" and "refs/book.bib" — neither of which exist. The fix is to guard the split: only split when the single argument is not itself a valid file path.

if (length(files_raw) == 1 && !file.exists(files_raw)) {
  # Single arg that isn't an existing path — treat as space-separated list
  files <- unlist(strsplit(files_raw, "\\s+"))
  files <- files[nchar(trimws(files)) > 0]
} else {
  files <- files_raw
}

Fix this →

The DOI_EXEMPT addition (lines 11–22 and 281–288) is correct and well-commented. The logic skips DOI-absent exempt entries but still validates DOIs that are present — that's the right behavior.


Verdict

Two targeted fixes needed before merge:

  1. troubleshooting.qmd — add a source attribution line after the quarto check bullet list
  2. check-bibliography-dois.R — guard the whitespace split so file paths with spaces aren't broken

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

summarize and link to quarto troubleshooting guide

3 participants