News:

Wondering if this will always be free?  See why free is better.

Main Menu

failed upgrade autopsy (2.0.14 to 2.0.15)

Started by brynn, January 28, 2018, 09:35:12 PM

Previous topic - Next topic

brynn

Ok, so starting to reinstall Stop Spammer, I have 8 failed tests.  As far as I can tell, none of them is the expected one.

More info. 

As I mentioned earlier, someone else had originally installed both forums.  I have no idea whether they needed to fix these things when they originally installed SS. 

I see a notation at the top of the installation info, which says that this mod works best with a mod called httpBL.  As far as I can tell, it looks similar to the mod Bad Behavior (integrates with Project Honeypot), which is what I have installed.  Not sure if this could account for the unexpected failed tests?

Also, please recall that in the middle of all this difficulty with the upgrade, I had the corrupt database (or...table, I think), which was successfully fixed.  Not sure it that would account for the unexpected failed tests either?

7 of the 8 failed tests are in ./Sources/ManageMembers.php, and 1 is in ./Sources/Subs.php

Should I just proceed and see what happens?  Or is this a bad sign, and I still need to install clean files?

Thanks for everyone's help and patience.

lurkalot

Brynn, I was just going to post on your forum, but now I get,

The following error or errors occurred while posting this message: Your session timed out while posting. Please try to re-submit your message.

brynn

#42
Do you mean a message in the forum, or PM?

EDIT:
I've tested both forum post and PM, and both post ok.  Well that was for Inkscape Community.  Don't think you're a member of the other forum.

EDIT 2:
Further testing.

Using regular member account, but only with the full editor, I can reproduce the error.  Doesn't happen with Quick Reply.  Doesn't happen with admin account, either way.

EDIT 3:
No, now I can't reproduce it....  strange!

EDIT 4:
Oh, but checking the error log -- the test PM I sent you threw 6 or 8 errors.  6 errors for line 2183 and 3 errors for line 2204.  Looking them up....

-Lex tidied up a bit...

brynn

#43
This is line 2183, which is in the section starting with the comment    // Now create the editor.

'height' => '175px',

This is 2204, which is in theh section starting with the comment    // If the user can post attachments prepare the warning labels.

$context['attachment_restrictions'][] = sprintf($txt['attach_restrict_' . $type], $modSettings[$type]);

Note that PM Attachments is not installed in this forum.

Neither one of those was edited, in the PersonalMessage.php file which Lex provided.  I don't know what to make of it.

Edit
Note that the PM was sent.  It just threw errors.
Whatever error which lurkalot reported, it doesn't seem to be reliably reproducible.  I thought I reproduced it once, but now I can't.

Edit #2
Also note that I still haven't even attempted to reinstall Stop Spammer in this forum yet.  Attempt reported above is for the other forum.

Aleksi "Lex" Kilpinen

Quote from: brynn on February 06, 2018, 03:34:40 PM
Ok, so starting to reinstall Stop Spammer, I have 8 failed tests.  As far as I can tell, none of them is the expected one.

More info. 

As I mentioned earlier, someone else had originally installed both forums.  I have no idea whether they needed to fix these things when they originally installed SS. 

I see a notation at the top of the installation info, which says that this mod works best with a mod called httpBL.  As far as I can tell, it looks similar to the mod Bad Behavior (integrates with Project Honeypot), which is what I have installed.  Not sure if this could account for the unexpected failed tests?

Also, please recall that in the middle of all this difficulty with the upgrade, I had the corrupt database (or...table, I think), which was successfully fixed.  Not sure it that would account for the unexpected failed tests either?

7 of the 8 failed tests are in ./Sources/ManageMembers.php, and 1 is in ./Sources/Subs.php

Should I just proceed and see what happens?  Or is this a bad sign, and I still need to install clean files?

Thanks for everyone's help and patience.
I can't really say much about the errors, but some of those mods may cause issues when installing other similar mods. That is quite normal to happen when you have many mods installed, that edit similar locations of the original code. I would say though that neither httpBL or Bad Behaviour are really required for the Stop Spammer mod as I understand it, it just a recommendation that it works well with httpBL.

Quote from: brynn on February 06, 2018, 10:17:08 PM
Oh, but checking the error log -- the test PM I sent you threw 6 or 8 errors.  6 errors for line 2183 and 3 errors for line 2204.  Looking them up....
This could have something to do with the PM mods you have, including the enhanced PM system - like I mentioned it is not available anymore, and not supported, and I'd guess there was some reason for that. ( I do not know exactly why though. )

Slava
Ukraini!
"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

How you can help SMF

brynn

Thanks Lex!  Since you didn't urge me to install clean files again, I will tentatively proceed with making the edit which Stop Spammer needs to be reinstalled.

Regarding the errors from PMs, in those lines which are reported in the Error Log, do you actually see any wrong code? 

That one line is so short, and seemingly nothing to do with....well I'm not sure what the middle line refers to on the left in an error report.  But the middle lines refer to
attach_restrict_pmAttachmentSizeLimit
attach_restrict_attachmentPMLimit
attach_restrict_attachmentNumPerPMLimit

while line 2183 of the code seems to be about the height of the editor.  Very confusing.

lurkalot, if you want to test further, I started a thread here on the Testing board:  https://forum.inkscapecommunity.com/index.php?topic=975.0  I still can't reproduce that error.

lurkalot

Quote from: brynn on February 07, 2018, 01:34:43 AM

lurkalot, if you want to test further, I started a thread here on the Testing board:  https://forum.inkscapecommunity.com/index.php?topic=975.0  I still can't reproduce that error.

All I did was use the "quote selected" to quote part of a post, and reply to it. 

Thing is, I've just tried it again this morning and it worked fine..  ???

brynn

lurkalot: 

These edits to Stop Spammer appear to be very complicated as well.  (at least for me they're complicated)

There are 7 Find/Replace failed tests to deal with.  Every single Find code starts with

'sprintf' => array(

and following that are different codes.  However, that sprintf code only appears once.  I do find bits and pieces of the Find codes behind

=> array(

But I'm also finding a lot of the Replace code is already in the file.  So I wonder if a different approach would work better here.  If instead of searching for the Find code, I search for the Replace code.  If I find the Replace code is already in the file character for character and space for space, then does it make sense to just skip that edit?

Or is it important to delete whatever I can find of the Find codes, even if the Replace code is already in the file?

lurkalot

Quote from: brynn on February 07, 2018, 02:47:53 AM
lurkalot: 

These edits to Stop Spammer appear to be very complicated as well.  (at least for me they're complicated)

There are 7 Find/Replace failed tests to deal with.  Every single Find code starts with

'sprintf' => array(

and following that are different codes.  However, that sprintf code only appears once.  I do find bits and pieces of the Find codes behind

=> array(

But I'm also finding a lot of the Replace code is already in the file.  So I wonder if a different approach would work better here.  If instead of searching for the Find code, I search for the Replace code.  If I find the Replace code is already in the file character for character and space for space, then does it make sense to just skip that edit?

Or is it important to delete whatever I can find of the Find codes, even if the Replace code is already in the file?

I only had one edit to do when I installed stop spammer.  The problem you're having is because you use more than one antispam mod which I guess edit the same file.  Plus those mods are outdated due to the changes SMF 2.0.15

brynn

More than one spam mod?  Outdated?  Did you see my mod list, earlier in this thread?  (For the forum I'm currently trying to install Stop Spammer, it's in message #27.) 

As far as I understand, I only use 2.  Stop Spammer and Bad Behavior (which is similar to httpBL which is recommended to be used with SS).  It looks like Bad Behavior does have an update.  But Bad Behavior is the Project Honey Pot integration.  Would it be affecting ManageMembers.php?  Doesn't it just catch potential spammers in the honey, before they register?

I can see where there might be other mods editing ManageMembers.php file (non-spam mods).  But I'm not sure what you're suggesting I could do, to get SS reinstalled.

Aleksi "Lex" Kilpinen

Quote from: brynn on February 07, 2018, 01:34:43 AM
Thanks Lex!  Since you didn't urge me to install clean files again, I will tentatively proceed with making the edit which Stop Spammer needs to be reinstalled.

Regarding the errors from PMs, in those lines which are reported in the Error Log, do you actually see any wrong code? 

That one line is so short, and seemingly nothing to do with....well I'm not sure what the middle line refers to on the left in an error report.  But the middle lines refer to
attach_restrict_pmAttachmentSizeLimit
attach_restrict_attachmentPMLimit
attach_restrict_attachmentNumPerPMLimit

while line 2183 of the code seems to be about the height of the editor.  Very confusing.

lurkalot, if you want to test further, I started a thread here on the Testing board:  https://forum.inkscapecommunity.com/index.php?topic=975.0  I still can't reproduce that error.
What are the errors you are getting exactly?
Perhaps it would be best to try diagnose those first, before adding more code changes in the game.
Slava
Ukraini!
"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

How you can help SMF

brynn

#51
Just to make sure it's clear.  2 forums:  Inkscape Community (IC)  Inkscape for Cutting Design (ICD)

The current problem re-installing Stop Spammer is in ICD.  The PM errors are in IC.  ICD does not produce the PM errors.  Eventually I'll re-install SS in IC too.

My regular member account produced these:

https://forum.inkscapecommunity.com/index.php?action=pm;sa=send
8: Undefined index: attach_restrict_attachmentNumPerPMLimit
File: /home/brynn/public_html/forum/Sources/PersonalMessage.php
Line: 2204

https://forum.inkscapecommunity.com/index.php?action=pm;sa=send
8: Undefined index: attach_restrict_attachmentPMLimit
File: /home/brynn/public_html/forum/Sources/PersonalMessage.php
Line: 2204

https://forum.inkscapecommunity.com/index.php?action=pm;sa=send
8: Undefined index: attach_restrict_pmAttachmentSizeLimit
File: /home/brynn/public_html/forum/Sources/PersonalMessage.php
Line: 2204


My admin account produced those above, and these next 3 below:

https://forum.inkscapecommunity.com/index.php?action=pm;sa=send
8: Undefined index: attach_restrict_pmAttachmentSizeLimit
File: /home/brynn/public_html/forum/Sources/PersonalMessage.php
Line: 2183

https://forum.inkscapecommunity.com/index.php?action=pm;sa=send
8: Undefined index: attach_restrict_attachmentPMLimit
File: /home/brynn/public_html/forum/Sources/PersonalMessage.php
Line: 2183

https://forum.inkscapecommunity.com/index.php?action=pm;sa=send
8: Undefined index: attach_restrict_attachmentNumPerPMLimit
File: /home/brynn/public_html/forum/Sources/PersonalMessage.php
Line: 2183

Overall, the ones indicating Line 2183 are far more numerous.  Another member has produced these 3:

https://forum.inkscapecommunity.com/index.php?action=pm;sa=send2
8: Undefined index: attach_restrict_pmAttachmentSizeLimit
File: /home/brynn/public_html/forum/Sources/PersonalMessage.php
Line: 2488

https://forum.inkscapecommunity.com/index.php?action=pm;sa=send2
8: Undefined index: attach_restrict_attachmentPMLimit
File: /home/brynn/public_html/forum/Sources/PersonalMessage.php
Line: 2488

https://forum.inkscapecommunity.com/index.php?action=pm;sa=send2
8: Undefined index: attach_restrict_attachmentNumPerPMLimit
File: /home/brynn/public_html/forum/Sources/PersonalMessage.php
Line: 2488

Continuing thanks for patience, help and support!

brynn

OH!!  I just thought of a clue.  Clearly the errors are referring to PM attachments.  But I do not have PM Attachments mod installed here.  However, I do have Post and PM Inline Attachments installed.  I'll bet those errors about PM attachments are - somehow -  related to codes for Inline Attachments mod.

Also,  in ICD, I do have PM Attachments installed.  So my guess would be that because Inline Attachments mod does find the PM Attachments mod code, in ICD, everything is happy.  But in IC, Inline Attachments can't find PM Attachments code, because it's not installed.

Is that a reasonable explanation for the errors?

Aleksi "Lex" Kilpinen

Quote from: brynn on February 08, 2018, 07:41:21 PM
Is that a reasonable explanation for the errors?
Yes, I'd say that the PM Attachments code is a valid suspect, however if the PM Attachments mod is not installed there shouldn't really be errors related to it either.

Just to be sure now, could you again attach the current PersonalMessage.php from the forum producing those errors?

Slava
Ukraini!
"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

How you can help SMF

brynn


Aleksi "Lex" Kilpinen

The 2204 line error comes from this


// If the user can post attachments prepare the warning labels.
if (!empty($context['can_post_attachment']))
{
$context['allowed_extensions'] = strtr($modSettings['pmAttachmentExtensions'], array(',' => ', '));
$context['attachment_restrictions'] = array();
$attachmentRestrictionTypes = array('attachmentNumPerPMLimit', 'attachmentPMLimit', 'pmAttachmentSizeLimit');
foreach ($attachmentRestrictionTypes as $type)
if (!empty($modSettings[$type]))
$context['attachment_restrictions'][] = sprintf($txt['attach_restrict_' . $type], $modSettings[$type]);
}


That code looks like it is from PM Attachments mod, which I think you said should not be installed there, right?

The other 2 errors a bit of a mystery to me honestly... But still also clearly related to the same mod.
Slava
Ukraini!
"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

How you can help SMF

brynn

Yes, that's correct.  PM Attachments mod is not installed in the forum which is having these errors.

I do seem to recall that the person who originally installed the forum, commented that PM Attachments had been hard to install, and he warned me that some day we might not be able to use it.  And indeed, that day came.  But maybe he made some kind of unusual edits to that file, to make it work?  Maybe those edits are part of this trouble?

Fixable?  Or are we back to making the clean install again?

Although I suppose just putting up with the errors might be an option, since PMs work properly otherwise....?

Aleksi "Lex" Kilpinen

To start from a clean table is always an option, but if you don't wish to go there yet you could possibly also follow the PM Attachments -mod's manual installation instructions to either

a) remove the edits it does completely, noting that not all of them may be there now
or
b) complete the edits it needs, noting that it would seem some of them are already there

The manual installation instructions can be found on the mod download page
https://custom.simplemachines.org/mods/index.php?mod=1974
Slava
Ukraini!
"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

How you can help SMF

brynn

So you mean that somehow, it's partially installed?

I've never manually installed a mod before.  Is that a way of installing which bypasses the Package Manager?

If it had originally been manually installed, but uninstalled using the Package Manager, could that cause this situation?  As far as I recall, after an upgrade (2.0.13 or 2.0.14) it started throwing errors, and I uninstalled it.  But I used the Package Manager.  Maybe the person who originally installed did it manually?

So re the manual install instructions, you're saying I would need to UNDO the edits which the manual install instructions are saying to DO?  And do I need to fix all those 6 files?  Or just this one in question (PersonalMessage.php) ?

And finally.  Do you still think I need to do this, before I reinstall Stop Spammer?

Since I don't have these errors in the forum where I'm currently trying to re-install Stop Spammer, I should be able to reinstall it, right?  It's a different forum.  But I'm still stuck on that, details in Reply #47.

Aleksi "Lex" Kilpinen

Quote from: brynn on February 11, 2018, 02:51:20 AM
So you mean that somehow, it's partially installed?
Yes, clearly since the code is there and is part of that mod.
Quote from: brynn on February 11, 2018, 02:51:20 AM
I've never manually installed a mod before.  Is that a way of installing which bypasses the Package Manager?
Yes.
Manual Installation of Mods
Quote from: brynn on February 11, 2018, 02:51:20 AM
If it had originally been manually installed, but uninstalled using the Package Manager, could that cause this situation?  As far as I recall, after an upgrade (2.0.13 or 2.0.14) it started throwing errors, and I uninstalled it.  But I used the Package Manager.  Maybe the person who originally installed did it manually?
Did you get any errors in your uninstallation then? It could be the uninstallation was not complete.
Quote from: brynn on February 11, 2018, 02:51:20 AM
So re the manual install instructions, you're saying I would need to UNDO the edits which the manual install instructions are saying to DO?  And do I need to fix all those 6 files?  Or just this one in question (PersonalMessage.php) ?
Yes, if you have purposely uninstalled the mod and still have code left over from it, you would probably need to go through all the files it modifies, starting with the one now throwing errors, and make sure the edits have been removed correctly - So reverse the manual install instructions. This can be a tedious job to do though.
Quote from: brynn on February 11, 2018, 02:51:20 AM
And finally.  Do you still think I need to do this, before I reinstall Stop Spammer?
Always a good idea to fix current problems first, before possible creating new ones.
Quote from: brynn on February 11, 2018, 02:51:20 AM
Since I don't have these errors in the forum where I'm currently trying to re-install Stop Spammer, I should be able to reinstall it, right?  It's a different forum.  But I'm still stuck on that, details in Reply #47.
To help with that, I would need to know each and every error you got in their entirety - and probably see the files you are working with.
It's hard to offer advice on an error, when I don't really know what the error is.
https://wiki.simplemachines.org/smf/Error_in_mod_installation
Slava
Ukraini!
"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

How you can help SMF

Advertisement: