Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Sybre Waaijer

    (@cybr)

    Hello!

    Thank you for the details and the links; it allowed me to test the issue quickly.

    What you’re facing is a limitation in PHP where it tries to safeguard itself from overloading; I replicated the following error: “PREG_JIT_STACKLIMIT_ERROR (6): JIT stack limit exhausted.”

    Since we use recursion in our blazing-fast HTML parser to remove all unusable content in as little as two runs, I cannot see a fix other than adjusting the server limits (which isn’t feasible), disabling JIT (please don’t), making a slower parser (defeats its purpose of being fast), writing a description manually (this takes time), or doing nothing and let the search engine generate a description for you (which they often do, anyway).

    I am going to try and see if I can reduce the number of stacks it takes, but I already spent over two weeks on this single line of code (this is where it fails). It works well on even larger content than you have, but that depends on the structure: enormous tables (read: 332,323 characters of stacking HTML) seem to cause this issue. If we’d remove the safeguarding limitation, your content would be parsed in approximately 90 milliseconds in 72k steps, which (patting myself on my back) is fast considering the size.

    Perhaps I’ll have a moment of brilliance and become able to fix the issue. In the meantime, I recommend writing a custom description for pages with huge tables — it’d take a load off your site.

    Thread Starter r3crac

    (@r3crac)

    Thank you for your reply, I really appreaciate your work. Your plugin is faster than the others, for example Yoast. Maybe you can add an option (in auto description feature) that will remove, for example, 90% last characters of the text if the post contains x characters (high number of characters/long post) and then that text will be parsed. In most cases description is generated from the beginning of the post, I guess.
    I will wait for your fix!

    Thanks!

    • This reply was modified 2 years, 10 months ago by r3crac.
    Plugin Author Sybre Waaijer

    (@cybr)

    Thanks for the suggestion. I’m afraid that wouldn’t work because we need to “balance” the HTML tags — we cannot assume where the end of the tag is unless it’s actually missing; it’d break the parser.

    Here’s an example where the href-attribute of the <a-element contains multiple lines of HTML code that shouldn’t be considered for content: https://regex101.com/r/9fP7r8/1.
    Remove the ">This must be group 3, actual text!</a> text at the end (simulating the removal of an X amount of last characters), and you see the entire match change (depicted via color changes), where it will consider the attribute’s HTML as text.

    Even tactfully removing content preemptively would circle back to this exact issue: We need to know the HTML before we know what we can remove.

    This is what makes it so complex, among other things: https://tsf.fyi/kb/explaining-the-description-generator/.

    I cannot promise a fix anytime soon, but perhaps I’ll have a stroke of luck. Ultimately, it’s a limitation in PHP and not a bug in TSF.

    • This reply was modified 2 years, 10 months ago by Sybre Waaijer. Reason: typo
    Thread Starter r3crac

    (@r3crac)

    Alright, I will wait for a fix!

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘No meta description for long posts’ is closed to new replies.