Git Product home page Git Product logo

Comments (11)

benoitchantre avatar benoitchantre commented on July 19, 2024 1

Thank you, I'll do some tests and let you know

from wp-simple-smtp.

benoitchantre avatar benoitchantre commented on July 19, 2024 1

Re-opening this issue - due to a major bug the #116 PR triggered, this has been reverted.

If this was working for you, I recommend not upgrading to 1.3.2.1.

Thank you for the note.

I have finally build a mu-plugin with the required filters instead of this plugin because of #121.

from wp-simple-smtp.

benoitchantre avatar benoitchantre commented on July 19, 2024

To prevent this error, I had to stop alerts for the post type sbss_email_log in Sucuri Scanner settings or disable Receive email alerts for changes in the post status (configure from Ignore Posts Changes).

from wp-simple-smtp.

soup-bowl avatar soup-bowl commented on July 19, 2024

Great, it detects the CPT of the email log and notifies by default that something has changed, thereby initiating an infinite logic loop of it detecting a change, sending an email, detecting a change, etc etc etc until PHP crashes... At least that's how it worked on my test machine.

Edit: Interestingly, I've hooked on another email logging plugin and did not experience the same problem (later edit: because it uses a custom table not a CPT).

from wp-simple-smtp.

soup-bowl avatar soup-bowl commented on July 19, 2024
// Patch fix to stop Sucuri from spamming the log. Should be investigated more.
$dup_check = post_exists( $log->get_subject(), '', current_time( 'mysql' ), $this->post_type );
if ( 0 !== $dup_check ) {
	return $dup_check;
}

This added to line 63 of src/log/class-logservice.php (underneath public function new_log_entry( $log ) {) catches the rampant logging on my side. I'm going to do a few more tests and add it to the next release if it works. If you've got a dev environment of the affected site, a confirmation would be appreciated.

from wp-simple-smtp.

soup-bowl avatar soup-bowl commented on July 19, 2024

To be clear: It will still write 1-2 notification entries in the log after an email is sent, but this 'patch' will stop it writing them indefinitely. I think that's the best approach I can take from this plugin side without re-writing the logging code.

from wp-simple-smtp.

benoitchantre avatar benoitchantre commented on July 19, 2024

Unfortunately, there's no filter available in Sucuri Scanner to programmatically ignore status changes for the sbss_email_log post type.

from wp-simple-smtp.

soup-bowl avatar soup-bowl commented on July 19, 2024

Unfortunately, there's no filter available in Sucuri Scanner to programmatically ignore status changes for the sbss_email_log post type.

Thanks, I think I'll reach out to the developers anyway to discuss it. I'm not a primary WP dev anymore so I'll ask them in case there's something I've missed. Either way, this patch should stop the runaway generations at least.

from wp-simple-smtp.

soup-bowl avatar soup-bowl commented on July 19, 2024

Re-opening this issue - due to a major bug the #116 PR triggered, this has been reverted.

If this was working for you, I recommend not upgrading to 1.3.2.1.

from wp-simple-smtp.

soup-bowl avatar soup-bowl commented on July 19, 2024

Nice - glad to hear you made a solution that works better for you. In that case you can unsubscribe on the right hand side so you don’t get pestered with updates that are now irrelevant.

from wp-simple-smtp.

soup-bowl avatar soup-bowl commented on July 19, 2024

Added a warning about plugin incompatibility to the plugin readme.

from wp-simple-smtp.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.