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

Trigger_Refetch_All not working. #33260

Closed
2 tasks done
psharma-ii opened this issue Sep 20, 2021 · 2 comments · Fixed by #33264
Closed
2 tasks done

Trigger_Refetch_All not working. #33260

psharma-ii opened this issue Sep 20, 2021 · 2 comments · Fixed by #33264
Labels
topic: source-wordpress Related to Gatsby's integration with WordPress type: bug An issue or pull request relating to a bug in Gatsby

Comments

@psharma-ii
Copy link
Contributor

Preliminary Checks

Description

I had created following issue on wp-gatsby, but after talking with @TylerBarnes, the issue should be opened here.

We had discussed about a syncing issue with a plugin and you had asked me to use trigger_refetch_all which is also used by permalink_structure changes. The function didn't work (implementation example below). I also tested permalink structure change, which also didn't seemed to do any rebuilds. When i started digging around the gatsby-source-wordpress plugin, I noticed 2 things and I am not sure if they are the cause or I am completely looking into the wrong place. #1) There is no conditional for REFETCH_ALL here which probably is okay. #2) Also, noticed the conditional here was evaluating to false for REFETCH_ALL and never hitting this.

@TylerBarnes had suggested a fix, so I will be checking that out and see if I can do a PR

Reproduction Link

https://gatsby.dev/reproduction

Steps to Reproduce

  1. Setup wordpresss locally
  2. Add WP GRAPHQL, WP Gatsby Plugin
  3. Install GatsbyJS and gatsby-source-wordpress plugin
  4. Add some post in WP
  5. Run gatsby build && gatsby serve
  6. Do a permalink structure change.
    1. Run gatsby build && gatsby serve
  7. The change to permalink structure is not reflected.

...

Expected Result

Permalink structure change should reflect on Gatsby

Actual Result

Permalink structure change should reflect on Gatsby

Environment

System:
    OS: macOS 10.15.7
    CPU: (12) x64 Intel(R) Core(TM) i7-9750H CPU @ 2.60GHz
    Shell: 5.7.1 - /bin/zsh
  Binaries:
    Node: 12.18.0 - ~/.asdf/installs/nodejs/12.18.0/bin/node
    Yarn: 1.22.11 - /usr/local/bin/yarn
    npm: 7.16.0 - ~/.asdf/installs/nodejs/12.18.0/.npm/bin/npm
  Languages:
    Python: 2.7.16 - /usr/bin/python
  Browsers:
    Chrome: 93.0.4577.82
    Firefox: 92.0
    Safari: 14.1.2
  npmPackages:
    gatsby: ^3.10.2 => 3.10.2
    gatsby-plugin-gatsby-cloud: ^2.10.1 => 2.10.1
    gatsby-plugin-image: ^1.10.1 => 1.10.1
    gatsby-plugin-manifest: ^3.10.0 => 3.10.0
    gatsby-plugin-meta-redirect: ^1.1.1 => 1.1.1
    gatsby-plugin-offline: ^4.10.0 => 4.10.0
    gatsby-plugin-postcss: ^4.10.0 => 4.10.0
    gatsby-plugin-react-helmet: ^4.10.0 => 4.10.0
    gatsby-plugin-react-helmet-canonical-urls: ^1.4.0 => 1.4.0
    gatsby-plugin-robots-txt: ^1.6.8 => 1.6.8
    gatsby-plugin-sass: ^4.10.0 => 4.10.0
    gatsby-plugin-sharp: ^3.10.2 => 3.10.2
    gatsby-plugin-sitemap: ^4.6.0 => 4.6.0
    gatsby-plugin-styled-components: ^4.10.0 => 4.10.0
    gatsby-source-filesystem: ^3.10.0 => 3.10.0
    gatsby-source-wordpress: ^5.10.0 => 5.14.0-next.4
    gatsby-transformer-sharp: ^3.10.0 => 3.10.0
  npmGlobalPackages:
    gatsby-cli: 3.7.1

Config Flags

No response

@psharma-ii psharma-ii added the type: bug An issue or pull request relating to a bug in Gatsby label Sep 20, 2021
@gatsbot gatsbot bot added the status: triage needed Issue or pull request that need to be triaged and assigned to a reviewer label Sep 20, 2021
@TylerBarnes TylerBarnes added topic: source-wordpress Related to Gatsby's integration with WordPress and removed status: triage needed Issue or pull request that need to be triaged and assigned to a reviewer labels Sep 20, 2021
@github-actions
Copy link

Hiya!

This issue has gone quiet. Spooky quiet. 👻

We get a lot of issues, so we currently close issues after 60 days of inactivity. It’s been at least 20 days since the last update here.
If we missed this issue or if you want to keep it open, please reply here.
As a friendly reminder: the best way to see this issue, or any other, fixed is to open a Pull Request. Check out gatsby.dev/contribute for more information about opening PRs, triaging issues, and contributing!

Thanks for being a part of the Gatsby community! 💪💜

@github-actions github-actions bot added the stale? Issue that may be closed soon due to the original author not responding any more. label Oct 11, 2021
@psharma-ii
Copy link
Contributor Author

The PR is still open for this -#33264

@github-actions github-actions bot removed the stale? Issue that may be closed soon due to the original author not responding any more. label Oct 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: source-wordpress Related to Gatsby's integration with WordPress type: bug An issue or pull request relating to a bug in Gatsby
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants