mhanberg / mhanberg/jekyll-postcss

`postcssNode: AtRule`: failed build

Open
#34 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Ruby
Stars
70
Forks
12
PR merge metrics
No merged PRs in 30d

Description

Unsure if this is a jekyll-postcss error due to the cryptic messages I get from Jekyll but will have a go here.

Issue

Build stalls with bundle exec jekyll s -l --trace

No error is thrown; the build just stalls after Jekyll starts and throws the following code:

Configuration file: /Users/gschiavon/Documents/dev/sites.nosync/xxx/_config.yml
PostCSS Server listening on port 8124...
            Source: /Users/gschiavon/Documents/dev/sites.nosync/xxx
       Destination: /Users/gschiavon/Documents/dev/sites.nosync/xxx/_site
 Incremental build: disabled. Enable with --incremental
      Generating... 
       Jekyll Feed: Generating feed for posts
         AutoPages: Disabled/Not configured in site.config.
        Pagination: Complete, processed 9 pagination page(s)
              WebP: Processing /Users/gschiavon/Documents/dev/sites.nosync/xxxy/assets/img
              WebP: Generator Complete: 0 file(s) generated
[...]
  postcssNode: AtRule {
    raws: { before: '\n  ', between: '', afterName: ' ' },
    type: 'atrule',
    name: 'apply',
    parent: Rule {
      raws: [Object],
      type: 'rule',
      nodes: [Array],
      parent: [Root],
      source: [Object],
      selector: '.form-control',
      lastEach: 14,
      indexes: [Object],
      [Symbol(isClean)]: false,
      [Symbol(my)]: true
    },
    source: { start: [Object], input: [Input], end: [Object] },
    params: '.py-3',
    [Symbol(isClean)]: false,
    [Symbol(my)]: true
  },
  plugin: undefined
}

Upon interrupting the process, I get:


^CTraceback (most recent call last):
        44: from /Users/gschiavon/.rubies/ruby-2.7.3/bin/bundle:23:in `<main>'
        43: from /Users/gschiavon/.rubies/ruby-2.7.3/bin/bundle:23:in `load'
        42: from /Users/gschiavon/.rubies/ruby-2.7.3/lib/ruby/gems/2.7.0/gems/bundler-2.2.30/exe/bundle:37:in `<top (required)>'
        41: from /Users/gschiavon/.rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/friendly_errors.rb:103:in `with_friendly_errors'
        40: from /Users/gschiavon/.rubies/ruby-2.7.3/lib/ruby/gems/2.7.0/gems/bundler-2.2.30/exe/bundle:49:in `block in <top (required)>'
        39: from /Users/gschiavon/.rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/cli.rb:25:in `start'
        38: from /Users/gschiavon/.rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/vendor/thor/lib/thor/base.rb:485:in `start'
        37: from /Users/gschiavon/.rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/cli.rb:31:in `dispatch'
        36: from /Users/gschiavon/.rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/vendor/thor/lib/thor.rb:392:in `dispatch'
        35: from /Users/gschiavon/.rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/vendor/thor/lib/thor/invocation.rb:127:in `invoke_command'
        34: from /Users/gschiavon/.rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
        33: from /Users/gschiavon/.rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/cli.rb:478:in `exec'
        32: from /Users/gschiavon/.rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/cli/exec.rb:23:in `run'
        31: from /Users/gschiavon/.rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/cli/exec.rb:58:in `kernel_load'
        30: from /Users/gschiavon/.rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/cli/exec.rb:58:in `load'
        29: from /Users/gschiavon/.gem/ruby/2.7.3/bin/jekyll:25:in `<top (required)>'
        28: from /Users/gschiavon/.gem/ruby/2.7.3/bin/jekyll:25:in `load'
        27: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/exe/jekyll:15:in `<top (required)>'
        26: from /Users/gschiavon/.gem/ruby/2.7.3/gems/mercenary-0.4.0/lib/mercenary.rb:21:in `program'
        25: from /Users/gschiavon/.gem/ruby/2.7.3/gems/mercenary-0.4.0/lib/mercenary/program.rb:44:in `go'
        24: from /Users/gschiavon/.gem/ruby/2.7.3/gems/mercenary-0.4.0/lib/mercenary/command.rb:221:in `execute'
        23: from /Users/gschiavon/.gem/ruby/2.7.3/gems/mercenary-0.4.0/lib/mercenary/command.rb:221:in `each'
        22: from /Users/gschiavon/.gem/ruby/2.7.3/gems/mercenary-0.4.0/lib/mercenary/command.rb:221:in `block in execute'
        21: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/commands/serve.rb:86:in `block (2 levels) in init_with_program'
        20: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/command.rb:91:in `process_with_graceful_fail'
        19: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/command.rb:91:in `each'
        18: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/command.rb:91:in `block in process_with_graceful_fail'
        17: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/commands/build.rb:36:in `process'
        16: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/commands/build.rb:65:in `build'
        15: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/command.rb:28:in `process_site'
        14: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/site.rb:80:in `process'
        13: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/site.rb:211:in `render'
        12: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/site.rb:538:in `render_pages'
        11: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/site.rb:538:in `each'
        10: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/site.rb:539:in `block in render_pages'
         9: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/site.rb:547:in `render_regenerated'
         8: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/renderer.rb:63:in `run'
         7: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/renderer.rb:84:in `render_document'
         6: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/renderer.rb:104:in `convert'
         5: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/renderer.rb:104:in `reduce'
         4: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/renderer.rb:104:in `each'
         3: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-4.2.1/lib/jekyll/renderer.rb:106:in `block in convert'
         2: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-postcss-0.5.0/lib/jekyll/converters/postcss.rb:42:in `convert'
         1: from /Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-postcss-0.5.0/lib/jekyll-postcss/socket.rb:28:in `read'
/Users/gschiavon/.gem/ruby/2.7.3/gems/jekyll-postcss-0.5.0/lib/jekyll-postcss/socket.rb:28:in `gets': Interrupt
package.json
"devDependencies": {
    "autoprefixer": "^10.3.6",
    "cssnano": "^5.0.8",
    "postcss": "^8.3.10",
    "postcss-cli": "^7.1.0",
    "postcss-import": "^14.0.1",
    "purgecss": "^4.0.3",
    "tailwindcss": "^2.1.1",
    "tailwindcss-spinner": "^1.0.0",
    "@tailwindcss/typography": "^0.4.1",
    "postcss-color-function": "^4.1.0",
    "postcss-simple-vars": "^5.0.2",
    "stickyfilljs": "^2.1.0"
  },
Gemfile
source "https://rubygems.org"

gem "jekyll", "~> 4.2"
gem 'kramdown-parser-gfm', '~> 1.1'

group :jekyll_plugins do
  gem "jekyll-feed"
  gem "jekyll-sitemap"
  gem "jekyll-seo-tag"
  gem "jekyll-postcss"
  gem "jekyll-purgecss"
  gem 'jekyll-fontawesome-svg'
  gem 'jekyll-redirect-from'
  gem 'jekyll-paginate-v2'
  gem 'jekyll-webp'
end

# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
gem "tzinfo-data", platforms: [:mingw, :mswin, :x64_mingw, :jruby]

# Semantic indexing
gem 'classifier-reborn'

# Performance-booster for watching directories on Windows
gem "wdm", "~> 0.1.0" if Gem.win_platform?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing with bundle exec jekyll s -l --trace, then compare the Gemfile and package.json versions. Inspect jekyll-postcss/socket.rb at the read call shown in the traceback and determine why the PostCSS build stalls on the @apply rule. Done means the reported site builds without hanging and the failure is covered by a reproducible check.

Written by the indexing model from the issue text.

Assessment

Tech stack
jekyll, ruby, tailwindcss
Domain
build-system
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.