Skip to content

Error: Unknown tag 'toc' #1438

@DriesSmit

Description

@DriesSmit

Acknowledge the following

  • I carefully read and followed the Getting Started guide.
  • I read through FAQ and searched through the past issues, none of which addressed my issue.
  • The issue I am raising is a potential bug in al-folio and not just a usage question.
    [For usage questions, please post in the Discussions instead of raising an issue.]

Describe the bug
I forked the repo as instructed. But the build then fails with the following message:

Warning:  github-pages can't satisfy your Gemfile's dependencies.
  Logging at level: debug
Configuration file: /github/workspace/./_config.yml
      GitHub Pages: github-pages v228
      GitHub Pages: jekyll v3.9.3
             Theme: jekyll-theme-primer
      Theme source: /usr/local/bundle/gems/jekyll-theme-primer-0.6.0
         Requiring: jekyll-github-metadata
To use retry middleware with Faraday v2.0+, install `faraday-retry` gem
  Liquid Exception: Liquid syntax error (line 42): Unknown tag 'toc' in /_layouts/post.html
/usr/local/bundle/gems/liquid-4.0.4/lib/liquid/block.rb:38:in `unknown_tag': Liquid syntax error (line 42): Unknown tag 'toc' (Liquid::SyntaxError)
	from /usr/local/bundle/gems/liquid-4.0.4/lib/liquid/tags/if.rb:38:in `unknown_tag'
	from /usr/local/bundle/gems/liquid-4.0.4/lib/liquid/block.rb:68:in `block in parse_body'
	from /usr/local/bundle/gems/liquid-4.0.4/lib/liquid/block_body.rb:32:in `parse'
	from /usr/local/bundle/gems/liquid-4.0.4/lib/liquid/block.rb:58:in `parse_body'
	from /usr/local/bundle/gems/liquid-4.0.4/lib/liquid/tags/if.rb:30:in `parse'
	from /usr/local/bundle/gems/liquid-4.0.4/lib/liquid/tag.rb:10:in `parse'
	from /usr/local/bundle/gems/liquid-4.0.4/lib/liquid/block_body.rb:34:in `parse'
	from /usr/local/bundle/gems/liquid-4.0.4/lib/liquid/document.rb:10:in `parse'
	from /usr/local/bundle/gems/liquid-4.0.4/lib/liquid/document.rb:5:in `parse'
	from /usr/local/bundle/gems/liquid-4.0.4/lib/liquid/template.rb:130:in `parse'
	from /usr/local/bundle/gems/liquid-4.0.4/lib/liquid/template.rb:[11](https://github.com/DriesSmit/DriesSmit.github.io/actions/runs/5031144714/jobs/9024025334#step:4:12)4:in `parse'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/liquid_renderer/file.rb:13:in `block in parse'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/liquid_renderer/file.rb:49:in `measure_time'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/liquid_renderer/file.rb:[12](https://github.com/DriesSmit/DriesSmit.github.io/actions/runs/5031144714/jobs/9024025334#step:4:13):in `parse'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/renderer.rb:121:in `render_liquid'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/renderer.rb:195:in `render_layout'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/renderer.rb:158:in `place_in_layouts'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/renderer.rb:88:in `render_document'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/renderer.rb:62:in `run'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/site.rb:479:in `render_regenerated'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/site.rb:464:in `block (2 levels) in render_docs'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/site.rb:463:in `each'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/site.rb:463:in `block in render_docs'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/site.rb:462:in `each_value'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/site.rb:462:in `render_docs'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/site.rb:191:in `render'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/site.rb:71:in `process'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/command.rb:28:in `process_site'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/commands/build.rb:65:in `build'
	from /usr/local/bundle/gems/jekyll-3.9.3/lib/jekyll/commands/build.rb:36:in `process'
	from /usr/local/bundle/gems/github-pages-228/bin/github-pages:70:in `block (3 levels) in <top (required)>'
	from /usr/local/bundle/gems/mercenary-0.3.6/lib/mercenary/command.rb:220:in `block in execute'
	from /usr/local/bundle/gems/mercenary-0.3.6/lib/mercenary/command.rb:220:in `each'
	from /usr/local/bundle/gems/mercenary-0.3.6/lib/mercenary/command.rb:220:in `execute'
	from /usr/local/bundle/gems/mercenary-0.3.6/lib/mercenary/program.rb:42:in `go'
	from /usr/local/bundle/gems/mercenary-0.3.6/lib/mercenary.rb:19:in `program'
	from /usr/local/bundle/gems/github-pages-228/bin/github-pages:6:in `<top (required)>'
	from /usr/local/bundle/bin/github-pages:23:in `load'
	from /usr/local/bundle/bin/github-pages:23:in `<main>'
         Requiring: jekyll-seo-tag
         Requiring: jekyll-feed
         Requiring: jekyll-sitemap
         Requiring: jemoji
         Requiring: jekyll-coffeescript
         Requiring: jekyll-commonmark-ghpages
         Requiring: jekyll-gist
         Requiring: jekyll-github-metadata
         Requiring: jekyll-paginate
         Requiring: jekyll-relative-links
         Requiring: jekyll-optional-front-matter
         Requiring: jekyll-readme-index
         Requiring: jekyll-default-layout
         Requiring: jekyll-titles-from-headings
   GitHub Metadata: Initializing...
            Source: /github/workspace/.
       Destination: /github/workspace/./_site
 Incremental build: disabled. Enable with --incremental
      Generating... 
       EntryFilter: excluded /bin
       EntryFilter: excluded /Gemfile
           Reading: _posts/2022-12-10-giscus-comments.md
           Reading: _posts/2023-04-24-videos.md
           Reading: _posts/2015-07-15-code.md
           Reading: _posts/2023-04-25-audios.md
           Reading: _posts/2015-03-15-formatting-and-links.md
           Reading: _posts/2021-07-04-diagrams.md
           Reading: _posts/2023-03-21-tables.md
           Reading: _posts/2020-09-28-twitter.md
           Reading: _posts/2015-05-15-images.md
           Reading: _posts/2022-02-01-redirect.md
           Reading: _posts/2018-12-22-distill.md
           Reading: _posts/2023-04-25-sidebar-table-of-contents.md
           Reading: _posts/2023-05-12-custom-blockquotes.md
           Reading: _posts/2015-10-20-disqus-comments.md
           Reading: _posts/2015-10-20-math.md
           Reading: _posts/2020-09-28-github-metadata.md
           Reading: _posts/2023-03-20-table-of-contents.md
           Reading: _news/announcement_1.md
           Reading: _news/announcement_3.md
           Reading: _news/announcement_2.md
           Reading: _projects/2_project.md
           Reading: _projects/4_project.md
           Reading: _projects/1_project.md
           Reading: _projects/3_project.md
           Reading: _projects/6_project.md
           Reading: _projects/5_project.md
        Generating: JekyllOptionalFrontMatter::Generator finished in 0.000254303 seconds.
        Generating: JekyllReadmeIndex::Generator finished in 0.0014189[13](https://github.com/DriesSmit/DriesSmit.github.io/actions/runs/5031144714/jobs/9024025334#step:4:14) seconds.
       Jekyll Feed: Generating feed for posts
        Generating: JekyllFeed::Generator finished in 0.000706406 seconds.
        Generating: Jekyll::JekyllSitemap finished in 0.00101051 seconds.
        Generating: Jekyll::Paginate::Pagination finished in 6.2e-06 seconds.
        Generating: JekyllRelativeLinks::Generator finished in 0.000563406 seconds.
        Generating: JekyllDefaultLayout::Generator finished in 0.000363103 seconds.
        Generating: JekyllTitlesFromHeadings::Generator finished in 2.3101e-05 seconds.
         Rendering: _posts/20[15](https://github.com/DriesSmit/DriesSmit.github.io/actions/runs/5031144714/jobs/9024025334#step:4:16)-03-15-formatting-and-links.md
  Pre-Render Hooks: _posts/[20](https://github.com/DriesSmit/DriesSmit.github.io/actions/runs/5031144714/jobs/9024025334#step:4:21)15-03-15-formatting-and-links.md
  Rendering Markup: _posts/2015-03-15-formatting-and-links.md
         Requiring: kramdown-parser-gfm
  Rendering Layout: _posts/2015-03-15-formatting-and-links.md
     Layout source: site
github-pages [22](https://github.com/DriesSmit/DriesSmit.github.io/actions/runs/5031144714/jobs/9024025334#step:4:23)8 | Error:  Liquid syntax error (line [42](https://github.com/DriesSmit/DriesSmit.github.io/actions/runs/5031144714/jobs/9024025334#step:4:43)): Unknown tag 'toc'

I tried the other solutions where I first set the branch in Pages to None. However it still fails to build. What is the recommended thnk to do here? Thank you for your time.

To Reproduce
I forked the repo and I am using an Ubuntu machine.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions