Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[R][Docs] RMarkdown error in vignettes/arrow.Rmd #40535

Closed
kou opened this issue Mar 14, 2024 · 7 comments
Closed

[R][Docs] RMarkdown error in vignettes/arrow.Rmd #40535

kou opened this issue Mar 14, 2024 · 7 comments

Comments

@kou
Copy link
Member

kou commented Mar 14, 2024

Describe the bug, including details regarding any error messages, version, and platform.

https://github.com/apache/arrow/actions/runs/8272294958/job/22633854105#step:7:13544

Reading 'vignettes/arrow.Rmd'
-- RMarkdown error -------------------------------------------------------------

Quitting from lines 192-195 [unnamed-chunk-14] (arrow.Rmd)
Warning message:
The vignette title specified in \VignetteIndexEntry{} is different from the title in the YAML metadata. The former is "", and the latter is "Get started with Arrow". If that is intentional, you may set options(rmarkdown.html_vignette.check_title = FALSE) to suppress this check. 
--------------------------------------------------------------------------------
---
Standard error:
Attaching package: 'arrow'

The following object is masked from 'package:utils':

    timestamp

Warning message:
In process_conditional_examples(x) :
  @examplesIf condition `arrow_with_dataset() && identical(Sys.getenv("NOT_CRAN"), "true")` is FALSE
---
Backtrace:
1. pkgdown::build_site(install = FALSE)
2. pkgdown:::build_site_external(pkg = pkg, examples = examples, run_dont_run = run_d...
3. callr::r(function(..., cli_colors, pkgdown_internet) { ...
4. callr:::get_result(output = out, options)
5. callr:::throw(callr_remote_error(remerr, output), parent = fix_msg(remerr[[3]]))
---
Subprocess backtrace:
 1. pkgdown::build_site(...)
 2. pkgdown:::build_site_local(pkg = pkg, examples = examples, run_dont_run = run_dont...
 3. pkgdown::build_articles(pkg, lazy = lazy, override = override, preview = FALSE)
 4. purrr::walk(pkg$vignettes$name, build_article, pkg = pkg, quiet = quiet,...
 5. purrr::map(.x, .f, ..., .progress = .progress)
 6. purrr:::map_("list", .x, .f, ..., .progress = .progress)
 7. purrr:::with_indexed_errors(i = i, names = names, error_call = .purrr_error_call...
 8. base::withCallingHandlers(expr, error = function(cnd) { ...
 9. purrr:::call_with_cleanup(map_impl, environment(), .type, .progress, ...
10. local .f(.x[[i]], ...)
11. pkgdown:::render_rmarkdown(pkg, input = input, output = output_file, output_format...
12. base::tryCatch(callr::r_safe(function(...) rmarkdown::render(...), ...
13. base::tryCatchList(expr, classes, parentenv, handlers)
14. base::tryCatchOne(expr, names, parentenv, handlers[[1L]])
15. value[[3L]](cond)
16. rlang::abort("Failed to render RMarkdown", parent = cnd)
17. | rlang:::signal_abort(cnd, .file)
18. | base::signalCondition(cnd)
19. (function (cnd) ...
20. cli::cli_abort(message, location = i, name = name, parent = cnd, ...
21. | rlang::abort(message, ..., call = call, use_cli_format = TRUE, ...
22. | rlang:::signal_abort(cnd, .file)
23. | base::signalCondition(cnd)
24. global (function (e) ...
Execution halted

Component(s)

Documentation, R

@thisisnic
Copy link
Member

Looks like a failure to install pyarrow on that job for some reason; I've kicked off another run at https://github.com/apache/arrow/actions/runs/8272294958 to double check it's not random failure, will investigate more if that fails.

@thisisnic
Copy link
Member

Hmm, weird, it failed again. There hasn't been a new version of the reticulate package (which is failing to find pyarrow), so that isn't it.

@raulcd
Copy link
Member

raulcd commented Mar 14, 2024

It might be related to: #40455
@kou do we require to enable the virtualenv here?
I see there was a change on the Dockerfile:

#8 [3/5] RUN python3 -m venv /arrow-dev &&     . /arrow-dev/bin/activate &&     pip install -U pip setuptools wheel &&     pip install       -r arrow/python/requirements-build.txt       -r arrow/python/requirements-test.txt

@raulcd
Copy link
Member

raulcd commented Mar 14, 2024

I am not familiar with reticulate but we might require to update where to find pyarrow due to the new virtualenv installation:
https://rstudio.github.io/reticulate/articles/versions.html#providing-hints

@amoeba
Copy link
Member

amoeba commented Mar 14, 2024

It would be nice to be able to keep that vignette (arrow.Rmd) unchanged here so taking advantage of reticulate's RETICULATE_PYTHON_ENV env var makes sense. So I think if we set it based on whatever's in ARROW_PYTHON_VENV, it should get picked up. It looks like setting that on the ubuntu-docs job definition would be enough for it to get picked up.

raulcd added a commit to raulcd/arrow that referenced this issue Mar 15, 2024
kou added a commit that referenced this issue Mar 16, 2024
#40571)

### Rationale for this change

With the changes in #40455 reticulate can't find pyarrow.

### What changes are included in this PR?

Set `RETICULATE_PYTHON_ENV` to `ARROW_PYTHON_VENV`.
See https://rstudio.github.io/reticulate/articles/versions.html#order-of-discovery why we can use `RETICULATE_PYTHON_ENV`.

This also simplifies the current configurations:
* Install Meson by `apt-get`.
* Use `ARROW_PYTHON_VENV` to install Sphinx and related packages.

### Are these changes tested?

Via archery.

### Are there any user-facing changes?

No
* GitHub Issue: #40535

Lead-authored-by: Raúl Cumplido <[email protected]>
Co-authored-by: Sutou Kouhei <[email protected]>
Signed-off-by: Sutou Kouhei <[email protected]>
@kou
Copy link
Member Author

kou commented Mar 16, 2024

Issue resolved by pull request 40571
#40571

@kou kou added this to the 16.0.0 milestone Mar 16, 2024
@kou kou closed this as completed Mar 16, 2024
@amoeba
Copy link
Member

amoeba commented Mar 16, 2024

Thanks @raulcd and @kou.

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

No branches or pull requests

4 participants