-
Notifications
You must be signed in to change notification settings - Fork 66
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
Provide way to deal with distro inconsistencies #109
Comments
I guess we could easily implement a class per special case. Thing is, if we don't do if else here to explicitly provide the distros we know are "problematic", we'll be forcing checking for that consistency throughout all distros even if 99% of them don't have that problem. I'm not saying we shouldn't, just raising it as an issue. My intuition tells me that a "bug which happens once is not a bug". We can specifically specify Linux Mint's condition in the code and return different values for it. If we stumble across additional distros containing this issue, we can start discussing a mechanism. The implementation doesn't have to be ugly. We could state a list of distros which override the type of information returned and put mint in that list. |
To make things easier for us and more consistent across multiple tools imo we should treat bugs in /etc/*-release files as bugs upstream instead of something actionable in Distro. Thoughts from other maintainers? |
While I would absolutely sympathize with this approach, this might mean that things stay broken for a long time. It's sometimes hard to motivate distros to change something in their *-release files, and even if they are willing to, the release cycles might be pretty long. |
I'm with @brejoc here. The reason why you need distro in the first place is to abstract long-term ugliness. |
I'm not sure that this fix is needed though, wouldn't we see more chatter / +1s on this issue if there were widespread problems with distributions identifying incorrectly? Quoting @nir0s from 2016:
I feel we should place our already limited time+focus on new and non-deprecated platforms instead. |
There are Linux distros that have inconsistent information in the data sources that
ld
uses.For example , see issue #78 about Linux Mint. In that case, the precedence implemented by
ld
causes Linux Mint to be shown as an Ubuntu. While it is fairly compatible to Ubuntu, it is not Ubuntu. It has its own name, id, version (Linux Mint 17.3 is based upon Ubuntu 14.04), and code name ("rose" for Linux Mint 17).I think that instead of asking the distros to become consistent, that calls for some mechanism in
ld
to deal with that.We already parse all three data sources if available, and we could find out that the (normalized) IDs are different, and if so, trigger some special-case processing. In the case of Linux Mint, the special processing would be to ignore those data sources that advertise Ubuntu.
I guess the trick is to implement this without getting into endless if-elif-else statements.
The text was updated successfully, but these errors were encountered: