Jump to content

New Hooks in 1.5 RC


Recommended Posts

/**
 * Return retrocompatible hook name
 *
 * @since 1.5.0
 * @param string $hook_name Hook name
 * @return int Hook ID
 */

public static function getRetroHookName($hook_name)

 

As if it is not enough to change the hook names completely in 1.5, what goes into this method and what comes out? Is the parameter to method 1.4 hook name or 1.5 hook name? What is with the l33t method name? If you cannot even add the correct comment for this method, why not self-document it with something like:

 

public static function getNewHookName($oldHookName)

 

And, no it does not return a hook id.

Link to comment
Share on other sites

I think we all need to bear inmind that this is still only a RC, I am sure we would all rather have bugs resolved in the basic product than 300 pages of documentation written and not have a product to go with it... Get it working then go back and explain how it works.

Link to comment
Share on other sites

Did you change the title of this post?

Nope. This is their dominion and they make the changes as and when they please you know. Some has the courtesy to leave a note in the thread, others don't.

 

For the record, If you think "Unberable lightness of PrestaShop development" was not a suitable title for the post, "New Hooks in RC 1.5" is not any better and also misleading. The post I made has nothing to do specifically with new RC 1.5 hooks but happens to mention the situation from a RC 1.5 Hook class client's point of view. It is ONE example of A LOT OF of similar issues with 1.3, 1.4, and now RC 1.5. Maybe a better title would be 'Poor documentation of PrestaShop codebase is not getting any better with RC 1.5"

Link to comment
Share on other sites

Hi Phrasespot,

 

Instead of complaining on the forum why didn't you just make a report on the forge like you did for this one ?

http://forge.prestashop.com/browse/PSCFV-2784 (I'm working on it by the way).

 

I think it can happen to every developer to choose a not clear name function (even for you, right ? :P)

I will see what I can do to make this function name more bearable.

 

Concerning the documentation, we know that there were large lack of documentation in 1.4, but we are trying not to reproduce the same mistake. We have a documentalist now that working hard on documentation for 1.5.

 

Best regards,

Link to comment
Share on other sites

Dear Fabien

 

Instead of complaining on the forum why didn't you just make a report on the forge like you did for this one ?

Because if I attempted to open a bug report for every documentation error I would be spending the next week opening bug reports.

 

I think it can happen to every developer to choose a not clear name function (even for you, right ? :P)

True, true. More often than not after implementing a solution I go back and rename many methods, fields, database columns to have more meaningful, consistent names.

 

Please do not take my above post personally. The examle I gave happens to be from Hook class which I know to be under your responsibility (and it did not help that someone has changed the topic title to give the whole post a different slant). I think your contribution and approach to areas under your responsibility is invaluable and I respect you a lot as a developer.

 

It is not the Hook class, or new 1.5 hooks that is the problem but PrestaShop's overall approach. It does not need a bug fix. It needs a shift in thinking, procedures and quality control.

 

I don't think I am alone here. Everyone who writes code against the PrestaShop's public interface expects to see, clear, unambigious documentation, and some even give up. I am not there yet and still believe a much better PrestaShop is possible.

Edited by phrasespot (see edit history)
Link to comment
Share on other sites

Hi,

 

Because if I attempted to open a bug report for every documentation error I would be spending the next week opening bug reports.

 

Unfortunately, you're right on this part :-/

 

Please do not take my above post personally. The examle I gave happens to be from Hook class which I know to be under your responsibility (and it did not help that someone has changed the topic title to give the whole post a different slant).

 

I do not take it personally, I think I would have answered the same way if you have said something about the class Product.

I know that sometimes code not clear or not well-coded, so do not hesitate to report it on the forge, that's all I'm sayin :)

 

It is not the Hook class, or new 1.5 hooks that is the problem but PrestaShop's overall approach. It does not need a bug fix. It needs a shift in thinking, procedures and quality control.

 

We aware of that, I assure you we are thinking hard about how to improve that for next version (quality check between developers, code documentation, ...).

 

I don't think I am alone here. Everyone who writes code against the PrestaShop's public interface expects to see, clear, unambigious documentation, and some even give up. I am not there yet and still believe a much better PrestaShop is possible.

 

I think so, and I'm glad you help us improving the software. We will do better on this part for next version.

Meanwhile, I'll try to fix / document a maximum before the final.

 

Best regards,

Link to comment
Share on other sites

×
×
  • Create New...