Page 41 of 70

Re: [RC] Digests 3.2.4-RC11

Posted: Mon Oct 02, 2017 1:13 pm
by DavidIQ
The reset seems to have "fixed" it, but why would it be trying to catch up at all? Plus it seems to fail at trying to catch up. There some setting I haven't seen that would prevent this "catch-up"?

Re: [RC] Digests 3.2.4-RC11

Posted: Mon Oct 02, 2017 1:19 pm
by MarkDHamill
If digests have been offline, for example the board was disabled for a long period of time due to an upgrade, digests will try to catch up. Every time an hour is processed the date and hour digests were last sent successfully is stored in a configuration variable as a Unix timestamp. I don't see how this would get changed unless it is due to a bug, but it's possible. If the value in the database were edited, this could cause the problem.

Re: [RC] Digests 3.2.4-RC11

Posted: Mon Oct 02, 2017 8:59 pm
by MarkDHamill
I found a new bug in Balance load function. Essentially, the subscriber names shown for a given hour are incorrect. They are shifted to an hour offset from the user's timezone from UTC. So if your profile's timezone is -4UTC and you are subscribed for a digest at 16h in your timezone (20h UTC), the count for the hour is correct (you will show up in the count for 16h) but your name will appear for 20h.

The code fix below applies to the latest version 3.2.4. If you want to fix this, edit ext/phpbbservices/digests/acp/main_module.php. Near the bottom of the file look for the get_subscribers_for_hour() function. Change line 2022 from:

Code: Select all

	function get_subscribers_for_hour ($hour, $tz_text)
to

Code: Select all

	function get_subscribers_for_hour ($hour, $offset_from_utc)
and change lines 2029-2030 from:

Code: Select all

		$hour_utc = $hour - $this->helper->make_tz_offset($tz_text);
		$hour_utc = $this->helper->check_send_hour($hour_utc);
to

Code: Select all

		$hour_utc = $this->helper->check_send_hour($hour - $offset_from_utc);
That's it. You don't need to purge the cache.

Re: [RC] Digests 3.2.4-RC11

Posted: Fri Oct 13, 2017 6:06 pm
by jan_2017
I see no tables in the e-mail.
Settings : HTML with table was chosen.

Purge Cache done.

I use a Board with 3.2.0 phpbb and the newest digests Version.

Can anyone help me?

thx Jan

Re: [RC] Digests 3.2.4-RC11

Posted: Fri Oct 13, 2017 6:30 pm
by MarkDHamill
It's unclear if you are seeing any content at all. If digest logging is enabled there should be evidence in the Admin log of digests being created and going out.

It could be that your settings are incorrect.

Try using the manual mailer feature, and save the output to disk. Then in the maintenance log get the filename that was created and view it. Is there a table?

Re: [RC] Digests 3.2.4-RC11

Posted: Sat Oct 14, 2017 6:15 am
by jan_2017
I'm sorry ..... i uninstall digests.
Thanks

Jan

Digests 3.2.4-RC11 problems with installation

Posted: Sun Oct 22, 2017 2:57 pm
by arnyeinstein
Hi Mark
I updated from 3.1.10 to 3.2 and removed the old digest folder (I don't seem to find any crontabs). I moved the new digest version to the described folder and added a cache folder within (777). However, when I "enable" digest, I get the message

"Something went wrong during the request and an exception was thrown. The changes made before the error occurred were reversed to the best of our abilities, but you should check the board for errors.
MODULE_EXISTS
Return to the extension list"

Any help would be appreciated.
Renger

Re: [RC] Digests 3.2.4-RC11

Posted: Sun Oct 22, 2017 4:51 pm
by MarkDHamill
You don't need to add a cache folder inside the digest extension. Rather, it uses phpBB's cache folder instead. So if you use the manual mailer to send the digests to files instead of mailing them, they will show up under /cache/phpbbservices/digests. In the admin log you will see the file name.

Your error was probably due to not disabling the digests extension prior to upgrading phpBB, a standard procedure if you read the documentation for upgrading phpBB. By disabling it first, the modules would have been removed. By enabling it again without doing this, the modules already exist. So you may have to do the following:
  1. Manually delete the digests modules using SQL: DELETE FROM `phpbb_modules` WHERE `module_langname` LIKE '%DIGESTS%'
  2. Purge the cache
  3. Try again

Re: [RC] Digests 3.2.4-RC11

Posted: Sun Oct 22, 2017 6:07 pm
by arnyeinstein
Mea culpa! Thanks for the fast reply. It is now working again
Renger

Re: [RC] Digests 3.2.4-RC11

Posted: Thu Nov 02, 2017 12:02 pm
by dafinch
Mark,

We have a phpbb3.1 board running your digest extension. We have been having a problem for a couple months where the cron process was failing and not sending out mail. But we found we could manually run the mailer in the extension tab in the acp. This week we found the root cause which was the max memory size for a php script to run being set at 128meg. Once we bumped it to 256meg everything started working. This setting was in the php.ini file.

Now the issue we have is when the auto cron jobs runs it want to send mail out going back 2 months. How can I reset that last sent date/time. I see a field in the user table named user_digest_last_sent. I'm guessing that needs to be changed but its a large integer and I don't know how to calculate what to put in there or if that would even fix the issue.

Andy suggestions would be appreciated.

Re: [RC] Digests 3.2.4-RC11

Posted: Thu Nov 02, 2017 12:42 pm
by MarkDHamill
dafinch,

Good troubleshooting. There is a simple solution to your problem. In the ACP, on the Extensions tab select the option to Reset mailer, select Yes and Submit.

Re: [RC] Digests 3.2.4-RC11

Posted: Thu Nov 02, 2017 5:57 pm
by dafinch
Oh perfect. Thank you Mark!

Re: [RC] Digests 3.2.4-RC11

Posted: Tue Nov 21, 2017 4:45 pm
by nou nou
Hello Mark,


I have a general question regarding Digests. I remember you saying at some point that the extension is built for convenience rather than performance. Would you say that there may be a point where running this extension would prove problematic? Like, from 100 users, or maybe 10000?

Or does it not really matter, and that was meant as a general comment?

Thanks for the great work on Digests by the way, looking forward to its release!

Re: [RC] Digests 3.2.4-RC11

Posted: Tue Nov 21, 2017 5:04 pm
by MarkDHamill
Later versions of the digest mod and the digest extension are much more efficient. The database is queried just once for posts and the posts are placed in an array. The mailer parses the array and filters out posts that don't meet the user's criteria. Private messages in digests though are queried at the time the digest is assembled for a particular user.

The main issue with sending out digests has to do with hosting quotas on outgoing emails. phpBB could do much better at handling this issue. I wrote a post on my blog that talks about the handshake issues between phpBB and email servers.

There is also the issue of timely delivery of digests. In general using a system cron is recommended or your users have to be forgiving if digests are received late due to little board traffic. This issue is discussed in the first post.

If you don't have to worry about emailing quotas and have a dedicated or virtual server with plenty of CPU at your disposal in general there should be no issues. Sometimes PHP settings have to be tweaked so the mailer won't time out.

Re: [RC] Digests 3.2.4-RC11

Posted: Wed Nov 22, 2017 2:45 am
by nou nou
Thanks Mark, that's very helpful :)