Feed fetch problems

This topic contains 11 replies, has 2 voices, and was last updated by  Eric Corpus 1 month, 1 week ago.

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #34213

    Hi,

    I have three Google iCal feeds syncing with EO (we’ll call them A, B, and C). The calendars are set to sync hourly, and Feeds A and B auto-sync fine. However, Feed C doesn’t sync unless I manually do it. And when I do, it spins for a while and then tells me:

    “An unknown error has occurred”

    When I refresh the iCal Feeds page, Feed C reports that it successfully synced.

    What can I do to make Feed C auto-sync correctly?

    Possibly related, when I delete events from Feed C’s Google calendar, the events do not get deleted from the website. However, when I imported Feed C on a local install of WP, deleted Google cal events get deleted from my local WP install.

    • This topic was modified 2 months, 1 week ago by  Eric Corpus.
    Eric Corpus
    #34248

    Hi Eric,

    Do you mind sharing the feed URLs? (If so, feel free to use the contact form to send them.

    Based on what you’re seeing, my initial thought is that its timing out. But this may require more investigation.

    It sounds like its working on your local test install. Is that right?

    Stephen Harris
    #34264

    Hi Stephen,

    I sent the three feed URLs through the contact form.

    I haven’t tested the auto-sync on my local install. However, when I do sync it, it doesn’t give me the “unknown error” message, and it deletes events that I delete on Google calendar.

    Eric Corpus
    #34283

    The scheduled auto-sync appears to be working on my local install. No reported errors.

    Eric Corpus
    #34786

    Hi Stephen – is there an update on this?

    Eric Corpus
    #34817

    Hi Eric,

    I ran these in my test environment, and I believe the feed in question is so large that its either timing out, or out of memory.

    The feed is large (about 5 times as large in size, and 4 times as large in lines as one of the other two). I found importing that feed took about 14 minutes, when using a standard http request the PHP server is usually limited in memory and time which makes it likely that it’ll run out of one or the other, or both.

    However, if you use WP Cli you can run the command:

    wp eo ical-feed fetch {feed id}
    

    To get the feed ID you can run

    wp eo ical-feed list
    

    Typically PHP Cli has larger memory / time limits. You also set up a cron job on the server to run that command routinely.

    Stephen Harris
    #34854

    Thanks, Stephen. I will look into this and let you know.

    Eric Corpus
    #34859

    Hi Stephen,

    I have a cron plugin that manages events. Could I run the command through the following? I’m new to CLI. Thanks!

    screenshot

    Eric Corpus
    #34974

    Hi Stephen – just checking on my question on whether I could put some PHP in the Cron plugin I screenshotted there. If so, can you guide as to what that code would be?

    Thanks!

    Eric Corpus
    #34980

    Hi Eric, you could try

     eo_fetch_feed( $feed_id );
    

    where $feed_id is the ID of the feed. Unfortunately you won’t be able to determine that ID from the iCal feed screen; it’s only exposed in the Cli – however, if you look at the HTML of the ical feed table, you’ll notice that echo ‘row’ is in fact <tbody> and has any ID of the form eo-feed-XXX – the XXX is the ID of the feed.

    Stephen Harris
    #34982

    Thanks, Stephen. I’ll try this and let you know.

    Eric Corpus
    #35030

    I added the code to the cron plugin, and the feed imports on schedule now. I also deleted a lot of old events from that Google calendar to keep it from getting too bloated.

    Thanks for your help!

    Eric Corpus
Viewing 12 posts - 1 through 12 (of 12 total)
To enable me to focus on Pro customers, only users who have a valid license for the Pro add-on may post new topics or replies in this forum. If you have a valid license, please log-in or register an account using the e-mail address you purchased the license with. If you don't you can purchase one here. Or there's always the WordPress repository forum.