Advertisement:

Author Topic: 2.0.16, error removing entries admin log  (Read 2437 times)

Offline a10

  • Charter Member
  • Sr. Member
  • *
  • Posts: 993
2.0.16, error removing entries admin log
« on: December 28, 2019, 07:33:20 AM »
When trying to clean out old entries occured in 2.0.15:

Apply Filter: Only show the error messages of this URL
https://www.xxx/forum/index.php?action=admin;area=logs;sa=adminlog;type=3
Apply Filter: Only show the errors with the same message
Database error, given array of string values is empty. (uneditable)
Function: ViewModlog
Apply Filter: Only show the errors from this file
File: /customers/xxx/httpd.www/forum/Sources/Modlog.php
Line: 95


Line 95 for individual, line 78 for 'remove all'
(ps, running php 7.3, all worked with 2.0.15)

edit: tested with php 7.2, same.
« Last Edit: December 28, 2019, 07:59:31 AM by a10 »
2.0.17, ssl, php 7.3.19, 10.3.21-MariaDB
Mods: Contact Page, Like Posts, Responsive Curve, Search Focus Dropdown, Add Join Date to Post.

Offline shawnb61

  • On Hiatus
  • SMF Hero
  • *
  • Posts: 2,110
    • sbulen on GitHub
Re: 2.0.16, error removing entries admin log
« Reply #1 on: December 28, 2019, 01:18:54 PM »
I cannot replicate this. 

Were there any errors encountered when applying 2.0.16?

Mods installed?

Can you show the lines of code you have around 78 & 95 in Modlog.php?

Also show lines of code ~62 & 63 in Modlog.php?
Address the process rather than the outcome.  Then, the outcome becomes more likely.   - Fripp

Offline a10

  • Charter Member
  • Sr. Member
  • *
  • Posts: 993
Re: 2.0.16, error removing entries admin log
« Reply #2 on: December 28, 2019, 01:45:22 PM »
No errors in install. Mods listed in signature. Modlog attached.
2.0.17, ssl, php 7.3.19, 10.3.21-MariaDB
Mods: Contact Page, Like Posts, Responsive Curve, Search Focus Dropdown, Add Join Date to Post.

Offline shawnb61

  • On Hiatus
  • SMF Hero
  • *
  • Posts: 2,110
    • sbulen on GitHub
Re: 2.0.16, error removing entries admin log
« Reply #3 on: December 28, 2019, 02:18:13 PM »
Somehow that matches the 2.0.15 version exactly.  No changes were applied to this file at all.  THAT doesn't make sense... 

Attached is the 2.0.16 equivalent.  You should be able to just swap out the file since there were no changes in your 2.0.15 version.

Hope this helps. 

Address the process rather than the outcome.  Then, the outcome becomes more likely.   - Fripp

Offline a10

  • Charter Member
  • Sr. Member
  • *
  • Posts: 993
Re: 2.0.16, error removing entries admin log
« Reply #4 on: December 28, 2019, 02:55:19 PM »
Applied that modlog, still the error & entries not going away. Approx 20 entries.

Wondering if it's only the old entries from 2.0.15, and any new ones from 2.0.16 will be deletable.
Can produce some fresh entries, can the 24h 'lock' be removed so I can test immediately?
$context['hoursdisable'] = 24;  ...would 0 produce any explosions? :O)

Edit: did the above, same with fresh .16 entries as old from .15
"Database error, given array of string values is empty. (uneditable)"

And btw same problem with Moderation Log.


« Last Edit: December 28, 2019, 03:12:16 PM by a10 »
2.0.17, ssl, php 7.3.19, 10.3.21-MariaDB
Mods: Contact Page, Like Posts, Responsive Curve, Search Focus Dropdown, Add Join Date to Post.

Offline shawnb61

  • On Hiatus
  • SMF Hero
  • *
  • Posts: 2,110
    • sbulen on GitHub
Re: 2.0.16, error removing entries admin log
« Reply #5 on: December 28, 2019, 03:30:29 PM »
Confirmed.  It's a bug. 

GDPR OFF, but mod & admin log ON, you will get this trying to clear your log.

I'll move this to the Bug Reports board.

THANX for the report. 

Logged as #102
Address the process rather than the outcome.  Then, the outcome becomes more likely.   - Fripp

Offline a10

  • Charter Member
  • Sr. Member
  • *
  • Posts: 993
Re: 2.0.16, error removing entries admin log
« Reply #6 on: December 28, 2019, 03:43:29 PM »
Thanks for following up. ftm can delete stuff in db table if needed.
2.0.17, ssl, php 7.3.19, 10.3.21-MariaDB
Mods: Contact Page, Like Posts, Responsive Curve, Search Focus Dropdown, Add Join Date to Post.

Offline shawnb61

  • On Hiatus
  • SMF Hero
  • *
  • Posts: 2,110
    • sbulen on GitHub
Re: 2.0.16, error removing entries admin log
« Reply #7 on: December 28, 2019, 03:46:59 PM »
The part that baffles me that the file attached above is from 2.0.15...   :o

You're clearly running 2.0.16 code, though, as those line #s wouldn't otherwise make sense. 

Address the process rather than the outcome.  Then, the outcome becomes more likely.   - Fripp

Offline a10

  • Charter Member
  • Sr. Member
  • *
  • Posts: 993
Re: 2.0.16, error removing entries admin log
« Reply #8 on: December 28, 2019, 04:02:23 PM »
Argh :o  was a modlog from the files backup taken right before installing .16
So that clears up that part. Sorry for the confusion, good spotting from your side.

And tested with enabled gdpr, all is indeed well, quite special interaction :)

2.0.17, ssl, php 7.3.19, 10.3.21-MariaDB
Mods: Contact Page, Like Posts, Responsive Curve, Search Focus Dropdown, Add Join Date to Post.

Offline m4z

  • 98.8% chimp
  • Localizer
  • Sophist Member
  • *
  • Posts: 1,109
  • /mɛs/
Re: 2.0.16, error removing entries admin log
« Reply #9 on: December 29, 2019, 04:56:27 PM »
Also applies to Moderation log entries:
Quote
Database error, given array of string values is empty. (uneditable)
Function: ViewModlog
Apply Filter: Only show the errors from this file
File: /home/rootpath/public_html/smfpath/Sources/Modlog.php
Line: 80


Edit: I see the fix already includes this. <3
"Faith is what you have in things that don't exist."
--Homer Simpson

Offline Vanomas

  • Newbie
  • *
  • Posts: 2
Re: 2.0.16, error removing entries admin log
« Reply #10 on: January 03, 2020, 10:30:16 AM »
I also can confirm this for admin and moderator log even after 24 hours.
SMF 2.0.17
MySQL: 5.7.17
PHP: 5.6.3

Offline BillLeeDee

  • Jr. Member
  • **
  • Posts: 101
Re: 2.0.16, error removing entries admin log
« Reply #11 on: January 04, 2020, 08:43:48 PM »
Same error with clean install of 2.0.17. Glad I left my directory of 2.0.15 to go back to.

Offline Scooter Trash

  • Semi-Newbie
  • *
  • Posts: 34
Re: 2.0.16, error removing entries admin log
« Reply #12 on: March 30, 2020, 09:59:09 PM »
Is there a fix for this yet?

If not, which database table/s are the moderation log and administration log located in?

Offline shawnb61

  • On Hiatus
  • SMF Hero
  • *
  • Posts: 2,110
    • sbulen on GitHub
Re: 2.0.16, error removing entries admin log
« Reply #13 on: April 02, 2020, 02:09:27 PM »
There is a fix for this coming in 2.0.18. 

In the meanwhile, if you have very high volume activity in these logs & really need to clear them out occasionally, the following should work.  (Me, I'm just waiting for 2.0.18 myself...)

Code: [Select]
DELETE FROM `smf_log_actions`
WHERE id_log IN (2,3)
AND action NOT IN ('agreement_updated', 'policy_updated');

Notes:
 - This will delete them regardless of time
 - id_log of 2 = mod log; 3 = admin log
 - You may need to change the table prefix to match your forum setting
Address the process rather than the outcome.  Then, the outcome becomes more likely.   - Fripp

Offline Scooter Trash

  • Semi-Newbie
  • *
  • Posts: 34
Re: 2.0.16, error removing entries admin log
« Reply #14 on: April 02, 2020, 02:26:22 PM »
There is a fix for this coming in 2.0.18. 

In the meanwhile, if you have very high volume activity in these logs & really need to clear them out occasionally, the following should work.  (Me, I'm just waiting for 2.0.18 myself...)

Code: [Select]
DELETE FROM `smf_log_actions`
WHERE id_log IN (2,3)
AND action NOT IN ('agreement_updated', 'policy_updated');

Notes:
 - This will delete them regardless of time
 - id_log of 2 = mod log; 3 = admin log
 - You may need to change the table prefix to match your forum setting


Thanks Shawn.


Offline aED

  • Sr. Member
  • ****
  • Posts: 992
  • Gender: Male
    • Free internet UBT/FBT - Opera Mini
Re: 2.0.16, error removing entries admin log
« Reply #15 on: July 28, 2020, 09:44:07 PM »
Do we have an ETA for 2.0.18?

Offline m4z

  • 98.8% chimp
  • Localizer
  • Sophist Member
  • *
  • Posts: 1,109
  • /mɛs/
Re: 2.0.16, error removing entries admin log
« Reply #16 on: July 29, 2020, 02:01:33 AM »
"Faith is what you have in things that don't exist."
--Homer Simpson