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

Workshop Overview Pages (without episodes) should be allowed #118

Closed
zkamvar opened this issue Apr 11, 2023 · 2 comments · Fixed by #132
Closed

Workshop Overview Pages (without episodes) should be allowed #118

zkamvar opened this issue Apr 11, 2023 · 2 comments · Fixed by #132
Labels
wontfix This will not be worked on

Comments

@zkamvar
Copy link
Contributor

zkamvar commented Apr 11, 2023

We have a situation where we have workshop overview pages for datacarpentry and library carpentry (e.g. https://datacarpentry.org/genomics-workshop/) that do not have any episodes.

Reprex

pegboard::get_lesson("datacarpentry/genomics-workshop")
#> Loading required namespace: gert
#> Error: The _episodes/ directory must have (R)markdown files

Created on 2023-08-08 with reprex v2.0.2

Note: this works for one workshop overview page because it has episodes:

pegboard::get_lesson("LibraryCarpentry/lc-overview")
#> Loading required namespace: gert
#> <Lesson>
#>   Public:
#>     blocks: function (type = NULL, level = 0, path = FALSE) 
#>     built: NULL
#>     challenges: function (path = FALSE, graph = FALSE, recurse = TRUE) 
#>     clone: function (deep = FALSE) 
#>     episodes: list
#>     extra: NULL
#>     files: active binding
#>     get: function (element = NULL, collection = "episodes") 
#>     handout: function (path = NULL, solution = FALSE) 
#>     initialize: function (path = ".", rmd = FALSE, jekyll = TRUE, ...) 
#>     isolate_blocks: function () 
#>     load_built: function () 
#>     n_problems: active binding
#>     path: /tmp/Rtmpk8ln7F/LibraryCarpentry--lc-overview
#>     reset: function () 
#>     rmd: FALSE
#>     sandpaper: FALSE
#>     show_problems: active binding
#>     solutions: function (path = FALSE) 
#>     summary: function (collection = "episodes") 
#>     thin: function (verbose = TRUE) 
#>     validate_divs: function () 
#>     validate_headings: function (verbose = TRUE) 
#>     validate_links: function () 
#>   Private:
#>     deep_clone: function (name, value)

Created on 2023-08-08 with reprex v2.0.2

Diagnosis

Currently, these fail here:

} else if (md_exists && md_n == 0L) {
stop(glue::glue("The _episodes/ directory must have (R)markdown files"),
call. = FALSE
)
} else {

If we can change this to a warning, then it should be okay.

This will help address carpentries/lesson-transition#83, carpentries/lesson-transition#84, carpentries/lesson-transition#85, carpentries/lesson-transition#86, and carpentries/lesson-transition#27

@zkamvar
Copy link
Contributor Author

zkamvar commented Apr 11, 2023

I'm going to think a bit more about this because {sandpaper} doesn't like lessons without episodes.

@zkamvar zkamvar added the wontfix This will not be worked on label Apr 11, 2023
@zkamvar zkamvar closed this as completed Apr 11, 2023
@zkamvar zkamvar reopened this Aug 8, 2023
@zkamvar
Copy link
Contributor Author

zkamvar commented Aug 8, 2023

Note: Workbench-wide details can be found at carpentries/workbench#65

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
wontfix This will not be worked on
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant