Symfony 2.0 RC4 is now available for download. This release candidate fixes some minor bugs but the main change comes from Doctrine annotations. If you are using the Symfony Standard Edition, you must update your autoload.php file by adding the following code:

// at the top of the file
use Doctrine\Common\Annotations\AnnotationRegistry;

// at the end of the file
AnnotationRegistry::registerLoader(function($class) use ($loader) {
    $loader->loadClass($class);
    return class_exists($class, false);
});
AnnotationRegistry::registerFile(__DIR__.'/../vendor/doctrine/lib/Doctrine/ORM/Mapping/Driver/DoctrineAnnotations.php');

Some bundles have also been renamed to better follow the naming conventions. So, to upgrading a Symfony Standard Edition application, update both the deps and deps.lock files:

Then, run the vendors script:

./bin/vendors install

After upgrading, don't forget to clear your cache:

php ./app/console cache:clear
Published in #Releases