question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Write more prominent log messages when no backends are found

See original GitHub issue

Summary

When no backends are found, tiny, easy to miss log messages are written:

[Core] Msg: Initializing ISystemBackend...
[Core] Msg:   No system backend...
[Core] Msg: Initializing IGraphicsBackend...
[Core] Msg:   No Graphics...
[Core] Msg: Initializing IAudioBackend...
[Core] Msg:   No Audio...
[Core] Msg: Initializing IEditorGraphicsBackend...
[Core] Msg:   No Editor Graphics...

Shortly after, things collapse in a cascade of exceptions.

It might be better to make these log messages more prominent instead, and note that this may result in issues?

I understand that there is no special case handling where no backend is found; it’s just the dummy backends’ names that are printed, not actual warnings. This means it won’t be easy to make them into warnings or errors.

Analysis

  • This may potentially help users identify why their Duality setup crashes easier.
  • However, making them warnings/errors might throw off people working on headless versions of Duality with plugins intentionally missing.
  • The no-brainer approach would be to add “this may cause issues with Duality” to the messages. Perhaps in all caps to be more eye-catching?
[Core] Msg: Initializing ISystemBackend...
[Core] Msg:   No system backend (THIS MAY CAUSE ISSUES WITH DUALITY)...
[Core] Msg: Initializing IGraphicsBackend...
[Core] Msg:   No Graphics (THIS MAY CAUSE ISSUES WITH DUALITY)...
[Core] Msg: Initializing IAudioBackend...
[Core] Msg:   No Audio (THIS MAY CAUSE ISSUES WITH DUALITY)...
[Core] Msg: Initializing IEditorGraphicsBackend...
[Core] Msg:   No Editor Graphics (THIS MAY CAUSE ISSUES WITH DUALITY)...
  • Preferably, though, these cases should be a warning (or error?).

Thoughts?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:1
  • Comments:8 (8 by maintainers)

github_iconTop GitHub Comments

2reactions
mfepcommented, Sep 13, 2017

I think the all caps solution is somewhat weird - in an unprofessional manner. I think that the best thing we could do is to promote these messages to the warning status.

0reactions
ilexpcommented, Oct 3, 2017

Implemented by @SirePi

Read more comments on GitHub >

github_iconTop Results From Across the Web

5 Useful Log Messages For a Backend Developer
As a backend developer, I found these 5 logs to be the most useful. Handler Request and Response. Pretty obvious candidates to log...
Read more >
No backend available · Issue #120 · pyusb/ ...
Hello,when I use pyusb.It occured a error.I don't know how to solve it. All the error : dev = usb.core.find(idVendor=0x0416,idProduct=0x5011)
Read more >
Logging
CONFIG_LOG_FRONTEND_ONLY : No backends are used when messages goes to frontend. CONFIG_LOG_CUSTOM_HEADER : Injects an application provided header into log.h.
Read more >
Logging Best Practices: The 13 You Should Know | DataSet
4. Write Meaningful Log Messages. This might probably be the most important best practice. There's nothing worse than cryptic log entries ...
Read more >
Logger v1.13.4
Backends. Logger supports different backends where log messages are written to. The available backends by default are: :console - logs messages to the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found