News Feed

News Archive
feed this:

Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Mattias Noback:
Backwards compatible bundle releases
September 29, 2014 @ 12:31:09

In his latest post Matthias Noback talks about a problem common to Symfony bundles (and, well, software in general) - dealing with backwards compatibility and breaks that could be introduced with new changes.

With a new bundle release you may want to rename services or parameters, make a service private, change some constructor arguments, change the structure of the bundle configuration, etc. Some of these changes may acually be backwards incompatible changes for the users of that bundle. Luckily, the Symfony DependenyInjection component and Config component both provide you with some options to prevent such backwards compatibility (BC) breaks.

He breaks the post up into a few different kinds of backwards compatibility breaks that could happen and code examples of each:

  • Renaming things
  • Changing visibility
  • Changing values

Each topic also includes methods for preventing issues with older users who maybe aren't using the new features. This includes things like sane default values for new settings, renaming services and creating new extensions for working with new properties.

0 comments voice your opinion now!
symfony bundle backwards compatibility changes prevent rename visibility values


Derick Rethans:
On Backwards Compatibility and not Being Evil
August 22, 2014 @ 09:20:55

Derick Rethans has shared some of his thoughts on how to not be evil when it comes to making changes in languages like PHP. He suggests that any backwards compatibility break should be treated with the weight it deserves and not just thrust upon users.

This is a repost of an email I sent to PHP internals as a reply to: "And since you're targetting[sic] the next major release, BC isn't an issue." This sort of blanket statements that "Backwards Compatibility is not an issue" with a new major version is extremely unwarranted. Extreme care should be taken when deciding to break Backwards Compatibility. It should not be "oh we have a major new version so we can break all the things"

He talks about the two kinds of backwards compatibility breaks: obvious things where features are removed or changed in a major way and subtle changes in how the underlying code for PHP works ("subtle changes"). He points out that most of the frustrations from users comes from the second type, making for a slower adoption rate and maybe not even adopting at all.

Can I please urge people to not take Backwards Compatibility issues so lightly. Please think really careful when you suggest to break Backwards Compatibility, it should only be considered if there is a real and important reason to do so.
0 comments voice your opinion now!
evil backwards compatibility break major version opinion

Just a warning, 5.5.13 introduces a backwards incomaptability
June 02, 2014 @ 11:56:16

In this recent post to, they point out a recent change in the core of PHP that could cause problems with backward compatibility: a change in the serialization handling to check for implementation of the Serializable interface.

Strings requiring unserialization of objects are now explicitly checked whether the object they contain implements the Serializable interface. This solves the situation where manipulated strings could be passed for objects using Serializable to disallow serialization. An object implementing Serializable will always start with "C:" in the serialized string, all other objects are represented with starting "O:". Objects implementing Serializable to disable serialization using zend_class_unserialize_deny and zend_class_serialize_deny, when instantiated from the serializer with a manipulated "O:" string at the start, will most likely be defectively initialized. This is now fixed at the appropriate place by checking for the presence of the serialize callback in the class entry.

The change corrects a bug that has been used, in certain cases, as a work-around to create objects without calling the constructor. The correct fix for it, if you're using it in your own applications, is to call ReflectionObject::newInstanceWithoutConstructor.

0 comments voice your opinion now!
backwards compatibility break serialize


HipHop VM Blog:
Compatibility Update
April 22, 2014 @ 09:16:38

The HipHop VM blog has a new post today with some updates around the compatibility work they're doing getting popular PHP projects to work 100% on the platform (and have all unit tests pass).

Earlier this year we set an ambitious goal of passing the PHPUnit test suites of 20 popular frameworks by the end of June; at the time, we were passing on only 6! With a huge amount of help from the community (especially our OpenAcademy students), we're proud to have hit this goal more than 2 months early, and we have more frameworks expected to reach 100% shortly.

Included in their list of projects/frameworks are things like Assetic, Composer, Doctrine2, Guzzle (v3), Laravel, Mockery and Monolog. Now that they've made significant strides to get the HHVM up to a greater level of compatibility, they're going to focus in on the issues list from GitHub to resolve problems there.

0 comments voice your opinion now!
compatibility update framework project unittest bugs issues


Anthony Ferrara:
An Opinion On The Future Of PHP
March 10, 2014 @ 09:41:40

In his latest post Anthony Ferrara shares some of his personal opinions about the future of PHP and how some of the pieces in play now might fit in.

There's been a lot of buzz in the community lately around PHP and its future. The vast majority of this buzz has been distinctly positive, which is awesome to hear. There's been a lot of talk about PHP6 and what that might look like. There's been a lot of questions around HHVM and its role in the future of the language and community. Well, let me share with you some of my thoughts in this space...

He covers a few different topics including backwards compatibility, the suggestions of a complete engine rewrite and turning the SPL all OOP. He spends most of the post talking about HHVM (the HipHop VM), how it compares to "plain old PHP" and why it's not exactly "magic".

0 comments voice your opinion now!
opinion future language hhvm hack engine backwards compatibility


Fabien Potencier:
About Symfony Stability over Features
April 15, 2013 @ 10:12:34

Fabien Potencier (of the Symfony framework) has a new post to his site talking about a philosophy that the Symfony framework community should work towards, providing stability over features.

Long story short: in the coming months, the Symfony core contributors should focus their efforts toward stabilizing the existing features instead of working on new ones. At this point, backward compatibility and stability are more important than everything else.

He highlights some of the points that come along with this effort including less refactoring for the sake of refactoring, fixing more bugs/edge cases and writing more tests/documentation. He gets into some of the specifics of this kind of thinking and points out the things that can and can't be changed during this time. He talks more about stability and suggests that not only can it help enhance performance but it could also help motivate more projects/corporate users to start using the framework.

0 comments voice your opinion now!
symfony stability features framework initiative tests bugs backward compatibility


Andrew Podner:
PHP 5.5 Preview New Password Hashing API
March 25, 2013 @ 12:32:26

Andrew Podner has posted about the password hashing functionality that's coming with PHP 5.5 - how it will work and some of the benefits of its use.

Recently PHP 5.5 was released into beta, which puts us one step closer to another release of PHP. This week, I thought I would spend a little time explaining a new feature that will be implemented in 5.5 that will hopefully make dealing with passwords easier for developers to grasp and properly implement. I cannot tell you the number of apps, even ones written within the last year or so, that I open up only to find either an md5 hash, or worse, clear text password storage. I keep telling myself that eventually this will come to an end, and people will stop taking the easy way out. Maybe PHP 5.5 will have made it so easy that there is simply no further excuse not to implement solid password hashing.

He includes an example of the four new functions that will come with the hashing functionality: password_get_info, password_hash, password_needs_rehash and password_verify. He includes the parameters that should be included in each call and the details from the call to get the hash's info. If you're not going to be able to move up to PHP 5.5 when it's released, you might consider looking into this compatibility library to have a similar interface and functionality (for 5.3.7 or greater).

0 comments voice your opinion now!
preview password hashing api compatibility library introduction

Sebastian Marek's Blog:
PHP 5.4 Compatibility Coding Standard for PHP_CodeSniffer
March 02, 2012 @ 10:52:32

In the wake of the official release of PHP 5.4 Sebastian Marek has made a quick post to his blog about bringing PHP_CodeSniffer rules help bring his code up to date with this latest version.

So with PHP 5.3 upgrade underway (and PHP 5.4 out of the door now!) I thought it's time to prepare for PHP 5.4 and make sure we're compatible. So by looking at Wim Godden's PHP53Compatibility code sniffs I have created a base for PHP 5.4 sniffs that we want to use to make sure we're compatible.

Sniffs included in set are:

  • PHP54Compatibility_Sniffs_PHP_BreakContinueVarSyntaxSniff
  • PHP54Compatibility_Sniffs_PHP_DeprecatedFunctionsSniff

You can grab this custom set of sniffs either from his github repository or from his personal PEAR channel if you'd rather install it that way (alpha channel).

0 comments voice your opinion now!
phpcodesniffer compatibility coding standard upgrade

Robert Basic's Blog:
A real gem - PHP_CompatInfo
December 28, 2010 @ 09:34:40

In this new post to his blog Robert Basic takes a look at what he calls a "real gem" in defining the requirements of his application - PHP_CompatInfo.

Last night I was pondering how nice would it be to have a tool of some sort, that would simply spit out what version of PHP does my app require. Something like: here are my .php files, what PHP version and/or extensions do I need for it? First I thought about jumping right in and writing it myself, but hey, this kind of a tool sounds way to useful not to be written already! After a bit of a googling there it was: PHP_CompatInfo. A nice PEAR package that can tell me everything I want about my code and even a bit more.

He includes a code snippet showing it in action. It's a basic example that defines the driver type to use, options and the directory to parse through (using parseDir() naturally). Other output formats are available too like CSV and HTML.

0 comments voice your opinion now!
phpcompatinfo pear package compatibility requirement

Ibuildings Blog:
Supporting a PHP migration
August 19, 2010 @ 11:19:23

On the Ibuildings blog today Andy Thompson has a new post looking at some of the challenges of migrating PHP applications up from the now end-of-development-life PHP 5.2.x versions up to PHP 5.3.

According to a recent Twitter poll, we found that over 50% of developers are already working with the latest 5.3 release. An additional 35% is already in the process of migrating to 5.3. This means that the majority of developers see the importance of upgrading and are already taking action, well before PHP's announcement.

He talks about how common migrations like this are in the IT industry and how dealing with multiple releases can only cause more issues. He also mentions some of the keys to successful migrations like compatibility testing and checking of any custom code you might have implemented in your codebase.

0 comments voice your opinion now!
support migration compatibility testing opinion

Community Events

Don't see your event here?
Let us know!

install opinion api podcast community framework symfony update release zendserver laravel interview library series language package tips deployment introduction list

All content copyright, 2014 :: - Powered by the Solar PHP Framework