• Resolved asafm7

    (@asafm7)


    Hi,

    On the plugin settings, after entering API key successfully, when I click “Get latest kit data” I get this error:

    “Failed to fetch kits”

    On DevTools console I see:

    reportRequestError.js:134 Font Awesome WordPress Plugin Error Report
    reportRequestError.js:145 WARNING: The last response from your WordPress server did not include the confirmation header that should be in all valid Font Awesome responses. This is a clue that some code from another theme or plugin is acting badly and causing the wrong headers to be sent.
    reportRequestError.js:149 WARNING: Invalid Data Trimmed from Server Response

    But I tried disabling all other plugins and reverting to stock Storefront and it still didn’t work.

    Please help.

    Thanks,
    Asaf

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author mlwilkerson

    (@mlwilkerson)

    Hello, thanks for the report.

    I see the there’s a console message indicating that some invalid data was trimmed from the server response, but then there’s no additional data shown in what you posted. Was the console blank after this?

    reportRequestError.js:149 WARNING: Invalid Data Trimmed from Server Response

    If there is some other output there, it may yield another clue as to what is causing the problem.

    Another thing to check would be (if you’re on a recent version of WordPress), in admin, go to Tools->Site Health.

    This will run diagnostics on your WordPress server’s REST API service, and may provide some additional information about what is causing it not to work.

    Thread Starter asafm7

    (@asafm7)

    Thanks for your reply,

    Attached are 2 screenshots with all the data I have:

    https://snipboard.io/etYfob.jpg
    https://snipboard.io/H9NgKV.jpg

    The SIte Health test didn’t find anything relevant.

    BTW, is there a benefit using the plugin over manually linking the kit script?

    Thanks,
    Asaf

    Plugin Author mlwilkerson

    (@mlwilkerson)

    That second screenshot shows something more like what I was expecting to see. It’s HTML output that seems to be trying to show an HTTP 403 Forbidden response.

    Whatever code is causing that kind of response to be emitted will end up breaking any other theme or plugins that try to make the same kinds of REST API requests that this plugin is making. So, yes, you could work around this problem by not using this plugin, but you might just find that you run into the same problem with a different theme or plugin later on.

    When I load your website and look at the page source, I notice that LiteSpeed Cache is involved, which makes me wonder what else may be sitting in front of your WordPress site that might limit what requests are passed through to your WordPress site. For example, LiteSpeed itself, or some Web Application Firewall or CDN, might have policies set to block requests like this one. If so, then their policies are tuned too aggressively. (Even so, it shouldn’t be returning a response in HTML format like this, but that’s a side issue). It could also be that the web server itself is configured to block such requests.

    So my best guess at the moment is that your web hosting configuration (such as in a Web Application Firewall or the web server hosting your WordPress site) is set up to disallow POST requests altogether, or to disallow POST requests for URLs like this:
    https://simply-hobbies.com/wp-json/font-awesome/v1/api

    That’s the URL shown in your first screen shot to which a POST request is failing.

    If there is such a policy somewhere it should be changed to allow this case.

    There are a few other REST API routes where this plugin uses POST, so it would be best to allow POST requests to any URL that matches this:
    https://simply-hobbies.com/wp-json/font-awesome/

    As for your question about the benefit of using this plugin versus manually linking a kit script: yes there are benefits, but if they don’t apply to your situation now, and they’re not likely to apply to you in the future either, then it might be a fine solution for you.

    The main additional benefit that is most likely to apply to you: this plugin helps to scan, detect, and resolve conflicts with other versions of Font Awesome loaded by other plugins or your theme–a very common problem for WordPress sites

    It also provides some API services for other themes or plugins to hook into to provide a better, more feature-rich, and conflict-free Font Awesome experience, but that’s less likely to apply to you at this time.

    If you know how to manually add the kit script, and you want to do that, go for it. You could also consult [our documentation on customizing WordPress](https://fontawesome.com/how-to-use/customizing-wordpress/intro/getting-started) for help with that.

    Thread Starter asafm7

    (@asafm7)

    Thank you for the fast and detailed response.

    I will try to dig in further to find the culprit

    Hi, I’m currently experiencing the same issue on over 80 websites each using different plugins. They all started acting up at the same time today and are spread across several hosts. I have activated debug mode but i’m not getting any extra info in the console.

    Any chance you have been able to fix this yet?

    Plugin Author mlwilkerson

    (@mlwilkerson)

    @dhokerbuldit I’d be glad to take a closer look at this, but could you open a different forum topic to track it? It initially sounds like a different problem, if 80 websites started acting up in the same way, spread across difference hosts.

    If you open another topic, could you also report more precisely what behaviors you observe that are unexpected? It would also be helpful to see a screenshot that’s typical of the unexpected behavior, and please report relevant diagnostic output that may appear in the browser’s JavaScript/Web console from the Font Awesome plugin.

    Plugin Author mlwilkerson

    (@mlwilkerson)

    Resolving as inactive

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Failed to fetch kits’ is closed to new replies.