Skip to content

error building site didn't fail Travis #520

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

Closed
SethTisue opened this issue Nov 10, 2016 · 9 comments
Closed

error building site didn't fail Travis #520

SethTisue opened this issue Nov 10, 2016 · 9 comments
Assignees
Labels

Comments

@SethTisue
Copy link
Member

SethTisue commented Nov 10, 2016

see #516 for details

why didn't Jekyll give a nonzero exit code here?

also, 748c635 was reverted, should be redone (#525)

@jarrodu
Copy link
Member

jarrodu commented Nov 10, 2016

Any word on Travis? I find it really strange that it did not catch it.

@SethTisue
Copy link
Member Author

I haven't had time to investigate.

@SethTisue
Copy link
Member Author

problem is reproducible locally with:

% bundle exec jekyll build && echo success
Configuration file: /Users/tisue/scala-lang/_config.yml
            Source: /Users/tisue/scala-lang
       Destination: /Users/tisue/scala-lang/_site
 Incremental build: disabled. Enable with --incremental
      Generating... 
Error reading file /Users/tisue/scala-lang/download/index.md: (<unknown>): did not find expected ',' or ']' while parsing a flow sequence at line 7 column 17 
                    done in 7.807 seconds.
 Auto-regeneration: disabled. Use --watch to enable.
success

@SethTisue
Copy link
Member Author

SethTisue commented Nov 12, 2016

I had thought maybe adding this to _config.yml might help:

liquid:
  error_mode: strict

but it didn't.

@SethTisue SethTisue added the bug label Nov 12, 2016
@ashawley
Copy link
Member

I ran across jekyll/jekyll#5257

Apparently,

We only throw on fatal errors and the inability to process a file is not fatal to us so we processed what we could and gave you the error so that you could fix it.

Scrolling further, it seems it might be a flaw in Jekyll and Ruby and not really a design decision:

We made the decision here some years ago (maybe even before I joined?) to warn here. We have never failed loudly here. I shudder to think how many tickets we would receive because "all of a sudden my site didn't build OH NOES!" In certain cases, failing gracefully is the right thing to do. [...]

I would be up for raising an error here. Unfortunately we don't have a mechanism for raising an error but continuing the process of building the rest of the site and still returning a 1 exit code. If we fail at all, we'll have to fail mid-build.

@SethTisue
Copy link
Member Author

perhaps we will have to capture and inspect Jekyll's output

@charafau
Copy link

I havent used it personally but on jekyll's docs mention html-proofer for checks. Maybe we can give it a try ?

@SethTisue
Copy link
Member Author

re: html-proofer, that's #535 now

@SethTisue
Copy link
Member Author

fixed by #537

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants