Replies: 6 comments
-
I agree that stack traces are not user friendly, the problem I have with one line error messages is that they will be pretty easily overlooked. |
Beta Was this translation helpful? Give feedback.
-
We could maybe make a multi line pretty message or something, the user
friendliness of that specific message has been discussed a few times
…On Mon, 6 Feb 2023, 12:34 MiniDigger | Martin, ***@***.***> wrote:
I agree that stack traces are not user friendly, the problem I have with
one line error messages is that they will be pretty easily overlooked.
Plugin authors resorting to soft depedencies because of bugs in the
current dependency resolution is a different issue, those will hopefully be
fixed with the whole paper plugin and lifecycle api stuff.
—
Reply to this email directly, view it on GitHub
<#8830 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAJMAZFGHAVOLN3QVULL4DTWWDVWLANCNFSM6AAAAAAUSR2U7Q>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
Here's an idea for a multi-line message:
|
Beta Was this translation helpful? Give feedback.
-
What would be the ideal of handling this? The exception is created and passed into the logger - to get this behaviour, it would make the most sense to just not create the exception at all? I'm happy to do this one if it's approved. I think it's a great idea :) |
Beta Was this translation helpful? Give feedback.
-
Unsure if the spacing is too much (it is one tab), but here is an example of what it could look like. |
Beta Was this translation helpful? Give feedback.
-
I haven't checked the internal code, though my thought (which I should have noted) is:
Haven't tried this, just brainstorming. 😄
I think there should be one less vertical space on both sides of the missing dependencies list. I don't mind the tab, in fact, it makes the message stand out more, which is one of the problems we need to resolve for this to be solved. That's personal opinion of course! 👍🏻 |
Beta Was this translation helpful? Give feedback.
-
Hi PaperMC community, I hope you're all doing well :)
I would like to bring attention to, and hopefully have resolved, an issue to do with how hard dependencies are handled by Spigot.
A thread on this identical issue was already created by Andre_601 in 2020, although that thread seems to have dwindled without any official comment on the matter.
When you run a plugin which has 'hard dependencies' (declared via
depend: [...]
inplugin.yml
), and your server does not have one of those hard dependencies installed, then Spigot will print a rather non-user-friendly message to inform about the missing dependency.The following console log was taken from this thread which shows you what this thread is about. The linked thread also serves as one of the many examples where a user believes a plugin is at fault (because they see a stack trace), although they have caused it by not following the plugin's installation instructions.
To us developers, this stack trace is extremely easy to read - the answer is right at the top. But for others, they see all of the Java jargon packed beneath the thing they should have seen, and assume that 'the plugin has a bug so bad that I can't even run it'. It's not user friendly when combined with the exception information.
To resolve this issue, the exception information should not be printed when this exception is caught by Bukkit's plugin loader. I assume this is quite a simple fix. It could look like this when logged to the console:
To get around the non-user-friendly stack trace, myself among other plugin developers declare hard dependencies as soft dependencies instead, and add logic to our
onEnable
methods to enforce these dependencies, which displays more user-friendly messages.I'd greatly appreciate to hear your opinion below on this matter. If you maintain a plugin which has hard dependencies, you've likely come across a user who reports this as a bug to you. It's for this reason that I avoid writing plugins that would require any hard dependency.
Thank you everyone, and all the best.
~ lokka30
Beta Was this translation helpful? Give feedback.
All reactions