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