I am proposing to do something about the "Broken NVIDIA RandR detected" error line, i think that this error serves no good purpose.
Motivation: * fallback
Firstly, if wine merely switches to a fallback in case of a problem - that's not an error, that's an expected and handled issue that is successfully worked around. If there are potential issues with the workaround - that's what should be noted.
Programs run with wine do work well (enough) when this "error" is present. I do understand that you can change certain settings to change the codepath so that this error to not appear, is this actually necessary to fix an actual problem? Sending someone on a path to fix this "error" when the program they're running is working perfectly well is not a great thing.
* calling it an error
More commonly, wine output is ignored when everything is running correctly, and only looked at when problems arise, so if you log an "error" around the time that a different issue happens it is reasonable to assume that the user will treat the error as the cause of the problem. So we end up with lots of threads like this: https://forum.winehq.org/viewtopic.php?t=32583 quote:
"Please don't title a forum thread with:Broken NVIDIA RandR detected, falling back to RandR 1.0. **This is totally meaningless and does not provide any description - what-so-ever - of what the thread is about. ** Wine outputs this terminal message, for anyone using the Nvidia proprietary driver. Whether they have a crappy, ancient video card or a shiny new Geforce RTX 2080 Ti ! **I patch out this warning message, on my Gentoo wine ebuild's, because it is so annoying.**
* error spam
So it confuses inexperienced users very much. I shouldn't have to point out the search engine keyword irrelevancy. But even for experienced users (the quoted user uses gentoo), it is annoying enough to patch out. If the quoted example wasn't enough here's a random pastebin from 2022 i found removing the line: https://pastebin.com/6auSsL4B, and i've got at least one personal example of someone patching the error out. It is repeated just too frequently. Spam makes reading more important errors harder too.
* recommending nouveau
This line is in a codepath commonly used in games. Recommending nouveau to usually inexperienced linux users - gamers is a horrible idea. Don't get me wrong, i'm all for a free solution, i'd love for nouveau to be just as good, but it is simply not. For a user without a reasonable understanding of linux a messup with video drivers costs a complete reinstall. Mindshare of free software is probably out of scope for wine, but i'm sure we can agree there's some general value there.
There is a wiki entry about this error: https://gitlab.winehq.org/wine/wine/-/wikis/FAQ#broken-nvidia-randr-detected... It all generally makes sense, and if you read it carefully it does say "for users who do not need the proprietary driver", but for an inexperienced user that's an encouragement that assumes they do not in fact need the proprietary driver. Also if you do understand what RandR is you're likely to understand that a program not launching for example probably isn't related to the "error", though i think even a knowing user would still consider it a possibility.
* keywords used
The workaround described under that is of legitemate value, but i think the correlation between the "error" keywords and the actual problematic behavior is not great. If we wish to point the user towards the workaround the line should be something along the lines of "program starts fullscreen at low resolution".
* code
I am not a maintainer and am not experienced enough to just pick up a codebase like this, so i'll start off with admitting i don't really know the specifics of the code. But just by looking at it, the comment on line 511 in dlls/winex11.drv/xrandr.c says that the check that causes the "error" line to print just checks if the driver is nvidia? Isn't that not even checking the specific behavior that it supposedly doesn't implement? (if it was fixed since that code was written)
Proposed solutions: Plain and simple - delete the line. This would solve all the problems mentioned above, perhaps with the exception of >keywords used. This pull request.
Change the message type to debug or trace or similar. This would address >calling it an error
Only print error on first use of function or in startup. This would address >error spam
From: hp hp@local
--- dlls/winex11.drv/xrandr.c | 2 -- 1 file changed, 2 deletions(-)
diff --git a/dlls/winex11.drv/xrandr.c b/dlls/winex11.drv/xrandr.c index d4c9e87be3b..b1946fc8250 100644 --- a/dlls/winex11.drv/xrandr.c +++ b/dlls/winex11.drv/xrandr.c @@ -511,8 +511,6 @@ static BOOL is_broken_driver(void) /* Check if it is NVIDIA proprietary driver */ if (XQueryExtension( gdi_display, "NV-CONTROL", &major, &event, &error )) { - ERR_(winediag)("Broken NVIDIA RandR detected, falling back to RandR 1.0. " - "Please consider using the Nouveau driver instead.\n"); pXRRFreeScreenResources( screen_resources ); return TRUE; }
### AI-generated Summary (verified)
The contributor proposes removing the "Broken NVIDIA RandR detected" error message from Wine for these reasons:
1. **Mischaracterized as an error**: The message appears when Wine successfully falls back to a working alternative, not when something actually breaks.
2. **Creates confusion**: Users see this "error" and try to fix it unnecessarily, even when their applications are running perfectly.
3. **Generates support noise**: Many forum threads are created by confused users about this message that doesn't actually indicate a problem.
4. **Error spam**: The message appears repeatedly, making it harder to spot actual issues and annoying experienced users who often patch it out themselves.
5. **Poor recommendation**: The message indirectly encourages using Nouveau drivers which may be inappropriate for gaming use cases.
The contributor proposes three potential solutions: - Delete the message entirely (preferred) - Change the message type to debug/trace level - Only print the message once during startup
I would rather suggest detecting broken old NVIDIA driver versions *specifically*, that are actually affected by this issue. I assume the latest NVIDIA open drivers (for Turing or newer) aren't affected?
### AI-generated Summary (verified)
What was the point of this?
I would rather suggest detecting broken old NVIDIA driver versions _specifically_, that are actually affected by this issue. I assume the latest NVIDIA open drivers (for Turing or newer) aren't affected?
That's what we do. The actual problem with NVidia is that it only reports one screen mode in xrandr 1.2, which is just wrong and broken. We check that, and then we check whether the driver is in fact an NVidia driver.
What was the point of this?
I was trying to make a point that, while I *do* appreciate the effort the author put into describing the motivation as well as frustration, people in my experience are going to skim long wall of text or even misread the intention.
I wanted it to serve as a wake-up call that, absent a summary, some people will just put it into generative AI and take whatever hallucination it would make, resulting in unnecessary confusion. (although in the case of the summary above I checked to be mostly correct.)
Long descriptions are not inherently bad (in fact that's what I often do too!), but the author should spend some time concluding it with an accompanying summary. It would also save the reviewer's time.