Jump to content

Community

Auto Welcome Support


Michael.J

Recommended Posts

6 hours ago, Logan0 said:

I see the chatbox+ integration still doesn't work Michael any thoughts on fixing it please.

Not for a while sorry, I'm quite busy with other updates and bugs.

3 hours ago, svit said:

during the auto welcome upgrade i got this error message:

What version of the Auto Welcome app did you upgrade from?

3 hours ago, Paul E. said:

The issue is that core_members is a table that no third-party plugin or application should touch. Auto Welcome likely was using this prior to 4.5 and is now expected to move it elsewhere. The part that moves it elsewhere is likely what died on us, but all a big guess.

Yes this was a retroactive change unfortunately, so I needed to handle existing core_members data. I've used the upgrade steps before without fail and you'll have to check with IPS in regards to it's reliability.

But if people are having issues with this, I'll setup a background task instead to shift that data across.

Link to comment
Share on other sites

2 minutes ago, Michael.J said:

Yes this was a retroactive change unfortunately, so I needed to handle existing core_members data. I've used the upgrade steps before without fail and you'll have to check with IPS in regards to it's reliability.

But if people are having issues with this, I'll setup a background task instead to shift that data across.

Totally understand. You're not the only one doing this by far.

See here for some strategy discussion, and sample code that worked at ~1,000,000 records.

You may also want to look at the UPGRADE_MANUAL_THRESHOLD constant as well and throw up the option for a query to run straight at the SQL level.

Link to comment
Share on other sites

17 hours ago, Michael.J said:

What version of the Auto Welcome app did you upgrade from?

 

I had 'the previous' version installed, since I am keeping all ups up-to-date, unfortunately, the site is down, due to the incomplete upgrade of the latest IPS patch which cannot be completed due to the hick-up of the Auto Welcome app, could you please advise on any patch which would help us with this issue?

Link to comment
Share on other sites

We moved forward with our 4.5 upgrade and uninstalled this application in 4.4. Now, when we go to our installed applications, the application is listed at the bottom as not installed with a button to install it. Pressing the install button says that the application is already installed.

Trying to install again from Marketplace says that the application must first be uninstalled.

To get past this, we removed applications/autowelcome from the file system and then went to ACP > applications and removed the "out of date" application at the bottom.

Edited by Paul E.
Link to comment
Share on other sites

1 hour ago, Paul E. said:

We moved forward with our 4.5 upgrade and uninstalled this application in 4.4. Now, when we go to our installed applications, the application is listed at the bottom as not installed with a button to install it. Pressing the install button says that the application is already installed.

Trying to install again from Marketplace says that the application must first be uninstalled.

To get past this, we removed applications/autowelcome from the file system and then went to ACP > applications and removed the "out of date" application at the bottom.

After testing, this is the approach I'd recommend for larger sites. Make a copy of your settings somewhere, uninstall just before the 4.5 upgrade, upgrade, and then reinstall. This stopped the entire issue of migrating data. Short of the above issue, it looks like this got us over the hurdle.

Link to comment
Share on other sites

On 9/13/2020 at 1:47 AM, Paul E. said:

After testing, this is the approach I'd recommend for larger sites. Make a copy of your settings somewhere, uninstall just before the 4.5 upgrade, upgrade, and then reinstall. This stopped the entire issue of migrating data. Short of the above issue, it looks like this got us over the hurdle.

Unfortunately, I had done the upgrade before so "Auto welcome" doesn't work anymore.

I try to uninstall the plugin it then doing a fresh reinstall  but the problem remains. 🤔

Link to comment
Share on other sites

I installed this on my community earlier today, and set it to send a PM one hour after someone signs up. I came back to my community now, and apparently the plugin sent the welcome message to all existing members. All five thousand of them.

Is this expected behavior? If it is, why wasn’t there a warning?

Link to comment
Share on other sites

On 9/11/2020 at 6:39 PM, Dean_ said:

I hope my problems are not returning... I had the previous version installed and updated yesterday and someone joined today and no welcome topic was created, yet it was working fine before the upgrade...

I'll keep my eyes on it and see if it happens again.

 

On 9/11/2020 at 11:31 PM, Dean_ said:

OK, someone else has just joined, and it's certainly not working now, and I have no idea why.

This is not working for me at all in 4.5.

Link to comment
Share on other sites

2 minutes ago, Paul E. said:

No delay, immediately.

Then I guess the delay functionality doesn’t account for existing members, and if installed on an old community, everyone will receive the welcome message.

I’m looking forward to the next invoice from Mailgun 😄

Link to comment
Share on other sites

3 hours ago, Runar said:

I installed this on my community earlier today, and set it to send a PM one hour after someone signs up. I came back to my community now, and apparently the plugin sent the welcome message to all existing members. All five thousand of them.

Is this expected behavior? If it is, why wasn’t there a warning?

I have it on a few sites.  Oddly, on one site it was doing this, sending to everyone.  The other site it works fine.  For the bogger site (just under 12k members) I only have it make a post.

Link to comment
Share on other sites

30 minutes ago, Runar said:

Then I guess the delay functionality doesn’t account for existing members, and if installed on an old community, everyone will receive the welcome message.

Oh dear. We have enough members that this would have been.... problematic, to say the least. @Lindy, something for your Marketplace resource testing/evaluation consideration.

/* Only get members not yet welcomed. */
$where = array( array( 'welcome_sent IS NULL' ) );

/* Only get members who joined after time delay */
$where[] = array( 'core_members.joined < ?', \IPS\DateTime::create()->sub( new \DateInterval( 'PT'.\IPS\Settings::i()->aw_welcome_delay.'H' ) )->getTimestamp() );

/* Look for matching members */
$members = \IPS\DB::i()->select( '*', 'core_members', $where, 'joined ASC', 15 )->join( 'autowelcome_members', 'core_members.member_id=autowelcome_members.welcome_member_id' );

The issue appears to be core_members.joined < (LESS THAN)The logic used is returning all members with no welcome_sent value, who joined any time before the threshold indicated. That probably should be >= instead.

Edit: For clarity, the above only gets hit if a delay is set. If no delay, you don't trigger this. Whatever you do, don't add a delay.

work itself out office space GIF

Edited by Paul E.
Workaround.
Link to comment
Share on other sites

As a safety measure, we've run the following SQL statement to populate autowelcome for all past members. This will mitigate this problem. PROVIDED AS-IS. USE AT YOUR OWN RISK, MAKE BACKUPS OF EVERYTHING FIRST. YOU HAVE BEEN WARNED.

INSERT INTO `autowelcome_members` (`welcome_member_id`,`welcome_sent`)
SELECT
     `core_members`.`member_id`
    ,1
FROM
    `core_members`
LEFT JOIN
    `autowelcome_members` ON `autowelcome_members`.`welcome_member_id` = `core_members`.`member_id`
WHERE
    `autowelcome_members`.`welcome_member_id` IS NULL

 

Link to comment
Share on other sites

1 hour ago, Paul E. said:

As a safety measure, we've run the following SQL statement to populate autowelcome for all past members. This will mitigate this problem. PROVIDED AS-IS. USE AT YOUR OWN RISK, MAKE BACKUPS OF EVERYTHING FIRST. YOU HAVE BEEN WARNED.

Thank you for taking your time to look into this issue. Unfortunately it’s too late for my community, but luckily my members found it funny and nice (even those with 20 years as members) so the damage isn’t that bad.

I hope this issue is fixed, though, as I can’t be the only one who’d like to send a PM some X hours after a new member signs up.

The good thing that’ll come from this is that from now on I’ll test all new plugins and applications on my staging server, even the simple and harmless ones like this one.

Link to comment
Share on other sites

36 minutes ago, Runar said:

Thank you for taking your time to look into this issue. Unfortunately it’s too late for my community, but luckily my members found it funny and nice (even those with 20 years as members) so the damage isn’t that bad.

Sending close to a million members an e-mail would have been detrimental for us. This is the sort of thing that we'd hope to catch in our previous code reviews, yet I personally have used the wrong comparison operator in my own code. It's one of those things that's easy for me to get backwards in my head.

We did test this in our test environment, matching our intended production configuration. We decided an immediate e-mail after registration made the most sense for our community, but did consider a delayed message. It's the sort of thing that later on we might reconsider, not realizing we're triggering a path of getting blacklisted for spam.

39 minutes ago, Runar said:

The good thing that’ll come from this is that from now on I’ll test all new plugins and applications on my staging server, even the simple and harmless ones like this one.

This, in my opinion, is a must. But, it's a lesson learned over many years of experience at when things like this go wrong.

Link to comment
Share on other sites

25 minutes ago, Paul E. said:

Sending close to a million members an e-mail would have been detrimental for us.

For me 5 000 messages is a lot (I even chose to send them from my own account), but one million would be disastrous.

29 minutes ago, Paul E. said:

We decided an immediate e-mail after registration made the most sense for our community, but did consider a delayed message.

In hindsight, I should have done the same, but I thought letting my new members get a feeling of the community before sending them a message would be best, and that a small delay would feel more natural than receding the message immediately after signing up.

31 minutes ago, Paul E. said:

This, in my opinion, is a must. But, it's a lesson learned over many years of experience at when things like this go wrong.

I usually do, and I’m even working on a new workflow consisting of a private git repo and Ansible, but that haven’t made it to production yet. Well, it could have been worse!

Also, if I hadn’t done this, we most likely wouldn’t have discovered the issue (at least not at this time).

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

We use technologies, such as cookies, to customise content and advertising, to provide social media features and to analyse traffic to the site. We also share information about your use of our site with our trusted social media, advertising and analytics partners. See more about cookies and our Privacy Policy