[development] module names and namespaces

Larry Garfield larry at garfieldtech.com
Thu Oct 21 13:48:33 UTC 2010


On Thursday, October 21, 2010 5:26:23 am João Ventura wrote:
> Hi,
> 
> Just wanted to contribute with a different point of view. Regarding the
> original problem, it's my opinion that fb_social did nothing wrong, it's
> your fault for assuming that you own the fb prefix and deleting every
> variable starting with that prefix. You should delete what you know that
> you own. So I second Dave Reid's opinion and suggest that you do a grep of
> variable_?et in your code and convert the results into variable_del calls.
> 
> However, there is indeed a problem here. I maintain the print module, to
> which I have added two sub-modules (print_mail and print_pdf).. Should I
> register those projects in drupal.org so that no one takes those names away
> (since the module is used by >35K sites, it would have to be done by
> someone with bad intentions and manners, but this is just an example). In
> the *_uninstall() of each of those modules, there a LONG list of
> variable_del calls.

That's what this discussion is for:
http://drupal.org/node/145164

> The problem is that I also create some per-content-type variables which are
> named print_display_[content type name], and it's simply not possible to
> know which content types existed at any time between installing the module
> and uninstalling it, that are no longer present. As such, the only solution
> is to delete everything starting with [module name]_display. Should I also
> register the print_display, print_pdf_display and print_mail_display
> projects?

That's what this API hook is for:
http://api.drupal.org/api/function/hook_node_type/6

At least some parts of the issue have very straightforward technical solutions 
that either already exist or are already under discussion.

--Larry Garfield


More information about the development mailing list