I was brainstorming a little and I came to the conclusion that as a module maintainer you sometimes just wish to use a module's code and not its features. In these cases, it is useless to fully load those modules and execute their hook implementations. Rather we should just make sure they're there to be called upon when needed. If we do this, we improve performance by loading and executing less code and by preventing the UI from getting cluttered with features the user actually doesn't need.

Comments

killes@www.drop.org’s picture

Priority: Normal » Minor

I've only seldomly encountered such a use case. If I'd encounter it, I could include() the code myself.

xano’s picture

I have come across quite a lot of situations in which loading code but not executing its hooks would be welcome. Also, including the code doesn't tell the user the code is required and should not be removed like with current dependencies.

sun’s picture

Status: Active » Postponed (maintainer needs more info)

Why doesn't module_exists() work for this case?

xano’s picture

Because then you don't show users module X really needs module Y to function.

catch’s picture

Version: 7.x-dev » 8.x-dev
Anonymous’s picture

Status: Postponed (maintainer needs more info) » Closed (won't fix)

As there doesn't seem to be much support for this, I'm going to say this is a won't fix.