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

"source and transform nodes" hangs system with gatsby-source-wordpress #4666

Closed
ehibun opened this issue Mar 23, 2018 · 11 comments
Closed

"source and transform nodes" hangs system with gatsby-source-wordpress #4666

ehibun opened this issue Mar 23, 2018 · 11 comments

Comments

@ehibun
Copy link

ehibun commented Mar 23, 2018

Description

When using the WordPress source in Gatsby on a large WordPress site (6200 posts, 3196 images), the build process hangs my machine (a Late 2016 MacBook Pro running macOS 10.13.3) entirely, even if left overnight. This is probably related to #4293, except in my case the process never actually finishes.

With Activity Monitor running at the same time, it doesn't look like there's much CPU or network activity, but that might just be Activity Monitor silently crashing.

Steps to reproduce

  • Using the Gatsby blog starter, install the gatsby-source-wordpress plugin and configure it to point at a large WordPress installation, with or without hostingWPCOM enabled.
  • Replace gatsby-node.js with https://github.com/gatsbyjs/gatsby/blob/master/examples/using-wordpress/gatsby-node.js, and copy the page.js and post.js templates from that same repo.
  • Attempt to run gatsby build or gatsby develop
  • Observe that the system becomes unresponsive, and later hangs.

Expected result

Gatsby should import all WordPress posts, pages, and images successfully.

Actual result

The system hangs and does not complete the build process.

Environment

  • Gatsby version: gatsby@1.9.239
  • gatsby-cli version: 1.1.47
  • Node.js version: v9.8.0
  • Operating System: macOS High Sierra 10.13.3

File contents (if changed):

gatsby-config.js (relevant part):

    {
      resolve: 'gatsby-source-wordpress',
      options: {
        baseUrl: 'large-self-hosted-wordpress-site.com',
        protocol: 'https',
        hostingWPCOM: false,
        useACF: false,
        verboseOutput: false,
      },
    },

package.json: Identical to gatsby-starter-blog, but with "gatsby-source-wordpress": "^2.0.69", added.
gatsby-node.js: Identical to https://github.com/gatsbyjs/gatsby/blob/master/examples/using-wordpress/gatsby-node.js
gatsby-browser.js: Unchanged
gatsby-ssr.js: Unchanged

@pieh
Copy link
Contributor

pieh commented Mar 23, 2018

When it get stuck on that step after checking all wordpress endpoints it usually waits to fetch all images but currently it tries to download them all at once (so doing over 3000 request more or less at once for your images), which is not good (but soon-ish we should fix that - #4616).

@lightstrike
Copy link
Contributor

I'm having related issues with a large WordPress site.

What causes the process to hang? Where can we trigger an explicit failure?

@kellymears
Copy link

i'm also getting this error.

additional info: my site is running in a wordpress network configuration, and it hangs whether i query a fresh site or a large one. don't know if multisite is compatible..

@pieh
Copy link
Contributor

pieh commented Aug 30, 2018

I'll close this as duplicate of #6654 - that issue has reproduction repository

@r1q
Copy link

r1q commented Sep 3, 2019

I know its closed but In my case when i tried all solutions and nothing seems to fix it .. the only thing that worked was:

Resizing the Terminal window !! when it gets stuck.

@lucashfreitas
Copy link

lucashfreitas commented Sep 8, 2019

Same here @r1q. I just resized my termina window and it worked.

@michelegera
Copy link

OMG, it actually worked 😳

@cyrusdavid
Copy link

Resizing the terminal window worked for me as well 🤯

@stldo
Copy link

stldo commented Sep 19, 2019

Resizing the terminal window worked here too.

@kangarang
Copy link

oh my goodness, i can't believe this actually worked

@edsu
Copy link

edsu commented Jul 29, 2021

This is probably the weirdest solution I've seen to a problem ever. What could the cause be?

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

No branches or pull requests