Meta Tags by Path uses two functions whose names start with _, which normally is pre-appended to the functions that other modules should not use. As a matter of fact, _nodewords_get_possible_tags() has been changed for 6.x-1.x-dev, and now Meta Tags by Path doesn't work anymore with that version (and possibly, with the next official version).

My plan is to add a function for third-party modules, or to rename _nodewords_get_possible_tags() in nodewords_get_possible_tags().

Comments

univate’s picture

This is the issue with providing hooks to allow modules to extend the functionality - you are limited in api changes you can make without potentially effecting other modules. I don't think this needs to be a big issue, if the api need to be changed then also increase the major version number and we can make a note on the project page that 1.x of this module is compatible with nodewords 1.x etc...

I guess in this specific case the problem is the change may only be in a private function (has the prefix '_'), so that may not be considered an api change? Although if you are adding public functions that is an api change isn't it?

apaderno’s picture

Actually, the function the module is using should have never been used, if not from Meta tags. A function that is someway marked as private (as much as that is possible with PHP 4 that doesn't support the private keyword) is not part of a public API.

univate’s picture

I agree it probably shouldn't have been used. But there is no point debating whether it should have been 'public' from the start or whether nodewords_by_path module should have implemented the functionality again itself.

I was just proposeing that the if you increase the major version of nodewords this module can make it clear on the project page that you need a specific version for this to work.

Any modules that provides hooks, like nodewords does really needs to always increase major version numbers if any api changes are made, since that is the only way it can be clear that the changes where substantial and my impact on other dependencies.

apaderno’s picture

I was just proposeing that the if you increase the major version of nodewords this module can make it clear on the project page that you need a specific version for this to work.

I cannot increase the version of Meta tags, because version 6.x-2.x-dev is developed from Robrecht Jacques.
I have not looked at his code, but it's probable Meta Tags by Path would not even work with the 6.x-2 branch of Meta tags.

There is not really an API change, anyway, in this case because I changed a function that was intended to be used from the module that defines it.
The only solution would be to duplicate the same code used by Meta tags in Meta Tags by Path; that is the reason I asked about merging Meta Tags by Path into Meta tags.

apaderno’s picture

Issue summary: View changes
Status: Active » Closed (outdated)

I am closing this issue, which is for a not supported Drupal version.