@sgiehl opened this Issue on October 24th 2014 Member

As soon as an API is marked as deprecated it is not possible anymore to call them.
Example:
http://demo.piwik.org/index.php?module=API&method=Live.getLastVisitsForVisitor&idSite=1&format=JSON

Those APIs should still be usable until they are removed. (Otherwise we could remove them directly)
As that breaks BC in some way, we should try to fix that asap.

@tsteur commented on October 27th 2014 Owner

True! Problem seems to be here https://github.com/piwik/piwik/blob/master/core/API/Proxy.php#L463 . In this case it seems to be caused by <a class='mention' href='https://github.com/ignore'>@ignore</a> and <a class='mention' href='https://github.com/deprecated'>@deprecated</a> as the method is tagged with both. I'm surprised about the <a class='mention' href='https://github.com/ignore'>@ignore</a>. If a method is not supposed to be available in the API it should not be in this class but in a Model or other class. Needs to be refactored...

When did it stop to work? Looks like this code is already there for a while

@sgiehl commented on October 27th 2014 Member

I don't know since when it's not working. Just noticed it as I'm about to
deprecate some parts of the usersettings API and wanted to add some test
that check that the API methods are still callable...
And a @deprecated seems to be enough to make the API uncallable.

@tsteur commented on October 28th 2014 Owner

I'm going to create an issue for removing all methods out of API.php that have an <a class='mention' href='https://github.com/ignore'>@ignore</a> tag. Edit: See #6535

This Issue was closed on October 28th 2014
Powered by GitHub Issue Mirror