Skip to contentSkip to conversation

_FEATURES_BACKFILL_CONSIDERED: confusing variable names?

DISTRO|MACHINE Michael Opdenacker 5 participants 7 messages Feb 23, 2023 – Feb 28, 2023

lore
Share & tools
lore
#0 lore raw

Greetings

Anybody else finding the DISTRO_FEATURES_BACKFILL_CONSIDERED and MACHINE_FEATURES_BACKFILL_CONSIDERED variable names confusing?

According to the documentation about "feature backfilling" (https://docs.yoctoproject.org/ref-manual/features.html#ref-features-backfill), these variables allow to exclude some features from being backfilled.

I'm not a native English speaker, but for me, "considered" carries the intention to include a feature, not to exclude one.

Shouldn't we call these variables DISTRO_FEATURES_BACKFILL_EXCLUDED and MACHINE_FEATURES_BACKFILL_EXCLUDED instead ?

Thanks in advance
Cheers
Michael.

Signature · 3 lines
Michael Opdenacker, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
#1 lore raw
Quoted 5 lines · Michael Opdenacker via lists.yoctoproject.org

Greetings

Anybody else finding the DISTRO_FEATURES_BACKFILL_CONSIDERED and MACHINE_FEATURES_BACKFILL_CONSIDERED variable names confusing?

I believe the history there is that those are "features" that were just always available and couldn't be turned off (e.g. they were implicit). When they became available to be turned off, it was desired to not break existing setups by making them "off by default", so you have to explicitly opt-out of said feature. I always think of it as "I CONSIDERED this features and don't want it"

Quoted 29 lines

According to the documentation about "feature backfilling"
(https://docs.yoctoproject.org/ref-manual/features.html#ref-features-backfill),
these variables allow to exclude some features from being backfilled.

I'm not a native English speaker, but for me, "considered" carries the intention to include a feature, not to exclude one.

Shouldn't we call these variables DISTRO_FEATURES_BACKFILL_EXCLUDED and MACHINE_FEATURES_BACKFILL_EXCLUDED instead ?

Thanks in advance
Cheers
Michael.

--
Michael Opdenacker, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#3728): https://lists.yoctoproject.org/g/docs/message/3728
Mute This Topic: https://lists.yoctoproject.org/mt/97187179/3616693
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/docs/unsub [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

#2 lore raw
In reply to Michael Opdenacker

I agree. The problem I have with these variable names is that it's ambiguous whether the features will be included or excluded from the backfill. All you can tell from the names is that the values were 'considered'. What does that mean? You have to go to the manual to find the full meaning.

What's important about the variables is that they will be 'excluded' from the backfill, so this does look much clearer to me:

	DISTRO_FEATURES_BACKFILL_EXCLUDED += "some-feature"

Is there a good reason why we have this separate variable and can't just do this?

DISTRO_FEATURES_BACKFILL:remove = "some-feature"

Tom

-----Original Message-----
From: [email protected] <[email protected]> On Behalf Of Michael Opdenacker via lists.openembedded.org
Sent: Thursday, February 23, 2023 11:00 AM
To: OE-core <[email protected]>
Cc: YP docs mailing list <[email protected]>
Subject: [OE-core] [DISTRO|MACHINE]_FEATURES_BACKFILL_CONSIDERED: confusing variable names?

Greetings

Anybody else finding the DISTRO_FEATURES_BACKFILL_CONSIDERED and MACHINE_FEATURES_BACKFILL_CONSIDERED variable names confusing?

According to the documentation about "feature backfilling"
(https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdocs.yoctoproject.org%2Fref-manual%2Ffeatures.html%23ref-features-backfill&data=05%7C01%7Ctom.hochstein%40nxp.com%7Cf4e5b1f4523a469612dc08db15bf5d8e%7C686ea1d3bc2b4c6fa92cd99c5c301635%7C0%7C0%7C638127683879148065%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=4i2IX0GpQlQXAh8Jausfvb2o1oF6MBZaU144KHKjcKg%3D&reserved=0),
these variables allow to exclude some features from being backfilled.

I'm not a native English speaker, but for me, "considered" carries the intention to include a feature, not to exclude one.

Shouldn't we call these variables DISTRO_FEATURES_BACKFILL_EXCLUDED and MACHINE_FEATURES_BACKFILL_EXCLUDED instead ?

Thanks in advance
Cheers
Michael.

Signature · 3 lines
Michael Opdenacker, Bootlin
Embedded Linux and Kernel engineering
https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fbootlin.com%2F&data=05%7C01%7Ctom.hochstein%40nxp.com%7Cf4e5b1f4523a469612dc08db15bf5d8e%7C686ea1d3bc2b4c6fa92cd99c5c301635%7C0%7C0%7C638127683879148065%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=S4rZtW35Uxk1ww8OkrPlCJdlI2FWgIpxHcq7PDq2M1o%3D&reserved=0
#3 lore raw

Greetings,

Thank you all for your replies and comments!

Quoted 5 lines · Tom Hochstein

I agree. The problem I have with these variable names is that it's ambiguous whether the features will be included or excluded from the backfill. All you can tell from the names is that the values were 'considered'. What does that mean? You have to go to the manual to find the full meaning.

What's important about the variables is that they will be 'excluded' from the backfill, so this does look much clearer to me:

	DISTRO_FEATURES_BACKFILL_EXCLUDED += "some-feature"

Richard, would you accept it if I sent a patch replacing "BACKFILL_CONSIDERED" by "BACKFILL_EXCLUDED" in the two variables?

Of course, I can understand if that's too late for the next release, and instead document this oddity, at least before we can make a change again.

Quoted 4 lines

Is there a good reason why we have this separate variable and can't just do this?

DISTRO_FEATURES_BACKFILL:remove = "some-feature"

Good question. Maybe because ":remove" is final, and cannot be overridden, if I understood correctly?

Cheers
Michael.

Signature · 3 lines
Michael Opdenacker, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
#4 lore raw
Quoted 9 lines · Michael Opdenacker via lists.openembedded.org

Greetings,

Thank you all for your replies and comments!

Quoted 4 lines · Tom Hochstein

I agree. The problem I have with these variable names is that it's ambiguous whether the features will be included or excluded from the backfill. All you can tell from the names is that the values were 'considered'. What does that mean? You have to go to the manual to find the full meaning.

What's important about the variables is that they will be 'excluded' from the backfill, so this does look much clearer to me:

Quoted 8 lines
Quoted 1 line
	DISTRO_FEATURES_BACKFILL_EXCLUDED += "some-feature"

Richard, would you accept it if I sent a patch replacing "BACKFILL_CONSIDERED" by "BACKFILL_EXCLUDED" in the two variables?

Of course, I can understand if that's too late for the next release, and instead document this oddity, at least before we can make a change again.

I don't want to rush into this. The idea of the variable was that the list were things that distro maintainers would need to consider when upgrading and then "mark as considered" so in that context, excluding them makes less sense. I'm sure there was discussion about the name at the time.

I'm nervous about renaming variables in general as it does create pain for users upgrading and some community feedback has been that we're bordering on frustrating users. I know we have mechanisms now to help but it isn't pain free.

Quoted 7 lines
Quoted 3 lines

Is there a good reason why we have this separate variable and can't just do this?

DISTRO_FEATURES_BACKFILL:remove = "some-feature"

Good question. Maybe because ":remove" is final, and cannot be overridden, if I understood correctly?

Right, the concern would have been it couldn't be undone and the distro setups from when this dates from were more complex.

Cheers,

Richard

#5 lore raw
Quoted 33 lines

-----Original Message-----
From: Richard Purdie <[email protected]>
Sent: Tuesday, February 28, 2023 4:04 AM
To: [email protected]; Tom Hochstein <[email protected]>; OE-core <openembedded- [email protected]>
Cc: YP docs mailing list <[email protected]>
Subject: Re: [OE-core] [DISTRO|MACHINE]_FEATURES_BACKFILL_CONSIDERED:
confusing variable names?

Quoted 6 lines · Michael Opdenacker via lists.openembedded.org

Greetings,

Thank you all for your replies and comments!

Quoted 1 line · Tom Hochstein

I agree. The problem I have with these variable names is that it's ambiguous

whether the features will be included or excluded from the backfill. All you can tell from the names is that the values were 'considered'. What does that mean? You have to go to the manual to find the full meaning.

Quoted 2 lines
Quoted 2 lines

What's important about the variables is that they will be 'excluded' from the

backfill, so this does look much clearer to me:

Quoted 7 lines
Quoted 2 lines
	DISTRO_FEATURES_BACKFILL_EXCLUDED += "some-feature"

Richard, would you accept it if I sent a patch replacing "BACKFILL_CONSIDERED" by "BACKFILL_EXCLUDED" in the two variables?

Quoted 8 lines
Quoted 2 lines

Of course, I can understand if that's too late for the next release, and instead document this oddity, at least before we can make a change again.

I don't want to rush into this. The idea of the variable was that the list were things that distro maintainers would need to consider when upgrading and then "mark as considered" so in that context, excluding them makes less sense. I'm sure there was discussion about the name at the time.

Not sure I understand. When you say 'idea of the variable', are you referring to the BACKFILL variable? I assume so since that seems to be the one that the distro maintainers will 'consider', right? After they've 'considered' the BACKFILL, then they will add the ones they _don't want_ to BACKFILL_CONSIDERED(_AND_NOT_WANTED). The ones they _do want_ are not marked.

Quoted 5 lines

I'm nervous about renaming variables in general as it does create pain for users upgrading and some community feedback has been that we're bordering on frustrating users. I know we have mechanisms now to help but it isn't pain free.

This I totally understand 😊

Quoted 4 lines
Quoted 2 lines
Quoted 2 lines

Is there a good reason why we have this separate variable and can't just do

this?

Quoted 1 line
Quoted 1 line
Quoted 8 lines
Quoted 5 lines
Quoted 1 line

DISTRO_FEATURES_BACKFILL:remove = "some-feature"

Good question. Maybe because ":remove" is final, and cannot be overridden, if I understood correctly?

Right, the concern would have been it couldn't be undone and the distro setups from when this dates from were more complex.

Since every variable is so afflicted by :remove, perhaps this isn't a good argument, particularly when there is a more general pattern for this: to add an extra variable at the point of the removal:

MY_DISTRO_FEATURES_BACKFILL_REMOVALS ??= "some-feature" DISTRO_FEATURES_BACKFILL:remove = "${ MY_DISTRO_FEATURES_BACKFILL_REMOVALS}"

Quoted 5 lines

Cheers,

Richard

#6 lore raw
In reply to Michael Opdenacker
Quoted 14 lines · Michael Opdenacker via lists.openembedded.org

Greetings,

Thank you all for your replies and comments!

Quoted 1 line · Tom Hochstein

I agree. The problem I have with these variable names is that it's

ambiguous whether the features will be included or excluded from the backfill. All you can tell from the names is that the values were 'considered'. What does that mean? You have to go to the manual to find the full meaning.

Quoted 2 lines

What's important about the variables is that they will be 'excluded'

from the backfill, so this does look much clearer to me:

Quoted 1 line
Quoted 9 lines
Quoted 1 line
      DISTRO_FEATURES_BACKFILL_EXCLUDED += "some-feature"

Richard, would you accept it if I sent a patch replacing "BACKFILL_CONSIDERED" by "BACKFILL_EXCLUDED" in the two variables?

Of course, I can understand if that's too late for the next release, and instead document this oddity, at least before we can make a change again.

Whole BACKFILL mechanism was added for easier backwards compatibility with existing DISTROs.

Renaming the variable breaks those DISTROs and personally I don't find the new variables less confusing than the old ones.

I've always read it as: These are the DISTRO_FEATURES which will be automatically BACKFILLED if you don't do anything and if you notice the change and CONSIDER them as not wanted, you opt-out by adding them to BACKFILL_CONSIDERED.

Yes it's confusing, but this whole mechanism wasn't used much, so I'm surprised a bit that people still have to deal with it.

Quoted 10 lines
Quoted 2 lines

Is there a good reason why we have this separate variable and can't just

do this?

Quoted 2 lines

DISTRO_FEATURES_BACKFILL:remove = "some-feature"

Good question. Maybe because ":remove" is final, and cannot be overridden, if I understood correctly?

IIRC BACKFILL mechanism predates :remove operator by quite a bit.

So BACKFILL wa added as very weak sort-of-append to DISTRO_FEATURES and BACKFILL_CONSIDERED was to opt-out from it.

Regards,