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

forward code-summary to ojs cells #7804

Merged
merged 4 commits into from
Dec 6, 2023
Merged

forward code-summary to ojs cells #7804

merged 4 commits into from
Dec 6, 2023

Conversation

cscheid
Copy link
Collaborator

@cscheid cscheid commented Dec 5, 2023

Closes #4927

@cscheid
Copy link
Collaborator Author

cscheid commented Dec 5, 2023

@cderv sorry to tag you here, but I'm pretty confused about why my test passes locally but fails here. Could this have something to do with the recent ojs code cell changes that just happened on knitr?

@cderv
Copy link
Collaborator

cderv commented Dec 6, 2023

Could this have something to do with the recent ojs code cell changes that just happened on knitr?

Yes exactly. @yihui did the change in dev version and we are testing against it. You can also install it locally. When you update configuration for test, it should do it by the way

echo " > Restoring renv project"
Rscript -e 'renv::restore()'
echo " > Installing dev knitr and rmarkdown"
Rscript -e "install.packages('rmarkdown', repos = c('https://rstudio.r-universe.dev'))"
Rscript -e "install.packages('knitr', repos = c('https://yihui.r-universe.dev'))"

#7799 is the solution here. We were missing the command for knitr to account for the content, but by adding them, we need to correctly account for the fact that now knitr is parsing the YAML part, and it needs to be added back. It wasn't before my PR

knitr::knit_engines$set(ojs = function(options) {
knitr:::one_string(c(
"```{ojs}",
options$yaml.code,
options$code,
"```"
))
})

Before

knitr::knit_engines$set(ojs = function(options) {
knitr:::one_string(c(
"```{ojs}",
options$code,
"```"
))
})

See yaml.code part.

So dev knitr is not working / compatible with Quarto 1.3 - only with current main as I merged #7799

If you rebase, the test should pass.

@cscheid
Copy link
Collaborator Author

cscheid commented Dec 6, 2023

Hm.. I did merge against main before testing this, though!

@cderv
Copy link
Collaborator

cderv commented Dec 6, 2023

Hm.. I did merge against main before testing this, though!

I merged today - not yesterday. When CI ran for this PR, the change of #7799 were not in main.

You should try rebase on main and see - I think this will pass.

@cscheid cscheid merged commit 29be6f2 into main Dec 6, 2023
6 checks passed
@cscheid cscheid deleted the bugfix/4927 branch December 6, 2023 16:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

code-summary for ojs chunks not working
2 participants