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

pages rendered, but not written to the _site #71

Open
mfortini opened this issue Apr 8, 2020 · 11 comments
Open

pages rendered, but not written to the _site #71

mfortini opened this issue Apr 8, 2020 · 11 comments
Labels
feedback waiting for feedback on the issue fixed? Issue fixed, waiting for confirmation

Comments

@mfortini
Copy link

mfortini commented Apr 8, 2020

I've been using datapage gen for a long time now, and it's always been working easily.
I've created some pages based on a YAML array. They are rendered by jekyll, but in the end they are not written to the website.
I could not find any reason. Using jekyll 4.0.0

@avillafiorita
Copy link
Owner

Hi, I have tried and have difficulties reproducing your error. I am using the .rb file in the _plugins directory and everything seems to be working fine with Jekyll 4.0.0 (page generated in _site).
Can you provide more details or sample code to try and reproduce the issue?
thanks in advance!
-a

@avillafiorita
Copy link
Owner

Sorry, I spoke too soon. I can reproduce the error. I will look into it.

@avillafiorita
Copy link
Owner

Tried again: it seems to be working now. If you still have the issue, if you let me have an example, I can try and have a look.

@avillafiorita avillafiorita added feedback waiting for feedback on the issue fixed? Issue fixed, waiting for confirmation labels Apr 16, 2020
@mfortini
Copy link
Author

mfortini commented Apr 16, 2020

Thank you for your help, the site we're working on is this https://github.com/emergenzeHack/covid19italia
there are other datapages that are rendered correctly (and thank you a lot for saving us so much time and complexity!)

if I add

-
    index_files: false
    data: cfg.issuecategories
    template: issuelist_category
    name: displayname
    dir: /categorie/

then with bundle exec jekyll serve --verbose I can see in the output:
Rendering: categorie/raccolte-fondi.html
Pre-Render Hooks: categorie/raccolte-fondi.html
Rendering Markup: categorie/raccolte-fondi.html
Rendering Layout: categorie/raccolte-fondi.html
Layout source: site

But in the final “writing” page they don’t get written to the output
I’m using jekyll 4.0.0 with ruby 2.5.0

@avillafiorita
Copy link
Owner

Hi, I had a look at the repo... it seems like it uses various plugins; I tried but I couldn't isolate the datapage generation issue. Can you provide a stripped-down example demonstrating the issue?

@jvanulde
Copy link

jvanulde commented May 7, 2020

I have a similar issue in this repo: https://github.com/OpenDRR/jekyll-info-viz

Locally, the pages get written as expected but in GitHub Pages they are not.

@JustinWoodring
Copy link

JustinWoodring commented May 7, 2020

I have exactly the same issue. I found a kind of annoying workaround though. https://github.com/Booglejr/osmwebsite

  1. Create a workflow that compiles it all in github actions and then deploys to a different branch in the repo

  2. point github pages at the compiled branch.

Here is the workflow file:

name: Build and Deploy GIT Update
on: [push]
jobs:
  build-and-deploy:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout 🛎️
        uses: actions/checkout@v2 # If you're using actions/checkout@v2 you must set persist-credentials to false in most cases for the deployment to work correctly.
        with:
          persist-credentials: false

      - name: Install and Build 🔧 # This example project is built using npm and outputs the result to the 'build' folder. Replace with the commands required to build your project, or remove this step entirely if your site is pre-built.
        run: |
          export PATH="$(ruby -r rubygems -e 'puts Gem.user_dir')/bin:$PATH"
          gem install --user-install jekyll bundler 
          bundle install
          bundle exec jekyll build --trace -V
      - name: Install SSH Client 🔑
        uses: webfactory/ssh-agent@v0.2.0
        with:
          ssh-private-key: ${{ secrets.DEPLOY_KEY }}

      - name: Deploy 🚀
        uses: JamesIves/github-pages-deploy-action@releases/v3
        with:
          SSH: true
          BRANCH: gh-pages # The branch the action should deploy to.
          FOLDER: _site # The folder the action should deploy.

@avillafiorita
Copy link
Owner

If I get it right, the issue is related to execution of datapage-generator on Github.

Github, however, allows the execution of a limited set of plugins on their websites, namely, those they trust and rightly so, since a plugin could do pretty nasty stuff. The list of allowed plugins is: https://pages.github.com/versions/.

If this is the case, there is not much I can do on the matter.

Did I get it right?

@pn11
Copy link

pn11 commented Jun 21, 2022

Hi, thanks for your information. I spent some time to find out the plugin does not work with Github Pages.
If there is that information somewhere on README together with this comment, it will help😄

@avillafiorita
Copy link
Owner

Hi, thanks for pointing out. I'll add it to the documentation!

Btw, you can still publish on Github pages even if plugins are not supported, as suggested here: https://docs.github.com/en/pages/setting-up-a-github-pages-site-with-jekyll/about-github-pages-and-jekyll#plugins

GitHub Pages cannot build sites using unsupported plugins. If you want to use unsupported plugins, generate your site locally and then push your site's static files to GitHub.

@pn11
Copy link

pn11 commented Jun 22, 2022

Thanks for your reply. I'll check that!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feedback waiting for feedback on the issue fixed? Issue fixed, waiting for confirmation
Projects
None yet
Development

No branches or pull requests

5 participants