Open vincentdavis opened 11 months ago
We could add an increasing value or the actual ID number as a suffix in cases of duplicates.
I suppose a problem with company names too is that they change over time if they get bought out or rebrand themselves.
If some names/descriptions aren't unique, we should probably make them unique, for example by making them Services.XIAOMI_INC_1
, Services.XIAOMI_INC_2
, and so on? Edit: the actual ID number, like @dlech suggests, even seems better as a stable value.
There's another issue that I'm thinking about now. The data sources we're using (Bluetooth SIG, IEEE OUIs, Nordic's database) regularly change/update those descriptions, for example after a company acquisition. As a result, our enums will change. An application that is using the value Services.STOLLMANN_E_V_GMBH
suddenly won't work anymore if it's called Services.TELIT_WIRELESS_SOLUTIONS_FORMERLY_STOLLMANN_E_V_GMBH
in a new version of the database. This will require careful communication of breaking changes in each release.
An application that is using the value
Services.STOLLMANN_E_V_GMBH
suddenly won't work anymore if it's calledServices.TELIT_WIRELESS_SOLUTIONS_FORMERLY_STOLLMANN_E_V_GMBH
in a new version of the database.
Ideally we wouldn't remove Services.STOLLMANN_E_V_GMBH
and we would have Services.TELIT_WIRELESS_SOLUTIONS
without the formerly part with both enums having the same value. But this would be difficult to automate.
@dlech request a feature in issue #42 using enum s for rever_lookup that works something like:
Looking into this a bit there is a problem with the uniqueness of the names and descriptions, of each id. What to do?
looking into this a bit more:
and