-
Notifications
You must be signed in to change notification settings - Fork 11.2k
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
jekyll 3.9.0 | Error: tried to create Proc object without a block #161
Comments
recloned and tried again to try to follow the whole issue. When I bundle install, there is an issue with conflicting expectations for the Jekyll version from Once I take care of the conflict by picking a Jekyll version and commenting out GitHub Pages, bundle install works. However, If I update the Gemfile to specify a Jekyll version, comment out the GitHub-pages, and add the webrick gem, I can get it to work. I don't really know why, though. Gemfile
|
It looks like your ruby version 3.0.0 is too recent. I'm able to reproduce the error with ruby 3.0.0, but it works just fine with 2.6.5. I suggest installing a different version. You can manage multiple ruby environments using rbenv. |
Just wanted to mention, I am also facing the same issue. |
@adib2149, please use ruby version 2.x instead of 3 for now. Some of the gems do not support ruby 3 as it came out just recently. I'll look into supporting ruby 3 once things stabilize later this year. |
Sounds good. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
I was getting the same issue. For anyone getting here and realizing this means they finally need to look into what RVM is, this is what I ran to use the earlier ruby version, in case it's helpful. First, install RVM: rvm install 2.7.2 && rvm use 2.7.2 (you can always check with I found that I also needed to add a line in my Gemfile to specify the jekyll version, because something in jekyll v3.8 and higher seems to be incompatible with jekyll-scholar. Downgrading like this solved my issue: group :jekyll_plugins do
# ....
gem 'jekyll', '3.7.3' # <-- this line
# ....
end Then I re-ran bundle install With Ruby v2.7.2 and jekyll v3.7.3, I did not run into the issue anymore. |
If you don't use RVM or you just want to use ruby3 for any other reason, my changes to the gemfile did make it work for me. It might work for you that way as well. |
@monkeywithacupcake, good point, it looks like ruby3 could work if you remove |
Following advice here: alshedivat/al-folio#161
Hey guys, 2 years later this is still an issue. Was it ever fixed? Using ruby 3.0, jekyll-scholar does not work. Kind regards EDIT: Finally got to the bottom of it, thanks to the responses above. One can not use Instead one should remove Then one will see some render errors, if the .md files do not have front matter in them, at minimum: "--- At the top of the file should be included. Then in your _layouts folder, you probably have a default.html defined. Inside of the front matter of md files write: "--- Now you get github pages rendering, thanks github-metadata and you get jekyll-scholar working and everything is great! Now you can use ruby 3.0 too! Took me two hours, hopefully saves someone 2 hours in the future finding this. Kind regards |
Or you could update your code to the latest version of the template. As you can see here it builds the site using ruby 3.2.2. |
Acknowledge the following
[For usage questions, please use gitter chat instead of raising an issue.]
Describe the bug
A clear and concise description of what the bug is.
cloned repo does not compile
To Reproduce
Steps to reproduce the behavior:
Expected behavior
A clear and concise description of what you expected to happen.
should serve the default site on localhost
Screenshots
If applicable, add screenshots to help explain your problem.
System (please complete the following information):
Additional context
Add any other context about the problem here.
I can serve other Jekyll sites
Problem appears to be partially due to biblography.rb call to
&Proc.new
but I cannot confirm. Commenting out offending code just moved the problem somewhere else.The text was updated successfully, but these errors were encountered: