Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Should the server log be spammed with warnings every second? #303

Closed
MCLV-pandorabox opened this issue Feb 25, 2023 · 1 comment · Fixed by #334
Closed

Should the server log be spammed with warnings every second? #303

MCLV-pandorabox opened this issue Feb 25, 2023 · 1 comment · Fixed by #334
Labels
Cleanup Cleanup of bad code or other redundant/unnecessary stuff Discussion Good first issue Good for newcomers

Comments

@MCLV-pandorabox
Copy link

get_RE_charge
and set_RE_charge
issue warning to the server log(like a lot)
but contain no real information to resolve the issue (location)
and will happen every time a player puts something that doesn't belong in the charge or discharge port.

Should the warning even be issued?
In it's current form it is quite pointless (unless your point is to produce large server logs)
On a server with lots of new users,putting all kinds of stuff in the charge/discharge ports of battery boxes, who might never return this could get out of hand quickly.
Even if a moderator would be willing to hunt down the object that can't be charged/discharged, he can't easily find it.

Easy fix would be to just remove the warning.

Kind regards,
Keep up the amazing work,
MCLV

@BuckarooBanzay
Copy link
Member

Log output in question:

2023-02-25 20:47:10: WARNING[Server]: technic.get_RE_charge item not registered as power tool: 
2023-02-25 20:47:10: WARNING[Server]: technic.get_RE_charge item not registered as power tool: 
2023-02-25 20:47:10: WARNING[Server]: technic.get_RE_charge item not registered as power tool: 
2023-02-25 20:47:10: WARNING[Server]: technic.get_RE_charge item not registered as power tool: 

Code locations:

minetest.log("error", "technic.set_RE_charge item not registered as power tool: "..stack:get_name())

and:

minetest.log("warning", "technic.get_RE_charge item not registered as power tool: "..stack:get_name())

IMO: the log statement can be removed

@OgelGames OgelGames added the Cleanup Cleanup of bad code or other redundant/unnecessary stuff label Aug 7, 2023
@S-S-X S-S-X closed this as completed in #334 Nov 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Cleanup Cleanup of bad code or other redundant/unnecessary stuff Discussion Good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants