Skip to content

render with intermediates_dir fails with images #500

Closed

Description

@petrelharp

The pandoc call fails because the _files directory is not put in intermediates_dir, so pandoc can't find the images.

MWE:
test.Rmd:

```{r plot}
plot(1)
```

Then, calling

render("test.Rmd", intermediates_dir="temp")

fails with

# pandoc: Could not fetch test_files/figure-html/plot-1.png

This is with the github version of rmarkdown (pulled just now).

Changing the relevant line in render to

files_dir <- intermediates_loc( rmarkdown:::knitr_files_dir(basename(output_file)))

fixes it in my simple case, but might break other use cases.

Activity

  1. added
    bug
    on Oct 13, 2017
  2. added this to the v1.7 milestone on Oct 17, 2017
  3. added a commit that references this issue on Oct 24, 2017
    bb5a7fa
  4. yihui commented on Oct 24, 2017

    @yihui
    Collaborator

    Should be fixed now. Thanks for the report!

  5. github-actions commented on Nov 3, 2020

    @github-actions

    This old thread has been automatically locked. If you think you have found something related to this, please open a new issue by following the issue guide (https://yihui.org/issue/), and link to this old issue if necessary.

  6. locked as resolved and limited conversation to collaborators on Nov 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions