Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I'm curious to find out the process/philosophy behind removing deprecated functions from core.

The Codex says this:

These functions below have been deprecated. That means they have been replaced by new functions or are no longer supported, and may be removed from future versions.

Since 'may be removed' is a bit ominous and somewhat unclear, I have the following questions.

  1. What is the criteria for deletion of a deprecated function? (i.e. version gap, time-frame, security risk, etc...)
  2. Is the deletion of a function communicated to the public officially?

For example: get_postdata() has been deprecated since 1.5.1 and doesn't have an official Codex page. Is there a reason this is still around other than to support older versions of WordPress?

share|improve this question
    
WordPress clearly states that it isn't backwards compatible (or, at least, doesn't care about it). The only reason I can imagine, is that they don't want to break all those outdated plugins. –  kaiser Feb 29 '12 at 18:28
    
There was some discussion a couple years ago to have a set number of releases between deprecation and removal, but at the time deprecation was poorly handled. There were a number of functions that did not have an @deprecated version number filled in, certain functions were widely used by loosely maintained plugins, and so on. It doesn't seem like there was any real resolution to the matter either. –  SickHippie Feb 29 '12 at 20:53
    
@SickHippie Can you please make your comment an answer? –  Brian Fegter Feb 29 '12 at 21:35
    
@BrianFegter - sure thing! –  SickHippie Feb 29 '12 at 22:32
add comment

4 Answers

up vote 8 down vote accepted

To the best of my knowledge, and having heard Nacin say it explicitly, no deprecated function has ever been removed from WordPress to date.

No guarantees for the future, but it's never happened yet. Still, avoid deprecated functions.

share|improve this answer
    
That's exactly what I wanted to know. Thanks for the input. –  Brian Fegter Mar 1 '12 at 4:06
    
See? There you go. :) –  Dougal Campbell Mar 1 '12 at 14:18
add comment

There was some discussion a couple years ago to have a set number of releases between deprecation and removal, but at the time deprecation was poorly handled. There were a number of functions that did not have an @deprecated version number filled in, certain functions were widely used by loosely maintained plugins, and so on. It doesn't seem like there was any real resolution to the matter either.

share|improve this answer
add comment

Don't take it as anything official, but I seem to recall one of the core devs saying something to the effect that they don't have plans to permanently remove any of the deprecated functions in the foreseeable future. That's not to say it won't happen eventually, though. If you see a function that doesn't have a Codex page, add it!

share|improve this answer
    
Great answer. :) The name Nacin clinched the answer. Thanks for your input. –  Brian Fegter Mar 1 '12 at 15:15
add comment

There is no "criteria" or whatever

…like in most other places.

share|improve this answer
    
I know it's not documented. I was hoping someone who's had these discussions in core development would chime in here. :) –  Brian Fegter Feb 29 '12 at 18:30
1  
You might find this an interesting read. –  kaiser Feb 29 '12 at 18:41
    
Cool thanks! (filler text) –  Brian Fegter Feb 29 '12 at 18:50
1  
Well it sounds plausible, considering the code behind WP. They care more about compatibility than any other factors, like performance, extensibility etc. –  onetrickpony Feb 29 '12 at 22:44
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.